From 4d1ff588288b1a7a98dd2fd7f2ba5717b8ecf102 Mon Sep 17 00:00:00 2001 From: James Conroy Date: Mon, 10 Jun 2019 17:06:39 +0100 Subject: IVGCVSW-3221 Refactor Mean ref workload and tests * Renamed RefMeanFloat32Workload and RefMeanUint8Workload to RefMeanWorkload, updated references to reflect this change. * Refactored RefFloorWorkload to use Decoders/Encoders, to support the use of multiple data types. * Deleted reference Unit8 Mean tests as they were duplicates of the Float32 tests. Refactored these tests to support multiple data types and updated references. * Adjusted the values used in the tests' input tensors so that they are more like floating point numbers e.g. change 1.0f to 1.5f. * Replace size_t with unsigned int in Mean ref workload, for better compatibility with the Encoder/Decoder, removed some unnecessary casts after this. * Added ValidateTensorDataTypesMatch() function to WorkloadData.cpp, added CreateIncorrectDimensionsErrorMsg function to RefLayerSupport.cpp. * Added passing and failing tests for ref IsMeanSupported. Signed-off-by: James Conroy Change-Id: Id3d44463d1385255c727a497d4026d21a49e7eb2 --- src/backends/reference/workloads/Mean.hpp | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) (limited to 'src/backends/reference/workloads/Mean.hpp') diff --git a/src/backends/reference/workloads/Mean.hpp b/src/backends/reference/workloads/Mean.hpp index 38c2e39653..dfb0302bf9 100644 --- a/src/backends/reference/workloads/Mean.hpp +++ b/src/backends/reference/workloads/Mean.hpp @@ -7,6 +7,7 @@ #include "armnn/DescriptorsFwd.hpp" #include "armnn/Tensor.hpp" +#include "BaseIterator.hpp" #include @@ -15,7 +16,7 @@ namespace armnn void Mean(const TensorInfo& inputInfo, const TensorInfo& outputInfo, const std::vector& axis, - const float* inputData, - float* outputData); + Decoder& input, + Encoder& output); } //namespace armnn -- cgit v1.2.1