0

I need to find all people or group of people in city square like this. I use CascadeClassifier.detectMultiScale function and prepare image by equalizeHist (correct brightness and contrast)enter image description here

As you can see not all people was found.

In description to haarcascade_fullbody.xml i read that detector support only frontal and back views.

Do you know some haarcascades collection for this problem, or may be i need to correct my code and leave this cascades?

victor1234
  • 871
  • 3
  • 12
  • 28
  • Might be useful : http://stackoverflow.com/questions/10231380/graphic-recognition-of-people/10385464#10385464 – Abid Rahman K Jul 28 '12 at 06:01
  • Were you able to get proper detection coz I get the same kind of detection as yours. – timemanx Aug 19 '13 at 16:39
  • No I found [deference](http://answers.opencv.org/question/1278/difference-between-cpu-and-gpu-detectmultiscale/) between CPU and GPU realization and left this problem. But I think, that one solution is using multiple cascades concurrently like in @Prakhar Mohan comment. Tell me if you have some interesting ideas. – victor1234 Sep 19 '13 at 20:57

1 Answers1

1

You can use the hog cascades provided by opencv to identify pedestrians. And all people might not be identified by your program as the cascade that you are using might not be trained to identify only the lower body or only the upper body. To do that you can use multiple cascades. Check the data folder in OpenCV, you'll find the haar and the hog cascades there.

praxmon
  • 5,009
  • 22
  • 74
  • 121
  • I try to use upperbody, lowerbody, mcs_upperbody and fullbody from OpenCV haarcascades directory, the best results i get with fullbody. Hog cascades i test with `peopledetect.cpp` sample and this result was the worst. Do you know some other cascasde collections? I think it standart problem and i think there is no need to training new cascades. – victor1234 Jul 26 '12 at 11:40
  • 1
    See the cascades have images with different thresholds. Now the problem that I can see is that some parts of buildings are being identified as humans, this might be so because their threshold somehow matches the threshold of the building. Another problem is when people are not being identified as their full body has not been captured in the pic, that I thought will be solved using the other haar classifiers. I'll try to search for more classifiers and get back to you if I find something. Have you tried to run multiple detection using multiple cascades concurrently? – praxmon Jul 26 '12 at 19:58