21.05
|
Basic function to run an opencl::kernels::ClConvertFullyConnectedWeightsKernel. More...
#include <CLConvertFullyConnectedWeights.h>
Public Member Functions | |
CLConvertFullyConnectedWeights () | |
Constructor. More... | |
~CLConvertFullyConnectedWeights () | |
Destructor. More... | |
CLConvertFullyConnectedWeights (const CLConvertFullyConnectedWeights &)=delete | |
Prevent instances of this class from being copied (As this class contains pointers) More... | |
CLConvertFullyConnectedWeights (CLConvertFullyConnectedWeights &&)=default | |
Default move constructor. More... | |
CLConvertFullyConnectedWeights & | operator= (const CLConvertFullyConnectedWeights &)=delete |
Prevent instances of this class from being copied (As this class contains pointers) More... | |
CLConvertFullyConnectedWeights & | operator= (CLConvertFullyConnectedWeights &&)=default |
Default move assignment operator. More... | |
void | configure (const ICLTensor *input, ICLTensor *output, const TensorShape &original_input_shape, DataLayout data_layout) |
Initialize the function. More... | |
void | configure (const CLCompileContext &compile_context, const ICLTensor *input, ICLTensor *output, const TensorShape &original_input_shape, DataLayout data_layout) |
Initialize the function. More... | |
void | run () override |
Run the kernels contained in the function. More... | |
Public Member Functions inherited from IFunction | |
virtual | ~IFunction ()=default |
Destructor. More... | |
virtual void | prepare () |
Prepare the function for executing. More... | |
Static Public Member Functions | |
static Status | validate (const ITensorInfo *input, const ITensorInfo *output, const TensorShape &original_input_shape, DataLayout data_layout) |
Static function to check if given info will lead to a valid configuration of CLConvertFullyConnectedWeights. More... | |
Basic function to run an opencl::kernels::ClConvertFullyConnectedWeightsKernel.
Definition at line 41 of file CLConvertFullyConnectedWeights.h.
Constructor.
Definition at line 41 of file CLConvertFullyConnectedWeights.cpp.
|
default |
Destructor.
|
delete |
Prevent instances of this class from being copied (As this class contains pointers)
|
default |
Default move constructor.
void configure | ( | const ICLTensor * | input, |
ICLTensor * | output, | ||
const TensorShape & | original_input_shape, | ||
DataLayout | data_layout | ||
) |
Initialize the function.
Valid data layouts:
Valid data type configurations:
src | dst |
---|---|
All | All |
[in] | input | Source weights tensor to convert. Must be 2 dimensional. Data types supported: All. |
[out] | output | The converted weights tensor. Shape and Data Type: Same as input . |
[in] | original_input_shape | Shape of the original input tensor (the one entering fully connected layer). |
[in] | data_layout | The data layout the weights have been trained in. |
Definition at line 47 of file CLConvertFullyConnectedWeights.cpp.
References arm_compute::test::validation::data_layout, CLKernelLibrary::get(), and arm_compute::test::validation::input.
Referenced by CLConvertFullyConnectedWeightsManaged::configure(), and CLFullyConnectedLayer::configure().
void configure | ( | const CLCompileContext & | compile_context, |
const ICLTensor * | input, | ||
ICLTensor * | output, | ||
const TensorShape & | original_input_shape, | ||
DataLayout | data_layout | ||
) |
Initialize the function.
[in] | compile_context | The compile context to be used. |
[in] | input | Source weights tensor to convert. Must be 2 dimensional. Data types supported: All. |
[out] | output | The converted weights tensor. Shape and Data Type: Same as input . |
[in] | original_input_shape | Shape of the original input tensor (the one entering fully connected layer). |
[in] | data_layout | The data layout the weights have been trained in. |
Definition at line 53 of file CLConvertFullyConnectedWeights.cpp.
References ARM_COMPUTE_ERROR_ON_NULLPTR, arm_compute::test::validation::data_layout, and arm_compute::test::validation::input.
|
delete |
Prevent instances of this class from being copied (As this class contains pointers)
|
default |
Default move assignment operator.
|
overridevirtual |
Run the kernels contained in the function.
For CPU kernels:
For OpenCL kernels:
Implements IFunction.
Definition at line 69 of file CLConvertFullyConnectedWeights.cpp.
References arm_compute::ACL_DST, arm_compute::ACL_SRC, and ITensorPack::add_tensor().
Referenced by CLFullyConnectedLayer::prepare(), and CLConvertFullyConnectedWeightsManaged::run().
|
static |
Static function to check if given info will lead to a valid configuration of CLConvertFullyConnectedWeights.
[in] | input | Source weights tensor info to convert. Must be 2 dimensional. Data types supported: All. |
[in] | output | The converted weights tensor info. Shape and Data Type: Same as input . |
[in] | original_input_shape | Shape of the original input tensor (the one entering fully connected layer). |
[in] | data_layout | The data layout the weights have been trained in. |
Definition at line 63 of file CLConvertFullyConnectedWeights.cpp.
References arm_compute::test::validation::data_layout, arm_compute::test::validation::input, and ClConvertFullyConnectedWeights::validate().
Referenced by CLFullyConnectedLayer::validate().