21.02
|
Basic function to run CLPixelWiseMultiplicationKernel. More...
#include <CLPixelWiseMultiplication.h>
Public Member Functions | |
CLPixelWiseMultiplication () | |
Default Constructor. More... | |
void | configure (const CLCompileContext &compile_context, ITensorInfo *input1, ITensorInfo *input2, ITensorInfo *output, float scale, ConvertPolicy overflow_policy, RoundingPolicy rounding_policy, const ActivationLayerInfo &act_info=ActivationLayerInfo()) |
Initialise the kernel's inputs, output and convertion policy. More... | |
void | run (ITensorPack &tensors) override |
Run the kernels contained in the function. More... | |
Public Member Functions inherited from ICLOperator | |
ICLOperator (IRuntimeContext *ctx=nullptr) | |
Constructor. More... | |
ICLOperator (const ICLOperator &)=delete | |
Prevent instances of this class from being copied (As this class contains pointers) More... | |
ICLOperator (ICLOperator &&)=default | |
Default move constructor. More... | |
ICLOperator & | operator= (const ICLOperator &)=delete |
Prevent instances of this class from being copied (As this class contains pointers) More... | |
ICLOperator & | operator= (ICLOperator &&)=default |
Default move assignment operator. More... | |
void | run (ITensorPack &tensors) override |
Run the kernels contained in the function. More... | |
void | prepare (ITensorPack &constants) override |
Prepare the function for executing. More... | |
MemoryRequirements | workspace () const override |
Return the memory requirements required by the workspace. More... | |
Public Member Functions inherited from IOperator | |
virtual | ~IOperator ()=default |
Destructor. More... | |
Static Public Member Functions | |
static Status | validate (const ITensorInfo *input1, const ITensorInfo *input2, const ITensorInfo *output, float scale, ConvertPolicy overflow_policy, RoundingPolicy rounding_policy, const ActivationLayerInfo &act_info=ActivationLayerInfo()) |
Static function to check if given info will lead to a valid configuration of CLPixelWiseMultiplication. More... | |
Basic function to run CLPixelWiseMultiplicationKernel.
Definition at line 41 of file CLPixelWiseMultiplication.h.
Default Constructor.
Definition at line 57 of file CLPixelWiseMultiplication.cpp.
void configure | ( | const CLCompileContext & | compile_context, |
ITensorInfo * | input1, | ||
ITensorInfo * | input2, | ||
ITensorInfo * | output, | ||
float | scale, | ||
ConvertPolicy | overflow_policy, | ||
RoundingPolicy | rounding_policy, | ||
const ActivationLayerInfo & | act_info = ActivationLayerInfo() |
||
) |
Initialise the kernel's inputs, output and convertion policy.
Valid configurations (Input1,Input2) -> Output :
[in] | compile_context | The compile context to be used. |
[in,out] | input1 | An input tensor. Data types supported: U8/QASYMM8/QASYMM8_SIGNED/S16/QSYMM16/F16/F32. The input tensor is [in, out] because its TensorInfo might be modified inside the kernel in case of broadcasting of dimension 0. |
[in,out] | input2 | An input tensor. Data types supported: U8/QASYMM8/QASYMM8_SIGNED/S16/QSYMM16/F16/F32. The input tensor is [in, out] because its TensorInfo might be modified inside the kernel in case of broadcasting of dimension 0. |
[out] | output | The output tensor. Data types supported: U8/QASYMM8/QASYMM8_SIGNED/S16/QSYMM16/F16/F32. |
[in] | scale | Scale to apply after multiplication. Scale must be positive and its value must be either 1/255 or 1/2^n where n is between 0 and 15. |
[in] | overflow_policy | Overflow policy. Supported overflow policies: Wrap, Saturate |
[in] | rounding_policy | Rounding policy. Supported rounding modes: to zero, to nearest even. |
[in] | act_info | (Optional) Activation layer information in case of a fused activation. |
Definition at line 62 of file CLPixelWiseMultiplication.cpp.
References ITensorInfo::dimension(), and arm_compute::REPLICATE.
|
overridevirtual |
Run the kernels contained in the function.
[in] | tensors | Vector that contains the tensors to operate on. |
Implements IOperator.
Definition at line 86 of file CLPixelWiseMultiplication.cpp.
References CLScheduler::enqueue_op(), CLScheduler::get(), and ICLOperator::run().
|
static |
Static function to check if given info will lead to a valid configuration of CLPixelWiseMultiplication.
Valid configurations (Input1,Input2) -> Output :
[in] | input1 | An input tensor info. Data types supported: U8/QASYMM8/QASYMM8_SIGNED/S16/QSYMM16/F16/F32. |
[in] | input2 | An input tensor info. Data types supported: U8/QASYMM8/QASYMM8_SIGNED/S16/QSYMM16/F16/F32. |
[in] | output | The output tensor info. Data types supported: U8/QASYMM8/QASYMM8_SIGNED/S16/QSYMM16/F16/F32. |
[in] | scale | Scale to apply after multiplication. Scale must be positive and its value must be either 1/255 or 1/2^n where n is between 0 and 15. |
[in] | overflow_policy | Overflow policy. Supported overflow policies: Wrap, Saturate |
[in] | rounding_policy | Rounding policy. Supported rounding modes: to zero, to nearest even. |
[in] | act_info | (Optional) Activation layer information in case of a fused activation. |
Definition at line 80 of file CLPixelWiseMultiplication.cpp.
References CLPixelWiseMultiplicationKernel::validate().
Referenced by CLPixelWiseMultiplication::validate().