Ask Your Question
1

Performance question: vehicle & pedestrian detection

asked 2013-07-27 13:00:41 -0600

Libbux gravatar image

I've got a massive collection of camera feeds (~496 of them) coming in, which I want to perform vehicle & pedestrian detection on. I'm just wondering if that's even possible.

The feeds are 352 x 240, so not very big, and they aren't video feeds, they're just JPEGs that change every second. So I basically need to do detection on 496 cameras (although I could definitely reduce this number, and just stick to the ones with the best angles) at 352 x 240, at 1 fps each. Seem like too much for a server or cluster of a couple servers to handle? (CPU obviously, server GPUs are potatoes)

edit retag flag offensive close merge delete

1 answer

Sort by ยป oldest newest most voted
3

answered 2013-07-27 19:56:46 -0600

It is possible, but it takes time. Look at the speed-up available in OpenCV: GPU or parallel_for_ (multi-threaded CPU). Or create multiple native threads to detect on multiple streams in the same time.

If you want to do it in real time, it means you have to make 496 detection per second. If you use a single threaded approach, you have to make each detection in less than 0.002 second, which will be difficult, but using 8 threads (assuming you have 8 CPU/Hyperthreading) you get 0.016 second for each detection. If you also used your GPU to perform another detection, you could increase this number. But everything will be so easy, you have to test it, look at the transfer time from CPU to GPU, etc.

edit flag offensive delete link more

Comments

Yes, I am doing it in 'real' time, although the framerate is only 1fps per feed.

The GPUs I'm dealing with here have 8-16MB of memory - which is why I'm inclined to take the CPU approach, because the GPUs are basically useless. Am I taking the right approach here?

Libbux gravatar imageLibbux ( 2013-07-27 23:04:05 -0600 )edit

Yes, use the CPU, the GPU will spend lots of time in transfers, and for any advantage. parallel_for_ is inspired by TBB, so it's straightforward to used, and multi-platform. I recommend you to make some test on a single stream, to be sure your CPU can do it in real time, or at least what to expect with multiple threads.

Mathieu Barnachon gravatar imageMathieu Barnachon ( 2013-07-27 23:41:11 -0600 )edit

Question Tools

1 follower

Stats

Asked: 2013-07-27 13:00:41 -0600

Seen: 785 times

Last updated: Jul 27 '13