24.02.1
|
Depthwise convolution assembly kernel glue. More...
#include <CpuDepthwiseConv2dAssemblyDispatch.h>
Public Member Functions | |
CpuDepthwiseConv2dAssemblyDispatch () | |
ARM_COMPUTE_DISALLOW_COPY_ALLOW_MOVE (CpuDepthwiseConv2dAssemblyDispatch) | |
~CpuDepthwiseConv2dAssemblyDispatch () | |
void | configure (const ITensorInfo *src, const ITensorInfo *weights, const ITensorInfo *bias, ITensorInfo *dst, const ConvolutionInfo &info) |
Initialize the function's source, destination, kernels and border_size. More... | |
void | run (ITensorPack &tensors) override |
Run the kernels contained in the function. More... | |
void | prepare (ITensorPack &tensors) override |
Prepare the function for executing. More... | |
experimental::MemoryRequirements | workspace () const override |
Return the memory requirements required by the workspace. More... | |
Public Member Functions inherited from INEOperator | |
INEOperator (IRuntimeContext *ctx=nullptr) | |
Constructor. More... | |
INEOperator (const INEOperator &)=delete | |
Prevent instances of this class from being copied (As this class contains pointers) More... | |
INEOperator (INEOperator &&)=default | |
Default move constructor. More... | |
INEOperator & | operator= (const INEOperator &)=delete |
Prevent instances of this class from being copied (As this class contains pointers) More... | |
INEOperator & | operator= (INEOperator &&)=default |
Default move assignment operator. More... | |
~INEOperator () | |
Default destructor. More... | |
Public Member Functions inherited from IOperator | |
virtual | ~IOperator ()=default |
Destructor. More... | |
Static Public Member Functions | |
static Status | validate (const ITensorInfo *src, const ITensorInfo *weights, const ITensorInfo *bias, const ITensorInfo *dst, const ConvolutionInfo &info) |
Static function to check if given info will lead to a valid configuration. More... | |
static bool | is_activation_supported (const ActivationLayerInfo &activation) |
Checks if activation is supported by the assembly kernels. More... | |
Depthwise convolution assembly kernel glue.
Definition at line 39 of file CpuDepthwiseConv2dAssemblyDispatch.h.
|
default |
ARM_COMPUTE_DISALLOW_COPY_ALLOW_MOVE | ( | CpuDepthwiseConv2dAssemblyDispatch | ) |
void configure | ( | const ITensorInfo * | src, |
const ITensorInfo * | weights, | ||
const ITensorInfo * | bias, | ||
ITensorInfo * | dst, | ||
const ConvolutionInfo & | info | ||
) |
Initialize the function's source, destination, kernels and border_size.
[in] | src | Source tensor info. Data type supported: QASYMM8/QASYMM8_SIGNED/F16/F32. |
[in] | weights | Weights tensor info. These are 3D tensors with shape [W, H, IFM]. Data type supported: same as src or QASYMM8/QASYMM8_SIGNED/QSYMM8_PER_CHANNEL when src is QASYMM8/QASYMM8_SIGNED. |
[in] | bias | (Optional) Biases tensor info. A 1D tensor with shape [IFM]. Must be nullptr if not needed. Data type supported: same as src or S32 if src is quantized. |
[out] | dst | Destination tensor info. Data type supported: same as src . |
[in] | info | Depthwise convolution meta-data. |
Definition at line 56 of file CpuDepthwiseConv2dAssemblyDispatch.cpp.
References arm_compute::ACL_INT_0, arm_compute::ACL_INT_1, ITensorInfo::are_values_constant(), ARM_COMPUTE_ERROR_ON, ARM_COMPUTE_LOG_PARAMS, bias, ci, IScheduler::cpu_info(), arm_compute::test::validation::dst, Scheduler::get(), arm_compute::test::validation::info, IScheduler::num_threads(), arm_compute::test::validation::src, and CpuDepthwiseConv2dAssemblyDispatch::validate().
|
static |
Checks if activation is supported by the assembly kernels.
[in] | activation | Activation to check |
Definition at line 99 of file CpuDepthwiseConv2dAssemblyDispatch.cpp.
References arm_compute::assembly_utils::map_to_arm_gemm_activation(), Activation::None, and Activation::type.
|
overridevirtual |
Prepare the function for executing.
Any one off pre-processing step required by the function is handled here
[in] | constants | Vector that contains the constants tensors. |
Reimplemented from INEOperator.
Definition at line 118 of file CpuDepthwiseConv2dAssemblyDispatch.cpp.
References arm_compute::ACL_INT_1, arm_compute::ACL_SRC_1, arm_compute::ACL_SRC_2, bias, ITensor::buffer(), ITensorPack::get_const_tensor(), ITensorPack::get_tensor(), ITensor::info(), BorderSize::left, ITensor::mark_as_unused(), ITensorInfo::offset_first_element_in_bytes(), ITensorInfo::padding(), and ITensorInfo::tensor_shape().
Referenced by CpuDepthwiseConv2dAssemblyDispatch::run().
|
overridevirtual |
Run the kernels contained in the function.
[in] | tensors | Vector that contains the tensors to operate on. |
Reimplemented from INEOperator.
Definition at line 105 of file CpuDepthwiseConv2dAssemblyDispatch.cpp.
References ARM_COMPUTE_ERROR_ON_MSG, Window::DimW, Window::DimZ, ITensorPack::empty(), Scheduler::get(), CpuDepthwiseConv2dAssemblyDispatch::prepare(), and IScheduler::schedule_op().
|
static |
Static function to check if given info will lead to a valid configuration.
Similar to CpuDepthwiseConv2dAssemblyDispatch::configure()
Definition at line 85 of file CpuDepthwiseConv2dAssemblyDispatch.cpp.
References bias, arm_compute::test::validation::dst, arm_compute::test::validation::info, arm_compute::test::validation::src, and CpuDepthwiseConv2dAssemblyWrapperKernel::validate().
Referenced by CpuDepthwiseConv2dAssemblyDispatch::configure().
|
overridevirtual |
Return the memory requirements required by the workspace.
Reimplemented from INEOperator.
Definition at line 94 of file CpuDepthwiseConv2dAssemblyDispatch.cpp.