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

I figured as much. :) That worked BTW. Now to see if this &^%$# new model is going to work.....so close.
When we have 2 servers running,making the analyse parallel or 1pic the server 1 and pic 2 the server 2?
 
When we have 2 servers running,making the analyse parallel or 1pic the server 1 and pic 2 the server 2?
The latter or you can have pic1 sent to server 1 and then pic 2 sent to server 1 if server 1 has finished pic 1, otherwise pic 2 to server 2.
 
Last edited:
  • Like
Reactions: maximosm
Thanks all for your time and support in here. Has been great. I have moved over from Shinobi/Tensorflow set up as am finding Blue Iris to do everything I want without the stuffing around. The last issue has been getting GPU support for Deepstack going. Excited to see the GPU windows version come out today.

I have installed and running aitools (Vorlon) but the new 2020 GPU beta doesn't seem to run with aitools. Does anyone else have it working fine?
 
Hey all. I was gooing to have a play with this but cannot find the EXE file in the zip. Yep I know.... What stupid thing have I missed
 
Hey all. I was gooing to have a play with this but cannot find the EXE file in the zip. Yep I know.... What stupid thing have I missed
Look in the folder you unzipped everything into look for AITool.exe should be the 6th item down
 
What's the state of play? Have you got it recognising any of your own subjects?

So.......
This is where I am.

  1. Deleted all my Docker containers.
    Opened Power shell and ran:
  2. docker pull deepquestai/deepstack:latest
    and
  3. docker pull deepquestai/deepstack:cpu-2020.12
    Why? Because I know nothing about Docker and was not sure if I needed both or if "latest" would do the trick.
    Then I created 2 Docker containers:
  4. docker run --restart=always -e mode=high -eVISION-DETECTION=True -v localstorage:/datastore -p 8383:5000 --name deepstack deepquestai/deepstack:latest
    and
  5. docker run --restart=always -e mode=high -eVISION-DETECTION=True -v C:\Users\user\Documents\my-models:/modelstore/detection -p 8000:5000 deepquestai/deepstack:cpu-2020.12
Again because I am clueless..
  1. I went into AI-Tool and entered both- 127.0.0.1:8000, 127.0.0.1:8383 into the AI serverURL(s) block
7 .Result was NO MORE FREAKING ERRORS!!!!, NO URL Errors, No 404 OR 403 Errors.

....However, while I am indeed getting alerts and snapshots are being sent to telegram I am not getting any "custom" results??
My custom model is pictures of me and family members, with the desired result being my/their name being shown under the pic if recognized. I stood in front of several of my cameras to see if it would work but only got the box with "person" instead my name. I used close to 300 images during the training and let it run for the complete 300 Epochs took 6 1/2 hours to complete. Waiting on some answer from John O.
 
I am trying to use Deepstack based on the new 2020 beta. AITOOLS reports that deepstack isn't fully running ( Deepstack partially running. You many need to manually kill server.exe, python.exe, redis-server.exe) and I get a 403 error when AITOOLS sends the image to Deepstack.

Does anyone have any suggestions? I have been struggling with 403 errors when I was trying WSL2 Docker installs with GPU support also. Only way I can get it to work is with the CPU Windows Deepstack installer, but really hoping to offload to my GPU.

Any help appreciated.
 
I'm trying to get DS running on a Jetson Nano and I'm having a bit of trouble. Here's what I've done so far. I installed the latest Jetpack on an SD card and then set the nano up using headless mode with a USB cable. I assigned a static IP address and then accessed the Nano with Putty. I then ran the following commands.

sudo apt-get update
sudo apt-get upgrade

sudo docker pull deepquestai/deepstack:jetpack-2020.12

sudo docker run --runtime nvidia --restart=unless-stopped -e VISION-DETECTION=True -p 80:5000 deepquestai/deepstack:jetpack-2020.12

sudo docker volume create portainer_data

sudo docker run -d -p 8000:8000 -p 9000:9000 --name=portainer --restart=always -v /var/run/docker.sock:/var/run/docker.sock -v portainer_data:/data portainer/portainer-ce

sudo systemctl enable docker.service

sudo reboot now

