aboutsummaryrefslogtreecommitdiff
path: root/src/armnn/layers/ElementwiseBaseLayer.hpp
diff options
context:
space:
mode:
authorConor Kennedy <conor.kennedy@arm.com>2018-12-21 14:38:36 +0000
committerLes Bell <les.bell@arm.com>2018-12-24 09:33:39 +0000
commit35052ae3f44d24cd71f437a2011c5032d34c94a7 (patch)
tree21cdc0f077606f80713f75c6eaeace2adcd4bb20 /src/armnn/layers/ElementwiseBaseLayer.hpp
parenta06bf31afabfb84e60740ea3219406ab13c8e6a6 (diff)
downloadarmnn-35052ae3f44d24cd71f437a2011c5032d34c94a7.tar.gz
IVGCVSW-59 Add documentation to the public API
* Add documentation to the Descriptors * Add documentation to the layers Change-Id: I5e0849753903565227fd47d329a600fd90b2feb9
Diffstat (limited to 'src/armnn/layers/ElementwiseBaseLayer.hpp')
-rw-r--r--src/armnn/layers/ElementwiseBaseLayer.hpp19
1 files changed, 16 insertions, 3 deletions
diff --git a/src/armnn/layers/ElementwiseBaseLayer.hpp b/src/armnn/layers/ElementwiseBaseLayer.hpp
index f0821ecfe9..5c2bbaa054 100644
--- a/src/armnn/layers/ElementwiseBaseLayer.hpp
+++ b/src/armnn/layers/ElementwiseBaseLayer.hpp
@@ -10,17 +10,30 @@
namespace armnn
{
-/// NOTE: this is an abstract class, it does not implement:
-/// std::unique_ptr<IWorkload> Layer::CreateWorkload(const Graph& graph, const IWorkloadFactory& factory) const = 0;
-/// Layer* Clone(Graph& graph) const = 0;
+/// NOTE: this is an abstract class to encapsulate the element wise operations, it does not implement:
+/// std::unique_ptr<IWorkload> Layer::CreateWorkload(const Graph& graph, const IWorkloadFactory& factory) const = 0;
+/// Layer* Clone(Graph& graph) const = 0;
class ElementwiseBaseLayer : public Layer
{
public:
+ /// Check if the input tensor shape(s)
+ /// will lead to a valid configuration of the element wise operation.
void ValidateTensorShapesFromInputs() override;
+
+ /// By default returns inputShapes if the number of inputs are equal to number of outputs,
+ /// otherwise infers the output shapes from given input shapes and layer properties.
+ /// @param [in] inputShapes The input shapes layer has.
+ /// @return A vector to the inferred output shape.
std::vector<TensorShape> InferOutputShapes(const std::vector<TensorShape>& inputShapes) const override;
protected:
+ /// @param numInputSlots The number of input slots for the layer.
+ /// @param numOutputSlots The number of output slots for the layer.
+ /// @param type The layer type.
+ /// @param name Optional name for the layer.
ElementwiseBaseLayer(unsigned int numInputSlots, unsigned int numOutputSlots, LayerType type, const char* name);
+
+ /// Default destructor
~ElementwiseBaseLayer() = default;
};