From 6940dd720ebb6b3d1df8ca203ab696daefe58189 Mon Sep 17 00:00:00 2001 From: Jim Flynn Date: Fri, 20 Mar 2020 12:25:56 +0000 Subject: renamed Documentation folder 20.02 and added .nojekyll file Signed-off-by: Jim Flynn --- ...armnn_1_1_shapes_are_broadcast_compatible.xhtml | 246 +++++++++++++++++++++ 1 file changed, 246 insertions(+) create mode 100644 20.02/structarmnn_1_1_shapes_are_broadcast_compatible.xhtml (limited to '20.02/structarmnn_1_1_shapes_are_broadcast_compatible.xhtml') diff --git a/20.02/structarmnn_1_1_shapes_are_broadcast_compatible.xhtml b/20.02/structarmnn_1_1_shapes_are_broadcast_compatible.xhtml new file mode 100644 index 0000000000..87f13db435 --- /dev/null +++ b/20.02/structarmnn_1_1_shapes_are_broadcast_compatible.xhtml @@ -0,0 +1,246 @@ + + + + + + + + + + + + + +ArmNN: ShapesAreBroadcastCompatible Struct Reference + + + + + + + + + + + + + + + + +
+
+ + + + ArmNN + + + +
+
+  20.02 +
+
+
+ + + + + + + +
+
+ +
+
+
+ +
+ +
+
+ + +
+ +
+ +
+ +
+
ShapesAreBroadcastCompatible Struct Reference
+
+
+ +

#include <LayerSupportRules.hpp>

+
+Inheritance diagram for ShapesAreBroadcastCompatible:
+
+
+ + +Rule + +
+ + + + + + + + + +

+Public Member Functions

unsigned int CalcInputSize (const TensorShape &in, const TensorShape &out, unsigned int idx)
 
 ShapesAreBroadcastCompatible (const TensorInfo &in0, const TensorInfo &in1, const TensorInfo &out)
 
- Public Member Functions inherited from Rule
bool operator() () const
 
+ + + + +

+Additional Inherited Members

- Public Attributes inherited from Rule
bool m_Res = true
 
+

Detailed Description

+
+

Definition at line 153 of file LayerSupportRules.hpp.

+

Constructor & Destructor Documentation

+ +

◆ ShapesAreBroadcastCompatible()

+ +
+
+ + + + + +
+ + + + + + + + + + + + + + + + + + + + + + + + +
ShapesAreBroadcastCompatible (const TensorInfoin0,
const TensorInfoin1,
const TensorInfoout 
)
+
+inline
+
+ +

Definition at line 162 of file LayerSupportRules.hpp.

+ +

References TensorShape::GetNumDimensions(), TensorInfo::GetShape(), and Rule::m_Res.

+
163  {
164  const TensorShape& shape0 = in0.GetShape();
165  const TensorShape& shape1 = in1.GetShape();
166  const TensorShape& outShape = out.GetShape();
167 
168  for (unsigned int i=0; i < outShape.GetNumDimensions() && m_Res; i++)
169  {
170  unsigned int sizeOut = outShape[i];
171  unsigned int sizeIn0 = CalcInputSize(shape0, outShape, i);
172  unsigned int sizeIn1 = CalcInputSize(shape1, outShape, i);
173 
174  m_Res &= ((sizeIn0 == sizeOut) || (sizeIn0 == 1)) &&
175  ((sizeIn1 == sizeOut) || (sizeIn1 == 1));
176  }
177  }
+
unsigned int CalcInputSize(const TensorShape &in, const TensorShape &out, unsigned int idx)
+
+
+
+

Member Function Documentation

+ +

◆ CalcInputSize()

+ +
+
+ + + + + +
+ + + + + + + + + + + + + + + + + + + + + + + + +
unsigned int CalcInputSize (const TensorShapein,
const TensorShapeout,
unsigned int idx 
)
+
+inline
+
+ +

Definition at line 155 of file LayerSupportRules.hpp.

+ +

References TensorShape::GetNumDimensions().

+
156  {
157  unsigned int offset = out.GetNumDimensions() - in.GetNumDimensions();
158  unsigned int sizeIn = (idx < offset) ? 1 : in[idx-offset];
159  return sizeIn;
160  }
+
+
+
The documentation for this struct was generated from the following file: +
+
+ + + + -- cgit v1.2.1