Hacker Newsnew | past | comments | ask | show | jobs | submitlogin

The Viola-Jones technique is still fairly competitive for face detection performance, IF you train it with a lot of data (and of course good data, which means with all the types of variations you expect to see). However, the pre-trained classifier provided with OpenCV is terrible (unless they've updated it recently).

Fortunately, OpenCV provides functions to train your own classifier using your own data, so if you can get good data, and are willing to wait for the week or two it'll take to process, you can get much better performance using the same technique.

Finding sufficient training data (labeled faces) is more tricky. For an automated approach, you could try bootstrapping it by simply running a more state-of-the-art detector (such as on Facebook, Google, etc.) and feedings the outputs into the training function (you'll need to do some work to actually get the outputs programmatically, perhaps through undocumented APIs).

Another approach is to use an existing face dataset. One possibility is the FDDB [1] although it's kind of small (5171 faces). Unfortunately, most other datasets I know of in the face community are either unrealistic images (e.g., only "mugshot"-style) or were detected using OpenCV (and thus won't help you get better).

The final approach is to label images yourself, which would require time and money (e.g., to do it on Amazon Mechanical Turk).

If you do decide to retrain classifiers, it's essential that you augment your data in various ways, such as by mirroring images (and labels) left/right, generating slightly rotated versions of faces, and at slightly different sizes. This augmentation can GREATLY improve the performance of your detector.

[1] http://vis-www.cs.umass.edu/fddb/index.html



Thanks for this great help, apu! A new issue was created on github (https://github.com/eduardolundgren/tracking.js/issues/88) to register the suggestions =)




Guidelines | FAQ | Lists | API | Security | Legal | Apply to YC | Contact

Search: