Skip to content

Instantly share code, notes, and snippets.

View shyam3089's full-sized avatar
🏠
Working from home

Shyam shyam3089

🏠
Working from home
View GitHub Profile
@radames
radames / python_opencv_camera_haar.py
Last active January 5, 2021 14:25
Example of Python with Opencv and camera face detection - repo complete https://github.com/radames/python_opencv_camera_haar
import cv2
cap = cv2.VideoCapture(0)
cap.set(3, 640) # WIDTH
cap.set(4, 480) # HEIGHT
face_cascade = cv2.CascadeClassifier(cv2.data.haarcascades + "haarcascade_frontalface_default.xml")
eye_cascade = cv2.CascadeClassifier(cv2.data.haarcascades + "haarcascade_eye.xml")
while(True):