21.08
IKernel Class Reference

Common information for all the kernels. More...

#include <IKernel.h>

## Public Member Functions

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 Windowwindow () const
The maximum window the kernel can be executed on. More...

bool is_window_configured () const
Function to check if the embedded window of this kernel has been configured. More...

## Detailed Description

Common information for all the kernels.

Definition at line 33 of file IKernel.h.

## ◆ IKernel()

 IKernel ( )

Constructor.

Definition at line 33 of file IKernel.cpp.

References Window::DimX, Window::DimY, and Window::set().

34  : _window()
35 {
36  // Create an empty window to make sure the children classes set the window values themselves
37  _window.set(Window::DimX, Window::Dimension(0, 0, 1));
38  _window.set(Window::DimY, Window::Dimension(0, 0, 1));
39 }
Describe one of the image&#39;s dimensions with a start, end and step.
Definition: Window.h:77
static constexpr size_t DimX
Alias for dimension 0 also known as X dimension.
Definition: Window.h:43
void set(size_t dimension, const Dimension &dim)
Set the values of a given dimension.
Definition: Window.inl:49
static constexpr size_t DimY
Alias for dimension 1 also known as Y dimension.
Definition: Window.h:45

## ◆ ~IKernel()

 virtual ~IKernel ( )
virtualdefault

Destructor.

## ◆ border_size()

 BorderSize border_size ( ) const
virtual

The size of the border for that kernel.

Returns
The width in number of elements of the border.

Definition at line 46 of file IKernel.cpp.

47 {
48  return BorderSize(0);
49 }
Container for 2D border size.
Definition: Types.h:264

## ◆ is_parallelisable()

 bool is_parallelisable ( ) const
virtual

Indicates whether or not the kernel is parallelisable.

If the kernel is parallelisable then the window returned by window() can be split into sub-windows which can then be run in parallel.

If the kernel is not parallelisable then only the window returned by window() can be passed to run()

Returns
True if the kernel is parallelisable

Definition at line 41 of file IKernel.cpp.

42 {
43  return true;
44 }

## ◆ is_window_configured()

 bool is_window_configured ( ) const

Function to check if the embedded window of this kernel has been configured.

Returns
True if the windows has been configured

Definition at line 51 of file IKernel.cpp.

Referenced by arm_compute::error_on_unconfigured_kernel().

52 {
53  return !((_window.x().start() == _window.x().end()) && (_window.x().end() == 0));
54 }
constexpr int end() const
Return the end of the dimension.
Definition: Window.h:99
constexpr int start() const
Return the start of the dimension.
Definition: Window.h:94
constexpr const Dimension & x() const
Alias to access the first dimension of the window.
Definition: Window.h:145

## ◆ window()

The documentation for this class was generated from the following files: