79521269

Date: 2025-03-19 20:01:26
Score: 1
Natty:
Report link

Ubuntu 16.04
Compare two camera JPEGs (moving detection)

# Command line
compare -metric NCC camLast.jpg camPrev.jpg null: ;echo
0.9974321

# Prog
floatDiff=$( compare -metric NCC camLast.jpg camPrev.jpg null: 2>&1 )
echo $floatDiff

- On two identical pictures, result is 1.
- Results on camera are between 0.997 and 0.998, due to camera noise and jpeg conversion loss.
- Results below 0.997 are true differences, meaning Moving detection on camera view field happened.

Reasons:
  • Has code block (-0.5):
  • Unregistered user (0.5):
  • Low reputation (1):
Posted by: Damijan Peternelj