Contents

MLTensor

A multi-dimensional array of numerical or Boolean scalars tailored to ML use cases, containing methods to perform transformations and mathematical operations efficiently using a ML compute device.

Declaration

struct MLTensor

Topics

Creating a tensor

Accessing tensor properties

Getting the sum

Performing a logical AND operation

Performing a logical OR operation

Accessing the indicies

Casting the elements

Computing the absolute, ceiling and floor

Performing arithmetic operations

Applying trigonometric functions

Accessing the minimum, maximum and mean

Splitting the tensor

Resizing the tensor

Padding the tensor

Replacing the tensor values

Gathering slices

Transposing the tensor

Unpacking the tensor

Getting the shaped representation of the tensor

Removing dimensions from the shape of the tensor

Accessing the product along an axes

Getting the largest values

Clamping and concatenating

Computing the cumulative value

Computing the exponent, pow and square root

Accessing the extended tensor, sign and reciprocal

Reshaping the tensor

Computing the softmax

Reversing the tensor

Accessing a multiarray’s elements

Default Implementations

See Also

Model tensor