321 using ArrayType = std::array<ValueType, MaxNumOfTensorDimensions>;
354 +
" at location [" + std::to_string(i) +
"].");
356 return m_DimMappings.at(i);
370 if (m_NumDimMappings != other.m_NumDimMappings)
return false;
371 for (
unsigned int i = 0; i < m_NumDimMappings; ++i)
373 if (m_DimMappings[i] != other.m_DimMappings[i])
return false;
383 isInverse = (m_DimMappings[other.m_DimMappings[i]] == i);
410 #define LIST_OF_LAYER_TYPE \
414 X(BatchNormalization) \
419 X(ConvertFp16ToFp32) \
420 X(ConvertFp32ToFp16) \
424 X(DepthwiseConvolution2d) \
426 X(DetectionPostProcess) \
428 X(ElementwiseUnary) \
429 X(FakeQuantization) \
435 X(InstanceNormalization) \
473 X(TransposeConvolution2d) \
477 X(UnidirectionalSequenceLstm) \
483 X(ElementwiseBinary) \
495 #define X(name) name,
#define LIST_OF_LAYER_TYPE
This list uses X macro technique.
arm::pipe::ProfilingGuid LayerGuid
Define LayerGuid type.
Each backend should implement an IBackend.
virtual const BackendId & GetId() const =0
Device specific knowledge to be passed to the optimizer.
virtual const BackendIdSet & GetSupportedBackends() const =0
typename ArrayType::const_iterator ConstIterator
PermutationVector(const ValueType *dimMappings, SizeType numDimMappings)
ConstIterator end() const
ValueType operator[](SizeType i) const
Indexing method with out-of-bounds error checking for the m_DimMappings array.
bool IsEqual(const PermutationVector &other) const
bool IsInverse(const PermutationVector &other) const
std::array< ValueType, MaxNumOfTensorDimensions > ArrayType
ConstIterator begin() const
Copyright (c) 2021 ARM Limited and Contributors.
PaddingMode
The padding mode controls whether the padding should be filled with constant values (Constant),...
MemorySource
Define the Memory Source to reduce copies.
std::function< void(LayerGuid guid, unsigned int slotIndex, ITensorHandle *tensorHandle)> DebugCallbackFunction
Define the type of callback for the Debug layer to call.
std::unordered_set< BackendId > BackendIdSet
unsigned int ImportedInputId
PaddingMethod
The padding method modifies the output of pooling layers.
@ Exclude
The padding fields don't count and are ignored.
@ IgnoreValue
The padding fields count, but are ignored.
std::chrono::high_resolution_clock::time_point HighResolutionClock
Define a timer and associated inference ID for recording execution times.
std::pair< HighResolutionClock, HighResolutionClock > InferenceTimingPair
@ BoundedReLu
min(a, max(b, input)) ReLu1 & ReLu6.
LayerType
When adding a new layer, adapt also the LastLayer enum value in the enum class LayerType below.
std::unique_ptr< IBackend, void(*)(IBackend *backend)> IBackendUniquePtr
constexpr unsigned int LOWEST_CAPTURE_PERIOD
The lowest performance data capture interval we support is 10 miliseconds.
constexpr unsigned int EXPIRE_RATE
Variable to control expire rate of priority queue.
BackendCapability
BackendCapability class.
@ NonConstWeights
Constant weights can be accessed through the descriptors, On the other hand, non-const weights can be...
@ AllOrNothing
False: Backends that can only be used if all layers in the graph are supported on that backend.
int LayerBindingId
Type of identifiers for bindable layers (inputs, outputs).
constexpr unsigned int MaxNumOfTensorDimensions
NormalizationAlgorithmChannel
unsigned int ImportedOutputId
NormalizationAlgorithmMethod
@ LocalContrast
Jarret 2009: Local Contrast Normalization.
@ LocalBrightness
Krichevsky 2012: Local Brightness Normalization.
const char * GetLayerTypeAsCString(LayerType type)
ShapeInferenceMethod
The ShapeInferenceMethod modify how the output shapes are treated.
@ InferAndValidate
Infer missing output shapes and validate all output shapes.
@ ValidateOnly
Validate all output shapes.
ProfilingDetailsMethod
Define the behaviour of the internal profiler when outputting network details.
std::shared_ptr< IBackend > IBackendSharedPtr