diff options
author | Colm Donelan <colm.donelan@arm.com> | 2023-11-28 15:46:09 +0000 |
---|---|---|
committer | Colm Donelan <colm.donelan@arm.com> | 2023-12-18 10:27:21 +0000 |
commit | eff204aa3ae75277b0cf689eed0e2073ff644ef8 (patch) | |
tree | cc222af9c397947f240a1554414fd2ac4c5cf636 /delegate/test/ArgMinMaxTestHelper.hpp | |
parent | 7790dc6531034778d92ba264fd61174bcff7051e (diff) | |
download | armnn-eff204aa3ae75277b0cf689eed0e2073ff644ef8.tar.gz |
IVGCVSW-7675 Rework DelegateUnitTests so backends are subcases.
The intent of this change is to remove the per backend test cases in
the delegate unit tests. They will be replaced by using DocTest
SUBCASES. The sub cases are paramaterized by the available backends.
The list of available backends are determined by the compilation flags.
Signed-off-by: Colm Donelan <colm.donelan@arm.com>
Change-Id: Ia377c7a7399d0e30dc287d7217b3e3b52e1ea074
Diffstat (limited to 'delegate/test/ArgMinMaxTestHelper.hpp')
-rw-r--r-- | delegate/test/ArgMinMaxTestHelper.hpp | 6 |
1 files changed, 3 insertions, 3 deletions
diff --git a/delegate/test/ArgMinMaxTestHelper.hpp b/delegate/test/ArgMinMaxTestHelper.hpp index 1086a5e6d3..9c6ac8dccb 100644 --- a/delegate/test/ArgMinMaxTestHelper.hpp +++ b/delegate/test/ArgMinMaxTestHelper.hpp @@ -126,7 +126,6 @@ std::vector<char> CreateArgMinMaxTfLiteModel(tflite::BuiltinOperator argMinMaxOp template <typename InputT, typename OutputT> void ArgMinMaxTest(tflite::BuiltinOperator argMinMaxOperatorCode, tflite::TensorType tensorType, - const std::vector<armnn::BackendId>& backends, const std::vector<int32_t>& inputShape, const std::vector<int32_t>& axisShape, std::vector<int32_t>& outputShape, @@ -135,7 +134,8 @@ void ArgMinMaxTest(tflite::BuiltinOperator argMinMaxOperatorCode, OutputT axisValue, tflite::TensorType outputType, float quantScale = 1.0f, - int quantOffset = 0) + int quantOffset = 0, + const std::vector<armnn::BackendId>& backends = {}) { using namespace delegateTestInterpreter; std::vector<char> modelBuffer = CreateArgMinMaxTfLiteModel<InputT, OutputT>(argMinMaxOperatorCode, @@ -157,7 +157,7 @@ void ArgMinMaxTest(tflite::BuiltinOperator argMinMaxOperatorCode, 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<InputT>(inputValues, 0) == kTfLiteOk); CHECK(armnnInterpreter.Invoke() == kTfLiteOk); |