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

If you have a location to change the start command for the docker you can add the environment variables on the start line.
For example: docker run -e VISION-DETECTION =True -v localstorage:/datastore -p 80:5000 deepquestai/deepstack:latest

But I think the easy answer is to just add the variables through the UI.


I found a few links that may help.

If you look at the this link Setup HomeAssistant on QNAP Container using Docker – Poyu do you see an option on the left side for environment variables ? see below image from the link listed.

View attachment 74149


Last I found this link that talks about working within the container config files.

Hope this helps some.
Entering the Environmental Variable as shown above wouldn't work because hyphens are not allowed. I'm going to read through the second link you provided. I really appreciate your help!
 
If your running Deepstack on a different machine in Docker, does that machine need access to the alert images on the BI machine where AI Tools is installed?
 
im trying to set this up but keep getting an error


[05.11.2020, 10:28:20]: ERROR: Processing the following image 'E:\Snapshots\Cam4.20201105_102819598.jpg' failed. Failure in AI Tool processing the image.
[05.11.2020, 10:30:26.002]: Cleaning cameras/history.csv if neccessary...
[05.11.2020, 10:30:28.703]: Loading time line from cameras/history.csv ...
[05.11.2020, 10:30:28.708]: Loading confidence-frequency chart from cameras/history.csv ...
[05.11.2020, 10:30:36.518]: Loading time line from cameras/history.csv ...
[05.11.2020, 10:30:36.522]: Loading confidence-frequency chart from cameras/history.csv ...
[05.11.2020, 10:31:02.304]: Loading time line from cameras/history.csv ...
[05.11.2020, 10:31:02.309]: Loading confidence-frequency chart from cameras/history.csv ...
[05.11.2020, 10:31:53]: ERROR: Processing the following image 'E:\Snapshots\Cam4.20201105_103153347.jpg' failed. Failure in AI Tool processing the image.
[05.11.2020, 10:31:53.373]:
[05.11.2020, 10:31:53.377]: Starting analysis of E:\Snapshots\Cam4.20201105_103153347.jpg
[05.11.2020, 10:31:53.392]: (1/6) Uploading image to DeepQuestAI Server
[05.11.2020, 10:31:53.451]: (2/6) Waiting for results
[05.11.2020, 10:31:53.548]: (3/6) Processing results:
[05.11.2020, 10:31:53.553]: System.NullReferenceException | Object reference not set to an instance of an object. (code: -2147467261 )
[05.11.2020, 10:31:53.556]: ERROR: Processing the following image 'E:\Snapshots\Cam4.20201105_103153347.jpg' failed. Failure in AI Tool processing the image.


deepstack is running on windows docker using this command

docker run -e VISION-SCENE=True -v localstorage:/datastore:rw -p 80:5000 deepquestai/deepstack
 
@105437 - From the error, the problem still does not look like it is on the AITOOL end. I dont think you have VISION-DETECTION=True set correct as talked about above. I wouldnt know how to do that for QNAP.

Same error here, and I'm pretty sure it is because he is using VISION-SCENE=True not VISION-DETECTION=True:

Damn it, that's my old post. I must try again in that case, as I never got it working...
 
  • Like
Reactions: Chris Dodge
@105437 - From the error, the problem still does not look like it is on the AITOOL end. I dont think you have VISION-DETECTION=True set correct as talked about above. I wouldnt know how to do that for QNAP.

Same error here, and I'm pretty sure it is because he is using VISION-SCENE=True not VISION-DETECTION=True:

Also I saw the Deepstack tab > STOP being used in the log before - to be clear, that is only for the Windows version running on the same machine. Nothing to do with the QNAP version. And you wouldn't see those PYTHON errors from qnap either.
We get viscio-scene from the deepstack tutorial of docker installation.

Copy and paste

Sent from my SM-N960F using Tapatalk
 
  • Like
Reactions: kosh42efg
We get viscio-scene from the deepstack tutorial of docker installation.

Copy and paste

Sent from my SM-N960F using Tapatalk
Yep, that feature looks at the entire image and tries to decide what the scene is. (conference room), detection looks for an object in an image to determine if its there. Or at least that is how I read it...
 
Last edited:
  • Like
Reactions: kosh42efg
Bug, annoyance or operator error?

