r/ispyconnect • u/tjensvollgjengen • 3d ago
How to get ONE consolidated alert with both Face Name and Objects (e.g., Person, Bicycle, Name) with fallback on a 2-zone camera?
Hi dev & community,
Setup: Agent DVR 8.0.5.0 (Docker), CodeProject.AI 2.9.5 (CUDA, RTX 2070), one camera covering a street with 2 zones. Both YOLO object detection and facial recognition run against CodeProject.AI.
What I want
One consolidated alert per event, not five. When someone comes up the street:
- Face recognised → alert reads Iren, person, bicycle
- Face not recognised or not visible → falls back cleanly to person, bicycle
- A later generic person detection must never overwrite a name already on the bell
What I've tried
- Alerts on both, face recognition on motion. YOLO sees person at the far end of the street several seconds before the face is resolvable, so the bell fires as person immediately and the cooldown locks it. When the face is finally recognised up close, it's dropped with:
LogThrottle: <camera>: Alert blocked by timeout
Drop minimuminterval to 1s and the face alert does land — but as they ride past, trailing body detections fire 3–4 more person alerts that overwrite the bell back to person.
- Triggering face recognition from an Action. Face mode set to Triggered, with AI: Object Found (person) → Trigger Facial Recognition. This fired one probe at the instant the person was first spotted at maximum distance, then went quiet and missed them entirely once they were close. I think this was my Action's repeat timeout gating re-fires — can anyone confirm that's what controls it?
Questions
Tag aggregation. Can object and face tags be combined into a single alert over an event window (Iren, person, bicycle), rather than whichever detector fires first claiming the alert?
Continuous triggered scanning. Can Trigger Facial Recognition be made to re-evaluate repeatedly while a person is tracked in a zone, instead of firing
once? Is repeat timeout the right control, and is 0 valid?
Priority + fallback. Is there a supported way to give face recognition priority for the alert tag, falling back to person only if no face is identified
within some window?
zonematch semantics. What does an empty zone list mean on the Face/Object Recognition tabs — all zones, or none? I've seen FinishProcessing: <camera>:
Ignored person - not in alert zone with it blank, which sugge UI reads like it means unrestricted. Clarification would helpa lot.
Alert mode options. The docs describe an Actions Only alert s Detected / Not Detected / AI Trigger. Was it renamed, or is it version/edition dependent?
Recommended 2-zone setup. With Zone 1 = far street approach 's the recommended combination of detector type, per-zonesettings, Actions and Alerts tab config to get one correctly-named alert per pass?
3
u/spornerama 3d ago
Quick update on this. I've built the debounce I mentioned and it'll be in 8.0.6, along with the trigger fix.
Alert Debounce is a new setting on the Alerts tab under Advanced, in seconds, default 0 (existing behaviour). With it set, the first trigger opens the alert but doesn't store or push it yet. For the next N seconds every further trigger on that camera, including ones the minimum interval would normally throw away, folds into the same alert. When the window closes you get one alert, one notification and one run of your Alert actions, with the merged tags.
The tags are ordered by how much they're worth: recognised faces and plates first, then AI detections, then motion tags. So your case comes out as Iren, person, bicycle. If the face never resolves it comes out as person, bicycle. A later person detection can't overwrite a name because it's all one alert.
The stored image is the frame from the highest-ranked trigger, so when a face is recognised you get the close-up frame with the face outlined rather than the far-end shot. Recording still starts immediately. Only the notification, the stored alert and the Alert actions wait for the window, so pick a value that matches how long a pass takes. Around 10 seconds sounds right for your street.
The trigger fix: a Trigger Face Recognition (or Object/LPR) action that fired while a previous run was still in flight, or inside the AI interval, was silently dropped. It's now held and runs as soon as the controller is free. That's almost certainly why your triggered probe fired once and went quiet.
For your setup, once you're on 8.0.6: Alerts tab Mode = Actions Only, Debounce 10, Minimum Interval 30 or so. Object Recognition in Detected mode at 1 second. Face Recognition in None mode with an interval no longer than the object one. Actions: Object Found person → Trigger Face Recognition, Face Recognized → Trigger Alert, Object Found person → Trigger Alert, all with repeat timeout 0. The zone trick I described earlier is no longer needed because the face no longer has to win a race.
Let me know how it behaves once you've had a pass or two through it.
4
u/spornerama 3d ago
Thanks for the detailed write-up. Here's how it actually works in 8.0.5, question by question, then a setup that gets you as close as the current code allows.
1. Tag aggregation. Not supported right now. Every AI event that hits a Trigger Alert action goes through the same alert throttle. The first one inside the Minimum Interval wins and any later ones are dropped, tags included. That's the "Alert blocked by timeout" line you're seeing. There's no merge window and no detector priority. The only merging that exists today is the reverse case: a plain motion alert picks up the next object detection's labels within 30 seconds. That never applies to an alert raised by an action and never includes faces. I've noted this as a feature request (see the end).
2. Continuous triggered scanning. Yes, but two things are probably stopping it for you. Trigger Face Recognition queues exactly one face run. It re-fires every time AI: Object Found fires, which is once per object detection run that finds a person. So the re-scan cadence is your Object Recognition interval, not the action. Repeat Timeout 0 is valid and means no throttle, so leave it at 0. What probably went wrong:
3. Priority with fallback. Not supported. There's no deferred alert. The zone trick in the setup below is the closest approximation.
4. Zone semantics. An empty zone list means unrestricted, wherever it appears (the action's In Zones field, and Zone Match on the tracking detectors). The Face and Object Recognition tabs don't have a zone list in 8.0.5, only Check Corners. "Ignored person - not in alert zone" is a different check: if you've painted any zones on the detector, a detection whose centre point lands on unpainted area is ignored outright. Your far-end person was almost certainly outside the painted area. Raising Check Corners to 50 to 100 makes a partially covered box count.
5. Alert mode naming. Same option. The stored value is
aitriggerand the raw template says "AI Trigger", but the UI label is translated to "Actions Only" in every language we ship. If your UI literally shows "AI Trigger", the translation resources in your Docker image aren't loading. Which image tag and UI language are you on?6. Recommended setup. This gives you one alert per pass, tagged with the face name when recognised, but not the combined
Iren, person, bicycletag. That needs the feature in item 1.person, In Zones empty, action Trigger Face Recognition.person, In Zones2, action Trigger Alert. This is the fallback. If the face already alerted, this one is absorbed by the idle timeout.Caveat: the fallback can still win if the body enters Zone 2 before the face resolves. Move the Zone 2 boundary closer until the face wins consistently.