Hell Yeah! Direct Deepstack Integration - 5.4.0 - March 31, 2021

fenderman

Staff member
Joined
Mar 9, 2014
Messages
36,897
Reaction score
21,250
One other message for Ken, I'm concerned about the reports elsewhere on the forum that surfaced that BI is atcually quite unstable and prone to crashing. It would be really good to write some code to log every event verbatum and then send the code as a crash report when BI crashes so as help identify the unsatble events / areas / code. A friend of mine wrote a similar self diagnosing code for the company he works for and it was highly successful in diagnosing and removing the bugs, although they also employed a large number of community testers who also fed back manual information on the events that led to a crash. It's slighty different here in that their users would have been actively using the App when it crashed, whereas with BI, being CCTV, it's often running on it's own when that occurs making the events that led up to it not obvious.
What are you talking about? That is simply a false statement. Blue iris is very stable. I have over 20 machines with BI that run rock solid. The crashing that some users report is often related to using an intel driver with a memory leak or user error or those who install a new release before its marked as stable. You need to understand that there a many thousands of blue iris users. Probably well over 100k. If a handful of users report an issue on a user forum its not something to be "concerned" about.
 

fenderman

Staff member
Joined
Mar 9, 2014
Messages
36,897
Reaction score
21,250
A note on BI stability. I am using the latest version, not even the version labelled as "stable" and I have NEVER had Blue Iris crash in over 4 years of using Bi and I always update to the absolute latest version. If BI is crashing, I would suggest check your Windows setup and not blame BI for it. There are many COMMERCIAL installs of Blue Iris running 24/7 that also never crash. BI has quite a good logging system already built in, I am pretty sure you can find the cause of virtually all crashes in the existing logging system and in the Windows Event Logs.
That said, I have never had to do that. Maybe the people with Blue Iris crashing are using the PC for more than just Blue Iris??
For something as critical as CCTV, I only use one other application on the BI PC, which is my home automation system. As both are critical services, I don't do anything else with the system.
He is not even a blue iris user and i believe to date owns one or two ipcameras. The premise that there is an increase in crashing is simply false and baseless.
 

austwhite

Getting the hang of it
Joined
Jun 7, 2020
Messages
93
Reaction score
92
Location
USA
He is not even a blue iris user and i believe to date owns one or two ipcameras. The premise that there is an increase in crashing is simply false and baseless.
I have read the "crash" threads. Most of them are more Windows crashing because they are not dedicating the machine to BI and using other crap software.
BI is rock solid. Seems a few people like to blame BI for crashing when it is either their crappy, second hand hardware or they run other crappy software on the same machine.
Yeah, basically agreeing with you. BI is solid.
Now back to the regularly scheduled program
 

RoelP

n3wb
Joined
Nov 7, 2020
Messages
5
Reaction score
1
Location
Utrecht
It somehow started to work automatically after a scheduled PTZ zoom event was triggered on the specific CAM that did not work previously. I did not have to reconfigure anything else luckily
Now I think it may not have been working because the ALERTS section of the camera was not fully configured to trigger the specific zones.
Previously it was set on this camera to never trigger alerts and when I enabled the alerts to tigger it was set to only 1 zone.
The zoom event I talked about previously helped to trigger the specific zone that was configured to trigger the alert.
So maybe deepstak will only process the image if all alert conditions are met?
For plate recognizer AI having alerts configured was not a dependency, but for deepstack it seems to be required, which makes sense (as the purpose of deepstack is to supress false alerts).
This is not fully confirmed by anyone, but maybe this will brainstorm will help others that were having the same issue with deepstack processing some cams and not other cams or not processing specific zones on those cams.

1617450684969.png
 

austwhite

Getting the hang of it
Joined
Jun 7, 2020
Messages
93
Reaction score
92
Location
USA
Blue Iris's implementation of the AI only takes the first image to process, though you can set that to take up to the first 5 images, at 1 second apart.
If motion triggers the camera, but Deepstack does not recognise an object in that first 1 to 5 seconds (depending how you have it set) then it wont detect it as an object.
This is where the AI Tool works better as it will process images throughout the entire trigger time. Ie: If you have BI set to take an image every 5 seconds when triggered, the AITool would send them to deepstack every 5 seconds, comparred to blue iris sending only a maximum of the first 5 images, 1 second apart.

