in BackgroundSubtractorMOG, can I have different learning rate in different region?

asked 2017-08-23 05:37:29 -0600

gino0717 gravatar image

updated 2017-08-23 05:40:00 -0600

hi,

I'm using BackgroundSubtractorMOG in opencv2411 and it work well. However, I want some specific regions have different learning rate, for example, in Rect(x,y,w,h), the learning rate is 0.05, and the outside is 0.01.

The method I come up with is that I make 2 BackgroundSubtractors with different learning rates, after I get two foreground masks, I copy the Rect of one mask (learning rate = 0.05) to another mask(learning rate = 0.01) . Is there any better solution?

Thanks for any advice!

edit retag flag offensive close merge delete