4

I have a camera set up on a ceiling , capturing people standing in line. I need to count the amount of people. Currently I do that with background subtraction and Hough transform. The detector works well for contrast heads, but if hair color is close to the cloth color, the performance is poor. Any advices would be greatly appreciated. Example image here http://old.nabble.com/file/p32380283/1.png

enter image description here

Jav_Rock
  • 22,059
  • 20
  • 123
  • 164
user923744
  • 41
  • 3
  • could you share your code on how to count the number of heads? I am currently working with our final project which is to count the number of people entering or leaving a room. Also, does it have to be a very high quality camera when I do this? Thank you for your help. – user1217904 Feb 22 '12 at 17:26

1 Answers1

0

Hough transform is generally good for geometric shapes that are partly obscured - wouldn't be my first choice for heads.

Assuming the camera is fixed I would start with anything that doesn't match a stored background image.

Then I would just look for edges and find a center of gravity and area of each blob. If the blob is large enough to be a head and it's c of g moves at about the right rate for a person (ie it isn't sub-pixel stable for minutes at a time or moves metres/second) then I would count that as a person.

Martin Beckett
  • 94,801
  • 28
  • 188
  • 263
  • 1
    Thanks for the proposal, I tried to implement blobs but the only problem with them is that people sometimes stand tightly close and its impossible to make out between them even by area size( – user923744 Sep 02 '11 at 07:32