Mila 0.13.48
Deep Neural Network Library
Loading...
Searching...
No Matches
Mila::Dnn::Serialization::ITensorBlob Struct Referenceabstractexport

Type-erased interface for a serialized tensor blob. More...

Inheritance diagram for Mila::Dnn::Serialization::ITensorBlob:

Public Member Functions

 ITensorBlob ()=default
 ITensorBlob (const ITensorBlob &)=delete
 ITensorBlob (ITensorBlob &&)=default
virtual ~ITensorBlob ()=default
virtual const void * data () const noexcept=0
virtual const TensorMetadatagetMetadata () const noexcept=0
ITensorBloboperator= (const ITensorBlob &)=delete
ITensorBloboperator= (ITensorBlob &&)=default
virtual size_t sizeBytes () const noexcept=0

Detailed Description

Type-erased interface for a serialized tensor blob.

Carries metadata alongside a raw host pointer to the underlying bytes. Concrete TensorBlob<MR> implementations own the memory via TensorBuffer. When MR is CudaPinnedMemoryResource, data() returns a pinned host pointer enabling direct DMA in the CUDA copyFromBlob path without driver staging.

This interface is the virtual boundary for loadParameter_ overrides — component implementations receive an ITensorBlob regardless of the originating memory resource.

Constructor & Destructor Documentation

◆ ~ITensorBlob()

virtual Mila::Dnn::Serialization::ITensorBlob::~ITensorBlob ( )
virtualdefault

◆ ITensorBlob() [1/3]

Mila::Dnn::Serialization::ITensorBlob::ITensorBlob ( )
default
Here is the caller graph for this function:

◆ ITensorBlob() [2/3]

Mila::Dnn::Serialization::ITensorBlob::ITensorBlob ( const ITensorBlob & )
delete
Here is the call graph for this function:

◆ ITensorBlob() [3/3]

Mila::Dnn::Serialization::ITensorBlob::ITensorBlob ( ITensorBlob && )
default
Here is the call graph for this function:

Member Function Documentation

◆ data()

virtual const void * Mila::Dnn::Serialization::ITensorBlob::data ( ) const
pure virtualnoexcept

Implemented in Mila::Dnn::Serialization::TensorBlob< MR >.

Here is the call graph for this function:
Here is the caller graph for this function:

◆ getMetadata()

virtual const TensorMetadata & Mila::Dnn::Serialization::ITensorBlob::getMetadata ( ) const
pure virtualnoexcept

Implemented in Mila::Dnn::Serialization::TensorBlob< MR >.

Here is the caller graph for this function:

◆ operator=() [1/2]

ITensorBlob & Mila::Dnn::Serialization::ITensorBlob::operator= ( const ITensorBlob & )
delete
Here is the call graph for this function:

◆ operator=() [2/2]

ITensorBlob & Mila::Dnn::Serialization::ITensorBlob::operator= ( ITensorBlob && )
default
Here is the call graph for this function:

◆ sizeBytes()

virtual size_t Mila::Dnn::Serialization::ITensorBlob::sizeBytes ( ) const
pure virtualnoexcept

Implemented in Mila::Dnn::Serialization::TensorBlob< MR >.

Here is the call graph for this function:
Here is the caller graph for this function:

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