Skip to content

Instantly share code, notes, and snippets.

View biparnakroy's full-sized avatar
🎓
learning

Biparnak Roy biparnakroy

🎓
learning
View GitHub Profile

MongoDB on Ubuntu 20.04

Stop MongoDB

Stop the mongod process by issuing the following command:

sudo service mongod stop

Remove Packages

To overcome the eval error add this in legacy/eval.py

from tensorflow.compat.v1 import ConfigProto
from tensorflow.compat.v1 import InteractiveSession

config= ConfigProto()
config.gpu_options.allow_growth =True
session = InteractiveSession(config=config)

Frame extractor from video

import cv2
import numpy as np
import math

cap= cv2.VideoCapture("vid.avi")
frameRate = cap.get(5) #frame rate
x=5050
while True: