21.05
|
Main network class which provides the interface for building up a neural network. More...
#include <INetwork.hpp>
Public Member Functions | |
Status | PrintGraph () |
IConnectableLayer * | AddInputLayer (LayerBindingId id, const char *name=nullptr) |
Adds an input layer to the network. More... | |
IConnectableLayer * | AddArgMinMaxLayer (const ArgMinMaxDescriptor &desc, const char *name=nullptr) |
Adds an ArgMinMax layer to the network. More... | |
IConnectableLayer * | AddCastLayer (const char *name=nullptr) |
Adds a cast layer to the network. More... | |
IConnectableLayer * | AddComparisonLayer (const ComparisonDescriptor &comparisonDescriptor, const char *name=nullptr) |
Add a Comparison layer to the network. More... | |
IConnectableLayer * | AddConcatLayer (const ConcatDescriptor &concatDescriptor, const char *name=nullptr) |
Adds a concatenation layer to the network. More... | |
IConnectableLayer * | AddConvolution2dLayer (const Convolution2dDescriptor &convolution2dDescriptor, const ConstTensor &weights, const Optional< ConstTensor > &biases, const char *name=nullptr) |
Adds a 2D convolution layer to the network. More... | |
IConnectableLayer * | AddConvolution2dLayer (const Convolution2dDescriptor &convolution2dDescriptor, const ConstTensor &weights, const char *name=nullptr) |
IConnectableLayer * | AddConvolution2dLayer (const Convolution2dDescriptor &convolution2dDescriptor, const ConstTensor &weights, const ConstTensor &biases, const char *name=nullptr) |
IConnectableLayer * | AddDepthToSpaceLayer (const DepthToSpaceDescriptor &depthToSpaceDescriptor, const char *name=nullptr) |
Adds a depth to space layer to the network. More... | |
IConnectableLayer * | AddDepthwiseConvolution2dLayer (const DepthwiseConvolution2dDescriptor &convolution2dDescriptor, const ConstTensor &weights, const Optional< ConstTensor > &biases, const char *name=nullptr) |
Adds a 2D depthwise convolution layer to the network. More... | |
IConnectableLayer * | AddDepthwiseConvolution2dLayer (const DepthwiseConvolution2dDescriptor &convolution2dDescriptor, const ConstTensor &weights, const char *name=nullptr) |
IConnectableLayer * | AddDepthwiseConvolution2dLayer (const DepthwiseConvolution2dDescriptor &convolution2dDescriptor, const ConstTensor &weights, const ConstTensor &biases, const char *name=nullptr) |
IConnectableLayer * | AddDequantizeLayer (const char *name=nullptr) |
Adds a Dequantize layer to the network. More... | |
IConnectableLayer * | AddDetectionPostProcessLayer (const DetectionPostProcessDescriptor &descriptor, const ConstTensor &anchors, const char *name=nullptr) |
Adds a Detection PostProcess layer to the network. More... | |
IConnectableLayer * | AddElementwiseUnaryLayer (const ElementwiseUnaryDescriptor &elementwiseUnaryDescriptor, const char *name=nullptr) |
Add an ElementwiseUnary layer to the network. More... | |
IConnectableLayer * | AddFillLayer (const FillDescriptor &fillDescriptor, const char *name=nullptr) |
Add an Fill layer to the network. More... | |
IConnectableLayer * | AddFullyConnectedLayer (const FullyConnectedDescriptor &fullyConnectedDescriptor, const Optional< ConstTensor > &weights, const Optional< ConstTensor > &biases, const char *name=nullptr) |
Adds a fully connected layer to the network. More... | |
IConnectableLayer * | AddFullyConnectedLayer (const FullyConnectedDescriptor &fullyConnectedDescriptor, const ConstTensor &weights, const Optional< ConstTensor > &biases, const char *name=nullptr) |
Adds a fully connected layer to the network. More... | |
IConnectableLayer * | AddFullyConnectedLayer (const FullyConnectedDescriptor &fullyConnectedDescriptor, const ConstTensor &weights, const char *name=nullptr) |
IConnectableLayer * | AddFullyConnectedLayer (const FullyConnectedDescriptor &fullyConnectedDescriptor, const ConstTensor &weights, const ConstTensor &biases, const char *name=nullptr) |
IConnectableLayer * | AddPermuteLayer (const PermuteDescriptor &permuteDescriptor, const char *name=nullptr) |
Adds a permute layer to the network. More... | |
IConnectableLayer * | AddBatchToSpaceNdLayer (const BatchToSpaceNdDescriptor &batchToSpaceNdDescriptor, const char *name=nullptr) |
Adds a batch to space ND layer to the network. More... | |
IConnectableLayer * | AddPooling2dLayer (const Pooling2dDescriptor &pooling2dDescriptor, const char *name=nullptr) |
Adds a pooling layer to the network. More... | |
IConnectableLayer * | AddActivationLayer (const ActivationDescriptor &activationDescriptor, const char *name=nullptr) |
Adds an activation layer to the network. More... | |
IConnectableLayer * | AddNormalizationLayer (const NormalizationDescriptor &normalizationDescriptor, const char *name=nullptr) |
Adds a normalization layer to the network. More... | |
IConnectableLayer * | AddSliceLayer (const SliceDescriptor &sliceDescriptor, const char *name=nullptr) |
Adds a slice layer to the network. More... | |
IConnectableLayer * | AddSoftmaxLayer (const SoftmaxDescriptor &softmaxDescriptor, const char *name=nullptr) |
Adds a softmax layer to the network. More... | |
IConnectableLayer * | AddSplitterLayer (const ViewsDescriptor &splitterDescriptor, const char *name=nullptr) |
Adds a splitter layer to the network. More... | |
IConnectableLayer * | AddMergeLayer (const char *name=nullptr) |
Adds a merge layer to the network. More... | |
IConnectableLayer * | AddMergerLayer (const MergerDescriptor &mergerDescriptor, const char *name=nullptr) |
Adds a concat layer to the network. More... | |
IConnectableLayer * | AddAbsLayer (const char *name=nullptr) |
Add absolute layer to the network. More... | |
IConnectableLayer * | AddAdditionLayer (const char *name=nullptr) |
Adds an addition layer to the network. More... | |
IConnectableLayer * | AddMultiplicationLayer (const char *name=nullptr) |
Adds a multiplication layer to the network. More... | |
IConnectableLayer * | AddBatchNormalizationLayer (const BatchNormalizationDescriptor &desc, const ConstTensor &mean, const ConstTensor &variance, const ConstTensor &beta, const ConstTensor &gamma, const char *name=nullptr) |
Adds a batch normalization layer to the network. More... | |
IConnectableLayer * | AddRankLayer (const char *name=nullptr) |
Adds a rank layer to the network. More... | |
IConnectableLayer * | AddResizeBilinearLayer (const ResizeBilinearDescriptor &resizeDesc, const char *name=nullptr) |
Adds a resize bilinear layer to the network. More... | |
IConnectableLayer * | AddResizeLayer (const ResizeDescriptor &resizeDescriptor, const char *name=nullptr) |
Adds a resize layer to the network. More... | |
IConnectableLayer * | AddReduceLayer (const ReduceDescriptor &reduceDescriptor, const char *name=nullptr) |
Adds a reduce layer to the network. More... | |
IConnectableLayer * | AddInstanceNormalizationLayer (const InstanceNormalizationDescriptor &desc, const char *name=nullptr) |
Adds an instance normalization layer to the network. More... | |
IConnectableLayer * | AddL2NormalizationLayer (const L2NormalizationDescriptor &desc, const char *name=nullptr) |
Adds an L2 normalization layer to the network. More... | |
IConnectableLayer * | AddLogSoftmaxLayer (const LogSoftmaxDescriptor &logSoftmaxDescriptor, const char *name=nullptr) |
Adds a log softmax layer to the network. More... | |
IConnectableLayer * | AddConstantLayer (const ConstTensor &input, const char *name=nullptr) |
Adds a layer with no inputs and a single output, which always corresponds to the passed in constant tensor. More... | |
IConnectableLayer * | AddReshapeLayer (const ReshapeDescriptor &reshapeDescriptor, const char *name=nullptr) |
Adds a reshape layer to the network. More... | |
IConnectableLayer * | AddSpaceToBatchNdLayer (const SpaceToBatchNdDescriptor &spaceToBatchNdDescriptor, const char *name=nullptr) |
Adds a space to batch layer to the network. More... | |
IConnectableLayer * | AddSpaceToDepthLayer (const SpaceToDepthDescriptor &spaceToDepthDescriptor, const char *name=nullptr) |
Adds a space to depth layer to the network. More... | |
IConnectableLayer * | AddFloorLayer (const char *name=nullptr) |
Adds a floor layer to the network. More... | |
IConnectableLayer * | AddOutputLayer (LayerBindingId id, const char *name=nullptr) |
Adds an output layer to the network. More... | |
IConnectableLayer * | AddLstmLayer (const LstmDescriptor &descriptor, const LstmInputParams ¶ms, const char *name=nullptr) |
Add a Lstm layer to the network. More... | |
IConnectableLayer * | AddDivisionLayer (const char *name=nullptr) |
Adds a division layer to the network. More... | |
IConnectableLayer * | AddSubtractionLayer (const char *name=nullptr) |
Adds a subtraction layer to the network. More... | |
IConnectableLayer * | AddMaximumLayer (const char *name=nullptr) |
Add a Maximum layer to the network. More... | |
IConnectableLayer * | AddMeanLayer (const MeanDescriptor &meanDescriptor, const char *name=nullptr) |
Add a Mean layer to the network. More... | |
IConnectableLayer * | AddPadLayer (const PadDescriptor &padDescriptor, const char *name=nullptr) |
Adds a fully pad layer to the network. More... | |
IConnectableLayer * | AddQuantizeLayer (const char *name=nullptr) |
Add a quantize layer to the network. More... | |
IConnectableLayer * | AddStridedSliceLayer (const StridedSliceDescriptor &stridedSliceDescriptor, const char *name=nullptr) |
Adds a strided slice layer to the network. More... | |
IConnectableLayer * | AddMinimumLayer (const char *name=nullptr) |
Add a Minimum layer to the network. More... | |
IConnectableLayer * | AddGreaterLayer (const char *name=nullptr) |
Add a Greater layer to the network. More... | |
IConnectableLayer * | AddEqualLayer (const char *name=nullptr) |
Add a Equal layer to the network. More... | |
IConnectableLayer * | AddRsqrtLayer (const char *name=nullptr) |
Add Reciprocal of square root layer to the network. More... | |
IConnectableLayer * | AddGatherLayer (const char *name=nullptr) |
Add Gather layer to the network. More... | |
IConnectableLayer * | AddGatherLayer (const GatherDescriptor &descriptor, const char *name=nullptr) |
Add Gather layer to the network. More... | |
IConnectableLayer * | AddSwitchLayer (const char *name=nullptr) |
Adds a switch layer to the network. More... | |
IConnectableLayer * | AddPreluLayer (const char *name=nullptr) |
Adds a PReLU layer to the network. More... | |
IConnectableLayer * | AddTransposeConvolution2dLayer (const TransposeConvolution2dDescriptor &descriptor, const ConstTensor &weights, const Optional< ConstTensor > &biases, const char *name=nullptr) |
Adds a 2D transpose convolution layer to the network. More... | |
IConnectableLayer * | AddTransposeLayer (const TransposeDescriptor &transposeDescriptor, const char *name=nullptr) |
Adds a transpose layer to the network. More... | |
IConnectableLayer * | AddStackLayer (const StackDescriptor &descriptor, const char *name=nullptr) |
Adds a stack layer to the network. More... | |
IConnectableLayer * | AddStandInLayer (const StandInDescriptor &descriptor, const char *name=nullptr) |
Add a stand-in layer for a type unknown to the Arm NN framework. More... | |
IConnectableLayer * | AddQuantizedLstmLayer (const QuantizedLstmInputParams ¶ms, const char *name=nullptr) |
Add a QuantizedLstm layer to the network. More... | |
IConnectableLayer * | AddQLstmLayer (const QLstmDescriptor &descriptor, const LstmInputParams ¶ms, const char *name=nullptr) |
Add a QLstm layer to the network. More... | |
IConnectableLayer * | AddLogicalBinaryLayer (const LogicalBinaryDescriptor &descriptor, const char *name=nullptr) |
Adds a Logical Binary layer to the network. More... | |
void | Accept (ILayerVisitor &visitor) const |
void | ExecuteStrategy (IStrategy &strategy) const |
Static Public Member Functions | |
static INetwork * | CreateRaw (NetworkOptions networkOptions={}) |
static INetworkPtr | Create (NetworkOptions networkOptions={}) |
static void | Destroy (INetwork *network) |
Protected Member Functions | |
~INetwork () | |
INetwork (NetworkOptions networkOptions={}) | |
Protected Attributes | |
std::unique_ptr< NetworkImpl > | pNetworkImpl |
Friends | |
class | TestConnectionPreservation |
void | VisitLayersTopologically (const INetwork *inputNetwork, IStrategy &strategy) |
TensorInfo | GetInputTensorInfo (const INetwork *network) |
IOptimizedNetworkPtr | Optimize (const INetwork &network, const std::vector< BackendId > &backendPreferences, const IDeviceSpec &deviceSpec, const OptimizerOptions &options, Optional< std::vector< std::string > &> messages) |
Create an optimized version of the network. More... | |
Main network class which provides the interface for building up a neural network.
This object is subsequently required by the IRuntime::Load() method.
Definition at line 178 of file INetwork.hpp.
|
protecteddefault |
Referenced by INetwork::INetwork().
|
protected |
Definition at line 41 of file Network.cpp.
References INetwork::~INetwork().
Referenced by INetwork::CreateRaw().
void Accept | ( | ILayerVisitor & | visitor | ) | const |
Definition at line 514 of file Network.cpp.
References INetwork::pNetworkImpl.
IConnectableLayer * AddAbsLayer | ( | const char * | name = nullptr | ) |
Add absolute layer to the network.
name | - Optional name for the layer. |
Definition at line 276 of file Network.cpp.
References armnn::Abs, and INetwork::pNetworkImpl.
IConnectableLayer * AddActivationLayer | ( | const ActivationDescriptor & | activationDescriptor, |
const char * | name = nullptr |
||
) |
Adds an activation layer to the network.
activationDescriptor | - ActivationDescriptor to configure the activation. |
name | - Optional name for the layer. |
Definition at line 237 of file Network.cpp.
References INetwork::pNetworkImpl.
IConnectableLayer * AddAdditionLayer | ( | const char * | name = nullptr | ) |
Adds an addition layer to the network.
name | - Optional name for the layer. |
Definition at line 281 of file Network.cpp.
References INetwork::pNetworkImpl.
Referenced by armnn::GetVector().
IConnectableLayer * AddArgMinMaxLayer | ( | const ArgMinMaxDescriptor & | desc, |
const char * | name = nullptr |
||
) |
Adds an ArgMinMax layer to the network.
desc | - Parameters for the L2 normalization operation. |
name | - Optional name for the layer. |
Definition at line 56 of file Network.cpp.
References INetwork::pNetworkImpl.
IConnectableLayer * AddBatchNormalizationLayer | ( | const BatchNormalizationDescriptor & | desc, |
const ConstTensor & | mean, | ||
const ConstTensor & | variance, | ||
const ConstTensor & | beta, | ||
const ConstTensor & | gamma, | ||
const char * | name = nullptr |
||
) |
Adds a batch normalization layer to the network.
mean | - Pre-calculated mean for each channel. |
variance | - Pre-calculated variance for each channel. |
beta | - Per-channel additive factor. |
gamma | - Per-channel multiplicative factor. |
name | - Optional name for the layer. |
Definition at line 291 of file Network.cpp.
References INetwork::pNetworkImpl.
Referenced by armnn::GetVector().
IConnectableLayer * AddBatchToSpaceNdLayer | ( | const BatchToSpaceNdDescriptor & | batchToSpaceNdDescriptor, |
const char * | name = nullptr |
||
) |
Adds a batch to space ND layer to the network.
batchToSpaceNdDescriptor | - Description of the layer. |
name | - Optional name for the layer. |
Definition at line 225 of file Network.cpp.
References INetwork::pNetworkImpl.
IConnectableLayer * AddCastLayer | ( | const char * | name = nullptr | ) |
Adds a cast layer to the network.
name | - Optional name for the layer. |
Definition at line 62 of file Network.cpp.
References INetwork::pNetworkImpl.
IConnectableLayer * AddComparisonLayer | ( | const ComparisonDescriptor & | comparisonDescriptor, |
const char * | name = nullptr |
||
) |
Add a Comparison layer to the network.
name | - Optional name for the layer. |
desc | - Descriptor for the comparison operation. |
Definition at line 67 of file Network.cpp.
References INetwork::pNetworkImpl.
IConnectableLayer * AddConcatLayer | ( | const ConcatDescriptor & | concatDescriptor, |
const char * | name = nullptr |
||
) |
Adds a concatenation layer to the network.
concatDescriptor | - ConcatDescriptor (synonym for OriginsDescriptor) to configure the concatenation process. Number of Views must be equal to the number of inputs, and their order must match - e.g. first view corresponds to the first input, second view to the second input, etc.... |
name | - Optional name for the layer. |
Definition at line 74 of file Network.cpp.
References INetwork::pNetworkImpl.
IConnectableLayer * AddConstantLayer | ( | const ConstTensor & | input, |
const char * | name = nullptr |
||
) |
Adds a layer with no inputs and a single output, which always corresponds to the passed in constant tensor.
input | - Tensor to be provided as the only output of the layer. The layer will maintain its own copy of the tensor data, meaning the memory referenced by input can be freed or reused after this function is called. |
name | - Optional name for the layer. |
Definition at line 350 of file Network.cpp.
References INetwork::pNetworkImpl.
IConnectableLayer * AddConvolution2dLayer | ( | const Convolution2dDescriptor & | convolution2dDescriptor, |
const ConstTensor & | weights, | ||
const Optional< ConstTensor > & | biases, | ||
const char * | name = nullptr |
||
) |
Adds a 2D convolution layer to the network.
convolution2dDescriptor | - Description of the 2D convolution layer. |
weights | - Tensor for the weights data. |
biases | - Optional tensor for the bias data. If specified, must match the output tensor shape. |
name | - Optional name for the layer. |
Definition at line 81 of file Network.cpp.
References INetwork::pNetworkImpl.
Referenced by armnn::GetVector().
IConnectableLayer * AddConvolution2dLayer | ( | const Convolution2dDescriptor & | convolution2dDescriptor, |
const ConstTensor & | weights, | ||
const char * | name = nullptr |
||
) |
Definition at line 90 of file Network.cpp.
References INetwork::pNetworkImpl.
IConnectableLayer * AddConvolution2dLayer | ( | const Convolution2dDescriptor & | convolution2dDescriptor, |
const ConstTensor & | weights, | ||
const ConstTensor & | biases, | ||
const char * | name = nullptr |
||
) |
Definition at line 99 of file Network.cpp.
References INetwork::pNetworkImpl.
IConnectableLayer * AddDepthToSpaceLayer | ( | const DepthToSpaceDescriptor & | depthToSpaceDescriptor, |
const char * | name = nullptr |
||
) |
Adds a depth to space layer to the network.
depthToSpaceDescriptor | - Parameters for the depth to space operation. |
name | - Optional name for the layer. |
Definition at line 112 of file Network.cpp.
References INetwork::pNetworkImpl.
IConnectableLayer * AddDepthwiseConvolution2dLayer | ( | const DepthwiseConvolution2dDescriptor & | convolution2dDescriptor, |
const ConstTensor & | weights, | ||
const Optional< ConstTensor > & | biases, | ||
const char * | name = nullptr |
||
) |
Adds a 2D depthwise convolution layer to the network.
convolution2dDescriptor | - Description of the 2D depthwise convolution layer. |
weights | - Tensor for the weights. Expected format: [channelMultiplier, inputChannels, height, width]. |
biases | Optional tensor for the bias data. If specified, must match the output tensor shape. |
name | - Optional name for the layer. |
Definition at line 119 of file Network.cpp.
References INetwork::pNetworkImpl.
Referenced by armnn::GetVector().
IConnectableLayer * AddDepthwiseConvolution2dLayer | ( | const DepthwiseConvolution2dDescriptor & | convolution2dDescriptor, |
const ConstTensor & | weights, | ||
const char * | name = nullptr |
||
) |
Definition at line 129 of file Network.cpp.
References INetwork::pNetworkImpl.
IConnectableLayer * AddDepthwiseConvolution2dLayer | ( | const DepthwiseConvolution2dDescriptor & | convolution2dDescriptor, |
const ConstTensor & | weights, | ||
const ConstTensor & | biases, | ||
const char * | name = nullptr |
||
) |
Definition at line 139 of file Network.cpp.
References INetwork::pNetworkImpl.
IConnectableLayer * AddDequantizeLayer | ( | const char * | name = nullptr | ) |
Adds a Dequantize layer to the network.
Definition at line 150 of file Network.cpp.
References INetwork::pNetworkImpl.
IConnectableLayer * AddDetectionPostProcessLayer | ( | const DetectionPostProcessDescriptor & | descriptor, |
const ConstTensor & | anchors, | ||
const char * | name = nullptr |
||
) |
Adds a Detection PostProcess layer to the network.
descriptor | - Description of the Detection PostProcess layer. |
anchors | - Tensor for anchors. |
name | - Optional name for the layer. |
Definition at line 156 of file Network.cpp.
References INetwork::pNetworkImpl.
IConnectableLayer * AddDivisionLayer | ( | const char * | name = nullptr | ) |
Adds a division layer to the network.
name | - Optional name for the layer. |
Definition at line 390 of file Network.cpp.
References INetwork::pNetworkImpl.
Referenced by armnn::GetVector().
IConnectableLayer * AddElementwiseUnaryLayer | ( | const ElementwiseUnaryDescriptor & | elementwiseUnaryDescriptor, |
const char * | name = nullptr |
||
) |
Add an ElementwiseUnary layer to the network.
name | - Optional name for the layer. |
desc | - Descriptor for the elementwiseUnary operation. |
Definition at line 165 of file Network.cpp.
References INetwork::pNetworkImpl.
IConnectableLayer * AddEqualLayer | ( | const char * | name = nullptr | ) |
Add a Equal layer to the network.
name | - Optional name for the layer. |
Definition at line 437 of file Network.cpp.
References armnn::Equal, and INetwork::pNetworkImpl.
IConnectableLayer * AddFillLayer | ( | const FillDescriptor & | fillDescriptor, |
const char * | name = nullptr |
||
) |
Add an Fill layer to the network.
name | - Optional name for the layer. |
fillDescriptor | - Descriptor for the fill operation. |
Definition at line 172 of file Network.cpp.
References INetwork::pNetworkImpl.
IConnectableLayer * AddFloorLayer | ( | const char * | name = nullptr | ) |
Adds a floor layer to the network.
name | - Optional name for the layer. |
Definition at line 374 of file Network.cpp.
References INetwork::pNetworkImpl.
IConnectableLayer * AddFullyConnectedLayer | ( | const FullyConnectedDescriptor & | fullyConnectedDescriptor, |
const Optional< ConstTensor > & | weights, | ||
const Optional< ConstTensor > & | biases, | ||
const char * | name = nullptr |
||
) |
Adds a fully connected layer to the network.
fullyConnectedDescriptor | - Description of the fully connected layer. |
weights | -Optional Tensor for the weights data. |
biases | - Optional tensor for the bias data. |
name | - Optional name for the layer. |
Definition at line 211 of file Network.cpp.
References INetwork::pNetworkImpl.
Referenced by armnn::GetVector().
IConnectableLayer * AddFullyConnectedLayer | ( | const FullyConnectedDescriptor & | fullyConnectedDescriptor, |
const ConstTensor & | weights, | ||
const Optional< ConstTensor > & | biases, | ||
const char * | name = nullptr |
||
) |
Adds a fully connected layer to the network.
fullyConnectedDescriptor | - Description of the fully connected layer. |
weights | - Tensor for the weights data. |
biases | - Optional tensor for the bias data. |
name | - Optional name for the layer. |
Definition at line 178 of file Network.cpp.
References INetwork::pNetworkImpl.
IConnectableLayer * AddFullyConnectedLayer | ( | const FullyConnectedDescriptor & | fullyConnectedDescriptor, |
const ConstTensor & | weights, | ||
const char * | name = nullptr |
||
) |
Definition at line 189 of file Network.cpp.
References INetwork::pNetworkImpl.
IConnectableLayer * AddFullyConnectedLayer | ( | const FullyConnectedDescriptor & | fullyConnectedDescriptor, |
const ConstTensor & | weights, | ||
const ConstTensor & | biases, | ||
const char * | name = nullptr |
||
) |
Definition at line 200 of file Network.cpp.
References INetwork::pNetworkImpl.
IConnectableLayer * AddGatherLayer | ( | const char * | name = nullptr | ) |
Add Gather layer to the network.
name | - Optional name for the layer. |
Definition at line 447 of file Network.cpp.
References INetwork::pNetworkImpl.
IConnectableLayer * AddGatherLayer | ( | const GatherDescriptor & | descriptor, |
const char * | name = nullptr |
||
) |
Add Gather layer to the network.
descriptor | - Description of the gather layer. |
name | - Optional name for the layer. |
Definition at line 453 of file Network.cpp.
References INetwork::pNetworkImpl.
IConnectableLayer * AddGreaterLayer | ( | const char * | name = nullptr | ) |
Add a Greater layer to the network.
name | - Optional name for the layer. |
Definition at line 432 of file Network.cpp.
References armnn::Greater, and INetwork::pNetworkImpl.
IConnectableLayer * AddInputLayer | ( | LayerBindingId | id, |
const char * | name = nullptr |
||
) |
Adds an input layer to the network.
id | - User generated id to uniquely identify a particular input. The same id needs to be specified. when passing the inputs to the IRuntime::EnqueueWorkload() function. |
name | - Optional name for the layer. |
Definition at line 50 of file Network.cpp.
References INetwork::pNetworkImpl.
IConnectableLayer * AddInstanceNormalizationLayer | ( | const InstanceNormalizationDescriptor & | desc, |
const char * | name = nullptr |
||
) |
Adds an instance normalization layer to the network.
desc | - Parameters for the instance normalization operation. |
name | - Optional name for the layer. |
Definition at line 332 of file Network.cpp.
References INetwork::pNetworkImpl.
IConnectableLayer * AddL2NormalizationLayer | ( | const L2NormalizationDescriptor & | desc, |
const char * | name = nullptr |
||
) |
Adds an L2 normalization layer to the network.
Normalization is performed along dimension 1, but requires a 4d input.
desc | - Parameters for the L2 normalization operation. |
name | - Optional name for the layer. |
Definition at line 338 of file Network.cpp.
References INetwork::pNetworkImpl.
IConnectableLayer * AddLogicalBinaryLayer | ( | const LogicalBinaryDescriptor & | descriptor, |
const char * | name = nullptr |
||
) |
Adds a Logical Binary layer to the network.
descriptor | - Description of the Logical Binary layer. |
name | - Optional name for the layer. |
Definition at line 508 of file Network.cpp.
References INetwork::pNetworkImpl.
IConnectableLayer * AddLogSoftmaxLayer | ( | const LogSoftmaxDescriptor & | logSoftmaxDescriptor, |
const char * | name = nullptr |
||
) |
Adds a log softmax layer to the network.
logSoftmaxDescriptor | - LogSoftmaxDescriptor to configure the log softmax. |
name | - Optional name for the layer. |
Definition at line 344 of file Network.cpp.
References INetwork::pNetworkImpl.
IConnectableLayer * AddLstmLayer | ( | const LstmDescriptor & | descriptor, |
const LstmInputParams & | params, | ||
const char * | name = nullptr |
||
) |
Add a Lstm layer to the network.
descriptor | - Parameters for the Lstm operation |
params | - Weights and biases for the LSTM cell |
name | - Optional name for the layer |
Definition at line 383 of file Network.cpp.
References INetwork::pNetworkImpl.
IConnectableLayer * AddMaximumLayer | ( | const char * | name = nullptr | ) |
Add a Maximum layer to the network.
name | - Optional name for the layer. |
Definition at line 400 of file Network.cpp.
References INetwork::pNetworkImpl.
IConnectableLayer * AddMeanLayer | ( | const MeanDescriptor & | meanDescriptor, |
const char * | name = nullptr |
||
) |
Add a Mean layer to the network.
meanDescriptor | - Parameters for the mean operation. |
name | - Optional name for the layer. |
Definition at line 405 of file Network.cpp.
References INetwork::pNetworkImpl.
IConnectableLayer * AddMergeLayer | ( | const char * | name = nullptr | ) |
Adds a merge layer to the network.
name | - Optional name for the layer. |
Definition at line 265 of file Network.cpp.
References INetwork::pNetworkImpl.
IConnectableLayer * AddMergerLayer | ( | const MergerDescriptor & | mergerDescriptor, |
const char * | name = nullptr |
||
) |
Adds a concat layer to the network.
mergerDescriptor | - MergerDescriptor (synonym for OriginsDescriptor) to configure the concatenation process. Number of Views must be equal to the number of inputs, and their order must match - e.g. first view corresponds to the first input, second view to the second input, etc.... |
name | - Optional name for the layer. |
Definition at line 270 of file Network.cpp.
References INetwork::pNetworkImpl.
IConnectableLayer * AddMinimumLayer | ( | const char * | name = nullptr | ) |
Add a Minimum layer to the network.
name | - Optional name for the layer. |
Definition at line 427 of file Network.cpp.
References INetwork::pNetworkImpl.
IConnectableLayer * AddMultiplicationLayer | ( | const char * | name = nullptr | ) |
Adds a multiplication layer to the network.
name | - Optional name for the layer. |
Definition at line 286 of file Network.cpp.
References INetwork::pNetworkImpl.
Referenced by armnn::GetVector().
IConnectableLayer * AddNormalizationLayer | ( | const NormalizationDescriptor & | normalizationDescriptor, |
const char * | name = nullptr |
||
) |
Adds a normalization layer to the network.
normalizationDescriptor | - NormalizationDescriptor to configure the normalization. |
name | - Optional name for the layer. |
Definition at line 243 of file Network.cpp.
References INetwork::pNetworkImpl.
IConnectableLayer * AddOutputLayer | ( | LayerBindingId | id, |
const char * | name = nullptr |
||
) |
Adds an output layer to the network.
id | - User generated id to uniquely identify a particular output. The same id needs to be specified when passing the outputs to the IRuntime::EnqueueWorkload() function. |
name | - Optional name for the layer. |
Definition at line 378 of file Network.cpp.
References INetwork::pNetworkImpl.
IConnectableLayer * AddPadLayer | ( | const PadDescriptor & | padDescriptor, |
const char * | name = nullptr |
||
) |
Adds a fully pad layer to the network.
paddings | - n by 2 tensor, where n is the rank of the input tensor, such that paddings[i,0] indicates the amount of padding to add in front of dimonsion i, and paddings[i,1] indicates the amount of padding to add after the end of dimension i |
name | - Optional name for the layer. |
Definition at line 410 of file Network.cpp.
References INetwork::pNetworkImpl.
IConnectableLayer * AddPermuteLayer | ( | const PermuteDescriptor & | permuteDescriptor, |
const char * | name = nullptr |
||
) |
Adds a permute layer to the network.
permuteDescriptor | - PermuteDescriptor to configure the permute. |
name | - Optional name for the layer. |
Definition at line 219 of file Network.cpp.
References INetwork::pNetworkImpl.
IConnectableLayer * AddPooling2dLayer | ( | const Pooling2dDescriptor & | pooling2dDescriptor, |
const char * | name = nullptr |
||
) |
Adds a pooling layer to the network.
pooling2dDescriptor | - Pooling2dDescriptor to configure the pooling. |
name | - Optional name for the layer. |
Definition at line 231 of file Network.cpp.
References INetwork::pNetworkImpl.
IConnectableLayer * AddPreluLayer | ( | const char * | name = nullptr | ) |
Adds a PReLU layer to the network.
name | - Optional name for the layer. |
Definition at line 464 of file Network.cpp.
References INetwork::pNetworkImpl.
IConnectableLayer * AddQLstmLayer | ( | const QLstmDescriptor & | descriptor, |
const LstmInputParams & | params, | ||
const char * | name = nullptr |
||
) |
Add a QLstm layer to the network.
descriptor | - Parameters for the QLstm operation |
params | - Weights and biases for the layer |
name | - Optional name for the layer |
Definition at line 501 of file Network.cpp.
References INetwork::pNetworkImpl.
IConnectableLayer * AddQuantizedLstmLayer | ( | const QuantizedLstmInputParams & | params, |
const char * | name = nullptr |
||
) |
Add a QuantizedLstm layer to the network.
params | - The weights and biases for the Quantized LSTM cell |
name | - Optional name for the layer |
Definition at line 495 of file Network.cpp.
References INetwork::pNetworkImpl.
IConnectableLayer * AddQuantizeLayer | ( | const char * | name = nullptr | ) |
Add a quantize layer to the network.
name | - Optional name for the layer. |
Definition at line 416 of file Network.cpp.
References INetwork::pNetworkImpl.
IConnectableLayer * AddRankLayer | ( | const char * | name = nullptr | ) |
Adds a rank layer to the network.
name | - Optional name for the layer. |
Definition at line 301 of file Network.cpp.
References INetwork::pNetworkImpl.
IConnectableLayer * AddReduceLayer | ( | const ReduceDescriptor & | reduceDescriptor, |
const char * | name = nullptr |
||
) |
Adds a reduce layer to the network.
ReduceDescriptor | - Parameters for the reduce operation. |
name | - Optional name for the layer. |
Definition at line 326 of file Network.cpp.
References INetwork::pNetworkImpl.
IConnectableLayer * AddReshapeLayer | ( | const ReshapeDescriptor & | reshapeDescriptor, |
const char * | name = nullptr |
||
) |
Adds a reshape layer to the network.
reshapeDescriptor | - Parameters for the reshape operation. |
name | - Optional name for the layer. |
Definition at line 356 of file Network.cpp.
References INetwork::pNetworkImpl.
IConnectableLayer * AddResizeBilinearLayer | ( | const ResizeBilinearDescriptor & | resizeDesc, |
const char * | name = nullptr |
||
) |
Adds a resize bilinear layer to the network.
resizeDesc | - Parameters for the resize operation. |
name | - Optional name for the layer. |
Definition at line 306 of file Network.cpp.
References armnn::Bilinear, ResizeBilinearDescriptor::m_AlignCorners, ResizeDescriptor::m_AlignCorners, ResizeBilinearDescriptor::m_DataLayout, ResizeDescriptor::m_DataLayout, ResizeBilinearDescriptor::m_HalfPixelCenters, ResizeDescriptor::m_HalfPixelCenters, ResizeDescriptor::m_Method, ResizeBilinearDescriptor::m_TargetHeight, ResizeDescriptor::m_TargetHeight, ResizeBilinearDescriptor::m_TargetWidth, ResizeDescriptor::m_TargetWidth, and INetwork::pNetworkImpl.
IConnectableLayer * AddResizeLayer | ( | const ResizeDescriptor & | resizeDescriptor, |
const char * | name = nullptr |
||
) |
Adds a resize layer to the network.
resizeDescriptor | - Parameters for the resize operation. |
name | - Optional name for the layer. |
Definition at line 320 of file Network.cpp.
References INetwork::pNetworkImpl.
IConnectableLayer * AddRsqrtLayer | ( | const char * | name = nullptr | ) |
Add Reciprocal of square root layer to the network.
name | - Optional name for the layer. |
Definition at line 442 of file Network.cpp.
References INetwork::pNetworkImpl, and armnn::Rsqrt.
IConnectableLayer * AddSliceLayer | ( | const SliceDescriptor & | sliceDescriptor, |
const char * | name = nullptr |
||
) |
Adds a slice layer to the network.
sliceDescriptor | - SliceDescriptor to configure the slice operation. |
name | - Optional name for the layer. |
Definition at line 249 of file Network.cpp.
References INetwork::pNetworkImpl.
IConnectableLayer * AddSoftmaxLayer | ( | const SoftmaxDescriptor & | softmaxDescriptor, |
const char * | name = nullptr |
||
) |
Adds a softmax layer to the network.
If the data type is QAsymm8, then the output quantization parameters must have a scale of 1/256 and an offset of 0
softmaxDescriptor | - SoftmaxDescriptor to configure the softmax. |
name | - Optional name for the layer. |
Definition at line 253 of file Network.cpp.
References INetwork::pNetworkImpl.
IConnectableLayer * AddSpaceToBatchNdLayer | ( | const SpaceToBatchNdDescriptor & | spaceToBatchNdDescriptor, |
const char * | name = nullptr |
||
) |
Adds a space to batch layer to the network.
spaceToBatchNdDescriptor | - Parameters for the space to batch operation. |
name | - Optional name for the layer. |
Definition at line 362 of file Network.cpp.
References INetwork::pNetworkImpl.
IConnectableLayer * AddSpaceToDepthLayer | ( | const SpaceToDepthDescriptor & | spaceToDepthDescriptor, |
const char * | name = nullptr |
||
) |
Adds a space to depth layer to the network.
spaceToDepthDescriptor | - Parameters for the space to depth operation. |
name | - Optional name for the layer. |
Definition at line 368 of file Network.cpp.
References INetwork::pNetworkImpl.
IConnectableLayer * AddSplitterLayer | ( | const ViewsDescriptor & | splitterDescriptor, |
const char * | name = nullptr |
||
) |
Adds a splitter layer to the network.
splitterDescriptor | - ViewsDescriptor to configure the splitting process. Number of Views must be equal to the number of outputs, and their order must match - e.g. first view corresponds to the first output, second view to the second output, etc.... |
name | - Optional name for the layer. |
Definition at line 259 of file Network.cpp.
References INetwork::pNetworkImpl.
IConnectableLayer * AddStackLayer | ( | const StackDescriptor & | descriptor, |
const char * | name = nullptr |
||
) |
Adds a stack layer to the network.
descriptor | - Description of the stack layer. |
name | - Optional name for the layer. |
Definition at line 483 of file Network.cpp.
References INetwork::pNetworkImpl.
IConnectableLayer * AddStandInLayer | ( | const StandInDescriptor & | descriptor, |
const char * | name = nullptr |
||
) |
Add a stand-in layer for a type unknown to the Arm NN framework.
Note: Due to the nature of this layer, no validation can be performed by the framework. Furthermore, Any model containing this layer cannot make use of dynamic tensors since the tensor sizes cannot be inferred. - Descriptor for the StandIn layer.
Definition at line 489 of file Network.cpp.
References INetwork::pNetworkImpl.
IConnectableLayer * AddStridedSliceLayer | ( | const StridedSliceDescriptor & | stridedSliceDescriptor, |
const char * | name = nullptr |
||
) |
Adds a strided slice layer to the network.
StridedSliceDescriptor | - Parameters for the strided slice operation. |
name | - Optional name for the layer. |
Definition at line 421 of file Network.cpp.
References INetwork::pNetworkImpl.
IConnectableLayer * AddSubtractionLayer | ( | const char * | name = nullptr | ) |
Adds a subtraction layer to the network.
name | - Optional name for the layer. |
Definition at line 395 of file Network.cpp.
References INetwork::pNetworkImpl.
Referenced by armnn::GetVector().
IConnectableLayer * AddSwitchLayer | ( | const char * | name = nullptr | ) |
Adds a switch layer to the network.
name | - Optional name for the layer. |
Definition at line 459 of file Network.cpp.
References INetwork::pNetworkImpl.
IConnectableLayer * AddTransposeConvolution2dLayer | ( | const TransposeConvolution2dDescriptor & | descriptor, |
const ConstTensor & | weights, | ||
const Optional< ConstTensor > & | biases, | ||
const char * | name = nullptr |
||
) |
Adds a 2D transpose convolution layer to the network.
descriptor | - Description of the 2D transpose convolution layer. |
weights | - Tensor for the weights data. |
biases | - Optional tensor for the bias data. |
name | - Optional name for the layer. |
Definition at line 469 of file Network.cpp.
References INetwork::pNetworkImpl.
IConnectableLayer * AddTransposeLayer | ( | const TransposeDescriptor & | transposeDescriptor, |
const char * | name = nullptr |
||
) |
Adds a transpose layer to the network.
transposeDescriptor | - TransposeDescriptor to configure the transpose. |
name | - Optional name for the layer. |
Definition at line 477 of file Network.cpp.
References INetwork::pNetworkImpl.
|
static |
Definition at line 529 of file Network.cpp.
References INetwork::CreateRaw(), and INetwork::Destroy().
Referenced by BOOST_AUTO_TEST_CASE(), BOOST_FIXTURE_TEST_CASE(), armnn::experimental::CreateStridedSliceNetwork(), CreatNetwork(), armnn::CreatNetwork(), GetSoftmaxProfilerJson(), QLstmEndToEnd(), SerializeArgMinMaxTest(), and VerifyPostOptimisationStructureTestImpl().
|
static |
Definition at line 524 of file Network.cpp.
References INetwork::INetwork().
Referenced by INetwork::Create().
|
static |
Definition at line 534 of file Network.cpp.
Referenced by INetwork::Create().
void ExecuteStrategy | ( | IStrategy & | strategy | ) | const |
Definition at line 519 of file Network.cpp.
References INetwork::pNetworkImpl.
Referenced by ISerializer::SerializerImpl::Serialize().
Status PrintGraph | ( | ) |
Definition at line 45 of file Network.cpp.
References INetwork::pNetworkImpl.
|
friend |
|
friend |
Create an optimized version of the network.
network | INetwork description of the network to be optimized. |
backendPreferences | The choice of the backend ordered by user preferences. |
deviceSpec | DeviceSpec object as queried from the runtime. See IRuntime::GetDeviceSpec() |
messages | If there are failures or warnings a string describing same will be added to the vector |
options | OptimizerOptions object with optimizer configuration options |
Definition at line 1568 of file Network.cpp.
|
friend |
Definition at line 698 of file INetwork.hpp.
|
protected |
Definition at line 708 of file INetwork.hpp.
Referenced by INetwork::Accept(), INetwork::AddAbsLayer(), INetwork::AddActivationLayer(), INetwork::AddAdditionLayer(), INetwork::AddArgMinMaxLayer(), INetwork::AddBatchNormalizationLayer(), INetwork::AddBatchToSpaceNdLayer(), INetwork::AddCastLayer(), INetwork::AddComparisonLayer(), INetwork::AddConcatLayer(), INetwork::AddConstantLayer(), INetwork::AddConvolution2dLayer(), INetwork::AddDepthToSpaceLayer(), INetwork::AddDepthwiseConvolution2dLayer(), INetwork::AddDequantizeLayer(), INetwork::AddDetectionPostProcessLayer(), INetwork::AddDivisionLayer(), INetwork::AddElementwiseUnaryLayer(), INetwork::AddEqualLayer(), INetwork::AddFillLayer(), INetwork::AddFloorLayer(), INetwork::AddFullyConnectedLayer(), INetwork::AddGatherLayer(), INetwork::AddGreaterLayer(), INetwork::AddInputLayer(), INetwork::AddInstanceNormalizationLayer(), INetwork::AddL2NormalizationLayer(), INetwork::AddLogicalBinaryLayer(), INetwork::AddLogSoftmaxLayer(), INetwork::AddLstmLayer(), INetwork::AddMaximumLayer(), INetwork::AddMeanLayer(), INetwork::AddMergeLayer(), INetwork::AddMergerLayer(), INetwork::AddMinimumLayer(), INetwork::AddMultiplicationLayer(), INetwork::AddNormalizationLayer(), INetwork::AddOutputLayer(), INetwork::AddPadLayer(), INetwork::AddPermuteLayer(), INetwork::AddPooling2dLayer(), INetwork::AddPreluLayer(), INetwork::AddQLstmLayer(), INetwork::AddQuantizedLstmLayer(), INetwork::AddQuantizeLayer(), INetwork::AddRankLayer(), INetwork::AddReduceLayer(), INetwork::AddReshapeLayer(), INetwork::AddResizeBilinearLayer(), INetwork::AddResizeLayer(), INetwork::AddRsqrtLayer(), INetwork::AddSliceLayer(), INetwork::AddSoftmaxLayer(), INetwork::AddSpaceToBatchNdLayer(), INetwork::AddSpaceToDepthLayer(), INetwork::AddSplitterLayer(), INetwork::AddStackLayer(), INetwork::AddStandInLayer(), INetwork::AddStridedSliceLayer(), INetwork::AddSubtractionLayer(), INetwork::AddSwitchLayer(), INetwork::AddTransposeConvolution2dLayer(), INetwork::AddTransposeLayer(), INetwork::ExecuteStrategy(), armnn::Optimize(), and INetwork::PrintGraph().