Using the newest AI tool V2. Since it does not use the camera folder, there are no masks being pulled, I have not drawn any custom masks but am getting this error - "The resolution of the mask 'C:\Users\user\Downloads\AI.Tool.1.67\Release\_Settings\Backyardsd.bmp' does not equal the resolution of the processed image. Skipping privacy mask feature. Image: 768x432, Mask: 1920x1080" Not sure if this is related or if I am even using it correctly but I do have Dynamic masking enabled and under settings I have listed dining table, chair, potted plant, cup, bowl, bench in the "objects" block. I assume items listed there are ignored by the system. TIA.
 
Bug, annoyance or operator error?

Using the newest AI tool V2. Since it does not use the camera folder, there are no masks being pulled, I have not drawn any custom masks but am getting this error - "The resolution of the mask 'C:\Users\user\Downloads\AI.Tool.1.67\Release\_Settings\Backyardsd.bmp' does not equal the resolution of the processed image. Skipping privacy mask feature. Image: 768x432, Mask: 1920x1080" Not sure if this is related or if I am even using it correctly but I do have Dynamic masking enabled and under settings I have listed dining table, chair, potted plant, cup, bowl, bench in the "objects" block. I assume items listed there are ignored by the system. TIA.
Not the camera folder, but it does save it in the _settings. If you copy your bmp from camera to _settings does fix the issue?
 
Not the camera folder, but it does save it in the _settings. If you copy your bmp from camera to _settings does fix the issue?
That's it I don't have any mask bmp or otherwise so not sure what it is seeing? I will check and see what is in the _settings
 
Not the camera folder, but it does save it in the _settings. If you copy your bmp from camera to _settings does fix the issue?
BINGO! That was it. I must have been playing around with thar camera in a previous version, there was indeed a BMP in there. Thanks for help!
 
  • Like
Reactions: Senor Pibb
Spending way too many hours trying to get AI Tool to work with my Docker instance of Deepstack running on my QNAP NAS. Keep getting this error when it tries to analyze alert images.

