[tool] [tutorial] Free AI Person Detection for Blue Iris

ManImCool

n3wb
Joined
Jun 4, 2020
Messages
4
Reaction score
0
Location
Texas
The main camera is the one that should send the MQTT event, not the cameraai one. Just add it to the On Alert trigger list of the main camera (HD feed) and it should work as you expect. That's how I was running for a while until...

... I added MQTT support directly in my alternate, Docker-based, approach. I really didn't like messing with BlueIris for MQTT events and wanted it to come directly from the AI system to my Home Assistant install. That way I can have home automation control when to kick BlueIris into recording with advanced logic, e.g. when I'm on the deck enjoying the nice weather there's no need to trigger HD recording.
Oh I hope that's the fix! Wait, does that mean I need to change for my main 24/7 camera, under "Alerts" tab "Fire when"? Because it's currently set to "Never." Or should I be changing something on my "Trigger" tab?
 

pmcross

Pulling my weight
Joined
Jan 16, 2017
Messages
371
Reaction score
185
Location
Pennsylvania
Oh I hope that's the fix! Wait, does that mean I need to change for my main 24/7 camera, under "Alerts" tab "Fire when"? Because it's currently set to "Never." Or should I be changing something on my "Trigger" tab?
on the HD camera motion detection should be turned off, but the fire when "this camera is triggered" should be on under the alerts tab.
 

ManImCool

n3wb
Joined
Jun 4, 2020
Messages
4
Reaction score
0
Location
Texas
Ok, I have the main camera to Fire When this camera is triggered, but the obvious question is how does it get triggered? On the Trigger tab, I have nothing checked under Sources. The only box checked on that entire Trigger tab is "Capture an alert list image."
 

pmcross

Pulling my weight
Joined
Jan 16, 2017
Messages
371
Reaction score
185
Location
Pennsylvania
Ok, I have the main camera to Fire When this camera is triggered, but the obvious question is how does it get triggered? On the Trigger tab, I have nothing checked under Sources. The only box checked on that entire Trigger tab is "Capture an alert list image."
It gets triggered by AI Tool using the URL or MQTT command, depending on which version you're running (AI Tool on Windows, or the @neile's version)
 

ManImCool

n3wb
Joined
Jun 4, 2020
Messages
4
Reaction score
0
Location
Texas
Awesome, that did the trick, thanks all!

Is there any way to tweak settings so that AI Tool is more likely to trigger BI? My tolerances are already 0-100% on AI Tool, yet there are plenty of images it scans where a person is in the picture but it fails to see the person and incorrectly calls it a false alert.
 

neile

Getting the hang of it
Joined
May 15, 2020
Messages
132
Reaction score
67
Oh I hope that's the fix! Wait, does that mean I need to change for my main 24/7 camera, under "Alerts" tab "Fire when"? Because it's currently set to "Never." Or should I be changing something on my "Trigger" tab?
See danecreekphotography/node-deepstackai-trigger. It has step-by-step instructions for setting up a single physical camera in the 24x7 SD/On demand HD configuration.
 

gazoo

n3wb
Joined
Dec 11, 2017
Messages
27
Reaction score
0
I can't get this to work no matter what. I've tried FOR DAYS. The AI tool just won't acknowledge the exisitence of the deepstack AI server. I tried a windows install on another machine, doesn't see it. Yes I can access it via URL and it says activated. Then I tried running both of those in admin mode, nope. Then I moved to a portainer container in Hass.IO like the video. Looks to be running (deepstack) - but AI Tool refuses to see it. Tried with all firewalls off - nope. I'm about to throw this in the lake.
 

neile

Getting the hang of it
Joined
May 15, 2020
Messages
132
Reaction score
67
I can't get this to work no matter what. I've tried FOR DAYS. The AI tool just won't acknowledge the exisitence of the deepstack AI server. I tried a windows install on another machine, doesn't see it. Yes I can access it via URL and it says activated. Then I tried running both of those in admin mode, nope. Then I moved to a portainer container in Hass.IO like the video. Looks to be running (deepstack) - but AI Tool refuses to see it. Tried with all firewalls off - nope. I'm about to throw this in the lake.
Try the Docker container approach. Same BlueIris config, different trigger manager. Comes with the Deepstack AI server as part of the package and pre-configured so there's no connectivity issues to worry about. Install it on the same machine that's running BlueIris for easy setup.
 

gazoo

n3wb
Joined
Dec 11, 2017
Messages
27
Reaction score
0
Try the Docker container approach. Same BlueIris config, different trigger manager. Comes with the Deepstack AI server as part of the package and pre-configured so there's no connectivity issues to worry about. Install it on the same machine that's running BlueIris for easy setup.
I just read through it and was having a hard time understanding it. So it's basically both tools in one right? How do I edit stuff in docker? I've never used docker, but have used it in the portainer container in hass.io recently. I'm wondering if I could load it on that?
 

GentlePumpkin

