- Download the Face and Smile Haarcascades to your machine
-
face: https://github.com/opencv/opencv/blob/master/data/haarcascades/haarcascade_frontalface_default.xml
-
smile: https://github.com/opencv/opencv/blob/master/data/haarcascades/haarcascade_smile.xml
-
Copy the file paths of both face and smile cascades and update the string in lines 4 and 5 of
detect_smile.py
-
Finally, run the command
python3 detect_smile.py
- Webcam
- Python 3
- OpenCV
https://docs.opencv.org/3.4.3/d7/d8b/tutorial_py_face_detection.html https://docs.opencv.org/3.4.3/dc/d88/tutorial_traincascade.html
https://www.python.org/downloads/ https://realpython.com/installing-python/
Have an optimization, idea, suggestion, bug report? Pull requests greatly appreciated!