30 output = 1.f / (1.f + expf(-in));
35 output = std::max(0.f, in);
40 output = std::min(a, std::max(b, in));
45 output = logf(1.0f + expf(in));
50 output = in > 0.0f ? in : (in * a);
55 output = in < 0 ? -in : in;
70 output = a * tanhf(b * in);
75 output = (in >= 0) ? in : a * (expf(in) - 1);
82 output = in * (std::min(std::max((in + 3),0.0f),6.0f)) / 6;
104 for (
unsigned int i = 0; i < numElements; i++)
virtual void Set(IType right)=0
Copyright (c) 2020 ARM Limited.
virtual IType Get() const =0
float Activation(float in, ActivationFunction function, float a, float b)
min(a, max(b, input)) ReLu1 & ReLu6.
unsigned int GetNumElements() const