diff options
author | Georgios Pinitas <georgios.pinitas@arm.com> | 2019-08-22 17:10:04 +0100 |
---|---|---|
committer | Georgios Pinitas <georgios.pinitas@arm.com> | 2019-08-23 11:03:19 +0000 |
commit | fb0fdcdaec57e6f8e1b96f924411921cc0ba6d94 (patch) | |
tree | 99dc659420ea76dc4fbf6724e1140467249ad105 /src/core/CL/cl_kernels | |
parent | c8530210c17b391f27ace95523e9590e8166fcd8 (diff) | |
download | ComputeLibrary-fb0fdcdaec57e6f8e1b96f924411921cc0ba6d94.tar.gz |
COMPMID-2460: Add ELU activation on NEON,CL,GLES
Change-Id: I641b12fcfc5dc4a18d2d489c38673b937125dfb9
Signed-off-by: Georgios Pinitas <georgios.pinitas@arm.com>
Reviewed-on: https://review.mlplatform.org/c/1796
Tested-by: Arm Jenkins <bsgcomp@arm.com>
Reviewed-by: Michele Di Giorgio <michele.digiorgio@arm.com>
Comments-Addressed: Arm Jenkins <bsgcomp@arm.com>
Diffstat (limited to 'src/core/CL/cl_kernels')
-rw-r--r-- | src/core/CL/cl_kernels/activation_float_helpers.h | 3 |
1 files changed, 3 insertions, 0 deletions
diff --git a/src/core/CL/cl_kernels/activation_float_helpers.h b/src/core/CL/cl_kernels/activation_float_helpers.h index 2efd2699d7..0c82f83dbc 100644 --- a/src/core/CL/cl_kernels/activation_float_helpers.h +++ b/src/core/CL/cl_kernels/activation_float_helpers.h @@ -50,6 +50,9 @@ // Soft RELU Activation #define srelu_op(DATA_TYPE, x, A_VAL, B_VAL) (log((DATA_TYPE)1.0 + exp(x))) +// ELU Activation +#define elu_op(DATA_TYPE, x, A_VAL, B_VAL) (select(((DATA_TYPE)A_VAL * (exp(x) - (DATA_TYPE)1.0)), x, isgreaterequal(x, (DATA_TYPE)0.0))) + // Absolute Activation #define abs_op(DATA_TYPE, x, A_VAL, B_VAL) (fabs(x)) |