Face Recognition with CNN
Hello everyone, I am trying to develop realtime face recognition using neural networks. I have read several answers in this forum, such as using the dnn module of opencv, caffe model. But I am still confused about the steps, so far I have written the steps as follows:
- prepare a face dataset to train face detection
- prepare a recognizable face dataset
- train the system to detect faces using haar or lbp cascade classifiers
- train the system to recognize faces based on detected faces using cnn
My question is :
- Is it possible to create a real time face recognition application using CNN to train face detection and face recognition using OpenCV?
- If possible, what do I need? and are my steps correct?
Thanks in advance :)
Well try to resolve/clarify you confusion - it will even get funnier from here on :-) There a difference between face detection and face recognition. Also, you are mixing haar or lbp cascade classifiers(old approach) with caffe models(dnn / new approach). They are somewhat doing the same thing (object detection) but they working different. Then you mentioed you want to create a training set? For object detection you can use a pre trained model. For the recognition part you get to get familar with embeddings.
Look dont undererstimate the things and try to get the basic first. Start small.
Hi, thanks for answering. By the way, your statement is quite clear, I will use a pretrained caffe model to detect faces. then, using what I can make my own face dataset, for use when face recognition?
You will need to locate the face, then crop it. Then you will do some further preprocessing steps(face alignment) so you can feed it into a another network(different (pretrained) model! - Google for facenet).
You will get a vector with 128 elements(128 dimensions). Then you can just use euclidean distance calculation to measure the similarity of two vectors/faces. Thats it - the rest you need to do yourself pls - this is just top level explanation what you need to do.
So basically you dont need to train anything. Just detect the face and get similarity vector and then compare - that's it.
ok got it, I'm done with face detection, it's time for the next step, thanks for advice