class
OnnxRuntime::Tensor
- OnnxRuntime::Tensor
- Reference
- Object
Overview
Tensor class provides high-level API for working with dense tensors in ONNX Runtime.
Defined in:
onnxruntime/tensor.crClass Method Summary
-
.create(data : Array(Float32), shape = nil, session = nil)
Creates a tensor from various data types
- .create(data : Array(Int32), shape = nil, session = nil)
- .create(data : Array(Int64), shape = nil, session = nil)
- .create(data : Array(Float64), shape = nil, session = nil)
- .create(data : Array(UInt8), shape = nil, session = nil)
- .create(data : Array(Int8), shape = nil, session = nil)
- .create(data : Array(UInt16), shape = nil, session = nil)
- .create(data : Array(Int16), shape = nil, session = nil)
- .create(data : Array(UInt32), shape = nil, session = nil)
- .create(data : Array(UInt64), shape = nil, session = nil)
- .create(data : Array(Bool), shape = nil, session = nil)
- .create(data : Array(String), shape = nil, session = nil)
- .create(data, shape = nil, session = nil)
-
.extract_data(tensor, session)
Extract data from a tensor
Class Method Detail
Creates a tensor from various data types