From e49e26613264842f91d29a32be3a226a0d6adb42 Mon Sep 17 00:00:00 2001 From: Moritz Pflanzer Date: Fri, 21 Jul 2017 15:55:28 +0100 Subject: COMPMID-415: Use half_float library for F16 3RDPARTY_UPDATE Change-Id: Iee572e18d5b1df71300d738cc8690f49d7203d5c Reviewed-on: http://mpd-gerrit.cambridge.arm.com/81353 Tested-by: Kaizen Reviewed-by: Anthony Barbier --- tests/validation/TensorFactory.h | 23 ++++++++--------------- 1 file changed, 8 insertions(+), 15 deletions(-) (limited to 'tests/validation/TensorFactory.h') diff --git a/tests/validation/TensorFactory.h b/tests/validation/TensorFactory.h index 2f33dd283d..a3bb5f9615 100644 --- a/tests/validation/TensorFactory.h +++ b/tests/validation/TensorFactory.h @@ -24,29 +24,24 @@ #ifndef __ARM_COMPUTE_TEST_TENSOR_FACTORY_H__ #define __ARM_COMPUTE_TEST_TENSOR_FACTORY_H__ -#include "RawTensor.h" -#include "Tensor.h" #include "arm_compute/core/Error.h" +#include "tests/RawTensor.h" +#include "tests/validation/Tensor.h" +#include "tests/validation/half.h" #include "boost_wrapper.h" -#if ARM_COMPUTE_ENABLE_FP16 -#include // needed for float16_t -#endif /* ARM_COMPUTE_ENABLE_FP16 */ - namespace arm_compute { namespace test { namespace validation { -using TensorVariant = boost::variant < Tensor, Tensor, +using TensorVariant = boost::variant, Tensor, Tensor, Tensor, Tensor, Tensor, -#ifdef ARM_COMPUTE_ENABLE_FP16 - Tensor, -#endif /* ARM_COMPUTE_ENABLE_FP16 */ - Tensor>; + Tensor, + Tensor>; /** Helper to create a constant type if the passed reference is constant. */ template @@ -95,12 +90,10 @@ public: using value_type_s32 = typename match_const::type; v = Tensor(shape, dt, fixed_point_position, reinterpret_cast(data)); break; -#ifdef ARM_COMPUTE_ENABLE_FP16 case DataType::F16: - using value_type_f16 = typename match_const::type; - v = Tensor(shape, dt, fixed_point_position, reinterpret_cast(data)); + using value_type_f16 = typename match_const::type; + v = Tensor(shape, dt, fixed_point_position, reinterpret_cast(data)); break; -#endif /* ARM_COMPUTE_ENABLE_FP16 */ case DataType::F32: using value_type_f32 = typename match_const::type; v = Tensor(shape, dt, fixed_point_position, reinterpret_cast(data)); -- cgit v1.2.1