21.02
|
Basic function to calculate the gradient for HOG. More...
#include <CLHOGGradient.h>
Public Member Functions | |
CLHOGGradient (std::shared_ptr< IMemoryManager > memory_manager=nullptr) | |
Default constructor. More... | |
void | configure (ICLTensor *input, ICLTensor *output_magnitude, ICLTensor *output_phase, PhaseType phase_type, BorderMode border_mode, uint8_t constant_border_value=0) |
Initialise the function's source, destinations, phase type and border mode. More... | |
void | configure (const CLCompileContext &compile_context, ICLTensor *input, ICLTensor *output_magnitude, ICLTensor *output_phase, PhaseType phase_type, BorderMode border_mode, uint8_t constant_border_value=0) |
Initialise the function's source, destinations, phase type 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 calculate the gradient for HOG.
This function calls the following OpenCL kernels:
Definition at line 50 of file CLHOGGradient.h.
CLHOGGradient | ( | std::shared_ptr< IMemoryManager > | memory_manager = nullptr | ) |
Default constructor.
Definition at line 34 of file CLHOGGradient.cpp.
void configure | ( | ICLTensor * | input, |
ICLTensor * | output_magnitude, | ||
ICLTensor * | output_phase, | ||
PhaseType | phase_type, | ||
BorderMode | border_mode, | ||
uint8_t | constant_border_value = 0 |
||
) |
Initialise the function's source, destinations, phase type and border mode.
[in,out] | input | Input tensor. Data type supported: U8. (Written to only for border_mode != UNDEFINED) |
[out] | output_magnitude | Output tensor (magnitude). Data type supported: U16. |
[out] | output_phase | Output tensor.(phase). Format supported: U8 |
[in] | phase_type | Type of PhaseType |
[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. |
Definition at line 43 of file CLHOGGradient.cpp.
References CLKernelLibrary::get().
Referenced by CLHOGDescriptor::configure(), and CLHOGMultiDetection::configure().
void configure | ( | const CLCompileContext & | compile_context, |
ICLTensor * | input, | ||
ICLTensor * | output_magnitude, | ||
ICLTensor * | output_phase, | ||
PhaseType | phase_type, | ||
BorderMode | border_mode, | ||
uint8_t | constant_border_value = 0 |
||
) |
Initialise the function's source, destinations, phase type and border mode.
[in] | compile_context | The compile context to be used. |
[in,out] | input | Input tensor. Data type supported: U8. (Written to only for border_mode != UNDEFINED) |
[out] | output_magnitude | Output tensor (magnitude). Data type supported: U16. |
[out] | output_phase | Output tensor.(phase). Format supported: U8 |
[in] | phase_type | Type of PhaseType |
[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. |
Definition at line 48 of file CLHOGGradient.cpp.
References CLTensorAllocator::allocate(), CLTensor::allocator(), ARM_COMPUTE_ERROR_ON_DATA_TYPE_CHANNEL_NOT_IN, CLDerivative::configure(), ITensor::info(), arm_compute::test::validation::info, ITensorAllocator::init(), arm_compute::L2NORM, MemoryGroup::manage(), arm_compute::S16, arm_compute::SIGNED, ITensorInfo::tensor_shape(), arm_compute::U8, and arm_compute::UNSIGNED.
|
overridevirtual |
Run the kernels contained in the function.
For Neon kernels:
For OpenCL kernels:
Implements IFunction.
Definition at line 84 of file CLHOGGradient.cpp.
References CLScheduler::enqueue(), CLScheduler::get(), and ICLSimpleFunction::run().
Referenced by CLHOGDescriptor::run(), and CLHOGMultiDetection::run().