Moving Target Detection Algorithm (sacon) based on background subtraction based on sample consistency)

Source: Internet
Author: User

The source of this article is http://blog.csdn.net/kezunhai.

Based on the papers of Hanzi Wang and othersBackground Subtraction based on a robust consensus methodBased on your understanding, if you are interested in the paper, you can click the open link to download the paper, the link collects common background modeling methods of the paper, you are welcome to exchange questions.
In this paper, the author proposes an efficient Adaptive Motion Target Detection Algorithm Based on statistics. This algorithm is called sacon (sample consensus). It evaluates the background model by calculating the sample consistency of each pixel. The algorithm is simple but has good performance. Compared with the latest algorithm, algorithms have strong application prospects. In the previous blog post of the blogger, this algorithm was briefly introduced in the middle layer of the Moving Target Detection Algorithm Based on Adaptive pixel segmentation. The following describes the sacon algorithm in the future.

1) Background Modeling

The Background Modeling in this article is a bit similar to the vibe algorithm, except that the vibe algorithm performs samples in a neighbor with a radius of R to establish a background model; the background model of the sacon algorithm is simpler and more straightforward. The algorithm uses the first N frames of the video sequence as the background model. Then, for each pixel, the background model can be expressed as: C (C1, C2 ,..., CN). For a color image, CI = (R, G, B) or the classification of the corresponding color space. For a gray image, it corresponds to a gray value.

2) Foreground Detection

Before introducing the foreground detection, we will first analyze the entire sacon Algorithm Framework, as shown in the frame chart:


It can be seen that this algorithm is mainly divided into four main parts: Inter-neighbor frame difference, Tom (Time Out map), sacon algorithm core processing, empty filling and other post-processing. The following sections describe these four parts.

① Inter-Domain Frame Difference

In order to reduce the calculation workload and speed up the calculation, the algorithm uses the inter-neighbor Frame Difference Method in the first step to extract Possible motion pixels (of course, it may also include some noise points and background points ).

② Tom

Tom is actually a counting matrix that records the number of times a pixel is continuously detected as a foreground. The formula is as follows:


Bt (m) = 0 indicates that pixels at m are detected as foreground, and the Tom value is added to 1. If the Tom value is higher than a certain threshold value, it is judged as the background (in this case, there are two situations: first, a certain moving target enters the scene and then stops the scene, for example, the car starts and stops; second, an object in the background is removed from the scene, such as a car driving), and the Tom value is set to 0.

③ Sacon algorithm core

Compare the new Pixel with the corresponding background model. The comparison method is as follows:


TR is a preset constant. For gray-scale images c = 1, for RGB color images c = (R, G, B ), the preceding value = 1 indicates the background, and 0 indicates the foreground. Next we will use the following formula to determine:


Among them, TN is a pre-defined threshold value, and its value is related to N. Generally, 2/3 NTR is recommended (in the case of color images ). Bt (m) = 0 indicates the foreground, otherwise it is the background.Personal opinion: the threshold here should adopt an adaptive method. The pixel threshold at different locations should be determined based on the characteristics of the pixels, such as contrast, average mean, and variance, you can refer to the PBAs algorithm's threshold calculation method.

④ Post-processing

For the detected foreground, the connectivity analysis is used to fill the holes in the foreground area, which can be achieved through morphological filtering. In this paper, the shadow detection is also analyzed in a simple way. For areas with foreground pixels similar to background pixels, the author uses further verification to reduce false positives.

After introducing the above four parts, it is necessary to simply clear the process: first, obtain the Possible motion prospects through the difference between frames possible foreground mask (PFM ); then, pass the background model, PFM, and Tom to sacon (detect the pixels corresponding to PFM in the sacon value), obtain the FM, analyze the connectivity of the FM, and fill in the holes, get the moving target. In terms of background update, pixel and block layers are updated. For details, see the thesis.

Finally, I posted several papers:




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.