diff options
author | Giorgio Arena <giorgio.arena@arm.com> | 2021-02-10 11:54:47 +0000 |
---|---|---|
committer | Giorgio Arena <giorgio.arena@arm.com> | 2021-02-10 16:10:32 +0000 |
commit | edc524ef7ed38e0521c874f28bb9a1f2407b44c6 (patch) | |
tree | 64eab5750f0284ddc184f44a5e5b6e8b7472d59e /src/core/helpers/Utils.h | |
parent | db35345753e4ba81384c8a92ece6a8f598fd841a (diff) | |
download | ComputeLibrary-edc524ef7ed38e0521c874f28bb9a1f2407b44c6.tar.gz |
Revert changes on tensor's strides and fix CLDepthwiseConvolution 3x3 Quantized
- Revert changes in strides > num_dimensions. Set them to 0
- Fix offset calculcation in depthwise 3x3 quantized using select and stride_y for max offset
Resolve COMPMID-4254
Change-Id: Ia99b9637f18b99b1fa3d4b7b4892046027d3e7e5
Signed-off-by: Giorgio Arena <giorgio.arena@arm.com>
Reviewed-on: https://review.mlplatform.org/c/ml/ComputeLibrary/+/5040
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/core/helpers/Utils.h')
-rw-r--r-- | src/core/helpers/Utils.h | 24 |
1 files changed, 0 insertions, 24 deletions
diff --git a/src/core/helpers/Utils.h b/src/core/helpers/Utils.h index d64eddb9aa..326dc962c7 100644 --- a/src/core/helpers/Utils.h +++ b/src/core/helpers/Utils.h @@ -50,30 +50,6 @@ inline Strides compute_strides(const ITensorInfo &info, T stride_x, Ts &&... fix strides.set(i, shape[i - 1] * strides[i - 1]); } - size_t first_zero = std::distance(strides.begin(), std::find_if(strides.begin(), strides.end(), [](uint32_t val) - { - return val == 0U; - })); - - if(first_zero > 0) - { - if(first_zero == 1) - { - strides.set(1, strides[0] * (shape[0] + info.padding().left + info.padding().right)); - ++first_zero; - } - else if(first_zero == 2) - { - strides.set(2, strides[1] * (shape[1] + info.padding().top + info.padding().bottom)); - ++first_zero; - } - - for(size_t i = first_zero; i < Strides::num_max_dimensions; ++i) - { - strides.set(i, strides[first_zero - 1]); - } - } - return strides; } |