nvidia.dali.experimental.dynamic.plugin.video.decoder#

nvidia.dali.experimental.dynamic.plugin.video.decoder(buffer, /, *, batch_size=None, device=None, affine=None, end_frame=None)#

Decodes a video file from a memory buffer (e.g. provided by external source).

The video streams can be in most of the container file formats. FFmpeg is used to parse video

containers and returns a batch of sequences of frames with shape (F, H, W, C) where F is the number of frames in a sequence and can differ for each sample.

Supported backends
  • ‘mixed’

Parameters:

buffer (Tensor/Batch) – Data buffer with a loaded video file.

Keyword Arguments:
  • affine (bool, optional, default = True) –

    Applies only to the mixed backend type.

    If set to True, each thread in the internal thread pool will be tied to a specific CPU core.

    Otherwise, the threads can be reassigned to any CPU core by the operating system.

  • end_frame (int, optional, default = 0) – Index of the end frame to be decoded.