aboutsummaryrefslogtreecommitdiff
path: root/src/core/CL/cl_kernels/nchw/normalization_layer.cl
diff options
context:
space:
mode:
authorSiCongLi <sicong.li@arm.com>2021-08-26 17:44:08 +0100
committerSiCong Li <sicong.li@arm.com>2021-09-03 09:45:37 +0000
commitaed61f2a14199fd54b8f7b0af9980689921fc0cc (patch)
tree0020bfc4a36add3a3547674af4abe1dc3fa730ba /src/core/CL/cl_kernels/nchw/normalization_layer.cl
parent50335fd3d0734157382741fcf1bfdaf630c60c4b (diff)
downloadComputeLibrary-aed61f2a14199fd54b8f7b0af9980689921fc0cc.tar.gz
Fix CLNormalizationLayer NCHW border calculation
* Calculate border using both norm size and vec_size_x * Expose reference tensor printer Resolves: COMPMID-4793 Change-Id: I7bd8e49779baf7d6848271757bc7993aa1ed2960 Signed-off-by: SiCongLi <sicong.li@arm.com> Reviewed-on: https://review.mlplatform.org/c/ml/ComputeLibrary/+/6201 Reviewed-by: Michele Di Giorgio <michele.digiorgio@arm.com> Reviewed-by: Giorgio Arena <giorgio.arena@arm.com> Comments-Addressed: Arm Jenkins <bsgcomp@arm.com> Tested-by: Arm Jenkins <bsgcomp@arm.com>
Diffstat (limited to 'src/core/CL/cl_kernels/nchw/normalization_layer.cl')
-rw-r--r--src/core/CL/cl_kernels/nchw/normalization_layer.cl5
1 files changed, 2 insertions, 3 deletions
diff --git a/src/core/CL/cl_kernels/nchw/normalization_layer.cl b/src/core/CL/cl_kernels/nchw/normalization_layer.cl
index 0fef98e295..deada49db5 100644
--- a/src/core/CL/cl_kernels/nchw/normalization_layer.cl
+++ b/src/core/CL/cl_kernels/nchw/normalization_layer.cl
@@ -134,9 +134,8 @@ __kernel void normalization_layer_in_map_nchw(TENSOR3D_DECLARATION(input),
const VEC_DATA_TYPE(DATA_TYPE, VEC_SIZE)
kappa_v = SQCVT_SAT(KAPPA);
- const int current_col = get_global_id(0) << 2;
- const int left_pos = max(-(int)RADIUS, -3 - current_col);
- const int right_pos = min((int)RADIUS, (int)WIDTH_SIZE - 1 - current_col);
+ const int left_pos = -(int)RADIUS;
+ const int right_pos = (int)RADIUS;
#if defined(IN_MAP_2D)
const int current_row = get_global_id(1);