Skip to content

Instantly share code, notes, and snippets.

View dishankjindal1's full-sized avatar
🎯

Dishank Jindal dishankjindal1

🎯
View GitHub Profile
from cv2 import cv2
video = cv2.VideoCapture(0)
if not video.isOpened():
print("Cannot open camera")
exit()
while True:
ret, frame = video.read()
gray = cv2.cvtColor(frame, cv2.COLOR_BGR2GRAY)