OpenCV halt system

asked 2014-03-14 10:33:02 -0500

John Smith gravatar image

updated 2014-03-15 06:17:47 -0500

berak gravatar image

I run opencv using this command, or the system crashes, or trying to stop a running process because of lack of memory. My computer has 4GB of memory, of them freely over half.

opencv_traincascade.exe -data haarcascade -vec positives.vec -bg negatives.dat -numStages 16 -minhitrate 0.999 -maxFalseAlarmRate 0.4 -numPos 282 -numNeg 500 -w 119 -h 119 -mode ALL -precalcValBufSize 512 -precalcIdxBufSize 512

edit retag flag offensive close merge delete

Comments

3

-w 119 -h 119 is your problem. I have a dedicated 3 GB of memory for the process and sizes over 100 pixels already cause memory issues over here. Resize your model to half dimensions -w 60 -h 60 and it should work

StevenPuttemans gravatar imageStevenPuttemans ( 2014-03-14 10:35:13 -0500 )edit

Thank you.As in this case, a program to train faces in excess of this size? All of them must be reduced to 60 * 60?

John Smith gravatar imageJohn Smith ( 2014-03-19 09:43:36 -0500 )edit

Yes and even lower. Most face detection algorithms resize to 24x24 pixels. This still contains enough information to reach a performant detection.

StevenPuttemans gravatar imageStevenPuttemans ( 2014-03-20 05:57:42 -0500 )edit