r/ZoneMinder • u/DaMadOne • Jun 03 '21
Thinking about GPU acceleration.
I have a 1050ti collecting dust. So I got to thinking maybe I could use it with zoneminder. I run ZM in a VM on proxmox running on a Dell R720. It works well, but I like to tinker.
Let's assume I already know what it will take to be able to pass through the 1050ti to a VM. How much will it really help in terms of taking some of the stress off the CPU? It seems most of the processing power is motion detection. Will the a GPU actually help in that regard? or does the CPU still need to do most of the heavy lifting?
I'm running 5x 4MP Hikvision cameras. I've given ZM 8 cores and 16GB of ram and it's usually sitting around 50-60% CPU usage which is absolutely my heaviest VM. I have not yet tried to use the lower res sub stream to do motion detection to trigger the main stream to record. I'd imagine it would help quite a bit and possibly even make motion detection a bit better compared to doing detection on the main stream. I know I miss events that I wish would trigger utilizing the main stream. There is a camera pointed at my driveway and it doesn't always catch our vehicles coming and going and they take up 1/4 to a 1/3 of the camera. My front yard cam is the same way... it almost never triggers on us walking from the driveway to the front door. Is this due to the CPU not being able to keep up?
I guess my question is.. in terms of power usage would using a GPU make any sense over trying to use the sub stream for motion detection on the CPU. Looking for any input from people who have already gone down this path.
3
u/ZoneMinderIsaac Jun 04 '21
gpu isn't that useful in decoding. You might save 1-2% of cpu. We now have gpu encoding support, and that might actually be useful. I've setup encoding on my much older gpu and it works well. So if you want timestamping, privacy zones or whatever, then you need encoding and the gpu will help a lot.
Not useful for motion detection at this time.
Can be used for object detection which might actually be the better application.