aboutsummaryrefslogtreecommitdiff
path: root/tests/validation/fixtures/ElementWiseUnaryFixture.h
diff options
context:
space:
mode:
Diffstat (limited to 'tests/validation/fixtures/ElementWiseUnaryFixture.h')
-rw-r--r--tests/validation/fixtures/ElementWiseUnaryFixture.h17
1 files changed, 17 insertions, 0 deletions
diff --git a/tests/validation/fixtures/ElementWiseUnaryFixture.h b/tests/validation/fixtures/ElementWiseUnaryFixture.h
index 37da3b1405..7837b085fa 100644
--- a/tests/validation/fixtures/ElementWiseUnaryFixture.h
+++ b/tests/validation/fixtures/ElementWiseUnaryFixture.h
@@ -98,6 +98,12 @@ protected:
library->fill(tensor, distribution, i);
break;
}
+ case ElementWiseUnary::SIN:
+ {
+ std::uniform_real_distribution<> distribution(100.0f, -100.0f);
+ library->fill(tensor, distribution, i);
+ break;
+ }
default:
ARM_COMPUTE_ERROR("Not implemented");
}
@@ -202,6 +208,17 @@ public:
ElementWiseUnaryValidationFixture<TensorType, AccessorType, FunctionType, T>::setup(shape, data_type, ElementWiseUnary::ABS);
}
};
+
+template <typename TensorType, typename AccessorType, typename FunctionType, typename T>
+class SinValidationFixture : public ElementWiseUnaryValidationFixture<TensorType, AccessorType, FunctionType, T>
+{
+public:
+ template <typename...>
+ void setup(const TensorShape &shape, DataType data_type)
+ {
+ ElementWiseUnaryValidationFixture<TensorType, AccessorType, FunctionType, T>::setup(shape, data_type, ElementWiseUnary::SIN);
+ }
+};
} // namespace validation
} // namespace test
} // namespace arm_compute