35 struct CLActivationLayer::Impl
37 const ICLTensor *
src{
nullptr };
38 ICLTensor *
dst{
nullptr };
39 CLRuntimeContext *ctx{
nullptr };
40 std::unique_ptr<opencl::ClActivation> op{
nullptr };
44 : _impl(
std::make_unique<Impl>())
62 _impl->dst = output ==
nullptr ?
input : output;
64 _impl->op = std::make_unique<opencl::ClActivation>();
65 _impl->op->configure(compile_context, _impl->src->info(), _impl->dst->info(), act_info);
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.
static CLKernelLibrary & get()
Access the KernelLibrary singleton.
Store the tensor's metadata.
void run() override
Run the kernels contained in the function.
Basic function to run opencl::kernels::ClActivationKernel.
Activation Layer Information class.
SimpleTensor< float > src
Copyright (c) 2017-2021 Arm Limited.
CLActivationLayer(CLRuntimeContext *ctx=nullptr)
Constructor.
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 of ClActivation.
CLActivationLayer & operator=(const CLActivationLayer &)=delete
Prevent instances of this class from being copied (As this class contains pointers) ...
Interface for OpenCL tensor.
void configure(ICLTensor *input, ICLTensor *output, ActivationLayerInfo act_info)
Set the input and output tensor.
#define ARM_COMPUTE_ERROR_ON_NULLPTR(...)
void add_tensor(int id, ITensor *tensor)
Add tensor to the pack.