Fine Tune/Filter ONVIF Triggers

0verthnk

n3wb
Jan 11, 2025
2
0
USA
Hi, Blue Iris/NVR noob, first post after much searching/lurking. Haven't found an answer for this, if I missed it, I apologize.

Like so many, struggling w/ false alarms. Experimenting w/ all the usual BI motion detection trigger settings, zones, etc. etc. Also experimenting w/ the camera's built-in triggers via ONVIF, which seem a little better in some ways, worse in others. Yes, I have played w/ a lot of parameters in the cameras' own setup interface. No BI/PC-based AI yet (waiting for my TPU), but I guess that's next.

On a pretty tight budget with this, so no i9, nuclear CUDA gpu, or expensive AI cameras on the horizon for me.

Here's the question: Generally, is there a way to further filter/manipulate the ONVIF data within BI, to, for example lose the motion-based triggers, keeping only the AI(camera) object detection, if that makes any sense?

Is there any way to get back the red detection rectangles in the jpg's when using ONVIF? They really help w/ troubleshooting.

I don't know if the ONVIF stream contains detailed info about the trigger and what caused it, or is it simply a yes/no event. I assume it may be camera make/model dependent?

Before I venture down this potentially long dead-end, was just wondering if anyone has already done any trailblazing?

Thanks so much for any seasoned input on this.
 
Last edited:
Like so many, struggling w/ false alarms. Experimenting w/ all the usual BI motion detection trigger settings, zones, etc. etc. Also experimenting w/ the camera's built-in triggers via ONVIF
Start with BASIC triggers first. Leave the advanced stuff alone till you get the BASIC stuff under control. Don't start turning on all these triggering schemes just yet. FWIW, I can trigger a rough quarter mile away with BASIC motion in BI.
Here's the question: Generally, is there a way to further filter/manipulate the ONVIF data within BI, to, for example lose the motion-based triggers, keeping only the AI(camera) object detection, if that makes any sense?
Yes to all the above. First do you need ONVIF, on cam triggering? BI will do more than what you should need, typically. For me I MUST have ONVIF on, pulling triggering events from the cams. My cams have strobes and audible alerts which I love. If you have normal cams then use BI to trigger from. Your question of lose motion based and keeping AI cam OD puzzles me. I don't need or use that code project AI deal. Never needed it so far.
Is there any way to get back the red detection rectangles in the jpg's when using ONVIF? They really help w/ troubleshooting.
This sounds like on cam triggering. I've seen the red boxes in older Hikvision firmware. If this is what you want login to the cam via a web browser. Set all the triggering you want. Then in BI, ENABLE ONVIF events to pull from the cams your triggered events.
I don't know if the ONVIF stream contains detailed info about the trigger and what caused it, or is it simply a yes/no event. I assume it may be camera make/model dependent?
It does have detail like line crossing events. Get that ONVIF manager program and select events I think it is. I still have this question as I use ONVIF as stated.
Before I venture down this potentially long dead-end, was just wondering if anyone has already done any trailblazing?
I have and still learning. I'm sure many more have done it all already.

I found BASIC motion is great for daytime events. It will trigger as far as your cam can get a clean shot of contrast variations and a size limit.

Night time is another animal. I found line crossing much better for car/truck headlights slash many triggers later deal. It really drops the false triggering which it is not really false, just doing it's job. Basic looks for contrast and at night there is a ton with lights.
 
Let's start with what cameras do you have - in one sentence you state you don't have money for new cameras, in another you state you have cameras with AI.

Don't waste your time and money on a TPU - it has shown to be problematic with AI.

If the cameras don't have AI, then no reason to be messing with ONVIF as the BI motion detection is far superior than motion detection from a camera.


Many of us eliminated most of the false triggers prior to any AI being available.

Mine got to the point prior to AI that if triggered and sent me a push, I knew a person or vehicle was on my property.

AI just took it the next step further and eliminated the few additional false triggers, AND made it less reliant on taking the time to dial in the motion settings.

The biggest thing is increasing make time - most field of views only Superman is getting thru it in under 4 seconds LOL and yet many have it set to 0.1 seconds LOL

Pay some neighborhood kids to walk thru the field of view and run thru the field of view and time it. That can give you a baseline time for motion detection.

