HDK
 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Friends Macros Groups Pages
Ort::Custom::Tensor< std::string > Class Template Reference

#include <onnxruntime_lite_custom_op.h>

+ Inheritance diagram for Ort::Custom::Tensor< std::string >:

Public Types

using strings = std::vector< std::string >
 

Public Member Functions

 Tensor (OrtKernelContext *ctx, size_t indice, bool is_input)
 
const stringsData () const
 
const voidDataRaw () const override
 
size_t SizeInBytes () const override
 
void SetStringOutput (const strings &ss, const std::vector< int64_t > &dims)
 
const Span< std::string > & AsSpan ()
 
const std::stringAsScalar ()
 
- Public Member Functions inherited from Ort::Custom::TensorBase
 TensorBase (OrtKernelContext *ctx, size_t indice, bool is_input)
 
 operator bool () const
 
const std::vector< int64_t > & Shape () const
 
ONNXTensorElementDataType Type () const
 
int64_t NumberOfElement () const
 
std::string Shape2Str () const
 
bool IsCpuTensor () const
 
- Public Member Functions inherited from Ort::Custom::ArgBase
 ArgBase (OrtKernelContext *ctx, size_t indice, bool is_input)
 
virtual ~ArgBase ()
 

Additional Inherited Members

- Protected Attributes inherited from Ort::Custom::TensorBase
std::optional< std::vector
< int64_t > > 
shape_
 
ONNXTensorElementDataType type_ = ONNX_TENSOR_ELEMENT_DATA_TYPE_UNDEFINED
 
const char * mem_type_ = "Cpu"
 
- Protected Attributes inherited from Ort::Custom::ArgBase
struct KernelContext ctx_
 
size_t indice_
 
bool is_input_
 

Detailed Description

template<>
class Ort::Custom::Tensor< std::string >

Definition at line 169 of file onnxruntime_lite_custom_op.h.

Member Typedef Documentation

Definition at line 171 of file onnxruntime_lite_custom_op.h.

Constructor & Destructor Documentation

Ort::Custom::Tensor< std::string >::Tensor ( OrtKernelContext *  ctx,
size_t  indice,
bool  is_input 
)
inline

Definition at line 173 of file onnxruntime_lite_custom_op.h.

Member Function Documentation

const std::string& Ort::Custom::Tensor< std::string >::AsScalar ( )
inline

Definition at line 230 of file onnxruntime_lite_custom_op.h.

const Span<std::string>& Ort::Custom::Tensor< std::string >::AsSpan ( )
inline

Definition at line 227 of file onnxruntime_lite_custom_op.h.

const strings& Ort::Custom::Tensor< std::string >::Data ( ) const
inline

Definition at line 202 of file onnxruntime_lite_custom_op.h.

const void* Ort::Custom::Tensor< std::string >::DataRaw ( ) const
inlineoverridevirtual

Implements Ort::Custom::TensorBase.

Definition at line 205 of file onnxruntime_lite_custom_op.h.

void Ort::Custom::Tensor< std::string >::SetStringOutput ( const strings ss,
const std::vector< int64_t > &  dims 
)
inline

Definition at line 217 of file onnxruntime_lite_custom_op.h.

size_t Ort::Custom::Tensor< std::string >::SizeInBytes ( ) const
inlineoverridevirtual

Implements Ort::Custom::TensorBase.

Definition at line 211 of file onnxruntime_lite_custom_op.h.


The documentation for this class was generated from the following file: