aboutsummaryrefslogtreecommitdiff
path: root/src/core/NEON/kernels/NEActivationLayerKernel.cpp
diff options
context:
space:
mode:
authorGeorgios Pinitas <georgios.pinitas@arm.com>2019-01-16 12:54:29 +0000
committerGeorgios Pinitas <georgios.pinitas@arm.com>2019-01-16 17:07:49 +0000
commit57016a419c89e737216fd12711e6eba7e030061e (patch)
treeb0ec19f51ed99292e16871231680b4fef2019012 /src/core/NEON/kernels/NEActivationLayerKernel.cpp
parent44b4e974590f1a6a07b235f203006cc9010b37e8 (diff)
downloadComputeLibrary-57016a419c89e737216fd12711e6eba7e030061e.tar.gz
COMPMID-1710: Fixes substitution errors in bare_metal build.
Change-Id: Icf76503b4d01e90a682b9bed0798a8a635840e46 Reviewed-on: https://review.mlplatform.org/528 Reviewed-by: Michalis Spyrou <michalis.spyrou@arm.com> Tested-by: Arm Jenkins <bsgcomp@arm.com>
Diffstat (limited to 'src/core/NEON/kernels/NEActivationLayerKernel.cpp')
-rw-r--r--src/core/NEON/kernels/NEActivationLayerKernel.cpp6
1 files changed, 3 insertions, 3 deletions
diff --git a/src/core/NEON/kernels/NEActivationLayerKernel.cpp b/src/core/NEON/kernels/NEActivationLayerKernel.cpp
index 97cb9ceb2e..7565a1214c 100644
--- a/src/core/NEON/kernels/NEActivationLayerKernel.cpp
+++ b/src/core/NEON/kernels/NEActivationLayerKernel.cpp
@@ -371,17 +371,17 @@ typename std::enable_if<std::is_same<T, qasymm8_t>::value, void>::type NEActivat
if(act == ActivationFunction::RELU)
{
tmp = std::max(const_0, in);
- tmp = std::max(0, std::min(static_cast<int32_t>(tmp * s + o), 255));
+ tmp = std::max<int32_t>(0, std::min<int32_t>(tmp * s + o, 255));
}
else if(act == ActivationFunction::BOUNDED_RELU)
{
tmp = std::min(a, std::max(const_0, in));
- tmp = std::max(0, std::min(static_cast<int32_t>(tmp * s + o), 255));
+ tmp = std::max<int32_t>(0, std::min<int32_t>(tmp * s + o, 255));
}
else if(act == ActivationFunction::LU_BOUNDED_RELU)
{
tmp = std::min(a, std::max(b, in));
- tmp = std::max(0, std::min(static_cast<int32_t>(tmp * s + o), 255));
+ tmp = std::max<int32_t>(0, std::min<int32_t>(tmp * s + o, 255));
}
else
{