aboutsummaryrefslogtreecommitdiff
path: root/tests/validation/NEON/ReduceMean.cpp
diff options
context:
space:
mode:
Diffstat (limited to 'tests/validation/NEON/ReduceMean.cpp')
-rw-r--r--tests/validation/NEON/ReduceMean.cpp42
1 files changed, 38 insertions, 4 deletions
diff --git a/tests/validation/NEON/ReduceMean.cpp b/tests/validation/NEON/ReduceMean.cpp
index 23229a08ef..e5a5a175fb 100644
--- a/tests/validation/NEON/ReduceMean.cpp
+++ b/tests/validation/NEON/ReduceMean.cpp
@@ -160,16 +160,33 @@ TEST_SUITE(QASYMM8)
FIXTURE_DATA_TEST_CASE(RunSmall,
NEReduceMeanQuantizedFixture<uint8_t>,
framework::DatasetMode::PRECOMMIT,
- combine(combine(combine(datasets::Small4DShapes(), framework::dataset::make("DataType", DataType::QASYMM8)), concat(axis_keep, axis_drop)), framework::dataset::make("QuantizationInfo", { QuantizationInfo(1.f / 255, 5) })))
+ combine(combine(combine(combine(datasets::Small4DShapes(), framework::dataset::make("DataType", DataType::QASYMM8)), concat(axis_keep, axis_drop)),
+ framework::dataset::make("QuantizationInfoInput", { QuantizationInfo(1.f / 255, 5) })),
+ framework::dataset::make("QuantizationInfoOutput", { QuantizationInfo(1.f / 255, 5) })))
{
// Validate output
validate(Accessor(_target), _reference, tolerance_u8);
}
+TEST_SUITE(Requant)
+FIXTURE_DATA_TEST_CASE(RunSmall,
+ NEReduceMeanQuantizedFixture<uint8_t>,
+ framework::DatasetMode::PRECOMMIT,
+ combine(combine(combine(combine(datasets::Small4DShapes(), framework::dataset::make("DataType", DataType::QASYMM8)), axis_drop),
+ framework::dataset::make("QuantizationInfoInput", { QuantizationInfo(1.f / 255, 5) })),
+ framework::dataset::make("QuantizationInfoOutput", { QuantizationInfo(1.f / 200, 16) })))
+{
+ // Validate output
+ validate(Accessor(_target), _reference, tolerance_u8);
+}
+TEST_SUITE_END() // Requant
+
FIXTURE_DATA_TEST_CASE(RunLarge,
NEReduceMeanQuantizedFixture<uint8_t>,
framework::DatasetMode::NIGHTLY,
- combine(combine(combine(datasets::Large4DShapes(), framework::dataset::make("DataType", DataType::QASYMM8)), concat(axis_keep, axis_drop)), framework::dataset::make("QuantizationInfo", { QuantizationInfo(1.f / 255, 5) })))
+ combine(combine(combine(combine(datasets::Large4DShapes(), framework::dataset::make("DataType", DataType::QASYMM8)), concat(axis_keep, axis_drop)),
+ framework::dataset::make("QuantizationInfoInput", { QuantizationInfo(1.f / 255, 5) })),
+ framework::dataset::make("QuantizationInfoOutput", { QuantizationInfo(1.f / 255, 5) })))
{
// Validate output
validate(Accessor(_target), _reference, tolerance_u8);
@@ -180,15 +197,32 @@ TEST_SUITE(QASYMM8_SIGNED)
FIXTURE_DATA_TEST_CASE(RunSmall,
NEReduceMeanQuantizedFixture<int8_t>,
framework::DatasetMode::PRECOMMIT,
- combine(combine(combine(datasets::Small4DShapes(), framework::dataset::make("DataType", DataType::QASYMM8_SIGNED)), concat(axis_keep, axis_drop)), framework::dataset::make("QuantizationInfo", { QuantizationInfo(1.f / 127, -10), QuantizationInfo(1.f / 250, -20) })))
+ combine(combine(combine(combine(datasets::Small4DShapes(), framework::dataset::make("DataType", DataType::QASYMM8_SIGNED)), concat(axis_keep, axis_drop)),
+ framework::dataset::make("QuantizationInfoInput", { QuantizationInfo(1.f / 127, -10), QuantizationInfo(1.f / 250, -20) })),
+ framework::dataset::make("QuantizationInfoInputOutput", { QuantizationInfo(1.f / 127, -10) })))
{
// Validate output
validate(Accessor(_target), _reference, tolerance_s8);
}
+TEST_SUITE(Requant)
+FIXTURE_DATA_TEST_CASE(RunSmall,
+ NEReduceMeanQuantizedFixture<int8_t>,
+ framework::DatasetMode::PRECOMMIT,
+ combine(combine(combine(combine(datasets::Small4DShapes(), framework::dataset::make("DataType", DataType::QASYMM8_SIGNED)), axis_drop),
+ framework::dataset::make("QuantizationInfoInput", { QuantizationInfo(1.f / 102, 2) })),
+ framework::dataset::make("QuantizationInfoOutput", { QuantizationInfo(1.f / 113, 10) })))
+{
+ // Validate output
+ validate(Accessor(_target), _reference, tolerance_s8);
+}
+TEST_SUITE_END() // Requant
+
FIXTURE_DATA_TEST_CASE(RunLarge,
NEReduceMeanQuantizedFixture<int8_t>,
framework::DatasetMode::NIGHTLY,
- combine(combine(combine(datasets::Large4DShapes(), framework::dataset::make("DataType", DataType::QASYMM8_SIGNED)), concat(axis_keep, axis_drop)), framework::dataset::make("QuantizationInfo", { QuantizationInfo(1.f / 127, 0) })))
+ combine(combine(combine(combine(datasets::Large4DShapes(), framework::dataset::make("DataType", DataType::QASYMM8_SIGNED)), concat(axis_keep, axis_drop)),
+ framework::dataset::make("QuantizationInfoInput", { QuantizationInfo(1.f / 127, -10) })),
+ framework::dataset::make("QuantizationInfoInputOutput", { QuantizationInfo(1.f / 127, -10) })))
{
// Validate output
validate(Accessor(_target), _reference, tolerance_s8);