From 4865c4fc171d6b0eb6e2b470f123ff81e45a34f8 Mon Sep 17 00:00:00 2001 From: Richard Burton Date: Mon, 13 Nov 2023 15:21:11 +0000 Subject: Modifications to linker scripts * Change reference to all ops resolver * Added our own 'all ops resolver' * Move Labels objects out of BRAM for simple_platform * Minor fixes to documentation Signed-off-by: Richard Burton Change-Id: I8b0d66ce83287f2bc027cfc36a1f378c97755481 --- docs/documentation.md | 1 + docs/sections/contributing.md | 4 +- .../platforms/mps3/sse-300/mps3-sse-300-debug.ld | 6 +- .../platforms/mps3/sse-300/mps3-sse-300-release.ld | 11 +- .../platforms/simple_platform/simple_platform.sct | 3 +- .../simple_platform/simple_platform_debug.ld | 8 +- .../simple_platform/simple_platform_release.ld | 13 +-- .../api/use_case/inference_runner/CMakeLists.txt | 4 +- .../include/MicroMutableAllOpsResolver.hpp | 119 ++----------------- .../inference_runner/include/TestModel.hpp | 21 ++-- .../src/MicroMutableAllOpsResolver.cc | 128 +++++++++++++++++++++ .../api/use_case/inference_runner/src/TestModel.cc | 11 +- 12 files changed, 177 insertions(+), 152 deletions(-) create mode 100644 source/application/api/use_case/inference_runner/src/MicroMutableAllOpsResolver.cc diff --git a/docs/documentation.md b/docs/documentation.md index 99027f1..7258928 100644 --- a/docs/documentation.md +++ b/docs/documentation.md @@ -13,6 +13,7 @@ - [Memory Considerations](./documentation.md#memory-considerations) - [Troubleshooting](./documentation.md#troubleshooting) - [Appendix](./documentation.md#appendix) + - [Contributing](./documentation.md#contributing) - [FAQ](./documentation.md#faq) ## Trademarks diff --git a/docs/sections/contributing.md b/docs/sections/contributing.md index 5a23c54..a030bc9 100644 --- a/docs/sections/contributing.md +++ b/docs/sections/contributing.md @@ -14,7 +14,7 @@ Contributions are only accepted under the following conditions: This can be done automatically by adding the `-s` option to your `git commit` command. You must use your real name, no pseudonyms or anonymous contributions are accepted. -- You give permission according to the [Apache License 2.0](../LICENSE_APACHE_2.0.txt). +- You give permission according to the [Apache License 2.0](../../LICENSE_APACHE_2.0.txt). In each source file, include the following copyright notice: @@ -42,7 +42,7 @@ Contributions are only accepted under the following conditions: This repository follows a set of guidelines, best practices, programming styles and conventions, see: -- [Coding standards and guidelines](./docs/sections/coding_guidelines.md) +- [Coding standards and guidelines](./docs/sections/coding_guidelines.md#Coding-standards-and-guidelines) - [Introduction](./docs/sections/coding_guidelines.md#introduction) - [Language version](./docs/sections/coding_guidelines.md#language-version) - [File naming](./docs/sections/coding_guidelines.md#file-naming) diff --git a/scripts/cmake/platforms/mps3/sse-300/mps3-sse-300-debug.ld b/scripts/cmake/platforms/mps3/sse-300/mps3-sse-300-debug.ld index d30d5e4..6531403 100644 --- a/scripts/cmake/platforms/mps3/sse-300/mps3-sse-300-debug.ld +++ b/scripts/cmake/platforms/mps3/sse-300/mps3-sse-300-debug.ld @@ -78,7 +78,7 @@ SECTIONS * This code is instead placed on BRAM. See comment in the BRAM * section for details. */ - *(EXCLUDE_FILE(*all_ops_resolver.o + *(EXCLUDE_FILE(*MicroMutableAllOpsResolver*.obj *hal.c.obj *_allocator.o *flatbuffer*.o @@ -245,11 +245,11 @@ SECTIONS /** * Place the all ops resolver code data here. This accounts - * for ~4k worth of saving on the ITCM load region. It is + * for ~9k worth of saving on the ITCM load region. It is * only designed to be included (by default) for the inference * runner use case. **/ - *all_ops_resolver.o (*.text*) + *MicroMutableAllOpsResolver*.obj (*.text*) . = ALIGN(4); *hal.c.obj (*.text*) . = ALIGN(4); diff --git a/scripts/cmake/platforms/mps3/sse-300/mps3-sse-300-release.ld b/scripts/cmake/platforms/mps3/sse-300/mps3-sse-300-release.ld index 0212753..c88280a 100644 --- a/scripts/cmake/platforms/mps3/sse-300/mps3-sse-300-release.ld +++ b/scripts/cmake/platforms/mps3/sse-300/mps3-sse-300-release.ld @@ -78,8 +78,7 @@ SECTIONS * This code is instead placed on BRAM. See comment in the BRAM * section for details. */ - *(EXCLUDE_FILE(*all_ops_resolver.o - *hal.c.obj + *(EXCLUDE_FILE(*hal.c.obj *_allocator.o *flatbuffer*.o *lcd*.obj @@ -235,14 +234,6 @@ SECTIONS *(.ARM.extab* .gnu.linkonce.armextab.*) . = ALIGN(4); - /** - * Place the all ops resolver code data here. This accounts - * for ~4k worth of saving on the ITCM load region. It is - * only designed to be included (by default) for the inference - * runner use case. - **/ - *all_ops_resolver.o (*.text*) - . = ALIGN(4); *hal.c.obj (*.text*) . = ALIGN(4); *_allocator.o (*.text*) diff --git a/scripts/cmake/platforms/simple_platform/simple_platform.sct b/scripts/cmake/platforms/simple_platform/simple_platform.sct index 01e1b4d..f34170e 100644 --- a/scripts/cmake/platforms/simple_platform/simple_platform.sct +++ b/scripts/cmake/platforms/simple_platform/simple_platform.sct @@ -1,4 +1,4 @@ -; SPDX-FileCopyrightText: Copyright 2021 Arm Limited and/or its affiliates +; SPDX-FileCopyrightText: Copyright 2021, 2023 Arm Limited and/or its affiliates ; SPDX-License-Identifier: Apache-2.0 ; ; Licensed under the Apache License, Version 2.0 (the "License"); @@ -99,6 +99,7 @@ LOAD_REGION_1 0x70000000 0x02000000 ; labels *.o (labels) + Labels.o (+RO-DATA) ; activation buffers a.k.a tensor arena when memory mode dedicated sram *.o (activation_buf_dram) diff --git a/scripts/cmake/platforms/simple_platform/simple_platform_debug.ld b/scripts/cmake/platforms/simple_platform/simple_platform_debug.ld index 9a4f88a..4bbe6c0 100644 --- a/scripts/cmake/platforms/simple_platform/simple_platform_debug.ld +++ b/scripts/cmake/platforms/simple_platform/simple_platform_debug.ld @@ -71,7 +71,7 @@ SECTIONS * This code is instead placed on BRAM. See comment in the BRAM * section for details. */ - *(EXCLUDE_FILE(*all_ops_resolver.o + *(EXCLUDE_FILE(*MicroMutableAllOpsResolver*.obj *hal.c.obj *_allocator.o *flatbuffer*.o @@ -189,6 +189,8 @@ SECTIONS /* labels */ *(labels) . = ALIGN (16); + *Labels*.obj (*.rodata*) + . = ALIGN (16); /* activation buffers a.k.a tensor arena when memory mode dedicated sram */ *(activation_buf_dram) . = ALIGN (16); @@ -236,11 +238,11 @@ SECTIONS /** * Place the all ops resolver code data here. This accounts - * for ~4k worth of saving on the ITCM load region. It is + * for ~9k worth of saving on the ITCM load region. It is * only designed to be included (by default) for the inference * runner use case. **/ - *all_ops_resolver.o (*.text*) + *MicroMutableAllOpsResolver*.obj (*.text*) . = ALIGN(4); *hal.c.obj (*.text*) . = ALIGN(4); diff --git a/scripts/cmake/platforms/simple_platform/simple_platform_release.ld b/scripts/cmake/platforms/simple_platform/simple_platform_release.ld index 492f6da..46b9636 100644 --- a/scripts/cmake/platforms/simple_platform/simple_platform_release.ld +++ b/scripts/cmake/platforms/simple_platform/simple_platform_release.ld @@ -71,8 +71,7 @@ SECTIONS * This code is instead placed on BRAM. See comment in the BRAM * section for details. */ - *(EXCLUDE_FILE(*all_ops_resolver.o - *hal.c.obj + *(EXCLUDE_FILE(*hal.c.obj *_allocator.o *flatbuffer*.o *lcd*.obj @@ -188,6 +187,8 @@ SECTIONS /* labels */ *(labels) . = ALIGN (16); + *Labels*.obj (*.rodata*) + . = ALIGN (16); /* activation buffers a.k.a tensor arena when memory mode dedicated sram */ *(activation_buf_dram) . = ALIGN (16); @@ -226,14 +227,6 @@ SECTIONS *(.ARM.extab* .gnu.linkonce.armextab.*) . = ALIGN(4); - /** - * Place the all ops resolver code data here. This accounts - * for ~4k worth of saving on the ITCM load region. It is - * only designed to be included (by default) for the inference - * runner use case. - **/ - *all_ops_resolver.o (*.text*) - . = ALIGN(4); *hal.c.obj (*.text*) . = ALIGN(4); *_allocator.o (*.text*) diff --git a/source/application/api/use_case/inference_runner/CMakeLists.txt b/source/application/api/use_case/inference_runner/CMakeLists.txt index a27ce63..e4754e6 100644 --- a/source/application/api/use_case/inference_runner/CMakeLists.txt +++ b/source/application/api/use_case/inference_runner/CMakeLists.txt @@ -1,5 +1,5 @@ #---------------------------------------------------------------------------- -# SPDX-FileCopyrightText: Copyright 2022 Arm Limited and/or its affiliates +# SPDX-FileCopyrightText: Copyright 2022-2023 Arm Limited and/or its affiliates # SPDX-License-Identifier: Apache-2.0 # # Licensed under the Apache License, Version 2.0 (the "License"); @@ -25,7 +25,7 @@ project(${INFERENCE_RUNNER_API_TARGET} LANGUAGES C CXX) # Create static library -add_library(${INFERENCE_RUNNER_API_TARGET} STATIC src/TestModel.cc) +add_library(${INFERENCE_RUNNER_API_TARGET} STATIC src/TestModel.cc src/MicroMutableAllOpsResolver.cc) target_include_directories(${INFERENCE_RUNNER_API_TARGET} PUBLIC include) diff --git a/source/application/api/use_case/inference_runner/include/MicroMutableAllOpsResolver.hpp b/source/application/api/use_case/inference_runner/include/MicroMutableAllOpsResolver.hpp index 96ac28d..67a7c9e 100644 --- a/source/application/api/use_case/inference_runner/include/MicroMutableAllOpsResolver.hpp +++ b/source/application/api/use_case/inference_runner/include/MicroMutableAllOpsResolver.hpp @@ -14,122 +14,25 @@ * See the License for the specific language governing permissions and * limitations under the License. */ -#ifndef INF_RUNNER_MICRO_MUTABLE_ALLOPS_RESOLVER_HPP -#define INF_RUNNER_MICRO_MUTABLE_ALLOPS_RESOLVER_HPP +#ifndef INF_RUNNER_MICRO_MUTABLE_ALL_OPS_RESOLVER_HPP +#define INF_RUNNER_MICRO_MUTABLE_ALL_OPS_RESOLVER_HPP #include -constexpr int kNumberOperators = 97; - namespace arm { namespace app { - /* Create our own AllOpsResolver by adding all Ops to MicroMutableOpResolver. */ - inline tflite::MicroMutableOpResolver CreateAllOpsResolver() { - tflite::MicroMutableOpResolver mutableAllOpResolver; - - mutableAllOpResolver.AddAbs(); - mutableAllOpResolver.AddAdd(); - mutableAllOpResolver.AddAddN(); - mutableAllOpResolver.AddArgMax(); - mutableAllOpResolver.AddArgMin(); - mutableAllOpResolver.AddAssignVariable(); - mutableAllOpResolver.AddAveragePool2D(); - mutableAllOpResolver.AddBatchToSpaceNd(); - mutableAllOpResolver.AddBroadcastArgs(); - mutableAllOpResolver.AddBroadcastTo(); - mutableAllOpResolver.AddCallOnce(); - mutableAllOpResolver.AddCast(); - mutableAllOpResolver.AddCeil(); - mutableAllOpResolver.AddCircularBuffer(); - mutableAllOpResolver.AddConcatenation(); - mutableAllOpResolver.AddConv2D(); - mutableAllOpResolver.AddCos(); - mutableAllOpResolver.AddCumSum(); - mutableAllOpResolver.AddDepthToSpace(); - mutableAllOpResolver.AddDepthwiseConv2D(); - mutableAllOpResolver.AddDequantize(); - mutableAllOpResolver.AddDetectionPostprocess(); - mutableAllOpResolver.AddDiv(); - mutableAllOpResolver.AddElu(); - mutableAllOpResolver.AddEqual(); - mutableAllOpResolver.AddEthosU(); - mutableAllOpResolver.AddExp(); - mutableAllOpResolver.AddExpandDims(); - mutableAllOpResolver.AddFill(); - mutableAllOpResolver.AddFloor(); - mutableAllOpResolver.AddFloorDiv(); - mutableAllOpResolver.AddFloorMod(); - mutableAllOpResolver.AddFullyConnected(); - mutableAllOpResolver.AddGather(); - mutableAllOpResolver.AddGatherNd(); - mutableAllOpResolver.AddGreater(); - mutableAllOpResolver.AddGreaterEqual(); - mutableAllOpResolver.AddHardSwish(); - mutableAllOpResolver.AddIf(); - mutableAllOpResolver.AddL2Normalization(); - mutableAllOpResolver.AddL2Pool2D(); - mutableAllOpResolver.AddLeakyRelu(); - mutableAllOpResolver.AddLess(); - mutableAllOpResolver.AddLessEqual(); - mutableAllOpResolver.AddLog(); - mutableAllOpResolver.AddLogicalAnd(); - mutableAllOpResolver.AddLogicalNot(); - mutableAllOpResolver.AddLogicalOr(); - mutableAllOpResolver.AddLogistic(); - mutableAllOpResolver.AddLogSoftmax(); - mutableAllOpResolver.AddMaxPool2D(); - mutableAllOpResolver.AddMaximum(); - mutableAllOpResolver.AddMean(); - mutableAllOpResolver.AddMinimum(); - mutableAllOpResolver.AddMirrorPad(); - mutableAllOpResolver.AddMul(); - mutableAllOpResolver.AddNeg(); - mutableAllOpResolver.AddNotEqual(); - mutableAllOpResolver.AddPack(); - mutableAllOpResolver.AddPad(); - mutableAllOpResolver.AddPadV2(); - mutableAllOpResolver.AddPrelu(); - mutableAllOpResolver.AddQuantize(); - mutableAllOpResolver.AddReadVariable(); - mutableAllOpResolver.AddReduceMax(); - mutableAllOpResolver.AddRelu(); - mutableAllOpResolver.AddRelu6(); - mutableAllOpResolver.AddReshape(); - mutableAllOpResolver.AddResizeBilinear(); - mutableAllOpResolver.AddResizeNearestNeighbor(); - mutableAllOpResolver.AddRound(); - mutableAllOpResolver.AddRsqrt(); - mutableAllOpResolver.AddSelectV2(); - mutableAllOpResolver.AddShape(); - mutableAllOpResolver.AddSin(); - mutableAllOpResolver.AddSlice(); - mutableAllOpResolver.AddSoftmax(); - mutableAllOpResolver.AddSpaceToBatchNd(); - mutableAllOpResolver.AddSpaceToDepth(); - mutableAllOpResolver.AddSplit(); - mutableAllOpResolver.AddSplitV(); - mutableAllOpResolver.AddSqrt(); - mutableAllOpResolver.AddSquare(); - mutableAllOpResolver.AddSquaredDifference(); - mutableAllOpResolver.AddSqueeze(); - mutableAllOpResolver.AddStridedSlice(); - mutableAllOpResolver.AddSub(); - mutableAllOpResolver.AddSum(); - mutableAllOpResolver.AddSvdf(); - mutableAllOpResolver.AddTanh(); - mutableAllOpResolver.AddTranspose(); - mutableAllOpResolver.AddTransposeConv(); - mutableAllOpResolver.AddUnidirectionalSequenceLSTM(); - mutableAllOpResolver.AddUnpack(); - mutableAllOpResolver.AddVarHandle(); - mutableAllOpResolver.AddWhile(); - mutableAllOpResolver.AddZerosLike(); + /* Maximum number of individual operations that can be enlisted. */ + constexpr int kNumberOperators = 97; - return mutableAllOpResolver; - } + /** An Op resolver containing all ops is no longer supplied with TFLite Micro + * so we create our own instead for the generic inference runner. + * + * @return MicroMutableOpResolver containing all TFLite Micro Ops registered. + */ + tflite::MicroMutableOpResolver CreateAllOpsResolver(); } /* namespace app */ } /* namespace arm */ -#endif /* INF_RUNNER_MICRO_MUTABLE_ALLOPS_RESOLVER_HPP */ +#endif /* INF_RUNNER_MICRO_MUTABLE_ALL_OPS_RESOLVER_HPP */ diff --git a/source/application/api/use_case/inference_runner/include/TestModel.hpp b/source/application/api/use_case/inference_runner/include/TestModel.hpp index 455e244..4fbbfc0 100644 --- a/source/application/api/use_case/inference_runner/include/TestModel.hpp +++ b/source/application/api/use_case/inference_runner/include/TestModel.hpp @@ -23,20 +23,19 @@ namespace arm { namespace app { - class TestModel : public Model { + class TestModel : public Model { - protected: - /** @brief Gets the reference to op resolver interface class. */ - const tflite::MicroMutableOpResolver& GetOpResolver() override; + protected: + /** @brief Gets the reference to op resolver interface class. */ + const tflite::MicroOpResolver& GetOpResolver() override; - /** @brief Adds operations to the op resolver instance, not needed as using AllOpsResolver. */ - bool EnlistOperations() override {return false;} + /** @brief Adds operations to the op resolver instance. */ + bool EnlistOperations() override; - private: - - /* No need to define individual ops at the cost of extra memory. */ - tflite::MicroMutableOpResolver m_opResolver = CreateAllOpsResolver(); - }; + private: + /* A mutable op resolver instance including every operation for Inference runner. */ + tflite::MicroMutableOpResolver m_opResolver; + }; } /* namespace app */ } /* namespace arm */ diff --git a/source/application/api/use_case/inference_runner/src/MicroMutableAllOpsResolver.cc b/source/application/api/use_case/inference_runner/src/MicroMutableAllOpsResolver.cc new file mode 100644 index 0000000..ed50912 --- /dev/null +++ b/source/application/api/use_case/inference_runner/src/MicroMutableAllOpsResolver.cc @@ -0,0 +1,128 @@ +/* + * SPDX-FileCopyrightText: Copyright 2023 Arm Limited and/or its affiliates + * SPDX-License-Identifier: Apache-2.0 + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + +#include "MicroMutableAllOpsResolver.hpp" + +namespace arm { +namespace app { + /* Create our own AllOpsResolver by adding all Ops to MicroMutableOpResolver. */ + tflite::MicroMutableOpResolver CreateAllOpsResolver() + { + tflite::MicroMutableOpResolver mutableAllOpResolver; + + mutableAllOpResolver.AddAbs(); + mutableAllOpResolver.AddAdd(); + mutableAllOpResolver.AddAddN(); + mutableAllOpResolver.AddArgMax(); + mutableAllOpResolver.AddArgMin(); + mutableAllOpResolver.AddAssignVariable(); + mutableAllOpResolver.AddAveragePool2D(); + mutableAllOpResolver.AddBatchToSpaceNd(); + mutableAllOpResolver.AddBroadcastArgs(); + mutableAllOpResolver.AddBroadcastTo(); + mutableAllOpResolver.AddCallOnce(); + mutableAllOpResolver.AddCast(); + mutableAllOpResolver.AddCeil(); + mutableAllOpResolver.AddCircularBuffer(); + mutableAllOpResolver.AddConcatenation(); + mutableAllOpResolver.AddConv2D(); + mutableAllOpResolver.AddCos(); + mutableAllOpResolver.AddCumSum(); + mutableAllOpResolver.AddDepthToSpace(); + mutableAllOpResolver.AddDepthwiseConv2D(); + mutableAllOpResolver.AddDequantize(); + mutableAllOpResolver.AddDetectionPostprocess(); + mutableAllOpResolver.AddDiv(); + mutableAllOpResolver.AddElu(); + mutableAllOpResolver.AddEqual(); + mutableAllOpResolver.AddEthosU(); + mutableAllOpResolver.AddExp(); + mutableAllOpResolver.AddExpandDims(); + mutableAllOpResolver.AddFill(); + mutableAllOpResolver.AddFloor(); + mutableAllOpResolver.AddFloorDiv(); + mutableAllOpResolver.AddFloorMod(); + mutableAllOpResolver.AddFullyConnected(); + mutableAllOpResolver.AddGather(); + mutableAllOpResolver.AddGatherNd(); + mutableAllOpResolver.AddGreater(); + mutableAllOpResolver.AddGreaterEqual(); + mutableAllOpResolver.AddHardSwish(); + mutableAllOpResolver.AddIf(); + mutableAllOpResolver.AddL2Normalization(); + mutableAllOpResolver.AddL2Pool2D(); + mutableAllOpResolver.AddLeakyRelu(); + mutableAllOpResolver.AddLess(); + mutableAllOpResolver.AddLessEqual(); + mutableAllOpResolver.AddLog(); + mutableAllOpResolver.AddLogicalAnd(); + mutableAllOpResolver.AddLogicalNot(); + mutableAllOpResolver.AddLogicalOr(); + mutableAllOpResolver.AddLogistic(); + mutableAllOpResolver.AddLogSoftmax(); + mutableAllOpResolver.AddMaxPool2D(); + mutableAllOpResolver.AddMaximum(); + mutableAllOpResolver.AddMean(); + mutableAllOpResolver.AddMinimum(); + mutableAllOpResolver.AddMirrorPad(); + mutableAllOpResolver.AddMul(); + mutableAllOpResolver.AddNeg(); + mutableAllOpResolver.AddNotEqual(); + mutableAllOpResolver.AddPack(); + mutableAllOpResolver.AddPad(); + mutableAllOpResolver.AddPadV2(); + mutableAllOpResolver.AddPrelu(); + mutableAllOpResolver.AddQuantize(); + mutableAllOpResolver.AddReadVariable(); + mutableAllOpResolver.AddReduceMax(); + mutableAllOpResolver.AddRelu(); + mutableAllOpResolver.AddRelu6(); + mutableAllOpResolver.AddReshape(); + mutableAllOpResolver.AddResizeBilinear(); + mutableAllOpResolver.AddResizeNearestNeighbor(); + mutableAllOpResolver.AddRound(); + mutableAllOpResolver.AddRsqrt(); + mutableAllOpResolver.AddSelectV2(); + mutableAllOpResolver.AddShape(); + mutableAllOpResolver.AddSin(); + mutableAllOpResolver.AddSlice(); + mutableAllOpResolver.AddSoftmax(); + mutableAllOpResolver.AddSpaceToBatchNd(); + mutableAllOpResolver.AddSpaceToDepth(); + mutableAllOpResolver.AddSplit(); + mutableAllOpResolver.AddSplitV(); + mutableAllOpResolver.AddSqrt(); + mutableAllOpResolver.AddSquare(); + mutableAllOpResolver.AddSquaredDifference(); + mutableAllOpResolver.AddSqueeze(); + mutableAllOpResolver.AddStridedSlice(); + mutableAllOpResolver.AddSub(); + mutableAllOpResolver.AddSum(); + mutableAllOpResolver.AddSvdf(); + mutableAllOpResolver.AddTanh(); + mutableAllOpResolver.AddTranspose(); + mutableAllOpResolver.AddTransposeConv(); + mutableAllOpResolver.AddUnidirectionalSequenceLSTM(); + mutableAllOpResolver.AddUnpack(); + mutableAllOpResolver.AddVarHandle(); + mutableAllOpResolver.AddWhile(); + mutableAllOpResolver.AddZerosLike(); + return mutableAllOpResolver; + } + +} /* namespace app */ +} /* namespace arm */ diff --git a/source/application/api/use_case/inference_runner/src/TestModel.cc b/source/application/api/use_case/inference_runner/src/TestModel.cc index c69a98d..94f17ef 100644 --- a/source/application/api/use_case/inference_runner/src/TestModel.cc +++ b/source/application/api/use_case/inference_runner/src/TestModel.cc @@ -16,8 +16,15 @@ */ #include "TestModel.hpp" #include "log_macros.h" +#include "MicroMutableAllOpsResolver.hpp" -const tflite::MicroMutableOpResolver& arm::app::TestModel::GetOpResolver() +const tflite::MicroOpResolver& arm::app::TestModel::GetOpResolver() { - return this->m_opResolver; + return this->m_opResolver; +} + +bool arm::app::TestModel::EnlistOperations() +{ + this->m_opResolver = CreateAllOpsResolver(); + return true; } -- cgit v1.2.1