From b4af2c6738614850aaca3754904f0e8e3b17f0b2 Mon Sep 17 00:00:00 2001 From: Georgios Pinitas Date: Mon, 10 Dec 2018 18:45:35 +0000 Subject: COMPMID-1710: Fixes in StrideSlice calculations. Change-Id: I66eb922f1ff15142de278bf4439a61c979f98ba7 Reviewed-on: https://review.mlplatform.org/382 Reviewed-by: Matthew Bentham Tested-by: Arm Jenkins Reviewed-by: Pablo Marquez --- src/runtime/CL/functions/CLSlice.cpp | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) (limited to 'src/runtime/CL') diff --git a/src/runtime/CL/functions/CLSlice.cpp b/src/runtime/CL/functions/CLSlice.cpp index bef7eca71c..f630853fe3 100644 --- a/src/runtime/CL/functions/CLSlice.cpp +++ b/src/runtime/CL/functions/CLSlice.cpp @@ -36,10 +36,10 @@ void CLSlice::configure(const ICLTensor *input, ICLTensor *output, const Coordin ARM_COMPUTE_ERROR_ON_NULLPTR(input); // Get absolute end coordinates - const Coordinates ends_abs = arm_compute::helpers::tensor_transform::slice_absolute_end_coords(input->info()->tensor_shape(), ends); + const int32_t slice_end_mask = arm_compute::helpers::tensor_transform::construct_slice_end_mask(ends); auto k = arm_compute::support::cpp14::make_unique(); - k->configure(input, output, starts, ends_abs, BiStrides(), 0, 0, 0); + k->configure(input, output, starts, ends, BiStrides(), 0, slice_end_mask, 0); _kernel = std::move(k); } @@ -54,8 +54,8 @@ Status CLSlice::validate(const ITensorInfo *input, const ITensorInfo *output, co })); // Get absolute end coordinates - const Coordinates ends_abs = arm_compute::helpers::tensor_transform::slice_absolute_end_coords(input->tensor_shape(), ends); + const int32_t slice_end_mask = arm_compute::helpers::tensor_transform::construct_slice_end_mask(ends); - return CLStridedSliceKernel::validate(input, output, starts, ends_abs, BiStrides(), 0, 0, 0); + return CLStridedSliceKernel::validate(input, output, starts, ends, BiStrides(), 0, slice_end_mask, 0); } } // namespace arm_compute -- cgit v1.2.1