By using openCV this project will open your web cam on your computer and detect whether or not you are wearing a mask. It will also be able to recognize specific indivisuals.
To try this out you will ned to follow the steps below
Please note that the photos have been removed for privacy concerns and that the program is CPU Intensive
- Set up your programming invoroment for Python
- Download the code
- cd into where you saved the code
- Add photos of ureself under images/person-# Type the following in your terminal to train the program
python face_trainer
in the terminal - Type the following command to run the code in your terminal
python face_rec.py
- To try the mask detector application go to the file called mask_rec and press run or type
python mask_rec
in the terminal - ENJOY
Want to test it out
-
try uploading more images person 1: Ryan Reynolds person 2: The Rock person 3: kevin Heart
-
use the file renamer program to insure that all pictures have been labeled in sequential order woth the same name
-
train using the facial recognition program
-
Finally run the facial recognition python file