Rat Surveillance and Re-Processing Footage

john897

n3wb
Joined
Dec 1, 2015
Messages
5
Reaction score
2
As a STEM/Maker project, my daughter and I have taken on the rodents in our crawlspace with a robot that we built which lays traps in places that I can’t easily access. Part of the project is “rat surveillance” to see their patterns so we can place traps along the path that they run and learn their habits, which is a basic extermination technique.


Anyway, I’m recording continuously and working on refining my alert settings for rats, not going that well, too many alerts for no activity, and usually have to watch a whole night of footage at 32x or slower to really see if he showed up – he’s smaller than the minimum 100 x 100 pixels. I commonly spend an hour at a time looking through footage for say, a rat or a lost cat, when the alerts were not set optimally. In the cat example last weekend, settings were set to flag a person walking through the scene. We fear the cat was eaten by a Coyote and I had to manually review a bunch of footage. There was a patch of grass where he liked to hang out where there was little motion / light changes, so that would have been perfect to reprocess.


Here’s the question. Is there a way to re-process footage through Blue Iris so that I can get new alerts based on new parameters? I suppose I could replay all of the footage and point a Blue Iris camera at the screen with new settings, but that is clumsy. I’ve seen other forums where people get different motion detection software, but it’s cumbersome to get new software and learn how to use it, then forget how to use it. All ideas welcome.
 

poptix

n3wb
Joined
Jan 19, 2016
Messages
19
Reaction score
14
If you're interested in playing with some basic Python programming you can do this pretty easily in OpenCV
 

davej

Getting the hang of it
Joined
Apr 25, 2014
Messages
279
Reaction score
69
I would like to see a simple example of video post-processing.
 

poptix

n3wb
Joined
Jan 19, 2016
Messages
19
Reaction score
14
I worked up this quick example based on some of the documentation. You'll need the python modules cv2, time, pandas, sys, imutils and datetime

motion.py <video.mp4> (technically, any video format cv2 supports will work, including .dav)

This will display a window that highlights motion with a green box, once it's done playing through it will create <video.mp4.csv> with the time code of each motion event.

http://poptix.net/opencv/motion.py
http://poptix.net/opencv/mailman.mp4 (sample video to download and use with motion.py, right click, save-as)
 
Last edited:

poptix

n3wb
Joined
Jan 19, 2016
Messages
19
Reaction score
14
The video I linked was just meant as a sample video for use with motion.py, I've updated my post.
 
Top