66 const std::string
kernel_name = std::string(
"gaussian1x5_sub_x");
71 constexpr
unsigned int num_elems_read_per_iteration = 20;
72 constexpr
unsigned int num_elems_written_per_iteration = 8;
95 if((_input->info()->valid_region().anchor[0] + _input->info()->valid_region().shape[0]) % 2 == 0)
106 ICLKernel::configure_internal(win);
139 unsigned int idx = 0;
177 const std::string
kernel_name = std::string(
"gaussian5x1_sub_y");
178 _kernel =
create_kernel(compile_context,
"gaussian5x1_sub_y");
182 constexpr
unsigned int num_rows_processed_per_iteration = 2;
183 constexpr
unsigned int num_elems_written_per_iteration = 8;
184 constexpr
unsigned int num_elems_read_per_iteration = 8;
185 constexpr
unsigned int num_rows_per_iteration = 5;
196 if((_input->info()->valid_region().anchor[1] + _input->info()->valid_region().shape[1]) % 2 == 0)
198 _t2_load_offset += 1;
207 ICLKernel::configure_internal(win);
241 unsigned int idx = 0;
BorderSize border_size() const override
The size of the border for that kernel.
Window first_slice_window_2D() const
First 2D slice of the window.
unsigned int top
top of the border
void scale(size_t dimension, float scale_value)
Scale the values of a given dimension by the given scale_value.
Window calculate_max_window(const ValidRegion &valid_region, const Steps &steps, bool skip_border, BorderSize border_size)
const Window & window() const
The maximum window the kernel can be executed on.
void configure(const ICLTensor *input, ICLTensor *output)
Initialise the kernel's source, destination and border mode.
void enqueue(IGCKernel &kernel, const Window &window, const gles::NDRange &lws=gles::NDRange(1U, 1U, 1U))
Add the kernel to the command queue with the given window.
virtual size_t dimension(size_t index) const =0
Return the size of the requested dimension.
void shift(size_t dimension, int shift_value)
Shift the values of a given dimension by the given shift_value.
Container for 2D border size.
constexpr int step() const
Return the step of the dimension.
cl::NDRange lws_hint() const
Return the Local-Workgroup-Size hint.
1 channel, 1 U8 per channel
std::string to_string(T &&value)
Convert integer and float values to string.
virtual DataType data_type() const =0
Data type used for each element of the tensor.
#define ARM_COMPUTE_ERROR_ON(cond)
If the condition is true then an error message is printed and an exception thrown.
static CLKernelLibrary & get()
Access the KernelLibrary singleton.
1 channel, 1 U16 per channel
std::string lower_string(const std::string &val)
Lower a given string.
Window calculate_max_window_horizontal(const ValidRegion &valid_region, const Steps &steps, bool skip_border, BorderSize border_size)
bool slide_window_slice_2D(Window &slice) const
Slide the passed 2D window slice.
Copyright (c) 2017-2021 Arm Limited.
virtual void set_valid_region(const ValidRegion &valid_region)=0
Set the valid region of the tensor.
void configure(const ICLTensor *input, ICLTensor *output)
Initialise the kernel's source, destination and border mode.
Implementation of a rectangular access pattern.
cl::Kernel create_kernel(const CLCompileContext &ctx, const std::string &kernel_name, const std::set< std::string > &build_opts=std::set< std::string >())
Creates an opencl kernel using a compile context.
const std::string & string_from_data_type(DataType dt)
Convert a data type identity into a string.
static constexpr size_t DimX
Alias for dimension 0 also known as X dimension.
bool update_window_and_padding(Window &win, Ts &&... patterns)
Update window and padding size for each of the access patterns.
virtual const TensorShape & tensor_shape() const =0
Size for each dimension of the tensor.
Class to describe a number of elements in each dimension.
Implementation of a row access pattern.
virtual ITensorInfo * info() const =0
Interface to be implemented by the child class to return the tensor's metadata.
unsigned int left
left of the border
#define ARM_COMPUTE_ERROR_ON_UNCONFIGURED_KERNEL(k)
#define ARM_COMPUTE_ERROR_ON_DATA_TYPE_CHANNEL_NOT_IN(t, c,...)
void run(const Window &window, cl::CommandQueue &queue) override
Enqueue the OpenCL kernel to process the given window on the passed OpenCL command queue...
static constexpr size_t DimY
Alias for dimension 1 also known as Y dimension.
void add_2D_tensor_argument(unsigned int &idx, const ICLTensor *tensor, const Window &window)
Add the passed 2D tensor's parameters to the object's kernel's arguments starting from the index idx...
Interface for OpenCL tensor.
Manages all the OpenCL kernels compilation and caching, provides accessors for the OpenCL Context...
CLGaussianPyramidVertKernel()
Default constructor.
BorderSize border_size() const override
The size of the border for that kernel.
constexpr const Dimension & y() const
Alias to access the second dimension of the window.
unsigned int num_elems_processed_per_iteration
CLGaussianPyramidHorKernel()
Default constructor.
void run(const Window &window, cl::CommandQueue &queue) override
Enqueue the OpenCL kernel to process the given window on the passed OpenCL command queue...
Container for valid region of a window.
static constexpr size_t num_max_dimensions
Number of dimensions the tensor has.
Describe a multidimensional execution window.
#define ARM_COMPUTE_ERROR_ON_INVALID_SUBWINDOW(f, s)
constexpr const Dimension & x() const
Alias to access the first dimension of the window.