From a544f0f5d01ea980ca86e1e13e2530fea4fddcd2 Mon Sep 17 00:00:00 2001 From: Ryan OShea Date: Wed, 25 Jan 2023 18:10:20 +0000 Subject: MLCE-753 Expand Tensorshape for relevent layers before verifying support Previously we were adding a reshape layer to "broadcast" tensors for elementwise operations. This broadcast was happening too late and was really just an expand dims. This was breaking the constant attributes of tensors and layer support of certain backends. * Remove addition of reshape layer when expanding dimensions * Replace broadcast function with expand dims to equal rank function * Fix some error status checks in various layers * Add new TensorUtil function that expands dims to a defined rank * Add unit tests to new TensorUtil function Signed-off-by: Ryan OShea Change-Id: I31aca47c98075fef4f86864a15470f5faa55ab8d --- delegate/src/Gather.hpp | 6 ++---- 1 file changed, 2 insertions(+), 4 deletions(-) (limited to 'delegate/src/Gather.hpp') diff --git a/delegate/src/Gather.hpp b/delegate/src/Gather.hpp index 9e98966471..9125997417 100644 --- a/delegate/src/Gather.hpp +++ b/delegate/src/Gather.hpp @@ -1,5 +1,5 @@ // -// Copyright © 2020,2022 Arm Ltd and Contributors. All rights reserved. +// Copyright © 2020,2022-2023 Arm Ltd and Contributors. All rights reserved. // SPDX-License-Identifier: MIT // @@ -101,8 +101,6 @@ TfLiteStatus VisitGatherOperator(DelegateData& delegateData, return inputsTensorsProcess; } - Connect(layer, tfLiteNode, delegateData); - - return kTfLiteOk; + return Connect(layer, tfLiteNode, delegateData); } } // namespace armnnDelegate \ No newline at end of file -- cgit v1.2.1