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

Performed suggested changes, been running for a couple of hours now without any errors. Thanks for the help PMCross
 
  • Like
Reactions: pmcross
I appear to be getting the same message. I am running DS on Hass.io Any suggestions on resolving this issue?

[10.05.2020, 18:31:09.010]: Starting analysis of D:\aiinput/SD_F_Side.20200510_183108971.jpg
[10.05.2020, 18:31:09.020]: (1/6) Uploading image to DeepQuestAI Server
[10.05.2020, 18:31:09.036]: (2/6) Waiting for results
[10.05.2020, 18:31:09.050]: (3/6) Processing results:
[10.05.2020, 18:31:09.070]: System.NullReferenceException | Object reference not set to an instance of an object. (code: -2147467261 )
[10.05.2020, 18:31:09.084]: ERROR: Processing the following image 'D:\aiinput/SD_F_Side.20200510_183108971.jpg' failed. Failure in AI Tool processing the image.
Is there a fix to get this working? Please let me know.

Thanks
Andy
 
Is there a fix to get this working? Please let me know.

Thanks
Andy

Sorry, I’m not sure what to have you try here. What OS are you running AI Tool on? I’ve only ran Deepstack on Windows and Ubuntu. This sounds like an issue with AI Tool possibly. Have you tried setting up AI Tool on another machine to see if you get the same error?


Sent from my iPhone using Tapatalk
 
Sorry, I’m not sure what to have you try here. What OS are you running AI Tool on? I’ve only ran Deepstack on Windows and Ubuntu. This sounds like an issue with AI Tool possibly. Have you tried setting up AI Tool on another machine to see if you get the same error?


Sent from my iPhone using Tapatalk
I have AI Tool running on a VM windows 10 machine. I have deepstack running off a VM for hassio. I can try downloading AI Tool again and reconfigure it.
 
Hello everyone. I have read through all the posts, and have tested out various installation methods, on various computers. I have gotten AITool to work with deepstack and Blue Iris. HUGE thanks to GentlePumpkin.

I have tested linux on the following systems:

1. Intel Celeron J3455 quad-core 1.5GHz (Synology 1019+)
2. Intel i5-8500 CPU @ 3.00GHz (Fujitsu Esprimo)
3. Intel i7-7700HQ CPU @ 2.80GHz, with Nvidia GForce 1060 (Asus laptop)

My problem is I only seem to get the noavx container to work on linux, and I would really like to get the full version (or better still: the nvidia version) to work. All my processors should in my opinion be able to run AVX.

@nstig8 seems to have had som experience with this from what I can see in a previous post (page 18).

My first question is: My impression is that when the web-page has no field for the api-key, the server will not respond to requests:

NOT working (cpu and gpu tag):
deepstack_latest.PNG

Working (noavx tag):
deepstack_noavx.PNG

Has anyone had other experiences, and am I right or wrong in my assumption?

If anyone has gotten Deepstack to work without the API-key-field on the web-page, I'd like to know more about what kind of linux installation used. Right now I'm using this benchmark to see if an installation will function, and I might be wrong here, and would need to test more before rejecting the installation as "not workin".

Thanks in advance for any feed-back.
 

Attachments

  • deepstack_noavx.PNG
    deepstack_noavx.PNG
    610.9 KB · Views: 29
Last edited:
@morten67, I'm not sure that the Celeron processors have AVX. The wiki I found on AVX said that most Pentium and Celeron brand CPU's lacked it and Core CPU's include it. I don't know if that's accurate or not as the Intel pages I checked don't mention AVX. I can confirm that I was unable to get the AVX version of DS to run on my QNAP NAS with a Celeron N3060. I did get it to run without AVX, but it was way too slow to be useful.



 
I had this same issue that a few people have been having running in a VM in Proxmox, actually 2 VMs - the Linux one I use for Docker and then the Windows one I use for Blue Iris. I finally figured it out. It is because the default processor type for VMs is kvm64 which does not have support for Advanced Vector Extensions (AVX) or the SSE instruction set. The deepquestai/deepstack docker image uses AVX so the image processing was failing. I only noticed because there is a noavx tagged deepstack image in the docker hub. Since my processor (Ivy Bridge) does support AVX I stopped the VMs and updated the config of the processor type in proxmox to Ivy Bridge and deepstack works now. I believe using the "host" processor type would have the same result (so long as your processor can support AVX). This would also explain TechNight's LXC working because LXCs use the host CPU directly rather than a virtual processor layer.
@morten67, I'm not sure that the Celeron processors have AVX. The wiki I found on AVX said that most Pentium and Celeron brand CPU's lacked it and Core CPU's include it. I don't know if that's accurate or not as the Intel pages I checked don't mention AVX. I can confirm that I was unable to get the AVX version of DS to run on my QNAP NAS with a Celeron N3060. I did get it to run without AVX, but it was way too slow to be useful.
Yes, you might be right about the Celeron. Thanks for your input. I know for a fact that the i7 has it, and I'm pretty sure the i5 has it. The Celeron (running noavx) takes roughly 6 seconds for each image, but can not hang on for long if there are more than 4-5 images in the queue. Right now I'm testing the windows version set on high on the i7 (but I believe it might not be using the gpu). Total response time is fairly fast. Will test some more. I'm especially hoping to improve detection at night by setting deepstack to HIGH. I'm very impressed with what it does in daylight, but a bit disappointed with images at night. I have inceased the contrast on the cameras, but detection is still below 50%.
 
