aboutsummaryrefslogtreecommitdiff
path: root/delegate/test/SpaceDepthTestHelper.hpp
diff options
context:
space:
mode:
Diffstat (limited to 'delegate/test/SpaceDepthTestHelper.hpp')
-rw-r--r--delegate/test/SpaceDepthTestHelper.hpp10
1 files changed, 3 insertions, 7 deletions
diff --git a/delegate/test/SpaceDepthTestHelper.hpp b/delegate/test/SpaceDepthTestHelper.hpp
index 6d566a61b4..5b8b0a94aa 100644
--- a/delegate/test/SpaceDepthTestHelper.hpp
+++ b/delegate/test/SpaceDepthTestHelper.hpp
@@ -1,5 +1,5 @@
//
-// Copyright © 2021, 2023 Arm Ltd and Contributors. All rights reserved.
+// Copyright © 2021, 2023-2024 Arm Ltd and Contributors. All rights reserved.
// SPDX-License-Identifier: MIT
//
@@ -10,12 +10,8 @@
#include <armnn_delegate.hpp>
#include <DelegateTestInterpreter.hpp>
-#include <flatbuffers/flatbuffers.h>
-#include <tensorflow/lite/kernels/register.h>
#include <tensorflow/lite/version.h>
-#include <doctest/doctest.h>
-
namespace
{
std::vector<char> CreateSpaceDepthTfLiteModel(tflite::BuiltinOperator spaceDepthOperatorCode,
@@ -114,11 +110,11 @@ std::vector<char> CreateSpaceDepthTfLiteModel(tflite::BuiltinOperator spaceDepth
template <typename T>
void SpaceDepthTest(tflite::BuiltinOperator spaceDepthOperatorCode,
tflite::TensorType tensorType,
- std::vector<armnn::BackendId>& backends,
std::vector<int32_t>& inputShape,
std::vector<int32_t>& outputShape,
std::vector<T>& inputValues,
std::vector<T>& expectedOutputValues,
+ const std::vector<armnn::BackendId>& backends = {},
int32_t blockSize = 2)
{
using namespace delegateTestInterpreter;
@@ -137,7 +133,7 @@ void SpaceDepthTest(tflite::BuiltinOperator spaceDepthOperatorCode,
std::vector<int32_t> tfLiteOutputShape = tfLiteInterpreter.GetOutputShape(0);
// Setup interpreter with Arm NN Delegate applied.
- auto armnnInterpreter = DelegateTestInterpreter(modelBuffer, backends);
+ auto armnnInterpreter = DelegateTestInterpreter(modelBuffer, CaptureAvailableBackends(backends));
CHECK(armnnInterpreter.AllocateTensors() == kTfLiteOk);
CHECK(armnnInterpreter.FillInputTensor<T>(inputValues, 0) == kTfLiteOk);
CHECK(armnnInterpreter.Invoke() == kTfLiteOk);