After the reboot both containers started and I could access Portainer as well as the DS web interface on port 80 but AI Tool can not communicate with DS.

12/19/2020 6:35:46 PM DetectObjects Unable to connect to the remote server [WebException] Mod: <DetectObjects>d__31 Line:999:48 Error AITOOLS.EXE 10.1.31.30:5000 GarageMotion GarageMotion.20201219_183544288.jpg 60 1 9 False aitool.[2020-12-19].log

The DS URL in AI Tool is set to 10.1.31.30:5000 which is the IP address of the Nano and I believe the port number is correct based on the docker run line.

This is my first time working with a Nano and my first experience with Docker so I'm not familiar with troubleshooting techniques on these platforms. From what I see in Portainer and the output of a few Docker commands everything looks fine to me, but then I don't have an experienced eye.

Now to complicate things. I have installed Jetpack on the Nano twice. Once using the Gui and once headless. I was able to get everything working with the Gui install but I wanted to try out headless install so I wiped the card, started over, and now I can't get DS to work again.

Any help will be appreciated.
 
I am trying to use Deepstack based on the new 2020 beta. AITOOLS reports that deepstack isn't fully running ( Deepstack partially running. You many need to manually kill server.exe, python.exe, redis-server.exe) and I get a 403 error when AITOOLS sends the image to Deepstack.

Does anyone have any suggestions? I have been struggling with 403 errors when I was trying WSL2 Docker installs with GPU support also. Only way I can get it to work is with the CPU Windows Deepstack installer, but really hoping to offload to my GPU.

Any help appreciated.
If you post some snapshots of your screens/logs that will be more helpful. If you are running the Windows version (you have a deepstack tab in AI-Tools) click stop then start, once it says running click save. I had the same issue before I went over to Docker.
 
Thatnk @balucanb . With the latest windows beta installer, aitools doesn't appear to start the service.