Yeah my older Celeron on my NAS was taking even longer per image, and I'm only sending it 640x480 images. It's pretty fast on my old i5-2300 BI box. But when I get all the cameras active and triggering, running everything on the one machine is pretty taxing on the CPU. I got a RPI 4 with the Intel Neural stick set up and it's working well. Less than a second per image (Deepstack side). Having this AI is a huge improvement for my setup. I certain cameras throwing frequent false alerts no matter what zones and detection settings in BI I tried. Now it's much more accurate.
 
  • Like
Reactions: morten67
If anyone has gotten Deepstack to work without the API-key-field on the web-page, I'd like to know more about what kind of linux installation used. Right now I'm using this benchmark to see if an installation will function, and I might be wrong here, and would need to test more before rejecting the installation as "not workin".

It's working for me with not tags specified. when i added the gpu tag it worked for a while then suddenly stopped working after a day or two. i've never seen the api key field on the webpage and up until now wondered what the web page was even for at that point.

i am running it in unraid
 
It's working for me with not tags specified. when i added the gpu tag it worked for a while then suddenly stopped working after a day or two. i've never seen the api key field on the webpage and up until now wondered what the web page was even for at that point.

i am running it in unraid
I was running Deep Stack on my HP Z420 with a Xeon E5-2960 V2 with 10 cores (20 cores with Hyper Threading) which also runs 15 cameras in BI, Home Assistant (using VMware Workstation) and a pfSense VM (also in VMware Workstation) to terminate an IPsec VPN tunnel for work and it was too much for the CPU to handle after adding on 3 additional cameras. I ended up reviving an old Dell PowerEdge 2950 with two quad core CPU's that I had sitting in my basement to run Deep Stack. I am running Ubuntu on it with Docker with the noavx tag as the CPU's don't support AVX. I am running in a RAID 5 config and I typically get less than a 2 second response time on the Deep Stack side. My plan is to buy another HP Z420 to run Deep Stack duty to replace the PowerEdge 2950. Overall this solution is far superior to Sentry. After creating masks in AI Tool and tweaking the confidence levels for each camera, I have about a 98% success rate on alerts, even at night.
 
  • Like
Reactions: fenderman
It's working for me with not tags specified. when i added the gpu tag it worked for a while then suddenly stopped working after a day or two. i've never seen the api key field on the webpage and up until now wondered what the web page was even for at that point.

i am running it in unraid

Interresting. So I have been wrong to outright dismiss the installation when there was no field to enter API-key. I believe I'll give it another try on my i7, starting with the cpu-container. I have already tried several times, but maybe I should let it run for some time before I dismiss it. For the gpu-container there are some more things to watch out for: nvidia-driver and nvidia-docker-version. Thanks for the feed-back.
 
Hey @GentlePumpkin just wanted to say thanks fo the tool and for posting the source on GitHub. I spent a few minutes in c# earlier and got it to work with my Synology Surveillance Station. Only had to make a couple changes to your code and it is working great.
 
My only issue with deepstack was one of the tutorials (deepstack.cc installation for linux) listed this as the run command:
docker run -e VISION-SCENE=True -v localstorage:/datastore -p 80:5000 deepquestai/deepstack

and I didn't initially notice that I needed VISION-DETECTION=True

Anyone who gets the following error, the above comment fixed it for me.

[14.05.2020, 20:05:36.045]: (1/6) Uploading image to DeepQuestAI Server
[14.05.2020, 20:05:36.070]: (2/6) Waiting for results
[14.05.2020, 20:05:36.078]: (3/6) Processing results:
[14.05.2020, 20:05:36.085]: System.NullReferenceException | Object reference not set to an instance of an object. (code: -2147467261 )
 
