This class represents the main Data representation node. More...
#include <ie_data.h>
Public Member Functions | |
Data (const std::string &name, Precision _precision, Layout layout=NCHW) | |
An empty constructor (dimensionless) More... |
|
Data (const std::string &name, const SizeVector &a_dims, Precision _precision, Layout layout=NCHW) | |
A full constructor (with dimensions) More... |
|
Data (const std::string &name, const TensorDesc &desc) | |
A constructor with tensor descriptor. More... |
|
bool | isInitialized () const |
Checks if the current node is resolved. More... |
|
void | setDims (const SizeVector &a_dims) |
Sets the data dimensions. After the current node is marked as resolved. More... |
|
void | setBatchSize (size_t batch_size) |
Sets the batch value in the data dimensions. Batch is defined as the last element in the dimensions vector. More... |
|
void | setLayout (Layout layout) |
Sets the layout value for this Data instance. More... |
|
void | reshape (const SizeVector &dims, Layout layout) |
changes dims and layout at same time More... |
|
Layout | getLayout () const |
Gets the layout value for this Data instance. |
|
const TensorDesc & | getTensorDesc () const |
Gets Tensor descriptor reference. More... |
|
const Precision & | getPrecision () const |
Gets a precision type of this Data instance. More... |
|
void | setPrecision (const Precision &precision) |
Gets a precision type of this Data instance. More... |
|
const SizeVector & | getDims () const |
CNNLayerWeakPtr & | getCreatorLayer () |
const std::string & | getName () const |
std::map< std::string, CNNLayerPtr > & | getInputTo () |
returns child layers in di-graph |
|
const UserValue & | getUserObject () const |
Data Fields | |
Precision | precision |
A precision type of this Data instance. More... |
|
Layout | layout |
A data layout of this Data instance. More... |
|
SizeVector | dims |
A tensor dimension array (the order is opposite to the order in the IR: w,h,c,n) of this Data instance. More... |
|
CNNLayerWeakPtr | creatorLayer |
A pointer to the layer that creates this data element, null for input data elements. More... |
|
std::string | name |
A unique name that identifies this data node. More... |
|
std::map< std::string, CNNLayerPtr > | inputTo |
A map of layers that use this node as input. It is useful for recursive NN graph traversal. More... |
|
UserValue | userObject |
A user utility place holder. More... |
|
This class represents the main Data representation node.
The NN graphs are di-graphs consisting of data nodes and layer nodes.
InferenceEngine::Data::Data | ( | const std::string & | name, |
Precision | _precision, | ||
Layout |
layout = NCHW |
||
) |
An empty constructor (dimensionless)
name | Name of the data node |
_precision | Precision of the data |
InferenceEngine::Data::Data | ( | const std::string & | name, |
const SizeVector & | a_dims, | ||
Precision | _precision, | ||
Layout |
layout = NCHW |
||
) |
InferenceEngine::Data::Data | ( | const std::string & | name, |
const TensorDesc & | desc | ||
) |
A constructor with tensor descriptor.
name | Name of the data node |
desc | Tensor descriptor |
CNNLayerWeakPtr& InferenceEngine::Data::getCreatorLayer | ( | ) |
const SizeVector& InferenceEngine::Data::getDims | ( | ) | const |
const std::string& InferenceEngine::Data::getName | ( | ) | const |
const Precision& InferenceEngine::Data::getPrecision | ( | ) | const |
const TensorDesc& InferenceEngine::Data::getTensorDesc | ( | ) | const |
Gets Tensor descriptor reference.
const UserValue& InferenceEngine::Data::getUserObject | ( | ) | const |
bool InferenceEngine::Data::isInitialized | ( | ) | const |
Checks if the current node is resolved.
void InferenceEngine::Data::reshape | ( | const SizeVector & | dims, |
Layout | layout | ||
) |
changes dims and layout at same time
dims | new dimensions |
layout | new layout |
void InferenceEngine::Data::setBatchSize | ( | size_t | batch_size | ) |
Sets the batch value in the data dimensions. Batch is defined as the last element in the dimensions vector.
batch_size | Batch size to set |
void InferenceEngine::Data::setDims | ( | const SizeVector & | a_dims | ) |
Sets the data dimensions. After the current node is marked as resolved.
a_dims | Tensor dimensions to set |
void InferenceEngine::Data::setLayout | ( | Layout | layout | ) |
Sets the layout value for this Data instance.
layout | Layout value to set |
void InferenceEngine::Data::setPrecision | ( | const Precision & | precision | ) |
CNNLayerWeakPtr InferenceEngine::Data::creatorLayer |
A pointer to the layer that creates this data element, null for input data elements.
SizeVector InferenceEngine::Data::dims |
A tensor dimension array (the order is opposite to the order in the IR: w,h,c,n) of this Data instance.
std::map<std::string, CNNLayerPtr> InferenceEngine::Data::inputTo |
A map of layers that use this node as input. It is useful for recursive NN graph traversal.
Layout InferenceEngine::Data::layout |
A data layout of this Data instance.
std::string InferenceEngine::Data::name |
A unique name that identifies this data node.
Precision InferenceEngine::Data::precision |
A precision type of this Data instance.
UserValue InferenceEngine::Data::userObject |
A user utility place holder.