26 #ifndef NVNEURAL_WEIGHTSDATA_H
27 #define NVNEURAL_WEIGHTSDATA_H
41 template<
typename TVectorData>
43 refobj::Implements<IWeightsData>>
64 const void*
data()
const noexcept
override;
69 std::vector<TVectorData> m_container;
Common helper classes and template function implementations.
Fundamental NvNeural data types are declared here.
NetworkBackendId
Enumeration describing common network backends.
Definition: CoreTypes.h:239
Standard IWeightsData implementation containing a vector of values in CPU memory.
Definition: WeightsData.h:44
bool memManagedExternally() const noexcept
Returns true if the memory is managed outside NvNeural and should not be freed or reallocated by the ...
Definition: WeightsData.cpp:55
const void * data() const noexcept
Returns a pointer to the first element of the weights buffer.
Definition: WeightsData.cpp:61
NetworkBackendId backendId() const noexcept
Returns the backend for which this weights data is relevant.
Definition: WeightsData.cpp:37
TensorDimension dimension() const noexcept
Returns the size of the weights buffer in elements.
Definition: WeightsData.cpp:49
WeightsData(TensorFormat format, TensorDimension dimension, std::vector< TVectorData > &&container)
Creates a new WeightsData object.
Definition: WeightsData.cpp:29
TensorFormat tensorFormat() const noexcept
Returns the tensor format for the weights buffer.
Definition: WeightsData.cpp:43
TensorDimension describes the dimensions of a four-dimensional image tensor.
Definition: CoreTypes.h:136
Parameterized base class implementing common IRefObject operations.
Definition: RefObject.h:336