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

cjowers

Getting the hang of it
Joined
Jan 28, 2020
Messages
107
Reaction score
36
Location
AUS
Hopefully a Windows 10 update is released at some point.
Yes, should be next month. Latest gpu version was supposed to work with WSL v2, but that may have some challenges.

For GPU support on windows, our plan is to enable this via WSL (Windows Subsystem for Linux)
 

Tinbum

Pulling my weight
Joined
Sep 5, 2017
Messages
446
Reaction score
126
Location
UK
Yes, should be next month. Latest gpu version was supposed to work with WSL v2, but that may have some challenges.
I tried yesterday to install it using docker desktop and wsl2 but am struggling. The files to download are many GB in size. I only have a 2mb internet connection and I'm struggling to get CUDA toolkit to install so I'm giving up and waiting until a windows version is out.
 

WildDoktor

Young grasshopper
Joined
Aug 25, 2020
Messages
76
Reaction score
11
Location
USA
I keep getting this error when trying to draw a custom mask...because the fire hydrant across the street is not, in fact, a person. :)

VorlonCD 1.81
BI 5.3.3.11
Windows 10

A generic error occurred in GDI+. Continue, Quit.

** Exception Text **
System.Runtime.InteropServices.ExternalException (0x80004005): A generic error occurred in GDI+.
at System.Drawing.Image.Save(String filename, ImageCodecInfo encoder, EncoderParameters encoderParams)
at AITool.Frm_CustomMasking.btnSave_Click(Object sender, EventArgs e) in D:\Documents\Projects\_GIT\VorlonCD\bi-aidetection\src\UI\Frm_CustomMasking.cs:line 376
at System.Windows.Forms.Control.OnClick(EventArgs e)
at System.Windows.Forms.Button.OnClick(EventArgs e)
at System.Windows.Forms.Button.OnMouseUp(MouseEventArgs mevent)
at System.Windows.Forms.Control.WmMouseUp(Message& m, MouseButtons button, Int32 clicks)
at System.Windows.Forms.Control.WndProc(Message& m)
at System.Windows.Forms.ButtonBase.WndProc(Message& m)
at System.Windows.Forms.Button.WndProc(Message& m)
at System.Windows.Forms.NativeWindow.Callback(IntPtr hWnd, Int32 msg, IntPtr wparam, IntPtr lparam)
 

Tinbum

Pulling my weight
Joined
Sep 5, 2017
Messages
446
Reaction score
126
Location
UK
I keep getting this error when trying to draw a custom mask...because the fire hydrant across the street is not, in fact, a person. :)

VorlonCD 1.81
BI 5.3.3.11
Windows 10

A generic error occurred in GDI+. Continue, Quit.

Exception Text
System.Runtime.InteropServices.ExternalException (0x80004005): A generic error occurred in GDI+.
at System.Drawing.Image.Save(String filename, ImageCodecInfo encoder, EncoderParameters encoderParams)
at AITool.Frm_CustomMasking.btnSave_Click(Object sender, EventArgs e) in D:\Documents\Projects\_GIT\VorlonCD\bi-aidetection\src\UI\Frm_CustomMasking.cs:line 376
at System.Windows.Forms.Control.OnClick(EventArgs e)
at System.Windows.Forms.Button.OnClick(EventArgs e)
at System.Windows.Forms.Button.OnMouseUp(MouseEventArgs mevent)
at System.Windows.Forms.Control.WmMouseUp(Message& m, MouseButtons button, Int32 clicks)
at System.Windows.Forms.Control.WndProc(Message& m)
at System.Windows.Forms.ButtonBase.WndProc(Message& m)
at System.Windows.Forms.Button.WndProc(Message& m)
at System.Windows.Forms.NativeWindow.Callback(IntPtr hWnd, Int32 msg, IntPtr wparam, IntPtr lparam)
Have you got a cameras folder in your aitool program folder?
 

Xavier6

n3wb
Joined
Dec 24, 2018
Messages
17
Reaction score
4
Location
Italy
This software is really EPIC !!!! thank you very much!!

I have a problem, I continue to receive the below message in the log. I cannot understand why? Someone had it and solved ?

[25.10.2020, 17:33:25]: ERROR: Can't write to cameras/history.csv!

Anyway, it is working fine except that Docker Desktop for windows continue to crash after 30 minutes of so.. already tried to re-install Docker and the components. I may need to try use docker on another VM.

