Operators

Function

Supported Device

Description

Add

HPU, CPU

Performs element-wise addition and supports Broadcasting.

BasicCrop

CPU

Crops input tensor along width, height and depth.

BitwiseAnd

HPU

Computes the output by doing bitwise AND operation on input tensors.

BitwiseOr

HPU

Computes the output by doing bitwise OR operation on input tensors.

BitwiseXor

HPU

Computes the output by doing bitwise XOR operation on input tensors.

Brightness

HPU

Defines the brightness of the image.

Cast

HPU

Changes the data type of the input tensor.

Clamp

HPU

Clamps all elements in input into the range [lowerBound, upperBound].

CocoReader

CPU

Reader for SSD Coco dataset which produces outputs as images and metadata.

ColorSpaceConversion

HPU

Transforms the image from one color representation to another color representation.

Concat

HPU

Concatenates tensors along one dimension.

CoinFlip

HPU, CPU

Outputs a tensor with random boolean values using a Bernoulli distribution.

Constant

HPU, CPU

Constant operator generates scalar constant value tensor.

Contrast

HPU

Defines the contrast of the image.

Crop

HPU, CPU

Crops input tensor with specified window dimensions and window position.

CropMirrorNorm

HPU

Performs fused cropping, mirroring, normalization, and type casting.

ExtCpuOp

CPU

Allows user to add existing CPU operators.

ExtHpuOp

HPU

Allows user to add existing TPC operators to media pipeline.

Flip

HPU

This operator flips selected dimensions (horizontal, vertical, depthwise).

GatherND

HPU

Gathers slices of input tensor into an output tensor of a specific rank.

GaussianBlur

HPU

Applies 1D Gaussian Blur on input tensor by applying grouped 1D convolution with input Gaussian kernel.

Hue

HPU

Modifies the hue of an image by specified degrees.

ImageDecoder

HPU

Decodes and resizes batch of images.

MediaConst

CPU

Generates constant data as per given shape and data type on every iteration.

MediaExtReaderOp

CPU

Integrates external data reader with media pipe.

MediaFunc

CPU

Allows user to generate new tensor data on every iteration.

MemCpy

HPU

Copies data from the input tensor to the output tensor.

Mult

HPU, CPU

Performs element-wise multiplication and supports Broadcasting.

Neg

HPU

Resultant output tensor has the sign flipped for each element in input.

Normalize

HPU

Normalizes the input tensor by subtracting mean and dividing by standard deviation.

Pad

HPU

Pads a tensor with zeros or any numbers. .

RandomBiasedCrop

CPU

Performs random crop operation based on label data.

RandomFlip

HPU, CPU

Flips images in a selected direction (horizontal or vertical) with a random predicate.

RandomNormal

HPU, CPU

Generates random numbers from a normal distribution.

RandomUniform

HPU, CPU

Generates random numbers from an uniform distribution.

ReadImageDatasetFromDir

CPU

Reader designed for image classification tasks.

ReadNumpyDatasetFromDir

CPU

Reads numpy data files and numpy label files either from given directory or file list and returns the batch of numpy images and labels.

ReduceMax

HPU

Computes the maximum of the input tensor’s elements along the provided dimension.

ReduceMin

HPU

Computes the minimum of the input tensor’s elements along the provided dimension.

Reshape

HPU

Returns a new tensor that has the same values as input tensor in the same order, except with a new shape given by size and tensorDim arguments.

Resize

HPU

Resizes an image by a scale factor using either bilinear, cubic, nearest neighbor or gaussian sampling.

Saturation

HPU

Modifies the saturation level of an image by a specified change factor.

Slice

HPU

Produces a slice of the input tensor along multiple axes.

Split

HPU

Splits a tensor into a list of tensors along the specified axis.

SSDMetadata

CPU

Takes the metadata output of Coco reader and performs operations such as crop, flip and encoding of bounding boxes.

Sub

HPU

Performs element-wise subtraction and supports Broadcasting.

Transpose

HPU

Produces a transposed tensor of the input tensor along multiple axes.

Where

HPU, CPU

Outputs a tensor of elements selected from either input0 or input1.

Zoom

CPU

Zoom operator supports zoom-in operation on the given images and labels.