OPENCV Learning---Moving target (foreground) detection

Source: Internet
Author: User

OPENCV Learning---moving target (foreground) detection

1. Frame Difference method

Principle: The video sequence uses pixel-based time difference between two frames or three frames, and the motion region of the image is extracted by the closed-value.

Advantages: The algorithm is simple, the computational amount is small, the training background is not necessary, and the light is not sensitive to the slow transformation.

Disadvantage: Susceptible to weather, shadow and clutter background, the choice of threshold T is very key, poor stability.

2. Background Difference method

Principle: Using the background parameter model to approximate the background image, the difference between the current frame and the background image is realized to detect the moving region.

Advantages: Low computational capacity, high real-time performance, background dynamic update using existing frame information

Disadvantage: How to set up a background model for dynamic change of different scenes, and reduce the influence of dynamic scene change on motion segmentation.

3.GMM Mixed Gaussian model

Principle: Use K (basically 3 to 5) Gaussian model to characterize the characteristics of each pixel in the image, update the mixed Gaussian model after the new frame image is obtained, assign an initial mean, standard deviation and weight for each pixel of the image, collect n-frame image to get the mean value of each pixel by using the online EM algorithm. Standard deviation and weight. Detects whether each point belongs to a background point starting from the n+1 frame.

Advantage: Adapt to the change of light, the effect of slow moving objects is also better.

Disadvantages: Large computational capacity, difficult to achieve real-time.

4. Optical Flow method

Principle: The main task of optical flow method is to calculate the optical flow field, that is, under the appropriate smoothness constraints, according to the space-time gradient of the image sequence to estimate the sports ground, through the analysis of the changes in the stadium to detect and segmentation of moving objects and scenes.

Usually there are two methods based on the global optical flow field and the characteristic point optical flow field.

Advantage: In the ideal case, it can detect the independent motion of the object, do not need to know the scene in advance any information, can be very accurate to calculate the speed of the moving object, and can be used in the case of camera motion

Disadvantage: The calculation method of the global optical flow field is large, and the noise, multi-source, shadow and occlusion factors will seriously affect the calculation results of the flow field distribution, and the optical flow method is complex and difficult to realize real-time processing.

5.Vibe algorithm

Principle: Using a single frame video sequence to initialize the background model, for a pixel point, combined with the adjacent pixel point has a similar pixel value of the spatial distribution characteristics, randomly select its neighborhood point pixel value as its model sample value. The background model stores a sample set for each background point, and then compares each new pixel value to the sample set to determine whether it belongs to the background.

Advantages: Small computational capacity, easy real-time, anti-noise and the integrity of the target segmentation is good,

Cons: Due to the possibility of using a moving object's pixel initialization sample set, it is easy to introduce the ghost area and the ghosting will be eliminated slowly.

OPENCV Learning---Moving target (foreground) detection

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.