I think this would explain a lot of my missed events that are not missed by AI Tools
 

austwhite

Getting the hang of it
Joined
Jun 7, 2020
Messages
93
Reaction score
92
Location
USA
i guess there is nothing stopping us from running both AI tools and BI's implementation at the same time to catch all ?
I am doing that at the moment, though to be honest, other than putting icons on the Alert image for car or person or whatever, AI Tools has never missed one that BI has caught on it's own.
I do like that it is integrated in BI and it likely catches 70% of events at this stage. I think it will improve as Ken refines it. It is definitely a good start.
 

sebastiantombs

Known around here
Joined
Dec 28, 2019
Messages
11,511
Reaction score
27,690
Location
New Jersey
....
Also note there posts where folks claim differences in accuracy between the cpu and gpu versions, where cpu is more accurate. Dont know if that has been resolved yet.
That may explain the lack of detection I am seeing at night. I'm using the NVidia version of DeepStack. At night it's not detecting anything, cars, trucks, buses, deer, cats, dogs but will occasionally "see" a human. On the other hand, the CPU impact is so low I can't see any real change at all.
 

austwhite

Getting the hang of it
Joined
Jun 7, 2020
Messages
93
Reaction score
92
Location
USA
That may explain the lack of detection I am seeing at night. I'm using the NVidia version of DeepStack. At night it's not detecting anything, cars, trucks, buses, deer, cats, dogs but will occasionally "see" a human. On the other hand, the CPU impact is so low I can't see any real change at all.
Try the CPU version. It doesnt really use too many extra cycles. The GPU version, particularly for Windows, can be a little hit and miss.
If you have a spare PC, could try running DeepStack on another computer, maybe in a Linux VM under virtualbox or something similar. The DeepStack Docker image is pretty good.
 

wittaj

IPCT Contributor
Joined
Apr 28, 2019
Messages
24,428
Reaction score
47,541
Location
USA
Yeah, I would expect the next update would include the ability to send photos during the whole motion detection or at least do more than 5? I am sure there is a reason he capped it at 5 for this first go around, probably to deal with CPU spikes.

It works great for my cameras field of view that I expected it to do well with, and struggles with the views I thought would be an issue, but modifying the motion detection setups has been improving this.
 
Last edited:

IAmATeaf

Known around here
Joined
Jan 13, 2019
Messages
3,287
Reaction score
3,252
Location
United Kingdom
The more pictures you send the more the load on imposes by Deepstack. When I used to ran AITools during the analysis my CPU would shoot up anywhere from 30% to 55-60%.
 
Joined
Jan 30, 2021
Messages
15
Reaction score
2
Location
Australia
So I installed the latest BI update to include the Deepstack implementation but I don't think it's working yet. If I put 127.0.0.1:my port, in a web browser I get the Deepstack page telling me it's activated. The Deepstack CLI window tells me I'm running version 2021.02.1 and the next two lines say - v1/backup and v1/restore but that's all I'm getting on there.
The main BI settings / AI tab has the Deepstack start / stop button showing "stop" indicating I've started it. In the BI alerts panel, all the alerts are listed as "Motion A" - Should I be expecting it to tell me what the alert subject is?
Any help appreciated.
 

fenderman

Staff member
Joined
Mar 9, 2014
Messages
36,897
Reaction score
21,250
So I installed the latest BI update to include the Deepstack implementation but I don't think it's working yet. If I put 127.0.0.1:my port, in a web browser I get the Deepstack page telling me it's activated. The Deepstack CLI window tells me I'm running version 2021.02.1 and the next two lines say - v1/backup and v1/restore but that's all I'm getting on there.
The main BI settings / AI tab has the Deepstack start / stop button showing "stop" indicating I've started it. In the BI alerts panel, all the alerts are listed as "Motion A" - Should I be expecting it to tell me what the alert subject is?
Any help appreciated.
You need to activate it in each camera in the trigger tab.
 

fenderman