I am considering setting up and testing this, anything I should know? Also, can you have the cool down be by event type? IE notification for vehicle (start vehicle cooldown), and if a human is then detected it notifies you and starts a human cooldown cycle?

Thanks,
-Dwight
 
Not natively. I think that the only way to achieve this would be to create a duplicate camera with a different name in BI as well as AI Tool and set the detection type to vehicles and the duplicate to person. This wouldn’t be controlled by the cool down period in AI Tool. This would be a nice feature though.


Sent from my iPhone using Tapatalk
 
  • Like
Reactions: DwightMorgan
If anyone has gotten Deepstack to work without the API-key-field on the web-page, I'd like to know more about what kind of linux installation used. Right now I'm using this benchmark to see if an installation will function, and I might be wrong here, and would need to test more before rejecting the installation as "not workin".

Thanks in advance for any feed-back.

I did not get the API-key field in my docker image install, which is working and it is the one I am currently using. I did get asked for a key for the Windows installation, but once I figured out the AVX issue I abandoned that one and went back to working with the docker container.
 
I was running Deep Stack on my HP Z420 with a Xeon E5-2960 V2 with 10 cores (20 cores with Hyper Threading) which also runs 15 cameras in BI, Home Assistant (using VMware Workstation) and a pfSense VM (also in VMware Workstation) to terminate an IPsec VPN tunnel for work and it was too much for the CPU to handle after adding on 3 additional cameras. I ended up reviving an old Dell PowerEdge 2950 with two quad core CPU's that I had sitting in my basement to run Deep Stack. I am running Ubuntu on it with Docker with the noavx tag as the CPU's don't support AVX. I am running in a RAID 5 config and I typically get less than a 2 second response time on the Deep Stack side. My plan is to buy another HP Z420 to run Deep Stack duty to replace the PowerEdge 2950. Overall this solution is far superior to Sentry. After creating masks in AI Tool and tweaking the confidence levels for each camera, I have about a 98% success rate on alerts, even at night.

I was seeing very poor detection performance at night just like @morten67 above. I have my confidence interval set from 10% - 100%. I'd still say it misses on over half my front door triggers, but is almost perfect in daylight. Do you have any other pointers on getting night detection to work better or is the contrast / overhead angle of my camera just bad for night detection?
I ended up setting up a day and night profile in Blue Iris for now. The day profile takes the screenshots that are processed by deepstack, while after sunset the night profile falls back on my old motion sensor trigger settings. This fixed most of my false alerts (shadows from trees) but I do still get the occasional spiderweb in front of a camera at night causing it to record almost all night long.
 
I was seeing very poor detection performance at night just like @morten67 above. I have my confidence interval set from 10% - 100%. I'd still say it misses on over half my front door triggers, but is almost perfect in daylight. Do you have any other pointers on getting night detection to work better or is the contrast / overhead angle of my camera just bad for night detection?
I ended up setting up a day and night profile in Blue Iris for now. The day profile takes the screenshots that are processed by deepstack, while after sunset the night profile falls back on my old motion sensor trigger settings. This fixed most of my false alerts (shadows from trees) but I do still get the occasional spiderweb in front of a camera at night causing it to record almost all night long.

Full disclosure, the majority of my cameras run in forced color mode at night, so this may be why I get better success with alerts at night.

When you look in AI Tool for missed events at night, are they showing as false alerts or is Deepstack detecting people as different objects?


Sent from my iPhone using Tapatalk
 
Full disclosure, the majority of my cameras run in forced color mode at night, so this may be why I get better success with alerts at night.

When you look in AI Tool for missed events at night, are they showing as false alerts or is Deepstack detecting people as different objects?


Sent from my iPhone using Tapatalk
Mostly missed completely (false alerts), although a couple where it identified me as a dog (40%). I had only set up my front door camera (DS-2CD2342WD-I) before which is mounted above and to the left of the porch so not as much contrast in night view between people and the ground I guess. I just now set up my garage camera (DS-2CD2343G0-I) with deepstack and it seems to work great even in night mode. The IR image is much better in the garage I think, and the substream feed for that camera is 640x480 instead of 640x360 for the front door.
I'll probably keep the front door on the motion sensor profile at night, but hopefully my other cameras can be full time deepstack triggered.
 
Tonight I thought I would install DeepQuestAI on another computer and have AI Tool point to this other computer. I entered the IP address in AI Tool but the errors I received were “can’t reach localhost:81”.

I am running DeepQuestAI on a Win10 machine.

Has anyone else tried to run DeepQuestAI on another computer (not the BI computer)?