About FaceRecognizer

asked 2013-08-25 05:06:47 -0500

cdbdyx gravatar image

Dear all, Right now I am developing a face recognition system by using OpenCV, and what I want to

implement is to find the similarity of the given face and the faces in database, and can list

the result like this:

face1: 95%

face2: 93%

face3: 92%

face4: 80%

I found a class named FaceRecognizer in opencv, and it has some interface like train and

predict, but finally I found that this two interface only can judge whether a face is belong to

the database or not, can not do what I want to do.

Is there any other interface can achieve my goal?

edit retag flag offensive close merge delete


If you're interested in solutions outside of OpenCV, I can check this post which summarizes 40+ API's for face detection and recognition:


GilLevi gravatar imageGilLevi ( 2013-08-25 10:02:03 -0500 )edit

"Is there any other interface can achieve my goal?"

unfortunately, not so. it's not only the interface, that does not meet your requirements, but also all 3 implementations do a single nearest neighbour search, what you want sounds more like knn. you'll also have to devise your own heuristics for expressing something like : 95%.

no real idea, what's the best solution here, either hack the interface/library, or just 'steal' the relevant parts and devise your own ( you probably don't need all 3(eigen,fisher,lbp), lbp seems to be the most easy of them )

berak gravatar imageberak ( 2013-08-25 10:04:10 -0500 )edit

Thanks for you reply berak, can you explain more about how can I steal the relevant parts and devise my own? I want more details about this....

cdbdyx gravatar imagecdbdyx ( 2013-08-25 22:09:32 -0500 )edit

look at modules/contrib/src/facerec.cpp

berak gravatar imageberak ( 2013-08-26 01:49:47 -0500 )edit

pls let me know where can I get the source code of opencv in android? or I can build my own android sdk from the master branch?

cdbdyx gravatar imagecdbdyx ( 2013-08-26 22:10:28 -0500 )edit