From d2d9361a0a338bce478f7d85b4af70d1ed20f26c Mon Sep 17 00:00:00 2001 From: Ramy Elgammal Date: Thu, 22 Dec 2022 15:21:03 +0000 Subject: Add extend padding lock flag - ITensorInfo's padding cannot be extended if its lock_paddings flag is set to True. Resolves: COMPMID-5714 Signed-off-by: Ramy Elgammal Change-Id: I6bca9bbf7172822af60562310578c438b9e15f46 Reviewed-on: https://review.mlplatform.org/c/ml/ComputeLibrary/+/8875 Tested-by: Arm Jenkins Reviewed-by: SiCong Li Reviewed-by: Gian Marco Iodice Comments-Addressed: Arm Jenkins Benchmark: Arm Jenkins --- arm_compute/core/SubTensorInfo.h | 9 ++++++++- 1 file changed, 8 insertions(+), 1 deletion(-) (limited to 'arm_compute/core/SubTensorInfo.h') diff --git a/arm_compute/core/SubTensorInfo.h b/arm_compute/core/SubTensorInfo.h index 374ea5b8c6..21703b0d93 100644 --- a/arm_compute/core/SubTensorInfo.h +++ b/arm_compute/core/SubTensorInfo.h @@ -1,5 +1,5 @@ /* - * Copyright (c) 2017-2022 Arm Limited. + * Copyright (c) 2017-2023 Arm Limited. * * SPDX-License-Identifier: MIT * @@ -116,7 +116,13 @@ public: ARM_COMPUTE_ERROR_ON(_parent == nullptr); return _parent->auto_padding(); }; + + ITensorInfo &set_lock_paddings(bool flag) override; + + bool lock_paddings() const override; + bool extend_padding(const PaddingSize &padding) override; + size_t dimension(size_t index) const override { return _tensor_shape[index]; @@ -256,6 +262,7 @@ private: Coordinates _coords; ValidRegion _valid_region; bool _extend_parent; + bool _lock_paddings; }; } // namespace arm_compute #endif /*ARM_COMPUTE_SUBTENSORINFO_H */ -- cgit v1.2.1