aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorSang-Hoon Park <sang-hoon.park@arm.com>2020-02-12 13:10:02 +0000
committerSang-Hoon Park <sang-hoon.park@arm.com>2020-02-12 16:00:15 +0000
commitbbe4458f92585777198cbb34aef4c9b0998197c5 (patch)
tree223e9fd7a7a6d274ea4646fb62fe79f9c4e4a126
parent0082c366fc2db46ee2cb0e171c588dfc8f26ce73 (diff)
downloadComputeLibrary-bbe4458f92585777198cbb34aef4c9b0998197c5.tar.gz
COMPMID-3084: Fix padding value for Reduce MAX/MIN
The correct minimum/maximum values of QASYMM8 is used for padding. Change-Id: Ia54e886e5acfd9c1236459b34d445bdc16446e3e Signed-off-by: Sang-Hoon Park <sang-hoon.park@arm.com> Reviewed-on: https://review.mlplatform.org/c/ml/ComputeLibrary/+/2721 Comments-Addressed: Arm Jenkins <bsgcomp@arm.com> Reviewed-by: Michele Di Giorgio <michele.digiorgio@arm.com> Tested-by: Arm Jenkins <bsgcomp@arm.com>
-rw-r--r--src/runtime/CL/functions/CLReductionOperation.cpp4
-rw-r--r--src/runtime/NEON/functions/NEReductionOperation.cpp4
2 files changed, 4 insertions, 4 deletions
diff --git a/src/runtime/CL/functions/CLReductionOperation.cpp b/src/runtime/CL/functions/CLReductionOperation.cpp
index e04982a315..fc902c4dfa 100644
--- a/src/runtime/CL/functions/CLReductionOperation.cpp
+++ b/src/runtime/CL/functions/CLReductionOperation.cpp
@@ -268,7 +268,7 @@ void CLReductionOperation::configure(ICLTensor *input, ICLTensor *output, unsign
}
case DataType::QASYMM8:
{
- pixelValue = PixelValue(255, input->info()->data_type(), input->info()->quantization_info());
+ pixelValue = std::get<1>(get_min_max(input->info()->data_type()));
break;
}
case DataType::QASYMM8_SIGNED:
@@ -300,7 +300,7 @@ void CLReductionOperation::configure(ICLTensor *input, ICLTensor *output, unsign
}
case DataType::QASYMM8:
{
- pixelValue = PixelValue(0, input->info()->data_type(), input->info()->quantization_info());
+ pixelValue = std::get<0>(get_min_max(input->info()->data_type()));
break;
}
case DataType::QASYMM8_SIGNED:
diff --git a/src/runtime/NEON/functions/NEReductionOperation.cpp b/src/runtime/NEON/functions/NEReductionOperation.cpp
index 43205ef762..9d29ee007c 100644
--- a/src/runtime/NEON/functions/NEReductionOperation.cpp
+++ b/src/runtime/NEON/functions/NEReductionOperation.cpp
@@ -156,7 +156,7 @@ void NEReductionOperation::configure(ITensor *input, ITensor *output, unsigned i
}
case DataType::QASYMM8:
{
- pixelValue = PixelValue(255, input->info()->data_type(), input->info()->quantization_info());
+ pixelValue = std::get<1>(get_min_max(input->info()->data_type()));
break;
}
default:
@@ -182,7 +182,7 @@ void NEReductionOperation::configure(ITensor *input, ITensor *output, unsigned i
}
case DataType::QASYMM8:
{
- pixelValue = PixelValue(0, input->info()->data_type(), input->info()->quantization_info());
+ pixelValue = std::get<0>(get_min_max(input->info()->data_type()));
break;
}
default: