From 77b8859688c333bca35ebc8ca4d0b2652f480c4a Mon Sep 17 00:00:00 2001 From: Manuel Bottini Date: Mon, 4 May 2020 18:42:32 +0100 Subject: COMPMID-3443: Android R CTS 1.3 QASYMM8_SIGNED failure with MEAN on CpuAcc - Properly perform the division of the sum of the elements by the interested dimension of the tensor Change-Id: I0a30be4e5e6cfc1bd24a17eb4307dd2acf98db3e Signed-off-by: Manuel Bottini Reviewed-on: https://review.mlplatform.org/c/ml/ComputeLibrary/+/3145 Tested-by: Arm Jenkins Comments-Addressed: Arm Jenkins Reviewed-by: Georgios Pinitas --- src/core/NEON/kernels/NEReductionOperationKernel.cpp | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-) (limited to 'src/core/NEON/kernels/NEReductionOperationKernel.cpp') diff --git a/src/core/NEON/kernels/NEReductionOperationKernel.cpp b/src/core/NEON/kernels/NEReductionOperationKernel.cpp index 9b8c971a35..afe58ed07d 100644 --- a/src/core/NEON/kernels/NEReductionOperationKernel.cpp +++ b/src/core/NEON/kernels/NEReductionOperationKernel.cpp @@ -724,14 +724,13 @@ struct RedOpX_quantized if(op == ReductionOperation::MEAN_SUM) { - res /= in_info.dimension(0); + res /= static_cast(in_info.dimension(0)); } else { // Subtract accumulated offsets res -= (in_info.dimension(0) - 1) * iq_info.offset; } - *reinterpret_cast(output.ptr()) = utils::cast::saturate_cast(res); } } -- cgit v1.2.1