VorlonCD/bi-aidetection

Issues with camera's on subfolders.

Opened this issue · 5 comments

I'm getting errors when trying to monitor camera's that have the images multiple levels deep. The subfolders are automatically created based on timestamps. In my example below these images are being outputted by two systems, one is an NVR dropping them into a folder and the other is from an application called sighthound.

I understand this isn't meant for monitoring SightHound or folders outside of blue iris but i thought i would give this question a shot. I tried creating a fake camera and i'm able to drop the files in that folder and it works perfectly.

Here's a couple examples.

Sighthound Dumps
image

image

NVR

image

image

I tried using the input file begins with for the NVR since the images start with REONVR_xxxxxxxxxxx.jpg but I still didn't have any luck.

In this example the NVR outputs the images with the camera number in front. It looks like Starts With in your app is looking for another period after the name?

  • REONVR_06_xxxxxxxxxx.jpg
  • REONVR_07_xxxxxxxxxx.jpg
  • etc

image

Pretty old version, test with the latest:
https://github.com/VorlonCD/bi-aidetection/tree/master/src/UI/Installer

FYI you can add Sighthound support directly via Settings > AI Server URLs > Edit > ADD. (Vehicle or Person)

You are my hero!!! I was building all these functions in powershell when i stumbled across this project.

Last question, Is there a way to identify a camera just based on the path?

image

image

image

In theory if the name, prefix etc doesnt match, it WILL match on the full folder path.

If you enable TRACE logging from Log > Log settings > Logging level, you will see a bunch of "GETCAMERA" trace log items telling you exactly how it is looking to match the camera. Enable, drop an image in, and disable after it finds it otherwise logging will go crazy.

Here's a snippet of the logs. When it searches for the camera name is it searching the whole file path or just in the file name?

Here's the two paths that the cameras write into. The images are two more levels deep in random folders.

  • V:\Sighthound\Videos\archive\garage\

  • V:\Sighthound\Videos\archive\front door\

  • V:\Sighthound\Videos\archive\front door\16431\thumbs

image

image

