From f24effa4995ea4c3dd91e33d4a2787e02decf8b4 Mon Sep 17 00:00:00 2001 From: Finn Williams Date: Fri, 3 Jul 2020 10:12:03 +0100 Subject: IVGCVSW-5155 Update Arm NN API to allow for call to shape inference Signed-off-by: Finn Williams Change-Id: I0a2babe5b5b09eb81c9900dc3a05071034a0440b --- src/armnn/layers/FullyConnectedLayer.cpp | 8 +++----- 1 file changed, 3 insertions(+), 5 deletions(-) (limited to 'src/armnn/layers/FullyConnectedLayer.cpp') diff --git a/src/armnn/layers/FullyConnectedLayer.cpp b/src/armnn/layers/FullyConnectedLayer.cpp index 174459b565..f10beda72b 100644 --- a/src/armnn/layers/FullyConnectedLayer.cpp +++ b/src/armnn/layers/FullyConnectedLayer.cpp @@ -61,13 +61,11 @@ std::vector FullyConnectedLayer::InferOutputShapes(const std::vecto return std::vector({ TensorShape({batches, weightShape[dimIdx]})}); } -void FullyConnectedLayer::ValidateTensorShapesFromInputs(ShapeInferenceMethod shapeInferenceMethod) +void FullyConnectedLayer::ValidateTensorShapesFromInputs() { - IgnoreUnused(shapeInferenceMethod); - const TensorShape& outputShape = GetOutputSlot(0).GetTensorInfo().GetShape(); - VerifyShapeInferenceType(outputShape, shapeInferenceMethod); + VerifyShapeInferenceType(outputShape, m_ShapeInferenceMethod); // check if we m_Weight data is not nullptr ARMNN_ASSERT_MSG(m_Weight != nullptr, "FullyConnectedLayer: Weights data should not be null."); @@ -78,7 +76,7 @@ void FullyConnectedLayer::ValidateTensorShapesFromInputs(ShapeInferenceMethod sh ARMNN_ASSERT(inferredShapes.size() == 1); ARMNN_ASSERT(inferredShapes[0].GetDimensionality() == Dimensionality::Specified); - ValidateAndCopyShape(outputShape, inferredShapes[0], shapeInferenceMethod, "FullyConnectedLayer"); + ValidateAndCopyShape(outputShape, inferredShapes[0], m_ShapeInferenceMethod, "FullyConnectedLayer"); } Layer::ConstantTensors FullyConnectedLayer::GetConstantTensorsByRef() -- cgit v1.2.1