Staff member
Joined
Mar 9, 2014
Messages
36,897
Reaction score
21,250
Sorry yeah done that too - dropped the min confidence level to 10%, tried 1 picture, tried 5 pictures. Tried ticking and not ticking the other boxes in that screen.
Try adding the camera again from scratch and see if it works
 

austwhite

Getting the hang of it
Joined
Jun 7, 2020
Messages
93
Reaction score
92
Location
USA
So I installed the latest BI update to include the Deepstack implementation but I don't think it's working yet. If I put 127.0.0.1:my port, in a web browser I get the Deepstack page telling me it's activated. The Deepstack CLI window tells me I'm running version 2021.02.1 and the next two lines say - v1/backup and v1/restore but that's all I'm getting on there.
The main BI settings / AI tab has the Deepstack start / stop button showing "stop" indicating I've started it. In the BI alerts panel, all the alerts are listed as "Motion A" - Should I be expecting it to tell me what the alert subject is?
Any help appreciated.
This doesn't sound right. When checking the CLI you should at least have the Detection URL come up as well, which is /v1/vision/detection.
Are you using Blue Iris to start DeepStack or are you running it separately? If you run separate from BI you need to use the option VISION-DETECTION=True.
When Object Detection API is enabled it should show these:
DeepStack: Version 2021.02.1
---------------------------------------
/v1/vision/detection
---------------------------------------
---------------------------------------
v1/backup
---------------------------------------
v1/restore
 
Joined
Jan 30, 2021
Messages
15
Reaction score
2
Location
Australia
This doesn't sound right. When checking the CLI you should at least have the Detection URL come up as well, which is /v1/vision/detection.
Are you using Blue Iris to start DeepStack or are you running it separately? If you run separate from BI you need to use the option VISION-DETECTION=True.
When Object Detection API is enabled it should show these:
DeepStack: Version 2021.02.1
---------------------------------------
/v1/vision/detection
---------------------------------------
---------------------------------------
v1/backup
---------------------------------------
v1/restore
I did initially just hit the "start" button in the main settings / AI tab of BI but when that didn't seem to be working I tried entering "deepstack --VISION-DETECTION True --PORT xx" into cmd. It took a second or two and then returned the same as the Deepstack CLI window (version and v1 backup / restore etc). I'm not 100% sure I'm even entering into cmd correctly tbh.
 

austwhite

Getting the hang of it
Joined
Jun 7, 2020
Messages
93
Reaction score
92
Location
USA
I did initially just hit the "start" button in the main settings / AI tab of BI but when that didn't seem to be working I tried entering "deepstack --VISION-DETECTION True --PORT xx" into cmd. It took a second or two and then returned the same as the Deepstack CLI window (version and v1 backup / restore etc). I'm not 100% sure I'm even entering into cmd correctly tbh.
It should be C:\DeepStack\deepstack.exe --VISION-DETECTION=True --PORT 83 assuming default install path on windows
Need the = sign in there.

Note: IF you start DeepStack in BI then try to run DeepStack with no options, it runs a second version of DeepStack with no API enabled, it doesn't show what the current version is running as.
 
Joined
Jan 30, 2021
Messages
15
Reaction score
2
Location
Australia
It should be C:\DeepStack\deepstack.exe --VISION-DETECTION=True --PORT 83 assuming default install path on windows
I just realised I didn't have an "=" before True in my command. Just ran it again with that and the CMD returned the following -
-----------------------------------------
DeepStack: Version 2021.02.1
flag provided but not defined: -Port
Usage of deepstack:
-ADMIN-KEY string
admin key to secure admin endpoints
-API-KEY string
api key to secure endpoints
-MODE string
performance mode (default "Medium")
-MODELSTORE-DETECTION string
path to custom detection models (default "/modelstore/detection/")
-PORT int
port (default 5000)
-TIMEOUT float
request timeout in seconds (default 60)
-VISION-DETECTION string
enable object detection
-VISION-FACE string
enable face detection
-VISION-SCENE string
enable scene recognition
-----------------------------------------------
Will keep playing with it in the morning - 2am here time for sleep.
Thanks for your help.
 
Top