Video motion detection / mdCCTV script - Script Writing - CHDK Forum

Video motion detection / mdCCTV script

  • 4 Replies
  • 4344 Views
*

Offline j

  • *
  • 10
Video motion detection / mdCCTV script
« on: 21 / January / 2013, 13:10:54 »
Advertisements
Hello. I have tested mdCCTV script for video motion detection.
The script fails badly, even in bright sun light. A group of people
may pass by without any detection. If I decrease the threshold,
the video rec triggers continuously.

There is also a problem in stopping the script. Perhaps
because press of button causes camera motion.
Even if I succeed to stop the script, the video recording
may continue: if I attempt to stop the video recording
with full press, the scripts starts again!

I would like to know details of the motion detection
algorithm:
How many pixels are compared and how?
How the algorithm adapts to different lighting
in 24 hour period?
What is the detection resolution (note, camera is in video mode)?

I could develop the motion detection algorithm off-camera
if I would know exactly how to record test video and
process it for the algorithm. If I record standard video,
will that do?



Re: Video motion detection / mdCCTV script
« Reply #1 on: 21 / January / 2013, 14:01:29 »
Hello. I have tested mdCCTV script for video motion detection.
Please provide a link to the version you are using?

This one : http://chdk.setepontos.com/index.php/topic,1596.msg14337.html#msg14337  ?

Here's a link to the wiki page that describes the MD function : http://chdk.wikia.com/wiki/Motion_Detection

Quote
The script fails badly, even in bright sun light. A group of people
may pass by without any detection. If I decrease the threshold,
the video rec triggers continuously.
Try increasing the millisecond delay value (d) to give the camera time to settle between motion detections.

Quote
There is also a problem in stopping the script. Perhaps
because press of button causes camera motion.
Even if I succeed to stop the script, the video recording
may continue: if I attempt to stop the video recording
with full press, the scripts starts again!
Sounds like the script needs http://chdk.wikia.com/wiki/Script_commands#restore

Quote
How many pixels are compared and how?
Varies with the pixel step size parameter.

Quote
How the algorithm adapts to different lighting in 24 hour period?
It doesn't.
« Last Edit: 21 / January / 2013, 14:06:45 by waterwingz »
Ported :   A1200    SD940   G10    Powershot N    G16

*

Offline reyalp

  • ******
  • 14128
Re: Video motion detection / mdCCTV script
« Reply #2 on: 21 / January / 2013, 16:22:07 »
Hello. I have tested mdCCTV script for video motion detection.
The script fails badly, even in bright sun light. A group of people
may pass by without any detection. If I decrease the threshold,
the video rec triggers continuously.
Which camera are you using? It's possible the problems you are seeing are related to the specific port, not the md code in general.

In my experience, on correctly functioning cameras, it's quite possible to adjust the parameters so they will detect quite small motion without false positives.

On some cameras, the video mode changes the viewport buffer resolution, which might break MD.
Quote
How many pixels are compared and how?
http://trac.assembla.com/chdk/browser/trunk/modules/motion_detector.c
Don't forget what the H stands for.

*

Offline j

  • *
  • 10
Re: Video motion detection / mdCCTV script
« Reply #3 on: 23 / January / 2013, 10:40:36 »
I have feature suggestion:
A test mode where the test-MD would show the sensitivity values
which would trigger the MD. E.g., if I see motion in the test display,
I would also see the threshold value which would detect that motion.
Some kind of movement meter.

AdaptiveMD solves the 24 hour problem. The script shows that
every important feature need not be built-in.

I have SX110IS. I have feeling the threshold works opposite than
suggested in most of the scripts (sunlight to dawn). Lower values
like 4 triggers but lower is needed to keep the video recording
because not all motion is detected. I increased the comparison
interval and decreased the pixel step, but problems remains.

Re: Video motion detection / mdCCTV script
« Reply #4 on: 25 / January / 2013, 23:54:31 »
I have feature suggestion: A test mode where the test-MD would show the sensitivity values
which would trigger the MD. E.g., if I see motion in the test display, I would also see the threshold value which would detect that motion. Some kind of movement meter.
Here you go :  http://chdk.setepontos.com/index.php?topic=9366.msg96305#msg96305

Ported :   A1200    SD940   G10    Powershot N    G16

 

Related Topics


SimplePortal © 2008-2014, SimplePortal