24.08
|
Go to the documentation of this file.
13 template <
typename Parameters>
31 unsigned int numOutputSlots,
33 const Parameters& param,
35 :
Layer(numInputSlots, numOutputSlots, type, name)
43 template <
typename QueueDescriptor>
46 descriptor.m_Parameters =
m_Param;
69 auto &constantLayer =
static_cast<ConstantLayer&
>(inputLayer);
71 tensors.push_back(constantLayer.m_LayerOutput);
void SerializeLayerParameters(ParameterStringifyFunction &fn) const override
Helper to serialize the layer parameters to string (currently used in DotSerializer and company).
void ExecuteStrategy(IStrategy &strategy) const override
Apply a visitor to this layer.
const InputSlot & GetInputSlot(unsigned int index) const override
Get a const input slot handle by slot index.
const Parameters & GetParameters() const override
If the layer has a descriptor return it.
const char * GetName() const override
Returns the name of the layer.
std::vector< std::reference_wrapper< const std::shared_ptr< ConstTensorHandle > >> ImmutableConstantTensors
Layer::ImmutableConstantTensors GetConnectedConstantAsInputTensors() const
virtual void SerializeLayerParameters(ParameterStringifyFunction &fn) const
Helper to serialize the layer parameters to string.
Layer & GetOwningLayer() const
Parameters m_Param
The parameters for the layer (not including tensor-valued weights etc.).
WorkloadInfo PrepInfoAndDesc(QueueDescriptor &descriptor) const
Helper function to reduce duplication in *Layer::CreateWorkload.
Contains information about TensorInfos of a layer.
~LayerWithParameters()=default
WorkloadInfo PrepInfoAndDesc(QueueDescriptor &descriptor) const
Helper function to reduce duplication in *Layer::CreateWorkload.
std::function< void(const std::string &name, const std::string &value)> ParameterStringifyFunction
static void Serialize(ParameterStringifyFunction &, const LayerParameter &)
unsigned int GetNumInputSlots() const override
Returns the number of connectable input slots.
A StridedSliceDescriptor for the StridedSliceLayer.
A layer that the constant data can be bound to.
Copyright (c) 2021 ARM Limited and Contributors.
bool GetAllowExpandedDims() const
LayerWithParameters(unsigned int numInputSlots, unsigned int numOutputSlots, LayerType type, const Parameters ¶m, const char *name)
LayerType
When adding a new layer, adapt also the LastLayer enum value in the enum class LayerType below.
virtual void ExecuteStrategy(const IConnectableLayer *layer, const armnn::BaseDescriptor &descriptor, const std::vector< armnn::ConstTensor > &constants, const char *name, const armnn::LayerBindingId id=0)=0