how are zones order processed?

Forum for questions and support relating to the 1.32.x releases only.
Post Reply
aarons6
Posts: 14
Joined: Mon Feb 08, 2016 12:13 pm

how are zones order processed?

Post by aarons6 » Fri Dec 14, 2018 12:54 am

what order are the zones processed? are they by name? or size? or internal number when created?

i have an active zone with a preclusive zone ontop of it.
the active zone has a threshold of 25 and the preclusive 150.
each one has a 3/3/2 area.. basically the default preset.

i live on a corner and this camera looks out to the street, this is to keep car headlights from causing an alarm, but still be able to detect people..

the issue is, as soon as the car goes around the corner i get a 1 frame alarm, then the preclusive kicks in and it stops the alarm for the next few frames.

how do i make the preclusive go first?

also ive tried to use the min/max threshold in active to do the same thing, but it didnt work at all.. even tho it says the overload is blocking frames in the log, the alarm still goes off when its done.


it doesnt seem the preclusive zone is working.. i made it more sensitive then the active zone i set the threshold to 5 and the log says its extending alarm count, i set the extended frames to 20 which is 4 FULL seconds at 5fps and i still get an alarm when a car shines the headlights on the driveway.

is there some raw data or something i can pull from a log that shows the intensity and pixel/blob size that caused an alarm?

here is steps to redo what ive tested, maybe someone else can see if its working correctly.
i setup a zone, max screen, default active..
then i setup a new zone, max screen, default preclusive.. i lowered the threshold on the preclusive to 20, the active is 25.

this SHOULD pretty much zero out ALL alarms.. since the preclusive HAS to go first.. yet, every single car that goes around the corner, gets an alarm. ??
here is a pic of what im dealing with, the light should be bright enough to be detected by the preclusive zone.
Image

User avatar
iconnor
Posts: 1189
Joined: Fri Oct 29, 2010 1:43 am
Location: Toronto
Contact:

Re: how are zones order processed?

Post by iconnor » Fri Dec 14, 2018 2:10 pm

Zones are loaded Sorted by Type, then Id.

Sorting is in ascending order so sorting by type, the order is:
'Active','Inclusive','Exclusive','Preclusive','Inactive','Privacy'

So Preclusive will not be first. This might be the problem.

canbikehere
Posts: 16
Joined: Tue Feb 27, 2018 6:09 pm

Re: how are zones order processed?

Post by canbikehere » Fri Dec 14, 2018 7:43 pm

I have a similar problem, and had a similar experience - there's a driveway across the street facing my camera. Whenever the neighbour turns his car on I get an alarm from the headlights; I created a preclusive zone right where the headlights are but never had any success. I guess that explains it!

aarons6
Posts: 14
Joined: Mon Feb 08, 2016 12:13 pm

Re: how are zones order processed?

Post by aarons6 » Sat Dec 15, 2018 2:20 am

iconnor wrote:
Fri Dec 14, 2018 2:10 pm
Zones are loaded Sorted by Type, then Id.

Sorting is in ascending order so sorting by type, the order is:
'Active','Inclusive','Exclusive','Preclusive','Inactive','Privacy'

So Preclusive will not be first. This might be the problem.
hmm, preclusive should be first?? its pointless to have the alarm go off before you want to suppress it?
also the reason why this is frustrating is it says in the wiki the preclusive zone is first.
https://wiki.zoneminder.com/Defining_Zones#Type

aarons6
Posts: 14
Joined: Mon Feb 08, 2016 12:13 pm

Re: how are zones order processed?

Post by aarons6 » Sat Dec 15, 2018 4:54 am

where is zm_zone.cpp located? i was going to change the order so preclusive is first on line 935.
not sure if that will work tho.

aarons6
Posts: 14
Joined: Mon Feb 08, 2016 12:13 pm

Re: how are zones order processed?

Post by aarons6 » Sat Dec 15, 2018 7:14 am