2020-11-05 16:28:40.006515|Info|AITOOLS.EXE|Shell_Load|None|None|None| APP START complete. Initialized in 1.9 seconds (1890ms)|75|2|yellow|1
2020-11-05 16:28:40.073473|Debug|AITOOLS.EXE|CleanHistoryList|None|None|None| No missing files to clean from database?|76|2||6
2020-11-05 16:28:40.073473|Debug|AITOOLS.EXE|CleanHistoryList|None|None|None| ...Cleaned 0 items in 175ms|77|2||6
2020-11-05 16:28:40.206392|Debug|AITOOLS.EXE|HistoryStartStop|None|None|None| History update timer started.|79|0||1
2020-11-05 16:29:15.628611|Debug|AITOOLS.EXE|OnCreated|None|None|None| |80|1||8
2020-11-05 16:29:15.628611|Debug|AITOOLS.EXE|OnCreated|None|Front_AI|Front_Cam.20201105_162915477.jpg| ====================== Adding new image to queue (Count=1): S:\BI_AI\Front_Cam.20201105_162915477.jpg|81|1||8
2020-11-05 16:29:15.996383|Debug|AITOOLS.EXE|WaitForNextURL|None|Front_AI|None| Updating/Resetting AI URL list...|82|1||6
2020-11-05 16:29:16.021369|Debug|AITOOLS.EXE|WaitForNextURL|None|Front_AI|None| ---- #1: Added new URL: 2020-11-05 16:29:16.021369|Debug|AITOOLS.EXE|WaitForNextURL|None|Front_AI|None| ...Found 1 AI URL's in settings.|84|0||6
2020-11-05 16:29:16.021369|Debug|AITOOLS.EXE|ImageQueueLoop|192.168.1.155:5000|Front_AI|Front_Cam.20201105_162915477.jpg| Adding task for file 'Front_Cam.20201105_162915477.jpg' (Image QueueTime='0.0' mins, URL Queue wait='30ms', URLOrder=1 of 1, URLOriginalOrder=1) on URL '2020-11-05 16:29:16.022368|Debug|AITOOLS.EXE|ImageQueueLoop|192.168.1.155:5000|Front_AI|None| Done adding 1 total threads, ErrCnt=0, ImageProcessQueue.Count=0|86|0||6
2020-11-05 16:29:16.047353|Debug|AITOOLS.EXE|DetectObjects|192.168.1.155:5000|Front_AI|Front_Cam.20201105_162915477.jpg| Starting analysis of S:\BI_AI\Front_Cam.20201105_162915477.jpg...|87|1||7
2020-11-05 16:29:16.100319|Debug|AITOOLS.EXE|IsValidImage|192.168.1.155:5000|Front_AI|None| Image file is valid: Front_Cam.20201105_162915477.jpg|88|2||7
2020-11-05 16:29:16.103317|Debug|AITOOLS.EXE|DetectObjects|192.168.1.155:5000|Front_AI|Front_Cam.20201105_162915477.jpg| (1/6) Uploading a 2562149 byte image to DeepQuestAI Server at 2020-11-05 16:29:16.160282|Error|AITOOLS.EXE|DetectObjects|192.168.1.155:5000|Front_AI|Front_Cam.20201105_162915477.jpg| Got http status code 'Forbidden' (403) in 57ms: Forbidden|90|1||7
2020-11-05 16:29:16.164279|Error|AITOOLS.EXE|DetectObjects|192.168.1.155:5000|Front_AI|Front_Cam.20201105_162915477.jpg| Empty string returned from HTTP post.|91|1||7
2020-11-05 16:29:16.166279|Debug|AITOOLS.EXE|DetectObjects|192.168.1.155:5000|Front_AI|Front_Cam.20201105_162915477.jpg| Total Time: 536ms (Count=1, Min=536ms, Max=536ms, Avg=536ms)|92|1||7
2020-11-05 16:29:16.166279|Debug|AITOOLS.EXE|DetectObjects|192.168.1.155:5000|Front_AI|Front_Cam.20201105_162915477.jpg| DeepStack (URL) Time: 57ms (Count=1, Min=57ms, Max=57ms, Avg=57ms)|93|1||7
2020-11-05 16:29:16.166279|Debug|AITOOLS.EXE|DetectObjects|192.168.1.155:5000|Front_AI|Front_Cam.20201105_162915477.jpg| File lock Time: 2ms (Count=1, Min=2ms, Max=2ms, Avg=2ms)|94|1||7
2020-11-05 16:29:16.166279|Debug|AITOOLS.EXE|DetectObjects|192.168.1.155:5000|Front_AI|Front_Cam.20201105_162915477.jpg| Image Queue Time: 417ms (Count=1, Min=417ms, Max=417ms, Avg=417ms)|95|1||7
2020-11-05 16:29:16.166279|Debug|AITOOLS.EXE|DetectObjects|192.168.1.155:5000|Front_AI|Front_Cam.20201105_162915477.jpg| Image Queue Depth: 1 (Count=1, Min=1, Max=1, Avg=1)|96|1||7
2020-11-05 16:29:16.166279|Info|AITOOLS.EXE|ImageQueueLoop|192.168.1.155:5000|Front_AI|None|...Problem with AI URL: '' (URL ErrCount=2, max allowed of 5)|97|0||7
2020-11-05 16:29:16.166279|Info|AITOOLS.EXE|ImageQueueLoop|192.168.1.155:5000|Front_AI|Front_Cam.20201105_162915477.jpg| ...Putting image back in queue due to URL '' problem (QueueTime=0.0, Image ErrCount=0, Image RetryCount=1, URL ErrCount=2): 'S:\BI_AI\Front_Cam.20201105_162915477.jpg', ImageProcessQueue.Count=0|98|1||7
2020-11-05 16:29:16.489040|Info|AITOOLS.EXE|WaitForNextURL|192.168.1.155:5000|Front_AI|None|---- Waiting 30 seconds before retrying bad URL. (ErrCount=2 of 5, Setting 'MinSecondsBetweenFailedURLRetry'=30): 2020-11-05 16:29:16.489040|Info|AITOOLS.EXE|WaitForNextURL|192.168.1.155:5000|Front_AI|None|---- All URL's are in use or disabled, waiting...|100|0||11
 
I ssh'd to the Deepstack Docker container and tried to run the following command. I know very little about Docker, just trying to learn as I go.

root@deepstack:/app/server# docker run -e VISION-DETECTION=True -v localstorage:/datastore:rw -p 80:5000 deepquestai/deepstack
bash: docker: command not found
root@deepstack:/app/server#
 
