23.08
|
Go to the documentation of this file.
36 struct CLActivationLayer::Impl
38 const ICLTensor *
src{
nullptr };
39 ICLTensor *
dst{
nullptr };
40 CLRuntimeContext *ctx{
nullptr };
41 std::unique_ptr<opencl::ClActivation> op{
nullptr };
45 : _impl(std::make_unique<Impl>())
63 _impl->dst = output ==
nullptr ?
input : output;
65 _impl->op = std::make_unique<opencl::ClActivation>();
66 _impl->op->configure(compile_context, _impl->src->info(), _impl->dst->info(),
act_info);
SimpleTensor< float > src
CLActivationLayer(CLRuntimeContext *ctx=nullptr)
Constructor.
Interface for OpenCL tensor.
void configure(ICLTensor *input, ICLTensor *output, ActivationLayerInfo act_info)
Set the input and output tensor.
void add_tensor(int id, ITensor *tensor)
Add tensor to the pack.
static CLKernelLibrary & get()
Access the KernelLibrary singleton.
Activation Layer Information class.
#define ARM_COMPUTE_ERROR_ON_NULLPTR(...)
static Status validate(const ITensorInfo *src, const ITensorInfo *dst, const ActivationLayerInfo &act_info)
Static function to check if given info will lead to a valid configuration.
static Status validate(const ITensorInfo *input, const ITensorInfo *output, const ActivationLayerInfo &act_info)
Static function to check if given info will lead to a valid configuration of CLActivationLayer.
~CLActivationLayer()
Destructor.
CLActivationLayer & operator=(const CLActivationLayer &)=delete
Prevent instances of this class from being copied (As this class contains pointers)
Copyright (c) 2017-2023 Arm Limited.
void run() override
Run the kernels contained in the function.
Store the tensor's metadata.
Basic function to run opencl::kernels::ClActivationKernel.