Ask Your Question

HOG CascadeClassifier Training - Amount of samples

asked 2013-06-24 03:27:13 -0500

doob gravatar image


I would like to know how many samples are necessary or usefull to train the CascadeClassifier with HOG Features for Pedastrian detection.

I tried to find out about the 'hogcascade_pedestrians.xml' in 'data/hogcascades' but didn't find any usefull information. Not even in the commit message.


edit retag flag offensive close merge delete



I would like to add to my question: If somebody knows with witch data 'hogcascade_pedestrians.xml' was trained, it would be nice to know.

doob gravatar imagedoob ( 2013-07-02 06:27:59 -0500 )edit

1 answer

Sort by ยป oldest newest most voted

answered 2013-07-29 18:23:51 -0500

updated 2016-01-01 10:29:17 -0500

You should read this paper: Histograms of Oriented Gradients for Human Detection, Navneet Dalal and Bill Triggs, CVPR 2005, PDF It explains almost everything on how to use HOG and linear SVM for pedestrian detection. It uses two dataset (MIT and INRIA) and specifies the number of samples used. Using the same parameters, you should be able to train a good pedestrian detector.

[ Additional information ]

HOG cascade is not supported in OpenCV 3.0 ( see here ), instead you can use HOGDescriptor

OpenCV 3.x have a sample application to train custom HOG+SVM detector train_HOG.cpp

edit flag offensive delete link more


I know how this stuff works and I know all the papers related. The question was specific to the cascade comming with OpenCV. Thanks anyways.

doob gravatar imagedoob ( 2013-08-29 07:54:40 -0500 )edit

Excellent answer, @Mathieu Barnachon !

Will Stewart gravatar imageWill Stewart ( 2014-02-25 10:44:22 -0500 )edit

Question Tools

1 follower


Asked: 2013-06-24 03:27:13 -0500

Seen: 3,316 times

Last updated: Jan 01 '16