2022-01-25 16:17:41.091674|Trace|AITOOLS.EXE|UpdateLogAddedRemovedAsync|Trace-Enter|Trace-Enter|| ---->ENTER UpdateLogAddedRemovedAsync, Depth=1|93547|1||1 2022-01-25 16:17:41.091674|Trace|AITOOLS.EXE|UpdateLogAddedRemovedAsync|Trace-Exit|Trace-Exit||----<EXIT UpdateLogAddedRemovedAsync, Time=0ms, Depth=0|93548|0||1 2022-01-25 16:17:41.185705|Trace|AITOOLS.EXE|AddImageToQueue|Trace-Enter|Trace-Enter|| ---->ENTER AddImageToQueue, Depth=1|93549|1||50 2022-01-25 16:17:41.185705|Trace|AITOOLS.EXE|GetCamera|Trace-Enter|Trace-Enter|| ---->ENTER GetCamera, Depth=2|93550|2||50 2022-01-25 16:17:41.185705|Debug|AITOOLS.EXE|GetCamera|Deepstack_Objects:127.0.0.1:81|SH - Front Garage|| No enabled camera with the same filename, cameraname, or prefix found for 'V:\Sighthound\Videos\archive\front door\16431\thumbs\1643130631462 - Copy (5).jpg'|93551|2||50 2022-01-25 16:17:41.185705|Trace|AITOOLS.EXE|GetCamera|Deepstack_Objects:127.0.0.1:81|SH - Front Garage|| (Found a DEFAULT camera for 'V:\Sighthound\Videos\archive\front door\16431\thumbs\1643130631462 - Copy (5).jpg': 'SH - Front Garage')|93552|2||50 2022-01-25 16:17:41.185705|Trace|AITOOLS.EXE|GetCamera|Trace-Exit|Trace-Exit|| ----<EXIT GetCamera, Time=0ms, Depth=1|93553|1||50 2022-01-25 16:17:41.185705|Debug|AITOOLS.EXE|AddImageToQueue|Deepstack_Objects:127.0.0.1:81|SH - Front Garage|| |93554|1||50 2022-01-25 16:17:41.185705|Debug|AITOOLS.EXE|AddImageToQueue|Deepstack_Objects:127.0.0.1:81|SH - Front Garage|1643130631462 - Copy (5).jpg| ====================== Adding new image to queue (Count=1): V:\Sighthound\Videos\archive\front door\16431\thumbs\1643130631462 - Copy (5).jpg|93555|1||50 2022-01-25 16:17:41.185705|Trace|AITOOLS.EXE|AddImageToQueue|Trace-Exit|Trace-Exit||----<EXIT AddImageToQueue, Time=0ms, Depth=0|93556|0||50 2022-01-25 16:17:41.186706|Trace|AITOOLS.EXE|EventMessage|Trace-Enter|Trace-Enter|| ---->ENTER EventMessage, Depth=1|93557|1||1 2022-01-25 16:17:41.191672|Trace|AITOOLS.EXE|EventMessage|Trace-Exit|Trace-Exit||----<EXIT EventMessage, Time=4ms, Depth=0|93558|0||1 2022-01-25 16:17:41.222673|Trace|AITOOLS.EXE|GetCamera|Trace-Enter|Trace-Enter|| ---->ENTER GetCamera, Depth=1|93559|1||16 2022-01-25 16:17:41.222673|Debug|AITOOLS.EXE|GetCamera|Deepstack_Objects:127.0.0.1:81|SH - Front Garage|| No enabled camera with the same filename, cameraname, or prefix found for 'V:\Sighthound\Videos\archive\front door\16431\thumbs\1643130631462 - Copy (5).jpg'|93560|1||16 2022-01-25 16:17:41.222673|Trace|AITOOLS.EXE|GetCamera|Deepstack_Objects:127.0.0.1:81|SH - Front Garage|| (Found a DEFAULT camera for 'V:\Sighthound\Videos\archive\front door\16431\thumbs\1643130631462 - Copy (5).jpg': 'SH - Front Garage')|93561|1||16 2022-01-25 16:17:41.222673|Trace|AITOOLS.EXE|GetCamera|Trace-Exit|Trace-Exit||----<EXIT GetCamera, Time=0ms, Depth=0|93562|0||16 2022-01-25 16:17:41.222673|Trace|AITOOLS.EXE|WaitForNextURL|Trace-Enter|Trace-Enter|| ---->ENTER WaitForNextURL, Depth=1|93563|1||16 2022-01-25 16:17:41.222673|Trace|AITOOLS.EXE|UpdateAIURLList|Trace-Enter|Trace-Enter|| ---->ENTER UpdateAIURLList, Depth=2|93564|2||16 2022-01-25 16:17:41.222673|Trace|AITOOLS.EXE|UpdateAIURLList|Trace-Exit|Trace-Exit|| ----<EXIT UpdateAIURLList, Time=0ms, Depth=1|93565|1||16 2022-01-25 16:17:41.222673|Trace|AITOOLS.EXE|WaitForNextURL|Trace-Exit|Trace-Exit||----<EXIT WaitForNextURL, Time=0ms, Depth=0|93566|0||16 2022-01-25 16:17:41.222673|Debug|AITOOLS.EXE|ImageQueueLoop|Deepstack_Objects:127.0.0.1:81|SH - Front Garage|1643130631462 - Copy (5).jpg| Adding task for file '1643130631462 - Copy (5).jpg' (Image QueueTime='0.0' mins, URL Queue wait='0ms', URLOrder=2, URLOriginalOrder=1) on URL 'http://127.0.0.1:81/v1/vision/detection'|93567|0||16 2022-01-25 16:17:41.222673|Debug|AITOOLS.EXE|ImageQueueLoop|Deepstack_Objects:127.0.0.1:81|SH - Front Garage|| Done adding 1 total threads, ErrCnt=0, ImageProcessQueue.Count=0|93568|0||16 2022-01-25 16:17:41.222673|Trace|AITOOLS.EXE|DetectObjects|Trace-Enter|Trace-Enter|| ---->ENTER DetectObjects, Depth=1|93569|1||23 2022-01-25 16:17:41.223673|Trace|AITOOLS.EXE|EventMessage|Trace-Enter|Trace-Enter|| ---->ENTER EventMessage, Depth=2|93570|3||1 2022-01-25 16:17:41.223673|Trace|AITOOLS.EXE|GetCamera|Trace-Enter|Trace-Enter|| ---->ENTER GetCamera, Depth=3|93571|3||23 2022-01-25 16:17:41.223673|Debug|AITOOLS.EXE|GetCamera|Deepstack_Objects:127.0.0.1:81|SH - Front Garage|| No enabled camera with the same filename, cameraname, or prefix found for 'V:\Sighthound\Videos\archive\front door\16431\thumbs\1643130631462 - Copy (5).jpg'|93572|3||23 2022-01-25 16:17:41.223673|Trace|AITOOLS.EXE|GetCamera|Deepstack_Objects:127.0.0.1:81|SH - Front Garage|| (Found a DEFAULT camera for 'V:\Sighthound\Videos\archive\front door\16431\thumbs\1643130631462 - Copy (5).jpg': 'SH - Front Garage')|93573|3||23 2022-01-25 16:17:41.223673|Trace|AITOOLS.EXE|GetCamera|Trace-Exit|Trace-Exit|| ----<EXIT GetCamera, Time=0ms, Depth=2|93574|2||23 2022-01-25 16:17:41.223673|Debug|AITOOLS.EXE|DetectObjects|Deepstack_Objects:127.0.0.1:81|SH - Front Garage|1643130631462 - Copy (5).jpg| Starting analysis of V:\Sighthound\Videos\archive\front door\16431\thumbs\1643130631462 - Copy (5).jpg...|93575|2||23 2022-01-25 16:17:41.223673|Trace|AITOOLS.EXE|LoadImage|Trace-Enter|Trace-Enter|| ---->ENTER LoadImage, Depth=3|93576|3||23 2022-01-25 16:17:41.223673|Trace|AITOOLS.EXE|WaitForFileAccess|Trace-Enter|Trace-Enter|| ---->ENTER WaitForFileAccess, Depth=4|93577|4||23 2022-01-25 16:17:41.227675|Trace|AITOOLS.EXE|EventMessage|Trace-Exit|Trace-Exit|| ----<EXIT EventMessage, Time=4ms, Depth=3|93578|3||1 2022-01-25 16:17:41.232675|Trace|AITOOLS.EXE|WaitForFileAccess|Trace-Exit|Trace-Exit|| ----<EXIT WaitForFileAccess, Time=9ms, Depth=2|93579|2||23