diff options
author | Matthew Sloyan <matthew.sloyan@arm.com> | 2022-05-10 13:21:01 +0100 |
---|---|---|
committer | Matthew Sloyan <matthew.sloyan@arm.com> | 2022-05-10 13:21:01 +0100 |
commit | 0bc74e9674eb161342fabd0ba83c4c87b45ecd84 (patch) | |
tree | 70ac62823ee9824f584fc75eba270fd222fd4e70 | |
parent | b29e08a5566307f0ecc59db058e3b65c75f71e35 (diff) | |
download | ml-embedded-evaluation-kit-0bc74e9674eb161342fabd0ba83c4c87b45ecd84.tar.gz |
MLECO-3189: Object detection keeps all detections
* Clear vector before each inference to make sure there are no leftover
results when running all inferences.
Signed-off-by: Matthew Sloyan <matthew.sloyan@arm.com>
Change-Id: If2417364151d7f380c3311447b10f971a5475f9e
-rw-r--r-- | source/use_case/object_detection/src/UseCaseHandler.cc | 3 |
1 files changed, 3 insertions, 0 deletions
diff --git a/source/use_case/object_detection/src/UseCaseHandler.cc b/source/use_case/object_detection/src/UseCaseHandler.cc index 332d199..4d0877a 100644 --- a/source/use_case/object_detection/src/UseCaseHandler.cc +++ b/source/use_case/object_detection/src/UseCaseHandler.cc @@ -102,6 +102,9 @@ namespace app { DetectorPostProcess postProcess = DetectorPostProcess(outputTensor0, outputTensor1, results, inputImgRows, inputImgCols); do { + /* Ensure there are no results leftover from previous inference when running all. */ + results.clear(); + /* Strings for presentation/logging. */ std::string str_inf{"Running inference... "}; |