module onnxrt.ops_cpu.op_size#

Inheritance diagram of mlprodict.onnxrt.ops_cpu.op_size

Short summary#

module mlprodict.onnxrt.ops_cpu.op_size

Runtime operator.

source on GitHub

Classes#

class

truncated documentation

Size

Size ==== Takes a tensor as input and outputs a int64 scalar that equals to the total number of elements of the input …

Properties#

property

truncated documentation

args_default

Returns the list of arguments as well as the list of parameters with the default values (close to the signature). …

args_default_modified

Returns the list of modified parameters.

args_mandatory

Returns the list of optional arguments.

args_optional

Returns the list of optional arguments.

atts_value

Returns all parameters in a dictionary.

Methods#

method

truncated documentation

__init__

_run

Documentation#

Runtime operator.

source on GitHub

class mlprodict.onnxrt.ops_cpu.op_size.Size(onnx_node, desc=None, **options)#

Bases: OpRun


Takes a tensor as input and outputs a int64 scalar that equals to the total number of elements of the input tensor.

Inputs

  • data (heterogeneous)T: An input tensor.

Outputs

  • size (heterogeneous)T1: Total number of elements of the input tensor

Type Constraints

  • T tensor(uint8), tensor(uint16), tensor(uint32), tensor(uint64), tensor(int8), tensor(int16), tensor(int32), tensor(int64), tensor(bfloat16), tensor(float16), tensor(float), tensor(double), tensor(string), tensor(bool), tensor(complex64), tensor(complex128): Input tensor can be of arbitrary type.

  • T1 tensor(int64): Constrain output to int64 tensor, which should be a scalar though.

Version

Onnx name: Size

This version of the operator has been available since version 13.

Runtime implementation: Size

__init__(onnx_node, desc=None, **options)#
_run(data, attributes=None, verbose=0, fLOG=None)#

Should be overwritten.

source on GitHub