aboutsummaryrefslogtreecommitdiff
path: root/src/core/Utils.cpp
diff options
context:
space:
mode:
authorSang-Hoon Park <sang-hoon.park@arm.com>2020-06-24 13:34:04 +0100
committerSang-Hoon Park <sang-hoon.park@arm.com>2020-06-30 11:03:10 +0000
commit3687ee1e7719436ff155a35911946b045903e8b6 (patch)
tree127d4b9da3996f473cef51f01a07fb02b75c0f1b /src/core/Utils.cpp
parent781cba7f33e056b1ca470ab34eb478177768eaf4 (diff)
downloadComputeLibrary-3687ee1e7719436ff155a35911946b045903e8b6.tar.gz
COMPMID-3539: Ignore align_corners for scaled size of 1
Scale kernels failed to validate when align_corners is true for scaled output size 1. Change this behavior to ignoring align_corners value to be aligned with expected behavior of higher-level frameworks. Also the minimum output size generated by the fixture for Scale kernels is changed to 1. Change-Id: Ib8e479af8bc43de3780005545f0c53fe195dc22e Signed-off-by: Sang-Hoon Park <sang-hoon.park@arm.com> Reviewed-on: https://review.mlplatform.org/c/ml/ComputeLibrary/+/3478 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/Utils.cpp')
-rw-r--r--src/core/Utils.cpp12
1 files changed, 0 insertions, 12 deletions
diff --git a/src/core/Utils.cpp b/src/core/Utils.cpp
index bdde082a1f..4d7e964695 100644
--- a/src/core/Utils.cpp
+++ b/src/core/Utils.cpp
@@ -456,18 +456,6 @@ QuantizationInfo arm_compute::get_softmax_output_quantization_info(DataType inpu
return QuantizationInfo(1.f / 256, 0);
}
-float arm_compute::calculate_resize_ratio(size_t input_size, size_t output_size, bool align_corners)
-{
- const size_t offset = align_corners ? 1 : 0;
- const auto in = input_size - offset;
- const auto out = output_size - offset;
-
- ARM_COMPUTE_ERROR_ON((input_size == 0 || output_size == 0) && offset == 1);
- ARM_COMPUTE_ERROR_ON(out == 0);
-
- return static_cast<float>(in) / static_cast<float>(out);
-}
-
std::pair<int32_t, int32_t> arm_compute::get_quantized_activation_min_max(ActivationLayerInfo act_info, DataType data_type, UniformQuantizationInfo oq_info)
{
const bool is_qasymm8_signed = is_data_type_quantized_asymmetric_signed(data_type);