IPCT Contributor
Joined
Sep 4, 2017
Messages
193
Reaction score
321
I can't get this to work no matter what. I've tried FOR DAYS. The AI tool just won't acknowledge the exisitence of the deepstack AI server. I tried a windows install on another machine, doesn't see it. Yes I can access it via URL and it says activated. Then I tried running both of those in admin mode, nope. Then I moved to a portainer container in Hass.IO like the video. Looks to be running (deepstack) - but AI Tool refuses to see it. Tried with all firewalls off - nope. I'm about to throw this in the lake.
You did select the detection API in Deepstack and you did select the right port? Please write me a private message with your Log, a screenshot of the deepstack website, a screenshot only of the url of Blue Iris Webinterface UI3 and a screenshot of your settings tab in AI Tool.
 

naidu

Young grasshopper
Joined
May 22, 2020
Messages
31
Reaction score
5
Location
USA
I just read through it and was having a hard time understanding it. So it's basically both tools in one right? How do I edit stuff in docker? I've never used docker, but have used it in the portainer container in hass.io recently. I'm wondering if I could load it on that?
I have same issue I am trying to make it work in HomeAssistant.
 

neile

Getting the hang of it
Joined
May 15, 2020
Messages
132
Reaction score
67
Yes, it's both tools in one and pre-configured to talk to each other. Docker really isn't hard. Skip portainer and hass.io, it's just way more complicated than you need. I assume you have a Windows machine already running BlueIris so install directly on that.

Follow the quick start instructions I provided above. You only make two edits to the docker-compose.yaml file, which is plain text and can be edited in any text editor you like (I recommend VSCode, but Notepad++ or even Notepad works). You'll have the system up and running but not really processing anything. Then edit the sample triggers.json file to configure your triggers (similar to the configuration you've done in the AI Tool) and it'll start detecting things.

If you have additional questions about trying this route I suggest adding them to the dedicated thread for the alternate approach.
 
Last edited:

pmcross

Pulling my weight
Joined
Jan 16, 2017
Messages
371
Reaction score
185
Location
Pennsylvania
I can't get this to work no matter what. I've tried FOR DAYS. The AI tool just won't acknowledge the exisitence of the deepstack AI server. I tried a windows install on another machine, doesn't see it. Yes I can access it via URL and it says activated. Then I tried running both of those in admin mode, nope. Then I moved to a portainer container in Hass.IO like the video. Looks to be running (deepstack) - but AI Tool refuses to see it. Tried with all firewalls off - nope. I'm about to throw this in the lake.
Please see post # 338 on this thread. It goes over the prerequisites for Deepstack on Windows. Also, does your processor support AVX? If not you'll need to run Deepstack inside of Docker on a Linux machine using the :noavx command.
 

gazoo

n3wb
Joined
Dec 11, 2017
Messages
27
Reaction score
0
Please see post # 338 on this thread. It goes over the prerequisites for Deepstack on Windows. Also, does your processor support AVX? If not you'll need to run Deepstack inside of Docker on a Linux machine using the :noavx command.
No sure how to check this (AVX), but I did do your suggested patches and it made no difference - AI tool did not reach the server. Also, I ran it on a different server. I'm running out of CPU cycles and space on my VM where Blue Iris runs so I tried to run it on the host windows 10 machine. So maybe I shall put it all in the same Vmachine and try again. I am somewhat interested in nelie's new way, but being a lazy non-programmer the AI tool makes config 10x faster and clearer than editing the files (which I'll probably end up doing if this doesn't work). The VM is probably even more muddy or worse so far as AVX support. I'll try anyway.
 

neile

Getting the hang of it
Joined
May 15, 2020
Messages
132
Reaction score
67
If you install VSCode and edit the files with it it's not really any different than the AI tool. You get full auto-complete for all the properties, with tooltips to tell you what everything is. The sample file I provide has a basic setup specifically for talking to BlueIris: all you have to do is change the names of the cameras and copy paste the block a few times for each camera you want to connect to.
 

pmcross

Pulling my weight
Joined
Jan 16, 2017
Messages
371
Reaction score
185
Location
Pennsylvania
No sure how to check this (AVX), but I did do your suggested patches and it made no difference - AI tool did not reach the server. Also, I ran it on a different server. I'm running out of CPU cycles and space on my VM where Blue Iris runs so I tried to run it on the host windows 10 machine. So maybe I shall put it all in the same Vmachine and try again. I am somewhat interested in nelie's new way, but being a lazy non-programmer the AI tool makes config 10x faster and clearer than editing the files (which I'll probably end up doing if this doesn't work). The VM is probably even more muddy or worse so far as AVX support. I'll try anyway.
More modern CPU's support AVX. I have a HP Z420 with a Xeon E5 2960 V2 CPU that supports AVX, but like you I was oversubscribing my CPU as I have BI with 15 cameras and running Deepstack on it was too much. The easiest way to be sure aboout AVX support is to spin up a Ubuntu VM and do docker pull deepquestai/deepstack:noavx and then start it with the noavx tag and see if AI Tool can contact it. I ended up reviving an old Dell PowerEdge to run ESXi on with a Ubuntu VM for Deepstack. noavx is slower, but I still get response times under 2 seconds running on low mode.
 

actran

Getting comfortable
Joined
May 8, 2016
Messages
806
Reaction score
731
Are there any plans to provide Deepstack AI with a list of known faces and only trigger action for unknown person event?
 
Top