diff options
author | Michele Di Giorgio <michele.digiorgio@arm.com> | 2021-01-28 12:51:02 +0000 |
---|---|---|
committer | Michele Di Giorgio <michele.digiorgio@arm.com> | 2021-02-01 08:46:01 +0000 |
commit | 655e8c6334580a570008243af1896d269fdd60ad (patch) | |
tree | 18f5e6e5cc9148a1afcc54c8c6ac54620242bc6d /src/runtime/CL/functions/CLScale.cpp | |
parent | cc438f23e206d9b5bb55e491b97fbc9b0962dabc (diff) | |
download | ComputeLibrary-655e8c6334580a570008243af1896d269fdd60ad.tar.gz |
Make data_layout an attribute of the Scale function
Resolves COMPMID-4208
Change-Id: I61ca670134a005462ad0528a5aff9507a90860e7
Signed-off-by: Michele Di Giorgio <michele.digiorgio@arm.com>
Reviewed-on: https://review.mlplatform.org/c/ml/ComputeLibrary/+/4942
Tested-by: Arm Jenkins <bsgcomp@arm.com>
Reviewed-by: Georgios Pinitas <georgios.pinitas@arm.com>
Comments-Addressed: Arm Jenkins <bsgcomp@arm.com>
Diffstat (limited to 'src/runtime/CL/functions/CLScale.cpp')
-rw-r--r-- | src/runtime/CL/functions/CLScale.cpp | 5 |
1 files changed, 3 insertions, 2 deletions
diff --git a/src/runtime/CL/functions/CLScale.cpp b/src/runtime/CL/functions/CLScale.cpp index aab5d9ba73..9862d0a1b3 100644 --- a/src/runtime/CL/functions/CLScale.cpp +++ b/src/runtime/CL/functions/CLScale.cpp @@ -1,5 +1,5 @@ /* - * Copyright (c) 2016-2020 Arm Limited. + * Copyright (c) 2016-2021 Arm Limited. * * SPDX-License-Identifier: MIT * @@ -50,7 +50,8 @@ void CLScale::configure(const CLCompileContext &compile_context, ICLTensor *inpu // Tune kernels CLScheduler::get().tune_kernel_static(*_kernel); - if(input->info()->data_layout() == DataLayout::NCHW && !_kernel->border_size().empty()) + const DataLayout data_layout = info.data_layout == DataLayout::UNKNOWN ? input->info()->data_layout() : info.data_layout; + if(data_layout == DataLayout::NCHW && !_kernel->border_size().empty()) { _border_handler->configure(compile_context, input, _kernel->border_size(), info.border_mode, info.constant_border_value); } |