Member-only story
Detecting Motion with OpenCV — Image Analysis for Beginners
How to detect and analyze moving objects with OpenCV
Motion detection has many purposes. You can use it to start recording once you see movement on a wildlife camera or a security camera, e.g. Another application is performance-improvement. Instead of analyzing a whole image, we only have to work with small parts that moved. Like only identifying the color of the moving cars in the image above.
In this article, we’ll create a fully working motion detector that can be used for all of the use-cases above. In the process, we’ll learn a lot about processing images with OpenCV. At the end of this article, you’ll have a fully operational motion detector and a lot more knowledge about image processing. Let’s code!
Series
This article is part of a series about OpenCV image processing. Check out the other articles:
- Reading images, video’s, your screen and the webcam
- Detecting and blurring faces
- Destroying Duck Hunt with template matching: finding images in images
- Creating a motion-detector (📍 You are here!)
- Detecting shapes without AI (under construction; coming soon)