From 6528aa20e768f2d801328aa164d672b7fdfe266f Mon Sep 17 00:00:00 2001 From: Georgios Pinitas Date: Thu, 15 Mar 2018 18:02:21 +0000 Subject: COMPMID-959: Set output valid region to CLPermuteKernel. Change-Id: Ieb62347c71cef5ac8941e632c8afa678f5db6f21 Reviewed-on: https://eu-gerrit-1.euhpc.arm.com/124813 Reviewed-by: Anthony Barbier Tested-by: Jenkins --- src/core/CL/kernels/CLPermuteKernel.cpp | 5 +++++ src/core/SubTensorInfo.cpp | 1 + 2 files changed, 6 insertions(+) diff --git a/src/core/CL/kernels/CLPermuteKernel.cpp b/src/core/CL/kernels/CLPermuteKernel.cpp index da34448c02..02fc667aee 100644 --- a/src/core/CL/kernels/CLPermuteKernel.cpp +++ b/src/core/CL/kernels/CLPermuteKernel.cpp @@ -114,6 +114,11 @@ void CLPermuteKernel::configure(const ICLTensor *input, ICLTensor *output, const // Configure kernel window Window win = calculate_max_window(*input->info(), Steps()); + // The CLPermute doesn't need padding so update_window_and_padding() can be skipped + Coordinates coord; + coord.set_num_dimensions(output->info()->num_dimensions()); + output->info()->set_valid_region(ValidRegion(coord, output->info()->tensor_shape())); + ICLKernel::configure(win); } diff --git a/src/core/SubTensorInfo.cpp b/src/core/SubTensorInfo.cpp index 836c3794c2..237f1333f2 100644 --- a/src/core/SubTensorInfo.cpp +++ b/src/core/SubTensorInfo.cpp @@ -100,6 +100,7 @@ ITensorInfo &SubTensorInfo::set_tensor_shape(const TensorShape &shape) if(_parent->tensor_shape().total_size() != 0 && !_extend_parent) { ARM_COMPUTE_ERROR_ON_INVALID_SUBTENSOR(_parent->tensor_shape(), _coords, shape); + _valid_region = ValidRegion{ _coords, shape }; } else if(_extend_parent) // Extend parent shape, configure if specified { -- cgit v1.2.1