vpi.BackgroundSubtractor
- class vpi.BackgroundSubtractor(size: Tuple[int, int], format: vpi.Format, backend: vpi.Backend = vpi.Backend.DEFAULT) vpi.BackgroundSubtractor
Creates the main object of the BgSub algorithm.
Note
This class allocates all resources needed by the background subtraction (BgSub) algorithm. An object of this class is able to run the BgSub algorithm via its
call operator
.- Parameters
size (Tuple[int, int]) – Dimensions of the input image to be processed.
format (vpi.Format) – Format of the input image to be processed.
backend (vpi.Backend, optional) – Backend to be used.
- Returns
The main object of the BgSub algorihtm.
- Return type
Caution
Restrictions to several arguments may apply. Check the C API references of the create payload function and the group concepts for more details.
Methods
__call__
(-> Tuple[vpi.Image, vpi.Image])Extracts fore/background of the input image.