开发者

People Counting System

I want to develop a "People Counting System" using OpenCV (or Emgu CV).

Please guide me on how to implement or lead me to some examples or open source projects.

(I have done some work: extracting diff then threshold to delete background, using motion history and like that; still no good results.)

Edit 1: I am counting a high people flow (a dozen of them may come through simultaneously).

Edit 2: It must be at least 80% accurate. People are walking through a door that is almost 5 meters wide. The problem is I have no control on the position or angle of the camera. Camera is shouting the place from a 10m distance at a 2.5m height.

Thank开发者_开发技巧 you


If you call a people counting system a system that counts people that are in a room then I recommend you implement the hardware with a microcontroller with 2 lazers(normal lazer toys work) and 2 photoresistors.For the microcontroller I recomen you use Arduino.And then make an C# application that has a SerialPort object and reads the data that the arduino sends through the USB.The arduino will send 1 for "someone entered the room" and 0 for "someone left the room" for example.Then the logging and statistics can be done easily in C#.

Arduiono Site:here

Photoresistor for $1: here

This solution is alot cheaper and easyer to implement than using a camera that is with a fairly good quality.

Hope I helped you.


Check out the HOG pedestrian detector that comes with recent versions of OpenCV (>= 2.2).

See modules/objdetect/src/hog.cpp and samples/cpp/peopledetect.cpp in the OpenCV sources. Unfortunately there is no official documentation about it yet.


This would help you to count moving things including people: Motion Detection project on CodeProject


Are people the only kind of "entities" in the scene? If this is not the case, do you care about considering a person some other kind of thing that moves through the scene? Because if that is the case, you could just count blobs that come in or come out from the scene. It may sound a bit naive but I will take some kind of motion image, group motion pixels by distance in clusters. Your distance metric could take into account some restrictions, such as that people will "often" stand so pixels in a cluster should group around some kind of regression line (an straight-up line if the camera is aligned with de floor). It shouldn't be necessary to track them in the scene, just noticing when they enter or they leave, though you'd get some issues with, for example, people entering on their own in the scene and leaving in pairs or in groups... Good luck :)


I think if you have dense people crowd with a lot of occlusions you have to use some machine learning algorithm, for example you can use Implicit Shape Model for features.


It really depends on the position of the camera. Assuming that you can get front facing profiles of the people in the images:

This problem is basically face detection and recognition.

There are many ways to go about finding faces, but this is the approach that I'm a little more familiar with.

For the face detection you need to do image segmentation on the skin tone color. This will extract skin regions. [Arms, the chest (for those wearing V cut tops), face, legs, etc] Then you would need to line up the profiles of the skin regions to the profile of your trained faces.

[You'll need to use Eigenfaces to create a generic profile of what a face looks like]

If the skin region lines up and doesn't devate too far from the profile, then it is considered a face. Once the face is confirmed, then add it into the eigenfaces data store [for recognition]. To save processing you might want to consider limiting the search area if you are looking for a previous face. [Given the frame rate, and last time the person was seen]

If you are referring to "Crowd flow" I think you just mean the density of faces in a crowd.

Now you've confirmed that a moving object in the video is a person. Now you just need to note that and then make sure that you don't consider them as a new person again.

This approach: Really depends on your ability to detect face regions. This may not work if the people in the video are looking down, not fitting the profile of the trained data etc. Also it may be effected if a person puts on sunglasses within the video. [Probably would be considered a "new face"]

0

上一篇:

下一篇:

精彩评论

暂无评论...
验证码 换一张
取 消

最新问答

问答排行榜