OpenCV: How to know the progress status of HaarTraining

风流意气都作罢 提交于 2019-12-13 00:53:07

问题


I'm running a HaarTraining process using OpenCV 2.2 (compiled with OpenMP). The training progress shows:

+----+----+-+---------+---------+---------+---------+
|7468| 44%|-|-2.712450| 1.000000| 0.719459| 0.108393|
+----+----+-+---------+---------+---------+---------+
|7469| 44%|-|-2.712449| 1.000000| 0.719459| 0.108393|
+----+----+-+---------+---------+---------+---------+
.......

What does the number 7469 mean (I only have 7000 samples)? How can I know when the process is going to finish?

Thanks!


回答1:


N means the current feature for this cascade. (see http://cv-kolaric.blogspot.com/2008/03/output-from-haartrainingexe.html)

+----+----+-+---------+---------+---------+---------+
|  N |%%SMP|F|  ST.THR |    HR   |    FA   | EXP. ERR|
+----+----+-+---------+---------+---------+---------+
N = current feature for this cascade (seq->total),
%%SMP = percentage of samples used, if trimmings enabled (v_wt)
F = '+' if isFilpped, if symmetry is specified (v_flipped), '-' otherwise
ST.THR = stage threshold, 
HR = Hit Rate based on Stage threshold (v_hitrate / numpos), 
FA = False alarm based on Stage threshold (v_falsealarm / numneg)
EXP.ERR = Strong classification error of adaboost algorithm,
based on threshold=0 (v_experr)

Different features are calculated for all your samples. E.g. x-y derratives, contrast-ratios etc. etc. Depending on the difference between your samples, more features are calculated, and it seems your positive images are just too different from each other, to categorize them.

Try to pre-process your images first, before training. E.g. remove background, find edges, threshold the images, flood-fill. Anything that can make your positive image set look more alike



来源:https://stackoverflow.com/questions/6483690/opencv-how-to-know-the-progress-status-of-haartraining

易学教程内所有资源均来自网络或用户发布的内容,如有违反法律规定的内容欢迎反馈
该文章没有解决你所遇到的问题?点击提问,说说你的问题,让更多的人一起探讨吧!