Spending way too many hours trying to get AI Tool to work with my Docker instance of Deepstack running on my QNAP NAS. Keep getting this error when it tries to analyze alert images.

2020-11-05 16:29:16.047353|Debug|AITOOLS.EXE|DetectObjects|192.168.1.155:5000|Front_AI|Front_Cam.20201105_162915477.jpg| Starting analysis of S:\BI_AI\Front_Cam.20201105_162915477.jpg...|87|1||7
2020-11-05 16:29:16.100319|Debug|AITOOLS.EXE|IsValidImage|192.168.1.155:5000|Front_AI|None| Image file is valid: Front_Cam.20201105_162915477.jpg|88|2||7
2020-11-05 16:29:16.103317|Debug|AITOOLS.EXE|DetectObjects|192.168.1.155:5000|Front_AI|Front_Cam.20201105_162915477.jpg| (1/6) Uploading a 2562149 byte image to DeepQuestAI Server at 2020-11-05 16:29:16.160282|Error|AITOOLS.EXE|DetectObjects|192.168.1.155:5000|Front_AI|Front_Cam.20201105_162915477.jpg| Got http status code 'Forbidden' (403) in 57ms: Forbidden|90|1||7
2020-11-05 16:29:16.164279|Error|AITOOLS.EXE|DetectObjects|192.168.1.155:5000|Front_AI|Front_Cam.20201105_162915477.jpg| Empty string returned from HTTP post.|91|1||7
2020-11-05 16:29:16.166279|Debug|AITOOLS.EXE|DetectObjects|192.168.1.155:5000|Front_AI|Front_Cam.20201105_162915477.jpg| Total Time: 536ms (Count=1, Min=536ms, Max=536ms,

403 forbidden when sending image to deepstack. That I have no clue on the 403. But I do see deepquestai/deepstack . I think that is different than mine. Somethings will be different as cpuset and host_os as I am running Unraid for my NAS. I have :latest added. I think that is just the version and yours may default to latest. just not sure.

root@localhost:# /usr/local/emhttp/plugins/dynamix.docker.manager/scripts/docker run -d --name='deepstack' --net='br0' --ip='192.168.0.179' --cpuset-cpus='3,4,5,19,20,21' -e TZ="America/New_York" -e HOST_OS="Unraid" -e 'VISION-DETECTION'='True' -e 'VISION-FACE'='True' -e 'TZ'='America/New_York' -e 'Mode'='High' 'deepquestai/deepstack:latest'
 
403 forbidden when sending image to deepstack. That I have no clue on the 403. But I do see deepquestai/deepstack . I think that is different than mine. Somethings will be different as cpuset and host_os as I am running Unraid for my NAS. I have :latest added. I think that is just the version and yours may default to latest. just not sure.

root@localhost:# /usr/local/emhttp/plugins/dynamix.docker.manager/scripts/docker run -d --name='deepstack' --net='br0' --ip='192.168.0.179' --cpuset-cpus='3,4,5,19,20,21' -e TZ="America/New_York" -e HOST_OS="Unraid" -e 'VISION-DETECTION'='True' -e 'VISION-FACE'='True' -e 'TZ'='America/New_York' -e 'Mode'='High' 'deepquestai/deepstack:latest'
Adding :latest to the end of the command still resulted in "command not found". Pretty frustrating because it's probably something very simple I'm not doing right. Just don't have the skills/experience with running Docker containers on a QNAP NAS.
 
Has anyone had any problems with ai tool not starting up if node red is running on same machine? I have had ai tool running flawlessly for months and last night i installed a node red server on the same machine as ai tool and today ai tool is off and will not start up. Last clip recorded on blue iris was around the time that i installed node red last night. When i click aitool.exe it does nothing, there are no ai tool processes or apps running in task manager and nothing is being triggered to record as far as cameras. Thanks
 
Has anyone had any problems with ai tool not starting up if node red is running on same machine? I have had ai tool running flawlessly for months and last night i installed a node red server on the same machine as ai tool and today ai tool is off and will not start up. Last clip recorded on blue iris was around the time that i installed node red last night. When i click aitool.exe it does nothing, there are no ai tool processes or apps running in task manager and nothing is being triggered to record as far as cameras. Thanks
Could you have a port conflict ?