30 #include "tests/datasets/SmallConvolutionLayerDataset.h" 35 #include "tests/validation/fixtures/FFTFixture.h" 47 TensorShape(4U, 2U, 3U), TensorShape(5U, 2U, 3U),
48 TensorShape(7U, 2U, 3U), TensorShape(8U, 2U, 3U),
49 TensorShape(9U, 2U, 3U), TensorShape(25U, 2U, 3U),
50 TensorShape(49U, 2U, 3U), TensorShape(64U, 2U, 3U),
51 TensorShape(16U, 2U, 3U), TensorShape(32U, 2U, 3U),
52 TensorShape(96U, 2U, 2U)
55 TensorShape(4U, 5U, 3U), TensorShape(5U, 7U, 3U),
56 TensorShape(7U, 25U, 3U), TensorShape(8U, 2U, 3U),
57 TensorShape(9U, 16U, 3U), TensorShape(25U, 32U, 3U),
58 TensorShape(192U, 128U, 2U)
63 ActivationLayerInfo(),
69 constexpr
float tolerance_num_f32 = 0.07f;
105 template <
typename T>
106 using CLFFT1DFixture = FFTValidationFixture<CLTensor, CLAccessor, CLFFT1D, FFT1DInfo, T>;
153 template <
typename T>
154 using CLFFT2DFixture = FFTValidationFixture<CLTensor, CLAccessor, CLFFT2D, FFT2DInfo, T>;
176 template <
typename T>
177 using CLFFTConvolutionLayerFixture = FFTConvolutionValidationFixture<CLTensor, CLAccessor, CLFFTConvolutionLayer, T>;
178 template <
typename T>
186 ActivationFunctionsSmallDataset))
194 ActivationFunctionsSmallDataset))
204 ActivationFunctionsSmallDataset))
unsigned int axis
Axis to run the FFT on.
constexpr float tolerance_num_f16
F16 Tolerance number.
TEST_SUITE(QASYMM8_to_F32) FIXTURE_DATA_TEST_CASE(RunSmall
Descriptor used by the FFT1D function.
Descriptor used by the FFT2D function.
static Status validate(const ITensorInfo *input, const ITensorInfo *output, const FFT1DInfo &config)
Static function to check if given info will lead to a valid configuration of CLFFT1D.
half_float::half half
16-bit floating point type
1 channel, 1 F32 per channel
ARM_COMPUTE_EXPECT(has_error==expected, framework::LogLevel::ERRORS)
std::enable_if< is_container< T >::value, ContainerDataset< T > >::type make(std::string name, T &&values)
Helper function to create a ContainerDataset.
Copyright (c) 2017-2023 Arm Limited.
1 channel, 1 F16 per channel
DATA_TEST_CASE(Validate, framework::DatasetMode::ALL, zip(zip(zip(framework::dataset::make("InputInfo", { TensorInfo(TensorShape(27U, 13U, 2U), 1, DataType::F32), TensorInfo(TensorShape(27U, 13U, 2U), 1, DataType::F32), TensorInfo(TensorShape(32U, 13U, 2U), 1, DataType::F32), TensorInfo(TensorShape(32U, 13U, 2U), 1, DataType::QASYMM8), TensorInfo(TensorShape(27U, 13U, 2U), 1, DataType::QASYMM8), TensorInfo(TensorShape(27U, 13U, 2U), 1, DataType::F32), TensorInfo(TensorShape(32U, 13U, 2U), 1, DataType::QSYMM16), TensorInfo(TensorShape(32U, 13U, 2U), 1, DataType::QSYMM16), TensorInfo(TensorShape(32U, 13U, 2U), 1, DataType::QSYMM16), }), framework::dataset::make("OutputInfo",{ TensorInfo(TensorShape(27U, 13U, 2U), 1, DataType::F16), TensorInfo(TensorShape(27U, 13U, 2U), 1, DataType::F32), TensorInfo(TensorShape(32U, 13U, 2U), 1, DataType::F32), TensorInfo(TensorShape(32U, 13U, 2U), 1, DataType::QASYMM8), TensorInfo(TensorShape(27U, 13U, 2U), 1, DataType::QASYMM8), TensorInfo(TensorShape(30U, 11U, 2U), 1, DataType::F32), TensorInfo(TensorShape(32U, 13U, 2U), 1, DataType::QSYMM16, QuantizationInfo(1.f/32768.f, 0)), TensorInfo(TensorShape(32U, 13U, 2U), 1, DataType::QSYMM16, QuantizationInfo(1.f/32768.f, 0)), TensorInfo(TensorShape(32U, 13U, 2U), 1, DataType::QSYMM16, QuantizationInfo(1.f/32768.f, 0)), })), framework::dataset::make("ActivationInfo", { ActivationLayerInfo(ActivationLayerInfo::ActivationFunction::RELU), ActivationLayerInfo(ActivationLayerInfo::ActivationFunction::RELU), ActivationLayerInfo(ActivationLayerInfo::ActivationFunction::RELU), ActivationLayerInfo(ActivationLayerInfo::ActivationFunction::LU_BOUNDED_RELU), ActivationLayerInfo(ActivationLayerInfo::ActivationFunction::TANH), ActivationLayerInfo(ActivationLayerInfo::ActivationFunction::RELU), ActivationLayerInfo(ActivationLayerInfo::ActivationFunction::TANH), ActivationLayerInfo(ActivationLayerInfo::ActivationFunction::LOGISTIC), ActivationLayerInfo(ActivationLayerInfo::ActivationFunction::SQRT), })), framework::dataset::make("Expected", { false, true, true, true, false, false, true, true, false })), input_info, output_info, act_info, expected)
DatasetMode
Possible dataset modes.
RelativeTolerance< float > tolerance_f32(0.01f)
Tolerance value for comparing reference's output against implementation's output for DataType::F32...
TEST_SUITE_END() FIXTURE_DATA_TEST_CASE(RunSmall
[CLActivationLayer Test snippet]
Accessor implementation for CLTensor objects.
FFTConvolutionValidationFixture< CLTensor, CLAccessor, CLFFTConvolutionLayer, T, true > CLFFTConvolutionLayerMixedDataLayoutFixture
validate(CLAccessor(output_state), expected_output)
RelativeTolerance< half_float::half > tolerance_f16(half_float::half(0.1))
Tolerance value for comparing reference's output against implementation's output for DataType::F16...
Num samples, channels, height, width.
FFTValidationFixture< CLTensor, CLAccessor, CLFFT2D, FFT2DInfo, T > CLFFT2DFixture
Lower and Upper Bounded Rectifier ( )
FIXTURE_DATA_TEST_CASE(RunSmall, CLAbsLayerFixture< half >, framework::DatasetMode::PRECOMMIT, combine(datasets::SmallShapes(), framework::dataset::make("DataType", DataType::F16)))
FFTValidationFixture< CLTensor, CLAccessor, CLFFT1D, FFT1DInfo, T > CLFFT1DFixture
Num samples, height, width, channels.
Store the tensor's metadata.
zip(zip(framework::dataset::make("Weights", { TensorInfo(TensorShape(32U, 13U, 2U, 2U), 1, DataType::F32), TensorInfo(TensorShape(32U, 13U, 2U, 2U), 1, DataType::F32), TensorInfo(TensorShape(32U, 13U, 2U, 1U), 1, DataType::F32), }), framework::dataset::make("MVBGInfo",{ TensorInfo(TensorShape(2U), 1, DataType::F32), TensorInfo(TensorShape(2U), 1, DataType::F16), TensorInfo(TensorShape(5U), 1, DataType::F32), })), framework::dataset::make("Expected", { true, false, false}))
DataType
Available data types.
DataLayout
[DataLayout enum definition]
combine(datasets::SmallShapes(), framework::dataset::make("DataType", DataType::F32)))
static Status validate(const ITensorInfo *input, const ITensorInfo *output, const FFT2DInfo &config)
Static function to check if given info will lead to a valid configuration of CLFFT2D.