Code:
2020-12-20 16:16:12.961857|Error|AITOOLS.EXE|GetDeepStackRun|None|None|None|   Deepstack partially running.  You many need to manually kill server.exe, python.exe, redis-server.exe|48|2||1
2020-12-20 16:16:12.973634|Info|AITOOLS.EXE|Shell_Load|None|None|None| APP START complete.  Initialized in 1.5 seconds (1525ms)|49|1|yellow|1
2020-12-20 16:16:13.697164|Debug|AITOOLS.EXE|HistoryStartStop|None|None|None| History update timer started.|51|0||1
2020-12-20 16:16:17.836951|Info|AITOOLS.EXE|ReloadLog||||Loaded 24645 lines in 323ms from C:\Programs\vrloncd aitool\_Settings\Logs\AITool.[2020-12-20].log.|1|0||1
2020-12-20 16:16:43.999274|Debug|AITOOLS.EXE|OnCreated||||  |2|1||8
2020-12-20 16:16:43.999274|Debug|AITOOLS.EXE|OnCreated||BackSD|BackSD.20201220_161643971.jpg|  ====================== Adding new image to queue (Count=1): V:\ai\BackSD.20201220_161643971.jpg|3|1||8
2020-12-20 16:16:44.277235|Debug|AITOOLS.EXE|WaitForNextURL||BackSD|| Updating/Resetting AI URL list...|4|0||9
2020-12-20 16:16:44.318284|Debug|AITOOLS.EXE|WaitForNextURL||BackSD|| ----   #1: Added new URL: http://192.168.5.252:5000/v1/vision/detection|5|0||9
2020-12-20 16:16:44.319239|Debug|AITOOLS.EXE|WaitForNextURL||BackSD|| ...Found 1 AI URL's in settings.|6|0||9
2020-12-20 16:16:44.321290|Debug|AITOOLS.EXE|ImageQueueLoop|192.168.5.252:5000|BackSD|BackSD.20201220_161643971.jpg| Adding task for file 'BackSD.20201220_161643971.jpg' (Image QueueTime='0.0' mins, URL Queue wait='54ms', URLOrder=1 of 1, URLOriginalOrder=1) on URL 'http://192.168.5.252:5000/v1/vision/detection'|7|0||9
2020-12-20 16:16:44.321290|Debug|AITOOLS.EXE|ImageQueueLoop|192.168.5.252:5000|BackSD|| Done adding 1 total threads, ErrCnt=0, ImageProcessQueue.Count=0|8|0||9
2020-12-20 16:16:44.365266|Debug|AITOOLS.EXE|DetectObjects|192.168.5.252:5000|BackSD|BackSD.20201220_161643971.jpg|  Starting analysis of V:\ai\BackSD.20201220_161643971.jpg...|9|1||9
2020-12-20 16:16:44.374200|Debug|AITOOLS.EXE|IsValidImage|192.168.5.252:5000|BackSD||   Image file is valid: BackSD.20201220_161643971.jpg|10|2||11
2020-12-20 16:16:44.376268|Debug|AITOOLS.EXE|DetectObjects|192.168.5.252:5000|BackSD|BackSD.20201220_161643971.jpg|  (1/6) Uploading a 268635 byte image to DeepQuestAI Server at http://192.168.5.252:5000/v1/vision/detection|11|1||11
2020-12-20 16:16:44.412263|Error|AITOOLS.EXE|DetectObjects|192.168.5.252:5000|BackSD|BackSD.20201220_161643971.jpg|  Got http status code 'Forbidden' (403) in 35ms: Forbidden|12|1||12
2020-12-20 16:16:44.414263|Error|AITOOLS.EXE|DetectObjects|192.168.5.252:5000|BackSD|BackSD.20201220_161643971.jpg|  Empty string returned from HTTP post.|13|1||12
2020-12-20 16:16:44.417264|Debug|AITOOLS.EXE|DetectObjects|192.168.5.252:5000|BackSD|BackSD.20201220_161643971.jpg|           Total Time:  415ms (Count=1, Min=415ms, Max=415ms, Avg=415ms)|14|1||12
2020-12-20 16:16:44.417264|Debug|AITOOLS.EXE|DetectObjects|192.168.5.252:5000|BackSD|BackSD.20201220_161643971.jpg| DeepStack (URL) Time:  35ms (Count=1, Min=35ms, Max=35ms, Avg=35ms)|15|1||12
2020-12-20 16:16:44.417264|Debug|AITOOLS.EXE|DetectObjects|192.168.5.252:5000|BackSD|BackSD.20201220_161643971.jpg|       File lock Time:  1ms (Count=1, Min=1ms, Max=1ms, Avg=1ms)|16|1||12
2020-12-20 16:16:44.417264|Debug|AITOOLS.EXE|DetectObjects|192.168.5.252:5000|BackSD|BackSD.20201220_161643971.jpg|     Image Queue Time:  364ms (Count=1, Min=364ms, Max=364ms, Avg=364ms)|17|1||12
2020-12-20 16:16:44.417264|Debug|AITOOLS.EXE|DetectObjects|192.168.5.252:5000|BackSD|BackSD.20201220_161643971.jpg|    Image Queue Depth:  1 (Count=1, Min=1, Max=1, Avg=1)|18|1||12
2020-12-20 16:16:44.417264|Info|AITOOLS.EXE|ImageQueueLoop|192.168.5.252:5000|BackSD||...Problem with AI URL: 'http://192.168.5.252:5000/v1/vision/detection' (URL ErrCount=2, max allowed of 5)|19|0||12
2020-12-20 16:16:44.418359|Info|AITOOLS.EXE|ImageQueueLoop|192.168.5.252:5000|BackSD|BackSD.20201220_161643971.jpg|...Putting image back in queue due to URL 'http://192.168.5.252:5000/v1/vision/detection' problem (QueueTime=0.0, Image ErrCount=0, Image RetryCount=1, URL ErrCount=2): 'V:\ai\BackSD.20201220_161643971.jpg', ImageProcessQueue.Count=0|20|0||12
2020-12-20 16:16:44.688723|Info|AITOOLS.EXE|WaitForNextURL|192.168.5.252:5000|BackSD||---- Waiting 30 seconds before retrying bad URL. (ErrCount=2 of 5, Setting 'MinSecondsBetweenFailedURLRetry'=30): http://192.168.5.252:5000/v1/vision/detection|21|0||12
2020-12-20 16:16:44.688723|Info|AITOOLS.EXE|WaitForNextURL|192.168.5.252:5000|BackSD||---- All URL's are in use or disabled, waiting...|22|0||12

