module onnxrt.ops_cpu.op_sequence_insert#

Inheritance diagram of mlprodict.onnxrt.ops_cpu.op_sequence_insert

Short summary#

module mlprodict.onnxrt.ops_cpu.op_sequence_insert

Runtime operator.

Classes#

class

truncated documentation

SequenceInsert

SequenceInsert ============== Outputs a tensor sequence that inserts ‘tensor’ into ‘input_sequence’ at ‘position’. ‘tensor’ …

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__

_infer_shapes

_infer_sizes

_infer_types

_run

Documentation#

Runtime operator.

New in version 0.7.

source on GitHub

class mlprodict.onnxrt.ops_cpu.op_sequence_insert.SequenceInsert(onnx_node, desc=None, **options)#

Bases: OpRun

Outputs a tensor sequence that inserts ‘tensor’ into ‘input_sequence’ at ‘position’. ‘tensor’ must have the same data type as ‘input_sequence’. Accepted range for ‘position’ is in [-n, n], where n is the number of tensors in ‘input_sequence’. Negative value means counting positions from the back. ‘position’ is optional, by default it inserts ‘tensor’ to the back of ‘input_sequence’.

Inputs

Between 2 and 3 inputs.

  • input_sequence (heterogeneous)S: Input sequence.

  • tensor (heterogeneous)T: Input tensor to be inserted into the input sequence.

  • position (optional, heterogeneous)I: Position in the sequence where the new tensor is inserted. It is optional and default is to insert to the back of the sequence. Negative value means counting positions from the back. Accepted range in [-n, n], where n is the number of tensors in ‘input_sequence’. It is an error if any of the index values are out of bounds. It must be a scalar(tensor of empty shape).

Outputs

  • output_sequence (heterogeneous)S: Output sequence that contains the inserted tensor at given position.

Type Constraints

  • T tensor(uint8), tensor(uint16), tensor(uint32), tensor(uint64), tensor(int8), tensor(int16), tensor(int32), tensor(int64), tensor(float16), tensor(float), tensor(double), tensor(string), tensor(bool), tensor(complex64), tensor(complex128): Constrain to any tensor type.

  • S seq(tensor(uint8)), seq(tensor(uint16)), seq(tensor(uint32)), seq(tensor(uint64)), seq(tensor(int8)), seq(tensor(int16)), seq(tensor(int32)), seq(tensor(int64)), seq(tensor(float16)), seq(tensor(float)), seq(tensor(double)), seq(tensor(string)), seq(tensor(bool)), seq(tensor(complex64)), seq(tensor(complex128)): Constrain to any tensor type.

  • I tensor(int32), tensor(int64): Constrain position to integral tensor. It must be a scalar(tensor of empty shape).

Version

Onnx name: SequenceInsert

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

Runtime implementation: SequenceInsert

__init__(onnx_node, desc=None, **options)#
_infer_shapes(S, T, ind=None)#

Should be overwritten.

source on GitHub

_infer_sizes(*args)#

Should be overwritten.

source on GitHub

_infer_types(S, T, ind=None)#

Should be overwritten.

source on GitHub

_run(S, T, ind=None, attributes=None, verbose=0, fLOG=None)#

Should be overwritten.

source on GitHub