From 4a626a7d52e9c4759bdc16b65401a53779dd975f Mon Sep 17 00:00:00 2001 From: Pablo Tello Date: Wed, 4 Apr 2018 10:01:14 +0100 Subject: COMPMID-801: NHWC support in CLIm2Col. And extended tests coverage adding kernel shapes 3x1, 1x5 and 7x7 Change-Id: Ia7c1d4da2368d5f5fbc1a41187f4ac1aca5f150f Reviewed-on: https://eu-gerrit-1.euhpc.arm.com/127727 Tested-by: Jenkins Reviewed-by: Gian Marco Iodice --- arm_compute/core/CL/kernels/CLIm2ColKernel.h | 17 +++++++++++++++++ 1 file changed, 17 insertions(+) (limited to 'arm_compute/core/CL/kernels/CLIm2ColKernel.h') diff --git a/arm_compute/core/CL/kernels/CLIm2ColKernel.h b/arm_compute/core/CL/kernels/CLIm2ColKernel.h index 45111fcedd..7e119a32a8 100644 --- a/arm_compute/core/CL/kernels/CLIm2ColKernel.h +++ b/arm_compute/core/CL/kernels/CLIm2ColKernel.h @@ -110,6 +110,23 @@ private: */ void run_generic(const Window &window, cl::CommandQueue &queue); + /** Chooses and configure the right kernel for the given input arguments. + * + * @param[in] input The input tensor to convert. 3 lower dimensions represent a single input [width, height, IFM], + * while every optional dimension from 4 and above represent a batch of inputs. Data types supported: QS8/QASYMM8/QS16/F16/F32 + * @param[in] output The output tensor. First 2 lower dimensions represent a transform of each 3D input, + * while every dimension above represents a batch. Data types supported: Same as @p input + * @param[in] kernel_dims The kernel dimensions (width and height). + * @param[in] dilation Dilation, in elements, across x and y. Defaults to (1, 1). + * @param[in] conv_info Contains padding and stride information described in @ref PadStrideInfo. + * @param[in] has_bias In case biases are provided expands the matrix with 1. + * @param[out] build_opts OpenCL buil program options. + * + * @return the name of the kernel chosen + */ + std::string configure_window(const ICLTensor *input, ICLTensor *output, const Size2D &kernel_dims, + const Size2D &dilation, const PadStrideInfo &conv_info, CLBuildOptions &build_opts); + /** Common signature for the kernel to run */ using Im2ColFunction = void (CLIm2ColKernel::*)(const Window &, cl::CommandQueue &); -- cgit v1.2.1