aakashjhawar / face-recognition-using-deep-learning

Identify faces from video and images using OpenCV and Deep Learning
MIT License
135 stars 33 forks source link
computer-vision cv2 deep-learning face face-classification face-detection face-embeddings face-recognition face-recognition-python image-processing live-face-recognition machine-learning neural-network opencv openface python svm

Face Recognition using OpenCV

Overview of OpenFace for a single input image

  1. Detect faces with a pre-trained models from dlib or OpenCV.
  2. Transform the face for the neural network. This repository uses dlib's real-time pose estimation with OpenCV's affine transformation to try to make the eyes and bottom lip appear in the same location on each image.
  3. Use a deep neural network to represent (or embed) the face on a 128-dimensional unit hypersphere. The embedding is a generic representation for anybody's face. Unlike other face representations, this embedding has the nice property that a larger distance between two face embeddings means that the faces are likely not of the same person. This property makes clustering, similarity detection, and classification tasks easier than other face recognition techniques where the Euclidean distance between features is not meaningful.
  4. Apply clustering or classification techniques to the features to complete the face recognition task.

Read more about OpenFace Working of OpenCV Face detector

Getting Started

How to use

git clone https://github.com/aakashjhawar/face-recognition-using-opencv
cd face-recognition-using-opencv

Prerequisites

Results

Detect and recognize faces from video camera-

Result