21.02
|
Basic function to execute harris corners detection. More...
#include <CLHarrisCorners.h>
Public Member Functions | |
CLHarrisCorners (std::shared_ptr< IMemoryManager > memory_manager=nullptr) | |
Constructor. More... | |
CLHarrisCorners (const CLHarrisCorners &)=delete | |
Prevent instances of this class from being copied (As this class contains pointers) More... | |
const CLHarrisCorners & | operator= (const CLHarrisCorners &)=delete |
Prevent instances of this class from being copied (As this class contains pointers) More... | |
~CLHarrisCorners () | |
Default destructor. More... | |
void | configure (ICLImage *input, float threshold, float min_dist, float sensitivity, int32_t gradient_size, int32_t block_size, ICLKeyPointArray *corners, BorderMode border_mode, uint8_t constant_border_value=0, bool use_fp16=false) |
Initialize the function's source, destination, conv and border_mode. More... | |
void | configure (const CLCompileContext &compile_context, ICLImage *input, float threshold, float min_dist, float sensitivity, int32_t gradient_size, int32_t block_size, ICLKeyPointArray *corners, BorderMode border_mode, uint8_t constant_border_value=0, bool use_fp16=false) |
Initialize the function's source, destination, conv and border_mode. More... | |
void | run () override |
Run the kernels contained in the function. More... | |
Public Member Functions inherited from IFunction | |
virtual | ~IFunction ()=default |
Destructor. More... | |
virtual void | prepare () |
Prepare the function for executing. More... | |
Basic function to execute harris corners detection.
This function calls the following CL and Neon kernels and functions:
Definition at line 63 of file CLHarrisCorners.h.
CLHarrisCorners | ( | std::shared_ptr< IMemoryManager > | memory_manager = nullptr | ) |
Constructor.
Definition at line 46 of file CLHarrisCorners.cpp.
References CLHarrisCorners::~CLHarrisCorners().
|
delete |
Prevent instances of this class from being copied (As this class contains pointers)
|
default |
Default destructor.
Referenced by CLHarrisCorners::CLHarrisCorners().
void configure | ( | ICLImage * | input, |
float | threshold, | ||
float | min_dist, | ||
float | sensitivity, | ||
int32_t | gradient_size, | ||
int32_t | block_size, | ||
ICLKeyPointArray * | corners, | ||
BorderMode | border_mode, | ||
uint8_t | constant_border_value = 0 , |
||
bool | use_fp16 = false |
||
) |
Initialize the function's source, destination, conv and border_mode.
[in,out] | input | Source image. Data types supported: U8. (Written to only for border_mode != UNDEFINED) |
[in] | threshold | Minimum threshold with which to eliminate Harris Corner scores (computed using the normalized Sobel kernel). |
[in] | min_dist | Radial Euclidean distance for the euclidean distance stage. |
[in] | sensitivity | Sensitivity threshold k from the Harris-Stephens equation |
[in] | gradient_size | The gradient window size to use on the input. The implementation supports 3, 5, and 7 |
[in] | block_size | The block window size used to compute the Harris Corner score. The implementation supports 3, 5, and 7. |
[out] | corners | Array of keypoints to store the results. |
[in] | border_mode | Border mode to use |
[in] | constant_border_value | (Optional) Constant value to use for borders if border_mode is set to CONSTANT. |
[in] | use_fp16 | (Optional) If true the FP16 kernels will be used. If false F32 kernels are used. |
Definition at line 67 of file CLHarrisCorners.cpp.
References CLKernelLibrary::get().
void configure | ( | const CLCompileContext & | compile_context, |
ICLImage * | input, | ||
float | threshold, | ||
float | min_dist, | ||
float | sensitivity, | ||
int32_t | gradient_size, | ||
int32_t | block_size, | ||
ICLKeyPointArray * | corners, | ||
BorderMode | border_mode, | ||
uint8_t | constant_border_value = 0 , |
||
bool | use_fp16 = false |
||
) |
Initialize the function's source, destination, conv and border_mode.
[in] | compile_context | The compile context to be used. |
[in,out] | input | Source image. Data types supported: U8. (Written to only for border_mode != UNDEFINED) |
[in] | threshold | Minimum threshold with which to eliminate Harris Corner scores (computed using the normalized Sobel kernel). |
[in] | min_dist | Radial Euclidean distance for the euclidean distance stage. |
[in] | sensitivity | Sensitivity threshold k from the Harris-Stephens equation |
[in] | gradient_size | The gradient window size to use on the input. The implementation supports 3, 5, and 7 |
[in] | block_size | The block window size used to compute the Harris Corner score. The implementation supports 3, 5, and 7. |
[out] | corners | Array of keypoints to store the results. |
[in] | border_mode | Border mode to use |
[in] | constant_border_value | (Optional) Constant value to use for borders if border_mode is set to CONSTANT. |
[in] | use_fp16 | (Optional) If true the FP16 kernels will be used. If false F32 kernels are used. |
Definition at line 74 of file CLHarrisCorners.cpp.
References CLTensorAllocator::allocate(), CLTensor::allocator(), ARM_COMPUTE_ERROR, ARM_COMPUTE_ERROR_ON, ARM_COMPUTE_ERROR_ON_DATA_TYPE_CHANNEL_NOT_IN, ARM_COMPUTE_ERROR_ON_TENSOR_NOT_2D, ARM_COMPUTE_UNUSED, CLNonMaximaSuppression3x3::configure(), CPPSortEuclideanDistanceKernel::configure(), CPPCornerCandidatesKernel::configure(), dt, arm_compute::F32, ITensor::info(), ITensorAllocator::init(), MemoryGroup::manage(), arm_compute::S16, arm_compute::S32, arm_compute::test::validation::shape, ITensorInfo::tensor_shape(), arm_compute::U8, arm_compute::UNDEFINED, Dimensions< T >::x(), and Dimensions< T >::y().
|
delete |
Prevent instances of this class from being copied (As this class contains pointers)
|
overridevirtual |
Run the kernels contained in the function.
For Neon kernels:
For OpenCL kernels:
Implements IFunction.
Definition at line 168 of file CLHarrisCorners.cpp.
References ARM_COMPUTE_ERROR_ON_MSG, Window::DimY, CLScheduler::enqueue(), Scheduler::get(), CLScheduler::get(), ICLArray< T >::map(), CLTensor::map(), ICLSimpleFunction::run(), IScheduler::schedule(), CLTensor::unmap(), and ICLArray< T >::unmap().