aboutsummaryrefslogtreecommitdiff
path: root/src/armnn/layers/FillLayer.cpp
diff options
context:
space:
mode:
authorKeith Davis <keith.davis@arm.com>2020-06-04 16:34:23 +0100
committerKeithARM <keith.davis@arm.com>2020-06-17 14:54:08 +0000
commit300ad5695e2a577d2a9292b3cd6d182aae3298a3 (patch)
tree3fb34c3dc50b62630538592e6964fc263d078921 /src/armnn/layers/FillLayer.cpp
parent6398a98ac273931cc0b3ab33222d255d1edf48b0 (diff)
downloadarmnn-300ad5695e2a577d2a9292b3cd6d182aae3298a3.tar.gz
IVGCVSW-4908 Add Serializer/Deserializer Support for FILL operator
Signed-off-by: Keith Davis <keith.davis@arm.com> Change-Id: Icae26505d0e378ee5ffb3e92b35d78d48b369d2e
Diffstat (limited to 'src/armnn/layers/FillLayer.cpp')
-rw-r--r--src/armnn/layers/FillLayer.cpp10
1 files changed, 6 insertions, 4 deletions
diff --git a/src/armnn/layers/FillLayer.cpp b/src/armnn/layers/FillLayer.cpp
index 03f93f76da..eb9f6af800 100644
--- a/src/armnn/layers/FillLayer.cpp
+++ b/src/armnn/layers/FillLayer.cpp
@@ -33,19 +33,21 @@ void FillLayer::ValidateTensorShapesFromInputs()
{
VerifyLayerConnections(1, CHECK_LOCATION());
- auto inferredShapes = InferOutputShapes({ GetInputSlot(0).GetConnection()->GetTensorInfo().GetShape() });
+ auto inferredShapes = InferOutputShapes( { GetInputSlot(0).GetConnection()->GetTensorInfo().GetShape() });
ARMNN_ASSERT(inferredShapes.size() == 1);
+ // Cannot validate the output shape from the input shape. but we can validate that the correct dims have been
+ // inferred
ConditionalThrowIfNotEqual<LayerValidationException>(
"FillLayer: TensorShape set on OutputSlot[0] does not match the inferred shape.",
- GetOutputSlot(0).GetTensorInfo().GetShape(),
- inferredShapes[0]);
+ GetOutputSlot(0).GetTensorInfo().GetNumDimensions(),
+ inferredShapes[0][0]);
}
void FillLayer::Accept(ILayerVisitor& visitor) const
{
- visitor.VisitGatherLayer(this, GetName());
+ visitor.VisitFillLayer(this, GetParameters(), GetName());
}
} // namespace armnn