Opencv cascade classifier got different result with different computers

asked 2015-10-22 10:13:41 -0500

Harold gravatar image

I've played with opencv3.0's cascade classifier recently, and came a long way to train a classifier that saved as cascade.xml. The classifier works well at my working place. But when I conducted the program at home using my laptop, the test result perform badly... Why would be that? My code and setting are the same. The working environment are also the same ( win7 x64, visualstudio2013 community with update5).

The key detection code are below: cascade.detectMultiScale(smallImg, faces, 1.1, 11, 0, Size(110, 110));

Setting in my cascade.xml: stageType: BOOST featureType: HAAR size: 20x20 boostType: GAB

Could anybody figure out what happened to the different result with the "same code", the smae "cascade.xml" and same "test images"?

edit retag flag offensive close merge delete


Are you absolutely sure about this? Have you tried in another third computer?

LorenaGdL gravatar imageLorenaGdL ( 2015-10-22 10:55:43 -0500 )edit

Stupid question: are you using the same test data ?

The minimal size you set is (110x110), the faces you want to detect are bigger than that ?

Eduardo gravatar imageEduardo ( 2015-10-22 11:54:54 -0500 )edit

I'm 100% sure that my code and test images are THE SAME... I purposely detect the size bigger than 110x110 since I'm not going to detect the face. I detect something else which I know the size and train the classifier myself. Though I still named the detection as faces...My bad

Harold gravatar imageHarold ( 2015-10-23 06:11:03 -0500 )edit

Did you build OpenCV yourself or use the pre-build dll ?

Eduardo gravatar imageEduardo ( 2015-10-23 07:18:14 -0500 )edit

What about the OpenCV version? Are in both cases the same?

LorenaGdL gravatar imageLorenaGdL ( 2015-10-24 05:25:09 -0500 )edit