1603663927811.png

1603664021114.png
 
Joined
Dec 15, 2019
Messages
2
Reaction score
0
Location
Calgary
i just installed the Windows version 1.67. Can someone give a high level explanation of what is generating the input files that AITool is working on? The motion detection is turned off on the BlueIris application, so I'm not sure what triggers the file creation.
 

WildDoktor

Young grasshopper
Joined
Aug 25, 2020
Messages
76
Reaction score
11
Location
USA
No, you should have one. Put one back in there.
Well...that was easy. :)

Do you happen to have as easy a fix that'll put the image that triggered an alert into the alert sms?

(Like, if a "person" is detected, I really want to see that person when I get a text, not my empty front yard.)

Pleeeeease???
 

WildDoktor

Young grasshopper
Joined
Aug 25, 2020
Messages
76
Reaction score
11
Location
USA
i just installed the Windows version 1.67. Can someone give a high level explanation of what is generating the input files that AITool is working on? The motion detection is turned off on the BlueIris application, so I'm not sure what triggers the file creation.
I'm still trying to figure it out too, but I think it's this:

Finally, go to Alerts and uncheck all motion zones. Makes sure that external is checked.
This is how I've set mine up; still trying to determine if this is correct according to the above.

1603666703723.png
1603666769968.png
1603666728398.png
 

Attachments

Joined
Dec 15, 2019
Messages
2
Reaction score
0
Location
Calgary

WildDoktor