Min object size is the next. Don't get greedy with a field of view trying to identify people way out in the distance.

Zone crossings are the next thing to work on.

For some checking the box about an object moves X number of pixels helps.

Edge Vector instead of simple.

There are ways, it just isn't done in 2 seconds. It takes some time to dial each camera in, but if you take the time, you can make it very reliable without all the fancy GPUs and top of the line computers.

Or just update cameras to ones with AI and be done with it LOL.
 
Thanks so much, guys, and sorry for the delay. Lot of snow/precip where I am, and it raises havok w/ my experiments/tuning/etc. I'm reading/learning/trying, and it's a slow process.
A couple of answers to the questions above:
When I refer to "AI" in camera's themselves, I probably used the wrong term. I'm referring to cameras that have some sort of "smart detection" in their own OS/firmware, capable of generating ONVIF data based upon what the cam "thinks" it sees. Not referring to cameras that have some sort of Tensorflow, et al in silicon. That said, my cheap cameras for now are:
Reolink CX810
REOLINK 2K Video Doorbell PoE
(2)Anpviz IPC-D3243W-S
Reolink Duo 2 PPOE
Hikvision_DS-2CD2132-i

My problems (at the moment) are the outside cams. I live "in the woods". 200' driveway, trees within 20' of the house, fox, racoons, a zillion birds, stray cats, etc. There is no amount of tuning I've found so far, using either the camera's detection via ONVIF, or only BI motion/object detection, or a combination which will result in:

No constant triggers/alarms due to:
snow/blowing rain/drizzle.
Tree shadows during strong sun/high wind
Birds flying directly in front of camera (the bastards do this A LOT)
Dusk/dawn IR mode changes in cameras
external lights turning on/off

Consistent correct detection at a reasonable range of distance, say 75 feet, for:
People
Vehicles

I'm trying to restrict zones, play with min/max object sizes, min. contrast, pixel motion, trigger length, etc.

I did get the ONVIF Manager and it's a great tool. I'm hoping to maybe find a Notepad++ plugin, or similar, to parse the output into something more human readable, lol.

Look, as I said, I'm a noob. I'm guessing this CAN be done. But right now, it seems like the total number of combinations of parameters involved in tuning BI object detection, by trial & error, would take Google's Willow 100 years, lol. I'm a reasonably technically proficient guy, but it's maxing my cpu(the one between my ears). I'm thinking that my particular use case is a perfect fit with AI.

I have things set up to send alerts to my phone, and my phone is on a wireguard vpn w/ the LAN that my NVR is on. I can open an RDP session from the phone to BI as I walk around the yard/driveway, and make nearly realtime changes. As I said, the problems arise when meteorological, light-level, or wildlife activity changes occur. Perhaps the first two can be compensated for w/ multiple profiles linked to h/w light-level, weather sensors, etc., but I'm hoping there's a better way.

The Coral reliability issues seem to be mostly related to the USB version. I have PCI.
I have it working. Better in some ways, worse in others.
I keep making changes and waiting. But it's mostly 2 steps forward/two steps back.

That said, there's a TON of good info out there and I'm reading/learning as fast as I can.

If I could get this down to a few false alarms a day, with NO missed real people/cars, across any day/night/weather/birds conditions, I'd be pretty happy with that.

Thanks again for the insights, and sorry for the delayed response.
 
Last edited:
As an Amazon Associate IPCamTalk earns from qualifying purchases.
Start with using one triggering device to start till you get the understanding of how they work.

1.Use BI to trigger from. Turn off all triggering in your cams. Disable everything. Remember to hit SAVE. RESTART the cams.
2.Start with BI BASIC motion triggering first. You have to learn what contrast does as well as min and max sizes. Take a still image from a cam at a truck or car. Set that car size to the max triggering size. Min size say a person or dog. Leave the time at 1 second for starters. Contrast is the difference of say a person with black pants on compared to snow on the ground.

BI on BASIC motion will trigger at least 1/4 mile that I've seen. It offers plenty of contrasting range. So no need to check all the other advanced triggering schemes just yet. Triggering 200 feet away and being able to recognize a stranger are TWO DIFFERENT THINGS. Yes you can trigger but the face will be blurry even with terrific lighting conditions. Try this and holler back.
 
  • Like
Reactions: jrbeddow