From d910ffa3ae6433404649f91ac53c8fa08bd6e196 Mon Sep 17 00:00:00 2001 From: Georgios Pinitas Date: Mon, 18 Sep 2017 16:04:42 +0100 Subject: COMPMID-534: Port MemoryManager to NEON functions (Images) Adds support to: -NEHarrisCorners -NEFastCorners Change-Id: I21eeb9961092d20f69e82f447fe1faa48b0f4ad8 Reviewed-on: http://mpd-gerrit.cambridge.arm.com/88113 Tested-by: Kaizen Reviewed-by: Moritz Pflanzer Reviewed-by: Pablo Tello --- arm_compute/runtime/NEON/functions/NEFastCorners.h | 6 +++++- arm_compute/runtime/NEON/functions/NEHarrisCorners.h | 5 ++++- 2 files changed, 9 insertions(+), 2 deletions(-) (limited to 'arm_compute/runtime/NEON') diff --git a/arm_compute/runtime/NEON/functions/NEFastCorners.h b/arm_compute/runtime/NEON/functions/NEFastCorners.h index d7c31750c5..5ecf0c2b19 100644 --- a/arm_compute/runtime/NEON/functions/NEFastCorners.h +++ b/arm_compute/runtime/NEON/functions/NEFastCorners.h @@ -31,9 +31,12 @@ #include "arm_compute/core/Types.h" #include "arm_compute/runtime/Array.h" #include "arm_compute/runtime/IFunction.h" +#include "arm_compute/runtime/IMemoryManager.h" +#include "arm_compute/runtime/MemoryGroup.h" #include "arm_compute/runtime/Tensor.h" #include +#include namespace arm_compute { @@ -51,7 +54,7 @@ class NEFastCorners : public IFunction { public: /** Constructor */ - NEFastCorners(); + NEFastCorners(std::shared_ptr memory_manager = nullptr); /** Initialize the function's source, destination, conv and border_mode. * * @param[in, out] input Source image. Data type supported: U8. (Written to only for @p border_mode != UNDEFINED) @@ -68,6 +71,7 @@ public: void run() override; private: + MemoryGroup _memory_group; NEFastCornersKernel _fast_corners_kernel; NEFillBorderKernel _border_handler; NENonMaximaSuppression3x3Kernel _nonmax_kernel; diff --git a/arm_compute/runtime/NEON/functions/NEHarrisCorners.h b/arm_compute/runtime/NEON/functions/NEHarrisCorners.h index a709871153..a9a6786db5 100644 --- a/arm_compute/runtime/NEON/functions/NEHarrisCorners.h +++ b/arm_compute/runtime/NEON/functions/NEHarrisCorners.h @@ -31,6 +31,8 @@ #include "arm_compute/core/Types.h" #include "arm_compute/runtime/Array.h" #include "arm_compute/runtime/IFunction.h" +#include "arm_compute/runtime/IMemoryManager.h" +#include "arm_compute/runtime/MemoryGroup.h" #include "arm_compute/runtime/NEON/functions/NENonMaximaSuppression3x3.h" #include "arm_compute/runtime/Tensor.h" @@ -63,7 +65,7 @@ public: * * Initialize _sobel, _harris_score and _corner_list to nullptr. */ - NEHarrisCorners(); + NEHarrisCorners(std::shared_ptr memory_manager = nullptr); /** Initialize the function's source, destination, conv and border_mode. * * @param[in, out] input Source image. Data type supported: U8. (Written to only for @p border_mode != UNDEFINED) @@ -85,6 +87,7 @@ public: void run() override; private: + MemoryGroup _memory_group; /**< Function's memory group */ std::unique_ptr _sobel; /**< Sobel function */ std::unique_ptr _harris_score; /**< Harris score kernel */ NENonMaximaSuppression3x3 _non_max_suppr; /**< Non-maxima suppression function */ -- cgit v1.2.1