ARM Compute Library
17.04
|
Interface for the accumulate weighted kernel. More...
#include <NEAccumulateKernel.h>
Public Member Functions | |
NEAccumulateWeightedKernel () | |
Default constructor. More... | |
void | configure (const ITensor *input, float alpha, ITensor *accum) |
Set the input and accumulation tensors, and the scale value. More... | |
void | run (const Window &window) override |
Execute the kernel on the passed window. More... | |
Public Member Functions inherited from ICPPSimpleKernel | |
ICPPSimpleKernel () | |
Constructor. More... | |
ICPPSimpleKernel (const ICPPSimpleKernel &)=delete | |
Prevent instances of this class from being copied (As this class contains pointers) More... | |
ICPPSimpleKernel & | operator= (const ICPPSimpleKernel &)=delete |
Prevent instances of this class from being copied (As this class contains pointers) More... | |
ICPPSimpleKernel (ICPPSimpleKernel &&)=default | |
Allow instances of this class to be moved. More... | |
ICPPSimpleKernel & | operator= (ICPPSimpleKernel &&)=default |
Allow instances of this class to be moved. More... | |
~ICPPSimpleKernel ()=default | |
Default destructor. More... | |
Public Member Functions inherited from ICPPKernel | |
virtual | ~ICPPKernel ()=default |
Default destructor. More... | |
Public Member Functions inherited from IKernel | |
IKernel () | |
Constructor. More... | |
virtual | ~IKernel ()=default |
Destructor. More... | |
virtual bool | is_parallelisable () const |
Indicates whether or not the kernel is parallelisable. More... | |
virtual BorderSize | border_size () const |
The size of the border for that kernel. More... | |
const Window & | window () const |
The maximum window the kernel can be executed on. More... | |
Interface for the accumulate weighted kernel.
Weighted accumulation is computed:
\[ accum(x,y) = (1 - \alpha)*accum(x,y) + \alpha*input(x,y) \]
Where \( 0 \le \alpha \le 1 \) Conceptually, the rounding for this is defined as:
\[ output(x,y)= uint8( (1 - \alpha) * float32( int32( output(x,y) ) ) + \alpha * float32( int32( input(x,y) ) ) ) \]
Definition at line 63 of file NEAccumulateKernel.h.
Default constructor.
Set the input and accumulation tensors, and the scale value.
[in] | input | Source tensor. Data type supported: U8. |
[in] | alpha | Scalar value in the range [0.0f, 1.0f] |
[in,out] | accum | Accumulated tensor. Data type supported: U8. |
|
overridevirtual |
Execute the kernel on the passed window.
[in] | window | Region on which to execute the kernel. (Must be a region of the window returned by window()) |
Implements ICPPKernel.
Reimplemented in NEAccumulateWeightedFP16Kernel.