Expand description
tosa
dialect.
The Tensor Operator Set Architecture (TOSA) dialect.
This dialect implements the TOSA standard described at https://www.mlplatform.org/tosa/tosa_spec.html .
Tensor Operator Set Architecture (TOSA) provides a set of whole-tensor operations commonly employed by Deep Neural Networks. The intent is to enable a variety of implementations running on a diverse range of processors, with the results at the TOSA level consistent across those implementations. Applications or frameworks which target TOSA can therefore be deployed on a wide range of different processors, such as CPUs or GPUs, with defined accuracy and compatibility constraints. Most operators from the common ML frameworks should be expressible in TOSA. It is expected that there will be tools to lower from the ML frameworks into TOSA.
Structs§
- An
abs
operation. Elementwise abs op. - A builder for an
abs
operation. - An
add
operation. Elementwise addition operator. - A builder for an
add
operation. - An
apply_scale
operation. Rescale scalar operator for Tosa tensor operators. - A builder for an
apply_scale
operation. - An
argmax
operation. Perform argmax on the input.. - A builder for an
argmax
operation. - An
arithmetic_right_shift
operation. Elementwise Arithmetic Right Shift. - A builder for an
arithmetic_right_shift
operation. - An
avg_pool2d
operation. Performs max pooling on the input.. - A builder for an
avg_pool2d
operation. - A
bitwise_and
operation. Bitwise AND operator. - A builder for a
bitwise_and
operation. - A
bitwise_not
operation. Bitwise NOT operator. - A builder for a
bitwise_not
operation. - A
bitwise_or
operation. Bitwise OR operator. - A builder for a
bitwise_or
operation. - A
bitwise_xor
operation. Bitwise XOR operator. - A builder for a
bitwise_xor
operation. - A
cast
operation. Cast operation. - A builder for a
cast
operation. - A
ceil
operation. Elementwise ceil op. - A builder for a
ceil
operation. - A
clamp
operation. Computes clamp(features, min, max).. - A builder for a
clamp
operation. - A
clz
operation. Elementwise count leading zero op. - A builder for a
clz
operation. - A
concat
operation. Concatenates tensors along one dimension.. - A builder for a
concat
operation. - A
const
operation. Constant op.. - A builder for a
const
operation. - A
conv2d
operation. 2D Convolution Operator. - A builder for a
conv2d
operation. - A
conv3d
operation. 3D Convolution operator. - A builder for a
conv3d
operation. - A
custom
operation. Custom operator wrapper for Tosa. - A builder for a
custom
operation. - A
depthwise_conv2d
operation. Depthwise 2D Convolution operator. - A builder for a
depthwise_conv2d
operation. - A
div
operation. Integer divide operator. - A builder for a
div
operation. - An
equal
operation. Returns the truth value of (x == y) element-wise.. - A builder for an
equal
operation. - An
erf
operation. Computes gauss error function of input. - A builder for an
erf
operation. - An
exp
operation. Elementwise exp op. - A builder for an
exp
operation. - A
fft2d
operation. Performs FFT2D operation on the input.. - A builder for a
fft2d
operation. - A
floor
operation. Elementwise floor op. - A builder for a
floor
operation. - A
fully_connected
operation. Fully Connected operator. - A builder for a
fully_connected
operation. - A
gather
operation. Gather operation,. - A builder for a
gather
operation. - A
greater_equal
operation. Returns the truth value of (x >= y) element-wise.. - A builder for a
greater_equal
operation. - A
greater
operation. Returns the truth value of (x > y) element-wise.. - A builder for a
greater
operation. - An
identity
operation. Identity operator. - A builder for an
identity
operation. - A
cond_if
operation. Conditional if operator. - A builder for a
cond_if
operation. - A
log
operation. Elementwise log op. - A builder for a
log
operation. - A
logical_and
operation. Returns the truth value of x AND y element-wise.. - A builder for a
logical_and
operation. - A
logical_left_shift
operation. Elementwise Logical Left Shift. - A builder for a
logical_left_shift
operation. - A
logical_not
operation. Returns the truth value of NOT x element-wise.. - A builder for a
logical_not
operation. - A
logical_or
operation. Returns the truth value of x OR y element-wise.. - A builder for a
logical_or
operation. - A
logical_right_shift
operation. Elementwise Logical Right Shift. - A builder for a
logical_right_shift
operation. - A
logical_xor
operation. Returns the truth value of x XOR y element-wise.. - A builder for a
logical_xor
operation. - A
matmul
operation. Matrix multiplication with bias. - A builder for a
matmul
operation. - A
max_pool2d
operation. Performs max pooling on the input.. - A builder for a
max_pool2d
operation. - A
maximum
operation. Elementwise Maximum. - A builder for a
maximum
operation. - A
minimum
operation. Elementwise Minimum. - A builder for a
minimum
operation. - A
mul
operation. Multiplication operator. - A builder for a
mul
operation. - A
negate
operation. Elementwise negate op. - A builder for a
negate
operation. - A
pad
operation. Pads a tensor with value specified.. - A builder for a
pad
operation. - A
pow
operation. Computes the power of one value to another.. - A builder for a
pow
operation. - A
rfft2d
operation. Performs RFFT2D operation on the input.. - A builder for a
rfft2d
operation. - A
reciprocal
operation. Elementwise reciprocal op. - A builder for a
reciprocal
operation. - A
reduce_all
operation. Reduce All operator. - A builder for a
reduce_all
operation. - A
reduce_any
operation. Reduce Any operator. - A builder for a
reduce_any
operation. - A
reduce_max
operation. Reduce Max operator. - A builder for a
reduce_max
operation. - A
reduce_min
operation. Reduce Min operator. - A builder for a
reduce_min
operation. - A
reduce_prod
operation. Reduce Prod operator. - A builder for a
reduce_prod
operation. - A
reduce_sum
operation. Reduce Sum operator. - A builder for a
reduce_sum
operation. - A
rescale
operation. Tosa rescale operator. - A builder for a
rescale
operation. - A
reshape
operation. Reshape operator. - A builder for a
reshape
operation. - A
resize
operation. Resize operation, supports various resize/upsample modes. - A builder for a
resize
operation. - A
reverse
operation. Reverse operator. - A builder for a
reverse
operation. - A
rsqrt
operation. Elementwise 1/sqrt op. - A builder for a
rsqrt
operation. - A
scatter
operation. Scatter operation,. - A builder for a
scatter
operation. - A
select
operation. Elementwise select operator. - A builder for a
select
operation. - A
sigmoid
operation. Computes elementwise sigmoid of input.. - A builder for a
sigmoid
operation. - A
slice
operation. Slice operator. - A builder for a
slice
operation. - A
sub
operation. Elementwise subtraction operator. - A builder for a
sub
operation. - A
table
operation. Table lookup op. - A builder for a
table
operation. - A
tanh
operation. Computes elementwise hyperbolic tangent of input. - A builder for a
tanh
operation. - A
tile
operation. Tile operator. - A builder for a
tile
operation. - A
transpose_conv2d
operation. Transpose 2D Convolution operator.. - A builder for a
transpose_conv2d
operation. - A
transpose
operation. Transpose operator. - A builder for a
transpose
operation. - A
variable
operation. Defines a variable. - A builder for a
variable
operation. - A
variable.read
operation. Read_buffer operator. - A builder for a
variable.read
operation. - A
variable.write
operation. Write_buffer operator. - A builder for a
variable.write
operation. - A
while_loop
operation. Output = input; While (Cond(output)) {output = Body(output)}. - A builder for a
while_loop
operation. - A
yield
operation. Yield operator. - A builder for a
yield
operation.
Functions§
- Creates an
abs
operation. - Creates an
add
operation. - Creates an
apply_scale
operation. - Creates an
argmax
operation. - Creates an
arithmetic_right_shift
operation. - Creates an
avg_pool2d
operation. - Creates a
bitwise_and
operation. - Creates a
bitwise_not
operation. - Creates a
bitwise_or
operation. - Creates a
bitwise_xor
operation. - Creates a
cast
operation. - Creates a
ceil
operation. - Creates a
clamp
operation. - Creates a
clz
operation. - Creates a
concat
operation. - Creates a
cond_if
operation. - Creates a
const
operation. - Creates a
conv2d
operation. - Creates a
conv3d
operation. - Creates a
custom
operation. - Creates a
depthwise_conv2d
operation. - Creates a
div
operation. - Creates an
equal
operation. - Creates an
erf
operation. - Creates an
exp
operation. - Creates a
fft2d
operation. - Creates a
floor
operation. - Creates a
fully_connected
operation. - Creates a
gather
operation. - Creates a
greater
operation. - Creates a
greater_equal
operation. - Creates an
identity
operation. - Creates a
log
operation. - Creates a
logical_and
operation. - Creates a
logical_left_shift
operation. - Creates a
logical_not
operation. - Creates a
logical_or
operation. - Creates a
logical_right_shift
operation. - Creates a
logical_xor
operation. - Creates a
matmul
operation. - Creates a
max_pool2d
operation. - Creates a
maximum
operation. - Creates a
minimum
operation. - Creates a
mul
operation. - Creates a
negate
operation. - Creates a
pad
operation. - Creates a
pow
operation. - Creates a
reciprocal
operation. - Creates a
reduce_all
operation. - Creates a
reduce_any
operation. - Creates a
reduce_max
operation. - Creates a
reduce_min
operation. - Creates a
reduce_prod
operation. - Creates a
reduce_sum
operation. - Creates a
rescale
operation. - Creates a
reshape
operation. - Creates a
resize
operation. - Creates a
reverse
operation. - Creates a
rfft2d
operation. - Creates a
rsqrt
operation. - Creates a
scatter
operation. - Creates a
select
operation. - Creates a
sigmoid
operation. - Creates a
slice
operation. - Creates a
sub
operation. - Creates a
table
operation. - Creates a
tanh
operation. - Creates a
tile
operation. - Creates a
transpose
operation. - Creates a
transpose_conv2d
operation. - Creates a
variable
operation. - Creates a
variable.read
operation. - Creates a
variable.write
operation. - Creates a
while_loop
operation. - Creates a
yield
operation.