Object Detection OpenCV-Python does not work
<p>For several days I am have been trying to build my own object classification program using Python-Open cv and Haar Cascade.</p>

<p>After creating the samples, here is how train the system:</p>

<pre><code> opencv_traincascade -data classifier -vec samples.vec -bg negatives.txt -numStages 12 -minHitRate 0.999 -maxFalseAlarmRate 0.5 -numPos 1000 -numNeg 600 -w 50 -h 50 -mode ALL -precalcValBufSize 1024 -precalcIdxBufSize 1024
</code></pre>

<p>and after stage 8 I have received this output</p>

<pre><code>===== TRAINING 8-stage =====
&lt;BEGIN
POS count : consumed   1000 : 1000
NEG count : acceptanceRatio    600 : 0.00221078
Precalculation time: 10
+----+---------+---------+
|  N |    HR   |    FA   |
+----+---------+---------+
|   1|        1|        1|
+----+---------+---------+
|   2|        1|        1|
+----+---------+---------+
|   3|        1|    0.898333|                                                      
+----+---------+---------+
|   4|        1| 0.916667|
+----+---------+---------+
|   5|        1| 0.691667|
+----+---------+---------+
|   6|        1| 0.681667|
+----+---------+---------+
|   7|        1| 0.518333|
+----+---------+---------+
|   8|        1| 0.626667|
+----+---------+---------+
|   9|        1| 0.441667|
+----+---------+---------+

===== TRAINING 9-stage =====
&lt;BEGIN
POS count : consumed   1000 : 1000
NEG count : acceptanceRatio    0 : 0
Required leaf false alarm rate achieved. Branch training terminated.
</code></pre>

<p>However the trained model does not detect any object (watch in this case). I am stucked and don't know how to solve this out. Any useful ideas are appreciated greatly.</p>

<p>Your desired parameters were acheived: "-minHitRate 0.999 -maxFalseAlarmRate 0.5".</p>

<p>You have (according the table you show above): HitRate=1 and FalseAlarmRate=0.441667, that's why training stopped.</p>

python opencv