BackgroundSubtraction

The BackgroundSubtraction block applies a background subtractor and computes a foreground mask for image src.

    BackgroundSubtraction

Library

ComputerVision/Videos/Operations

Parameters

BackgroundSubtraction_0

NameLabelDescriptionData TypeValid Values

type

Type

Specifies the algorithm.

Structure

type/MOG2

MOG2

Uses Gaussian Mixture-based algorithm.

Number

0
1

type/KNN

KNN

Uses K-nearest neighbors background subtraction algorithm.

Number

0
1

rate

Learning rate

The value between 0 and 1 that indicates how fast the background model is learnt. Negative parameter value makes the algorithm to use some automatically chosen learning rate. 0 means that the background model is not updated at all, 1 means that the background model is completely reinitialized from the last frame.

Scalar

externalActivation

External activation

This parameter defines if the block receives or inherits an external activation. When External Activation is used, an additional activation port is added to the block. Default is ON.

Number

0
1

Ports

NameTypeDescriptionIO TypeNumber

src

explicit

input

1

mask

explicit

output

1

Port 3

activation

input

externalActivation