OnnxRuntime
Ort::MemoryInfo Struct Reference

#include <onnxruntime_cxx_api.h>

Inherits Ort::Base< OrtMemoryInfo >.

Public Member Functions

 MemoryInfo (std::nullptr_t)
 
 MemoryInfo (OrtMemoryInfo *p)
 Used for interop with the C API. More...
 
 MemoryInfo (const char *name, OrtAllocatorType type, int id, OrtMemType mem_type)
 
std::string GetAllocatorName () const
 
OrtAllocatorType GetAllocatorType () const
 
int GetDeviceId () const
 
OrtMemType GetMemoryType () const
 
bool operator== (const MemoryInfo &o) const
 
- Public Member Functions inherited from Ort::Base< OrtMemoryInfo >
 Base ()=default
 
 Base (OrtMemoryInfo *p)
 
 ~Base ()
 
 operator OrtMemoryInfo * ()
 
 operator const OrtMemoryInfo * () const
 
OrtMemoryInforelease ()
 Releases ownership of the contained pointer. More...
 

Static Public Member Functions

static MemoryInfo CreateCpu (OrtAllocatorType type, OrtMemType mem_type1)
 

Additional Inherited Members

- Public Types inherited from Ort::Base< OrtMemoryInfo >
using contained_type = OrtMemoryInfo
 
- Protected Member Functions inherited from Ort::Base< OrtMemoryInfo >
 Base (const Base &)=delete
 
 Base (Base &&v) noexcept
 
Baseoperator= (const Base &)=delete
 
void operator= (Base &&v) noexcept
 
- Protected Attributes inherited from Ort::Base< OrtMemoryInfo >
OrtMemoryInfop_
 

Constructor & Destructor Documentation

◆ MemoryInfo() [1/3]

Ort::MemoryInfo::MemoryInfo ( std::nullptr_t  )
inlineexplicit

◆ MemoryInfo() [2/3]

Ort::MemoryInfo::MemoryInfo ( OrtMemoryInfo p)
inlineexplicit

Used for interop with the C API.

◆ MemoryInfo() [3/3]

Ort::MemoryInfo::MemoryInfo ( const char *  name,
OrtAllocatorType  type,
int  id,
OrtMemType  mem_type 
)

Member Function Documentation

◆ CreateCpu()

static MemoryInfo Ort::MemoryInfo::CreateCpu ( OrtAllocatorType  type,
OrtMemType  mem_type1 
)
static

◆ GetAllocatorName()

std::string Ort::MemoryInfo::GetAllocatorName ( ) const

◆ GetAllocatorType()

OrtAllocatorType Ort::MemoryInfo::GetAllocatorType ( ) const

◆ GetDeviceId()

int Ort::MemoryInfo::GetDeviceId ( ) const

◆ GetMemoryType()

OrtMemType Ort::MemoryInfo::GetMemoryType ( ) const

◆ operator==()

bool Ort::MemoryInfo::operator== ( const MemoryInfo o) const