Logs above. I will troll trough some documentation from deepstack, so if there is something different with the new build.
 
Thatnk @balucanb . With the latest windows beta installer, aitools doesn't appear to start the service.

Code:
2020-12-20 16:16:12.961857|Error|AITOOLS.EXE|GetDeepStackRun|None|None|None|   Deepstack partially running.  You many need to manually kill server.exe, python.exe, redis-server.exe|48|2||1
2020-12-20 16:16:12.973634|Info|AITOOLS.EXE|Shell_Load|None|None|None| APP START complete.  Initialized in 1.5 seconds (1525ms)|49|1|yellow|1
2020-12-20 16:16:13.697164|Debug|AITOOLS.EXE|HistoryStartStop|None|None|None| History update timer started.|51|0||1
2020-12-20 16:16:17.836951|Info|AITOOLS.EXE|ReloadLog||||Loaded 24645 lines in 323ms from C:\Programs\vrloncd aitool\_Settings\Logs\AITool.[2020-12-20].log.|1|0||1
2020-12-20 16:16:43.999274|Debug|AITOOLS.EXE|OnCreated||||  |2|1||8
2020-12-20 16:16:43.999274|Debug|AITOOLS.EXE|OnCreated||BackSD|BackSD.20201220_161643971.jpg|  ====================== Adding new image to queue (Count=1): V:\ai\BackSD.20201220_161643971.jpg|3|1||8
2020-12-20 16:16:44.277235|Debug|AITOOLS.EXE|WaitForNextURL||BackSD|| Updating/Resetting AI URL list...|4|0||9
2020-12-20 16:16:44.318284|Debug|AITOOLS.EXE|WaitForNextURL||BackSD|| ----   #1: Added new URL: http://192.168.5.252:5000/v1/vision/detection|5|0||9
2020-12-20 16:16:44.319239|Debug|AITOOLS.EXE|WaitForNextURL||BackSD|| ...Found 1 AI URL's in settings.|6|0||9
2020-12-20 16:16:44.321290|Debug|AITOOLS.EXE|ImageQueueLoop|192.168.5.252:5000|BackSD|BackSD.20201220_161643971.jpg| Adding task for file 'BackSD.20201220_161643971.jpg' (Image QueueTime='0.0' mins, URL Queue wait='54ms', URLOrder=1 of 1, URLOriginalOrder=1) on URL 'http://192.168.5.252:5000/v1/vision/detection'|7|0||9
2020-12-20 16:16:44.321290|Debug|AITOOLS.EXE|ImageQueueLoop|192.168.5.252:5000|BackSD|| Done adding 1 total threads, ErrCnt=0, ImageProcessQueue.Count=0|8|0||9
2020-12-20 16:16:44.365266|Debug|AITOOLS.EXE|DetectObjects|192.168.5.252:5000|BackSD|BackSD.20201220_161643971.jpg|  Starting analysis of V:\ai\BackSD.20201220_161643971.jpg...|9|1||9
2020-12-20 16:16:44.374200|Debug|AITOOLS.EXE|IsValidImage|192.168.5.252:5000|BackSD||   Image file is valid: BackSD.20201220_161643971.jpg|10|2||11
2020-12-20 16:16:44.376268|Debug|AITOOLS.EXE|DetectObjects|192.168.5.252:5000|BackSD|BackSD.20201220_161643971.jpg|  (1/6) Uploading a 268635 byte image to DeepQuestAI Server at http://192.168.5.252:5000/v1/vision/detection|11|1||11
2020-12-20 16:16:44.412263|Error|AITOOLS.EXE|DetectObjects|192.168.5.252:5000|BackSD|BackSD.20201220_161643971.jpg|  Got http status code 'Forbidden' (403) in 35ms: Forbidden|12|1||12
2020-12-20 16:16:44.414263|Error|AITOOLS.EXE|DetectObjects|192.168.5.252:5000|BackSD|BackSD.20201220_161643971.jpg|  Empty string returned from HTTP post.|13|1||12
2020-12-20 16:16:44.417264|Debug|AITOOLS.EXE|DetectObjects|192.168.5.252:5000|BackSD|BackSD.20201220_161643971.jpg|           Total Time:  415ms (Count=1, Min=415ms, Max=415ms, Avg=415ms)|14|1||12
2020-12-20 16:16:44.417264|Debug|AITOOLS.EXE|DetectObjects|192.168.5.252:5000|BackSD|BackSD.20201220_161643971.jpg| DeepStack (URL) Time:  35ms (Count=1, Min=35ms, Max=35ms, Avg=35ms)|15|1||12
2020-12-20 16:16:44.417264|Debug|AITOOLS.EXE|DetectObjects|192.168.5.252:5000|BackSD|BackSD.20201220_161643971.jpg|       File lock Time:  1ms (Count=1, Min=1ms, Max=1ms, Avg=1ms)|16|1||12
2020-12-20 16:16:44.417264|Debug|AITOOLS.EXE|DetectObjects|192.168.5.252:5000|BackSD|BackSD.20201220_161643971.jpg|     Image Queue Time:  364ms (Count=1, Min=364ms, Max=364ms, Avg=364ms)|17|1||12
2020-12-20 16:16:44.417264|Debug|AITOOLS.EXE|DetectObjects|192.168.5.252:5000|BackSD|BackSD.20201220_161643971.jpg|    Image Queue Depth:  1 (Count=1, Min=1, Max=1, Avg=1)|18|1||12
2020-12-20 16:16:44.417264|Info|AITOOLS.EXE|ImageQueueLoop|192.168.5.252:5000|BackSD||...Problem with AI URL: 'http://192.168.5.252:5000/v1/vision/detection' (URL ErrCount=2, max allowed of 5)|19|0||12
2020-12-20 16:16:44.418359|Info|AITOOLS.EXE|ImageQueueLoop|192.168.5.252:5000|BackSD|BackSD.20201220_161643971.jpg|...Putting image back in queue due to URL 'http://192.168.5.252:5000/v1/vision/detection' problem (QueueTime=0.0, Image ErrCount=0, Image RetryCount=1, URL ErrCount=2): 'V:\ai\BackSD.20201220_161643971.jpg', ImageProcessQueue.Count=0|20|0||12
2020-12-20 16:16:44.688723|Info|AITOOLS.EXE|WaitForNextURL|192.168.5.252:5000|BackSD||---- Waiting 30 seconds before retrying bad URL. (ErrCount=2 of 5, Setting 'MinSecondsBetweenFailedURLRetry'=30): http://192.168.5.252:5000/v1/vision/detection|21|0||12
2020-12-20 16:16:44.688723|Info|AITOOLS.EXE|WaitForNextURL|192.168.5.252:5000|BackSD||---- All URL's are in use or disabled, waiting...|22|0||12

Logs above. I will troll trough some documentation from deepstack, so if there is something different with the new build.

Ignore me, I forgot! Need to start it using deepstack --VISION-DETECTION True --PORT xyz in powershell otherwise you get that error, not the shortcut installed by deepstack. I missed this in the docs. Hopefully my stupidity helps someone else :D
 
  • Like
Reactions: balucanb
So.......
This is where I am.

  1. Deleted all my Docker containers.
    Opened Power shell and ran:
  2. docker pull deepquestai/deepstack:latest
    and
  3. docker pull deepquestai/deepstack:cpu-2020.12
    Why? Because I know nothing about Docker and was not sure if I needed both or if "latest" would do the trick.
    Then I created 2 Docker containers:
  4. docker run --restart=always -e mode=high -eVISION-DETECTION=True -v localstorage:/datastore -p 8383:5000 --name deepstack deepquestai/deepstack:latest
    and
  5. docker run --restart=always -e mode=high -eVISION-DETECTION=True -v C:\Users\user\Documents\my-models:/modelstore/detection -p 8000:5000 deepquestai/deepstack:cpu-2020.12
Again because I am clueless..
  1. I went into AI-Tool and entered both- 127.0.0.1:8000, 127.0.0.1:8383 into the AI serverURL(s) block
7 .Result was NO MORE FREAKING ERRORS!!!!, NO URL Errors, No 404 OR 403 Errors.

