From ef90497eccf48bd725a96eb79e062ebfd4e2d618 Mon Sep 17 00:00:00 2001 From: Richard Burton Date: Wed, 27 Apr 2022 17:24:36 +0100 Subject: MLECO-3076: Add use case API for object detection * Removed unused prototype for box drawing Signed-off-by: Richard Burton Change-Id: I1b03b88e710a5efb1ff8e107859d2245b1fead26 --- tests/use_case/object_detection/InferenceTestYoloFastest.cc | 9 ++------- tests/use_case/object_detection/ObjectDetectionUCTest.cc | 4 ---- 2 files changed, 2 insertions(+), 11 deletions(-) (limited to 'tests') diff --git a/tests/use_case/object_detection/InferenceTestYoloFastest.cc b/tests/use_case/object_detection/InferenceTestYoloFastest.cc index 8ef012d..2c035e7 100644 --- a/tests/use_case/object_detection/InferenceTestYoloFastest.cc +++ b/tests/use_case/object_detection/InferenceTestYoloFastest.cc @@ -94,13 +94,8 @@ void TestInferenceDetectionResults(int imageIdx, arm::app::Model& model, T toler REQUIRE(tflite::GetTensorData(output_arr[i])); } - arm::app::object_detection::DetectorPostprocessing postp; - postp.RunPostProcessing( - nRows, - nCols, - output_arr[0], - output_arr[1], - results); + arm::app::DetectorPostProcess postp{output_arr[0], output_arr[1], results, nRows, nCols}; + postp.DoPostProcess(); std::vector> expected_results; GetExpectedResults(expected_results); diff --git a/tests/use_case/object_detection/ObjectDetectionUCTest.cc b/tests/use_case/object_detection/ObjectDetectionUCTest.cc index a7e4f33..023b893 100644 --- a/tests/use_case/object_detection/ObjectDetectionUCTest.cc +++ b/tests/use_case/object_detection/ObjectDetectionUCTest.cc @@ -58,8 +58,6 @@ TEST_CASE("Inference by index") caseContext.Set("profiler", profiler); caseContext.Set("model", model); caseContext.Set("imgIndex", 0); - arm::app::object_detection::DetectorPostprocessing postp; - caseContext.Set("postprocess", postp); REQUIRE(arm::app::ObjectDetectionHandler(caseContext, 0, false)); } @@ -83,8 +81,6 @@ TEST_CASE("Inference run all images") caseContext.Set("profiler", profiler); caseContext.Set("model", model); caseContext.Set("imgIndex", 0); - arm::app::object_detection::DetectorPostprocessing postp; - caseContext.Set("postprocess", postp); REQUIRE(arm::app::ObjectDetectionHandler(caseContext, 0, true)); } -- cgit v1.2.1