Skip to content

Machine Learning model which uses kNN Algorithm & Computer Vision to recognise different faces

Notifications You must be signed in to change notification settings

matakshay/Face_recognition

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

3 Commits
 
 
 
 
 
 
 
 

Repository files navigation

Face_recognition

The Python script "gen_train_data.py" reads and shows video stream (from the default web camera). All faces from the frame are detected using Haar feature-based cascade classifiers (for more information refer https://docs.opencv.org/3.3.0/d7/d8b/tutorial_py_face_detection.html).

The faces are bounded by a rectangle. The largest face image is flattened, and saved as a Numpy array.

The above procedure can be repeated multiple times to generate the training data

The script "face_recog.py" takes the above generated data, creates class ID and identifies name. Then using the Web camera, it implements kNN algorithm to match the face with a training data. This identified face is enclosed in a rectangle and the name is shown on top.

Releases

No releases published

Packages

No packages published

Languages