Python code for Guassian Mixture Models, using for video background modeling, based on the paper of Stauffer, C. and W. E. L. Grimson (1999).
- Python 3.6.2
- Python OpenCV 4.2.0
PyGmm.py -i D:/video/test5.mp4 -o outpy.mp4
You can use surveillance videos to test the code. Here is my example of test Result:
Original video screenshot:
The Guassian Background substraction result:
-
The speed is very slow and should make something up to speed it.
-
Connect components and filter noise pixels.
-
Add Kalman filters to track the moving objects.
-
Stauffer, C. and W. E. L. Grimson (1999). Adaptive background mixture models for real-time tracking, IEEE.
-
KaewTraKulPong, P. and R. Bowden (2001). An improved adaptive background mixture model for real-time tracking with shadow detection.