Cascade classifier stage construction looping [closed]

asked 2015-11-25 07:27:35 -0600

belgraviton gravatar image

updated 2015-11-25 07:28:13 -0600

I detect looping of cascade classifier construction on last stages. I use script:

g:\Programs\opencv_3_64\bin\Release\opencv_traincascade.exe -data "d:\data\5_train_LHaar12" -vec positives.vec -bg tB4_negSamples.dat -numPos 10000 -numNeg 20000 -numStages 12 -w 16 -h 16 -minHitRate 0.995 -maxFalseAlarmRate 0.5 -weightTrimRate 0.95 -maxDepth 1 -maxWeakCount 800 -precalcValBufSize 1024 -precalcIdxBufSize 1024  -numThreads 7  -mode ALL

Results for stage N 11:

image description

...........

image description

Stage N 11 was constructed successfully for lower values of samples: -numPos 5000 -numNeg 10000

What are the reasons for looping? Insufficient number of data samples? There is no possibility to improve discriminative ability of cascade classifier? Or something else?

edit retag flag offensive reopen merge delete

Closed for the following reason question is not relevant or outdated by sturkmen
close date 2020-11-05 12:15:34.230015

Comments

What is your OpenCV version? In the 3 years I have used this interface I have never encountered this behaviour o_O

StevenPuttemans gravatar imageStevenPuttemans ( 2015-11-25 07:37:08 -0600 )edit

I have OpenCV 3.0.0. I meet this behaviour twice.

belgraviton gravatar imagebelgraviton ( 2015-11-26 00:26:34 -0600 )edit

O wow just noticed it now, but you have -maxWeakCount 800 isn't that quite alot? You are trying to achieve a strong classifier within a single stage. Normally it is set on 100.

StevenPuttemans gravatar imageStevenPuttemans ( 2015-11-26 01:47:23 -0600 )edit

What number of stages is typical for trained cascades with 100 classifiers in a stage? My task requires 10-12 stages with 150-250 classifiers.

belgraviton gravatar imagebelgraviton ( 2015-11-26 05:12:51 -0600 )edit

Hmm I normally limit to 100 classifiers. Since I am focussing on building minimal training data - optimal effective classifiers I normally quit between 15-17 stages. But that is with fairly limited, smartly selected training data.

StevenPuttemans gravatar imageStevenPuttemans ( 2015-11-26 06:11:47 -0600 )edit