....However, while I am indeed getting alerts and snapshots are being sent to telegram I am not getting any "custom" results??
My custom model is pictures of me and family members, with the desired result being my/their name being shown under the pic if recognized. I stood in front of several of my cameras to see if it would work but only got the box with "person" instead my name. I used close to 300 images during the training and let it run for the complete 300 Epochs took 6 1/2 hours to complete. Waiting on some answer from John O.
@balucanb
Needless to say since I'm not using the custom modelling I can only offer observations and suggestions.

1. I propose that you setup a default version of deepstack and confirm it is working as expected.
2. Remove the default container and load the custom version using the same port number as you used in point 1.

I do not believe you need two different versions of deepstack. I propose you stick with the 2020.12 version for both instances.

This will give us some fundamental info to determine if your custom model is working. You can check the processing time for example.
 
Hello everyone, I'm using BI version 5.3.7.0 along with AI Tool version 2.0.195.7637 and I'm running the newest version of Deepstack in Docker.

[[EDIT]]. *Note I'm using Ubiquiti Protect for managing the cameras on a Cloudkey 2+ *

I have an odd problem with AI Tools and Ubiquiti cameras, it seems like everything is working however only with one camera at a time even when I have others configured exactly the same in BlueIris, basically I was following this tutorial for Deepstack and everything is up and working but it seems one camera will be doing the detection unless I make a change in the Trigger section.

So lets say I have my Office camera set to Trigger/Motion Sensor/Min. Object Size = 1002 , this camera will be working and captures in my office will trigger on movement by me and AI Tool will process.

I have three other cameras set up to test and they all are configured to trigger the same way and basically when I created new cameras I used the option "copy from other camera" and then changed the RTSP url and the cameras show up fine but the ONLY way to make the others trigger is by going into the Trigger settings and adjusting "Trigger/Motion Sensor/Min. Object Size" option on say the Theatre camera as an example, so lets says the Min. Object Size on this camera was set to 840 and I change it to 740 then this camera will become the ONLY camera of the four that AI Tool now processes images for and it will keep doing this and no other cameras until I go into a different camera and slightly adjust "Trigger/Motion Sensor/Min. Object Size" option and then that camera becomes the one that AI Tool will process images for?

I know it sound odd buy hopefully another person with Ubiquiti cameras can confirm the same thing is happening with their setup, I have tested this with a single camera and of course that will work all the time but as soon as I add a second camera then I have this problem where only one camera will be processed, I have tested this with up to 14 cameras with the same result.

The only thing I think that possibly might have to do with this is I don't have all Ubiquiti cameras set to self managed so Ubiquiti Protect is using the cameras normally as it dos and recording fine and then Blue Iris I have all low quality RTSP substreams eg;

Camera Office = 192.168.1.120:7447/JJnG64KrxTHEzSCP

Camera Theatre= 192.168.1.120:7447/MMtG64LryuKKzTTY

The cameras of course still all have unique RTSP urls for High/Medium/Low and they work in BI to view video its just the triggers that seem broken somehow no matter what quality of stream I chose and they're not triggering like they should?

I'd rather not have to put the Ubiquiti cameras in stand alone mode and I've heard of others using Ubiquiti cameras in Ubiquiti Protect mode while also using BI so if anybody else has a similar configuration please let me know if you are using Ubiquiti Protect mode and your cameras are NOT in stand alone mode, are you seeing this same sort of problem I am?

Thanks in advance for any help.
 
Last edited:
@balucanb
Needless to say since I'm not using the custom modelling I can only offer observations and suggestions.

1. I propose that you setup a default version of deepstack and confirm it is working as expected.
2. Remove the default container and load the custom version using the same port number as you used in point 1.

I do not believe you need two different versions of deepstack. I propose you stick with the 2020.12 version for both instances.

This will give us some fundamental info to determine if your custom model is working. You can check the processing time for example.
Good info. I agree I do not think I am going to need both containers running 2 different versions. Since my original post I did shut each down and only had 1 version running at a time, I assume shutting it down is as good as deleting it? They both were processing normally minus putting the custom label on certain pictures, not sure about the processing times I will need to go back and check that.