nvidia.dali.fn.flip

nvidia.dali.fn.flip(*inputs, **kwargs)

Flips the images in selected dimensions (horizontal, vertical, and depthwise).

This operator allows sequence inputs and supports volumetric data.

Supported backends
  • ‘cpu’

  • ‘gpu’

Parameters

input (TensorList ('FDHWC', 'FHWC', 'DHWC', 'HWC', 'FCDHW', 'FCHW', 'CDHW', 'CHW')) – Input to the operator.

Keyword Arguments
  • bytes_per_sample_hint (int or list of int, optional, default = [0]) –

    Output size hint, in bytes per sample.

    If specified, the operator’s outputs residing in GPU or page-locked host memory will be preallocated to accommodate a batch of samples of this size.

  • depthwise (int or TensorList of int, optional, default = 0) – Flip the depthwise dimension.

  • horizontal (int or TensorList of int, optional, default = 1) – Flip the horizontal dimension.

  • preserve (bool, optional, default = False) – Prevents the operator from being removed from the graph even if its outputs are not used.

  • seed (int, optional, default = -1) –

    Random seed.

    If not provided, it will be populated based on the global seed of the pipeline.

  • vertical (int or TensorList of int, optional, default = 0) – Flip the vertical dimension.