so i just tried this which i think is the way preclusive zones are meant to work.
i have a sidewalk going up to my porch, i really dont want my camera telling me when people are leaving, just coming.

so i put the zone like this.
on the path far from the house, i put a small active zone then in the middle i put a inclusive zone, then at the closest to the porch a preclusive zone.
i put all the zones with the same numbers, 20 4/4/3 which is enough to detect people at night.

the preclusive zone i put a 20 frame extended alarm.. thats 4 seconds since im recording at 5 fps.

that seemed to work once i tweaked the extended to account for people walking

it seems i found another issue.. the switch from active to inclusive doesnt extend the alarm like it says it does in the wiki.

User avatar
knight-of-ni
Posts: 2257
Joined: Thu Oct 18, 2007 1:55 pm
Location: Shiloh, IL

Re: how are zones order processed?

Post by knight-of-ni » Tue Dec 25, 2018 2:33 pm

Inclusive zones are in fact working as intended so let's keep that discussion here, rather than the issue you reported in the github forum.

Motion in an inclusive zone adds to the motion in active zones, *only when there is motion occurring in the active zone*. As soon as there is no motion in the active zone(s), then inclusive zones do nothing... e.g. they don't have the ability to keep an alarm going after the object of interest has left the active zone(s), nor does the documentation say it does. You can't use inclusive zones to extend an event.

A use case for this might be an exterior camera with a door, with glass window, in the field of view. I might want to capture exterior motion, such as an exterior object moving near the door, but I don't want to capture motion if someone on the inside walks by the door. To do that I would put an inclusive zone around the glass, and active zones around the non-glass parts of the door.

For your use case of walking down the path, either use one active zone for the path or split it into two or more active zones, with increasing sensitivity the further from the camera's field of view.

UPDATE: You provided some details about your use case you did not in the github forum. It seems you are only interested in a certain direction of motion, rather than a certain area of motion. Direction of motion is called an analytic. Motion analytics, are not currently supported natively in ZoneMinder. Asker has done some work with object detection in his event server, but I'm not sure if it does direction. It might be worth asking him.

Typically, when I set up exterior motion detection I set a moderate pre and post poll. I'll start with 5 seconds of pre and 5 of post, then adjust as I monitor the camera. I'll tune the motion detection to pick up only the largest and/or closer objects. This is not what you asked, but it does help minimize events that occur on the fringes of your field of view you might not be interested in. For example, someone loitering on the sidewalk that does not come any closer.
Visit my blog for ZoneMinder related projects using the Raspberry Pi, Orange Pi, Odroid, and the ESP8266
All of these can be found at https://zoneminder.blogspot.com/

User avatar
Bluemax
Posts: 68
Joined: Wed Jun 12, 2019 5:15 pm

Re: how are zones order processed?

Post by Bluemax » Mon Apr 06, 2020 10:56 pm

I had exactly the same understanding of the 'inclusive zone' as the guys above. Its misleading and dangerous to have important areas covered with this zones. The wiki should explicitly state that it just adds score to the active zone and not extending alarms.
A real 'Active/Slave Zone' that extends the alarm trigger would be way more useful than the current implementation.

User avatar
knight-of-ni
Posts: 2257
Joined: Thu Oct 18, 2007 1:55 pm
Location: Shiloh, IL

Re: how are zones order processed?

Post by knight-of-ni » Tue Apr 07, 2020 1:56 am

Bluemax wrote:
Mon Apr 06, 2020 10:56 pm
I had exactly the same understanding of the 'inclusive zone' as the guys above. Its misleading and dangerous to have important areas covered with this zones. The wiki should explicitly state that it just adds score to the active zone and not extending alarms.
A real 'Active/Slave Zone' that extends the alarm trigger would be way more useful than the current implementation.
So what's stopping you from doing something about it?
Visit my blog for ZoneMinder related projects using the Raspberry Pi, Orange Pi, Odroid, and the ESP8266
All of these can be found at https://zoneminder.blogspot.com/

Post Reply

Who is online

Users browsing this forum: No registered users and 3 guests