aboutsummaryrefslogtreecommitdiff
path: root/tests/validation/reference/Convolution.cpp
diff options
context:
space:
mode:
authorSanghoon Lee <sanghoon.lee@arm.com>2017-12-13 11:28:50 +0000
committerAnthony Barbier <anthony.barbier@arm.com>2018-11-02 16:42:33 +0000
commitd7ba5397b676c966cb5069c7187a12a0c35305f5 (patch)
treeab95a7e64c44b3505eec3e845a5fe049ae5ba66d /tests/validation/reference/Convolution.cpp
parent6db0ff5b4bb49f834c7caa532a7feab228df10f9 (diff)
downloadComputeLibrary-d7ba5397b676c966cb5069c7187a12a0c35305f5.tar.gz
COMPMID-727 - Implement reference and CL/NEON validation for CustomConvolutionRectangle
Change-Id: I108a48ad5e6dc3f331fd5ceb38ced8ccdb31d81a Reviewed-on: https://eu-gerrit-1.euhpc.arm.com/113130 Tested-by: Jenkins <bsgcomp@arm.com> Reviewed-by: Georgios Pinitas <georgios.pinitas@arm.com> Reviewed-by: Anthony Barbier <anthony.barbier@arm.com>
Diffstat (limited to 'tests/validation/reference/Convolution.cpp')
-rw-r--r--tests/validation/reference/Convolution.cpp8
1 files changed, 4 insertions, 4 deletions
diff --git a/tests/validation/reference/Convolution.cpp b/tests/validation/reference/Convolution.cpp
index 84be858cfc..777e2df400 100644
--- a/tests/validation/reference/Convolution.cpp
+++ b/tests/validation/reference/Convolution.cpp
@@ -1,5 +1,5 @@
/*
- * Copyright (c) 2017 ARM Limited.
+ * Copyright (c) 2017, 2018 ARM Limited.
*
* SPDX-License-Identifier: MIT
*
@@ -35,7 +35,7 @@ namespace validation
namespace reference
{
template <typename T>
-SimpleTensor<T> convolution(const SimpleTensor<T> &src, const int16_t *conv, uint32_t scale, BorderMode border_mode, T constant_border_value, const unsigned int filter_size)
+SimpleTensor<T> convolution(const SimpleTensor<T> &src, const int16_t *conv, uint32_t scale, BorderMode border_mode, T constant_border_value, const unsigned int width, const unsigned int height)
{
SimpleTensor<T> dst(src.shape(), src.data_type());
SimpleTensor<int32_t> sum(src.shape(), src.data_type());
@@ -43,7 +43,7 @@ SimpleTensor<T> convolution(const SimpleTensor<T> &src, const int16_t *conv, uin
for(int element_idx = 0; element_idx < src.num_elements(); ++element_idx)
{
const Coordinates id = index2coord(src.shape(), element_idx);
- apply_2d_spatial_filter(id, src, sum, TensorShape(filter_size, filter_size), conv, 1, border_mode, constant_border_value);
+ apply_2d_spatial_filter(id, src, sum, TensorShape(width, height), conv, 1, border_mode, constant_border_value);
if(tensor_elem_at<int32_t>(sum, id, border_mode, constant_border_value) < 0)
{
@@ -63,7 +63,7 @@ SimpleTensor<T> convolution(const SimpleTensor<T> &src, const int16_t *conv, uin
}
template SimpleTensor<uint8_t> convolution(const SimpleTensor<uint8_t> &src, const int16_t *conv, uint32_t scale, BorderMode border_mode, uint8_t constant_border_value,
- const unsigned int filter_size);
+ const unsigned int widht, const unsigned int height);
} // namespace reference
} // namespace validation
} // namespace test