11

I've done the detection part. But when it comes to recognition, When another unknown person comes in front of the camera it should display "unknown person," but it is displaying the database person's name instead. Means for all other users it is displaying the same name of the person stored in DB.

Please help me out.

hacker
  • 8,919
  • 12
  • 62
  • 108

1 Answers1

8

I don't know how the API is working in java android. But as face recognition is a training algorithm, it will retreive you the closest face from the one you put in entry, even if you did not put it in the training database. However you can set a threshold on the eigenfacerecognizer method in order to determine if a face is in your database. Here is the documentation, "Settings the Threshold" part: http://docs.opencv.org/trunk/modules/contrib/doc/facerec/facerec_api.html

PedroCactus
  • 525
  • 4
  • 10
  • i'm using ndk based recognition..I don't find any place to change the threshold value. – hacker May 30 '14 at 07:58
  • what do you mean? the java api does not provide you the threshold parameter? Otherwise, you will have to use jni to do your stuff in C++ and wrap it to java. – PedroCactus May 30 '14 at 08:42
  • It is a known bug for the lib: http://answers.opencv.org/question/16244/createeigenfacerecognizer-android/ Maybe they fixed it in v2.4.9 – PedroCactus May 30 '14 at 09:27
  • Someone find any solution for this ? – hacker Jun 16 '14 at 06:01