Ask Your Question

Revision history [back]

You've got to be careful with the lightning conditions, haar classifiers are sensitive to this. Besides, there are two parameters, the pyramid iteration scaling (think 1.1 in the example you mention), and, more importantly, the minimum detected size (cvRect(30,30) in the example). The minimum size should ideally be different from eyes and face, and even related to each other. Try just reducing it substantially and see if you get better results. Finally, I recall a while ago figuring out that the Haar classifier does not take into account ROI, keep that in mind if you want to use the classification in real time apps, i.e. you'd need to implement that part with a bit of IplImage manipulation.