Any overhead by splitting a large zone into smaller ones?

Support and queries relating to all previous versions of ZoneMinder
Locked
User avatar
MJN
Posts: 251
Joined: Wed Jan 17, 2007 10:29 am
Location: Wiltshire, UK

Any overhead by splitting a large zone into smaller ones?

Post by MJN »

Can anyone tell me if there is any additional overhead (CPU, time, etc) of splitting, say, the default 'All' zone into two seperate zones covering the same area?

My reasons for wanting to do this are to have different thersholds for different parts of the picture so whilst the alarm zone coverage remains the same the thresholds of the two zones differ.

On a related note, and perhaps a daft question, does the shape of a zone bear any impact on processing overhead? For example, assuming the same area coverage would a star-shaped zone require more processing that a simple square?

Mathew
achix
Posts: 146
Joined: Tue Oct 02, 2007 9:38 am
Location: Greece

Post by achix »

Hi Mathew,
Why dont you monitor system load during both setups?

You could watch for load under analyzing mode, (idle state)
and under alarm/alert state.
So basically you should compare all 4 cases.
Do you have sar installed?
If yes, it would prove a valuable tool on monitoring system load
under normal idle state.

Achilleas
User avatar
MJN
Posts: 251
Joined: Wed Jan 17, 2007 10:29 am
Location: Wiltshire, UK

Post by MJN »

Ideally I would do that but the server runs a whole multitude of other functions (mail/web etc) so it's difficult to distinguish between cause and effect.

That said, I haven't noticed any change in the general load on the machine and so, for my situation at least, it's probably nothing to worry about - any potential load increase seems to be being lost in the 'noise' anyway.

I still have the curiosity to understand how things work so if anyone happens to know the answer I'd still be interested!

Mathew
achix
Posts: 146
Joined: Tue Oct 02, 2007 9:38 am
Location: Greece

Post by achix »

you could check if the same amount of "zma" instances in the single/multi zone/camera cases.

Then dig into the code! or just increase debugging verbosity.

Its always good to have the debugging shell window and the streaming browser window on the foreground when testing.
You can see the debugging messages live as you move in front of the camera.

Just in case you get no more answers!
(i hate it my self when people dont respond!)
User avatar
zoneminder
Site Admin
Posts: 5215
Joined: Wed Jul 09, 2003 2:07 pm
Location: Bristol, UK
Contact:

Re: Any overhead by splitting a large zone into smaller ones

Post by zoneminder »

MJN wrote:Can anyone tell me if there is any additional overhead (CPU, time, etc) of splitting, say, the default 'All' zone into two seperate zones covering the same area?

My reasons for wanting to do this are to have different thersholds for different parts of the picture so whilst the alarm zone coverage remains the same the thresholds of the two zones differ.

On a related note, and perhaps a daft question, does the shape of a zone bear any impact on processing overhead? For example, assuming the same area coverage would a star-shaped zone require more processing that a simple square?

Mathew
There will be a small additional overhead if your zones contain vertical extensions (e.g. like a capital H) as ZM will iterate across the empty spaces between them (if you have more than one) but not actually do anything else so it will be relatively minor. I hope to address this in a future version. This does not apply to horizontal extensions of a zone (like in a capital E) which will be processed optimally.

I very much doubt whether the minor differences would be measureable via top or anything else unless you are thrashing the box at very high frame rates, if even then.
Phil
User avatar
MJN
Posts: 251
Joined: Wed Jan 17, 2007 10:29 am
Location: Wiltshire, UK

Post by MJN »

Thank you both for the responses.

(Achix - Ideas are just as useful as authoritive responses so keep up the good work!)

Mathew
Locked