Young grasshopper
Joined
Aug 25, 2020
Messages
76
Reaction score
11
Location
USA
Yeah; this is totally confusing. :-(

I just walked out in front; no alert, nothing in the aitool history.
Back in camera settings, I checked the motion detection box and then walked back out front. I got 4 texts within about 5 seconds. none of them have me in the picture. ?????
I do have a 42 second clip, I show up 20 seconds into it (I expected that because of the settings).
As I'm typing this, I just got a 25 second clip a few seconds ago of a car driving by. But no alert...which seems correct since I'm not telling aitools to look for cars.
So now I'm getting recordings of all motion that's detected, and only getting alerted to motion that has people/cats/dogs in it. But the alerts don't contain a picture of what created the alerts.

My goals are:
To ONLY record when I get an alert that i've defined in aitools
To get a text that has a picture of whatever had caused aitools to fire the trigger

Why is this so hard?? What am I missing??? I've been an IT professional for literally 30 years, but this is apparently beyond me??

Ugh...I'm so frustrated with this...but there aren't really any alternatives, so I want to push thru and make this work as i expect it to.

i can't imagine trying to setup 9 cameras!!
 

DEADBEEF

n3wb
Joined
Apr 4, 2016
Messages
11
Reaction score
3
Fantastic tool. Great work.

Any plans to have an option to replace the BI alert image with one edited by AI-tool to overlay detected objects onto the original image.

If not may I propose that as a suggestion for a future version.
 
Last edited:

cjowers

Getting the hang of it
Joined
Jan 28, 2020
Messages
107
Reaction score
36
Location
AUS
Yeah; this is totally confusing. :-(

I just walked out in front; no alert, nothing in the aitool history.
Back in camera settings, I checked the motion detection box and then walked back out front. I got 4 texts within about 5 seconds. none of them have me in the picture. ?????
I do have a 42 second clip, I show up 20 seconds into it (I expected that because of the settings).
As I'm typing this, I just got a 25 second clip a few seconds ago of a car driving by. But no alert...which seems correct since I'm not telling aitools to look for cars.
So now I'm getting recordings of all motion that's detected, and only getting alerted to motion that has people/cats/dogs in it. But the alerts don't contain a picture of what created the alerts.
I would try to focus your testing more. if it's just you, maybe walk out -> leave an item -> then see if your blank alert image is before or after your motion trigger event that you would like the image of. You can improve this further and get it down to how many seconds it is off. if it's 20, its probably related to your pre-trigger buffer setting. if its 2s, it may be the delay in response time that it takes deepstack to process (or delay it takes camera to trigger?) odds are it is a setting somewhere. but your deepstack times are pretty slow to be fair - remember, it can't make an alert until after it has fully processed the 1st (sometimes possibly 2nd) image and ID'd a person.
 

WildDoktor

Young grasshopper
Joined
Aug 25, 2020
Messages
76
Reaction score
11
Location
USA
Here's an example timeline:

Aitool history shows 4 "Person" detections at 4:32:29, 4:32:32, 4:32:35, 4:32:38. All images are of yours truly in different "poses".
There's a recorded clip in BI from 4:32:02 to 4:32:44:
  • My front door (screen door) begins to open at 4:32:22.
  • I'm fully in the frame at 4:32:24.
  • I'm out of the picture and the screen door is closed (also now out of the picture) at 4:32:34.
I get 5 texts at 4:32:xx (my message app doesn't show seconds). All 4 texts have the same image, with the same time stamp: 4:32:22.

Next alert happened just a few seconds after the one above.
Aitool history shows 4 irrelevant Car images at 4:35:17, 4:35:20, 4:35:22, 4:35:25.
There's a recorded clip in BI from 4:34:56 to 4:35:21 where a car leaves the neighbor's yard and drives past our house from 4:35:14 to 4:35:21.
I get a single text at 4:35:xx (my message app doesn't show seconds). The time stamp on the image is 4:35:14.

Too tired right now to decipher what this all means; will get back on it tomorrow after I get home from work. :)
 

cjowers

Getting the hang of it
Joined
Jan 28, 2020
Messages
107
Reaction score
36
Location
AUS
I get 5 texts at 4:32:xx (my message app doesn't show seconds). All 4 texts have the same image, with the same time stamp: 4:32:22.
It sounds like it is showing the alert image as it should, just as the motion occurs from the screen door opening (or a split second before).

To make things easy, I'd also make sure that the time stamp you are using as a reference is placed by the camera (not BI or AI), and has been recently synced to your PC time in the camera web config. that way you know a certain time, is a certain time, and there's no way you can get some other image for a given timestamp. IIf you had this setup in your first example, this alert would have to show the screen door. If it doesn't, it is probably a system issue rather than a setting.

My point is that it seems to be triggering at the right times, so you should work to find out which direction it needs to move. Doing this will also make it apparent if the alert image occurs as it should (and just slightly off in timing) or if it is a problem with the alert image.
 

Tinbum

Pulling my weight
Joined
Sep 5, 2017
Messages
446
Reaction score
126
Location
UK
First have a look in the AITool input folders at the images you get in there. Are you in them? If not it's BI settings that want looking at. Are there 5 that are all the same?
 

Xavier6

n3wb
Joined
Dec 24, 2018
Messages
17
Reaction score
4
Location
Italy
This software is really EPIC !!!! thank you very much!!

I have a problem, I continue to receive the below message in the log. I cannot understand why? Someone had it and solved ?

[25.10.2020, 17:33:25]: ERROR: Can't write to cameras/history.csv!

Anyway, it is working fine except that Docker Desktop for windows continue to crash after 30 minutes of so.. already tried to re-install Docker and the components. I may need to try use docker on another VM.

View attachment 73371

View attachment 73372

I moved DeepQuest on a Photon VM on my esxi and it is now working perfecty. It also 600ms vs 3/4 second faster without almost resources.My blue iris is also on a Vm.
 

Xavier6

n3wb
Joined
Dec 24, 2018
Messages
17
Reaction score
4
Location
Italy
I'm still receiving all these notification

[26.10.2020, 15:07:08]: ERROR: Can't write to cameras/history.csv!
[26.10.2020, 15:07:08]: ERROR: Can't write to cameras/history.csv!
[26.10.2020, 15:12:08]: ERROR: Can't write to cameras/history.csv!
[26.10.2020, 15:12:08]: ERROR: Can't write to cameras/history.csv!
[26.10.2020, 15:12:08]: ERROR: Can't write to cameras/history.csv!
[26.10.2020, 15:12:08]: ERROR: Can't write to cameras/history.csv!
[26.10.2020, 15:12:08]: ERROR: Can't write to cameras/history.csv!

Someone solved this problem ?

As I read somewhere in the topic, it seem connected to when the pictures in the AiInput folder are deleted. Also if it doesn't make much sense as they are different folders.
 

Tinbum

Pulling my weight
Joined
Sep 5, 2017
Messages
446
Reaction score
126
Location
UK
Fantastic tool. Great work.

Any plans to have an option to replace the BI alert image with one edited by AI-tool to overlay detected objects onto the original image.

If not may I propose that as a suggestion for a future version.
Its already been done in the VorlonCD version.
 
Top