21.02
|
Neon kernel to perform the in-place matrix addition between 2 matrices taking into account that the second matrix might be weighted by a scalar value beta: More...
#include <NEGEMMMatrixAdditionKernel.h>
Public Member Functions | |
const char * | name () const override |
Name of the kernel. More... | |
NEGEMMMatrixAdditionKernel () | |
Constructor. More... | |
NEGEMMMatrixAdditionKernel (const NEGEMMMatrixAdditionKernel &)=delete | |
Prevent instances of this class from being copied. More... | |
NEGEMMMatrixAdditionKernel & | operator= (const NEGEMMMatrixAdditionKernel &)=delete |
Prevent instances of this class from being copied. More... | |
NEGEMMMatrixAdditionKernel (NEGEMMMatrixAdditionKernel &&)=default | |
Allow instances of this class to be moved. More... | |
NEGEMMMatrixAdditionKernel & | operator= (NEGEMMMatrixAdditionKernel &&)=default |
Allow instances of this class to be moved. More... | |
~NEGEMMMatrixAdditionKernel ()=default | |
Default destructor. More... | |
void | configure (const ITensor *input, ITensor *output, float beta) |
Initialise the kernel's input and output. More... | |
void | run (const Window &window, const ThreadInfo &info) 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... | |
virtual void | run_nd (const Window &window, const ThreadInfo &info, const Window &thread_locator) |
legacy compatibility layer for implemantions which do not support thread_locator In these cases we simply narrow the interface down the legacy version More... | |
virtual void | run_op (ITensorPack &tensors, const Window &window, const ThreadInfo &info) |
Execute the kernel on the passed window. 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... | |
Static Public Member Functions | |
static Status | validate (const ITensorInfo *input, const ITensorInfo *output, float beta) |
Static function to check if given info will lead to a valid configuration of NEGEMMMatrixAdditionKernel. More... | |
Neon kernel to perform the in-place matrix addition between 2 matrices taking into account that the second matrix might be weighted by a scalar value beta:
Definition at line 41 of file NEGEMMMatrixAdditionKernel.h.
Constructor.
Definition at line 113 of file NEGEMMMatrixAdditionKernel.cpp.
Referenced by NEGEMMMatrixAdditionKernel::name().
|
delete |
Prevent instances of this class from being copied.
|
default |
Allow instances of this class to be moved.
|
default |
Default destructor.
Referenced by NEGEMMMatrixAdditionKernel::name().
Initialise the kernel's input and output.
[in] | input | Input tensor (Matrix C). Data types supported: F16/F32 |
[in,out] | output | Output tensor. If this kernel is used to finalize the GEMM result, output contains the result obtained by the kernel NEGEMMMatrixMultiplyKernel. Data type supported: the same as input . |
[in] | beta | Weight of matrix C |
Definition at line 118 of file NEGEMMMatrixAdditionKernel.cpp.
References ARM_COMPUTE_ERROR, ARM_COMPUTE_ERROR_ON_NULLPTR, ARM_COMPUTE_ERROR_THROW_ON, ITensorInfo::data_type(), arm_compute::F16, arm_compute::F32, ITensor::info(), and arm_compute::validate_arguments().
Referenced by NEGEMMMatrixAdditionKernel::name().
|
inlineoverridevirtual |
Name of the kernel.
Implements ICPPKernel.
Definition at line 44 of file NEGEMMMatrixAdditionKernel.h.
References NEGEMMMatrixAdditionKernel::configure(), arm_compute::test::validation::info, arm_compute::test::validation::input, NEGEMMMatrixAdditionKernel::NEGEMMMatrixAdditionKernel(), NEGEMMMatrixAdditionKernel::operator=(), NEGEMMMatrixAdditionKernel::run(), NEGEMMMatrixAdditionKernel::validate(), IKernel::window(), and NEGEMMMatrixAdditionKernel::~NEGEMMMatrixAdditionKernel().
|
delete |
Prevent instances of this class from being copied.
Referenced by NEGEMMMatrixAdditionKernel::name().
|
default |
Allow instances of this class to be moved.
|
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()) |
[in] | info | Info about executing thread and CPU. |
Reimplemented from ICPPKernel.
Definition at line 153 of file NEGEMMMatrixAdditionKernel.cpp.
References ARM_COMPUTE_ERROR_ON_INVALID_SUBWINDOW, ARM_COMPUTE_ERROR_ON_UNCONFIGURED_KERNEL, ARM_COMPUTE_UNUSED, and IKernel::window().
Referenced by NEGEMMMatrixAdditionKernel::name().
|
static |
Static function to check if given info will lead to a valid configuration of NEGEMMMatrixAdditionKernel.
[in] | input | Input tensor info (Matrix C). Data types supported: F16/F32 |
[in] | output | Output tensor info. If this kernel is used to finalize the GEMM result, output contains the result obtained by the kernel NEGEMMMatrixMultiplyKernel. Data type supported: the same as input . |
[in] | beta | Weight of matrix C |
Definition at line 146 of file NEGEMMMatrixAdditionKernel.cpp.
References ARM_COMPUTE_RETURN_ON_ERROR, ICloneable< T >::clone(), num_elems_processed_per_iteration, and arm_compute::validate_arguments().
Referenced by NEGEMMMatrixAdditionKernel::name(), and NEGEMM::validate().