Codebook Background Modeling Update and code-based model how to free up memory

Source: Internet
Author: User

During the use of Codebook background modeling, there is always a problem with background updates for the model.

1 The objectives we require are:
    • 1 when a person is stationary, one cannot be updated into a background (it must be ensured that the person is always the foreground);
    • 2 but for moving books and so on to be able to be updated into the background
2 Proposed solution: 2.1 using two codebook background model,

A model: Main model M, used to split the foreground
Another model: Re-modeling model R, satisfying criteria for re-modeling success, R replacing M
R instead of M, release m and reinitialize a copy of R

temp = M;M = R;free(temp);R = Init();

How do I release the codebook model of the existing code?

voidint//len = width*height{    for(int0; j < len; j++)    {        if (T[j].cb)        {            for (int0; i < T[j].numEntries; i++)            {                delete T[j].cb[i];            }            delete [] T[j].cb;        }    }    if (T)        delete [] T;    T = NULL;}
2.2 Conditions for re-modeling (one can be met)
    1. The picture has no foreground, which means no one in the room at this time
    2. There are too many prospects when it means that the light has changed or the camera is moved, or the background model is not calculated accurately
3 Reference Papers

Smart Vision for Managed Home Care:
http://download.csdn.net/detail/quzhongxin/8671203

Codebook Background Modeling Update and code-based model how to free up memory

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.