diff options
author | Teresa Charlin <teresa.charlinreyes@arm.com> | 2023-09-15 15:19:21 +0100 |
---|---|---|
committer | TeresaARM <teresa.charlinreyes@arm.com> | 2023-09-29 11:05:29 +0000 |
commit | 077cddbe9e956c6740557a9add499385f235c384 (patch) | |
tree | ae1816443bf4f85c7968aa3e542ef2b5e5400e7e /src/armnnTfLiteParser/test/Activations.cpp | |
parent | 9a45e8fab86f7078d22360794058f5550413df78 (diff) | |
download | armnn-077cddbe9e956c6740557a9add499385f235c384.tar.gz |
IVGCVSW-8055 Add support for GELU activation function.
* Add support to CpuRef, CpuAcc and GpuAcc
* Add support to tflite parser, classic and opaque tflite delegates
* Add support to serializer and deserializer
* Add Unit tests
Signed-off-by: Teresa Charlin <teresa.charlinreyes@arm.com>
Change-Id: Ibc60ef2ef2a051e6d9af6e15d24c46316ec19de4
Diffstat (limited to 'src/armnnTfLiteParser/test/Activations.cpp')
-rw-r--r-- | src/armnnTfLiteParser/test/Activations.cpp | 12 |
1 files changed, 12 insertions, 0 deletions
diff --git a/src/armnnTfLiteParser/test/Activations.cpp b/src/armnnTfLiteParser/test/Activations.cpp index a3d75edab5..9cd03a3c9d 100644 --- a/src/armnnTfLiteParser/test/Activations.cpp +++ b/src/armnnTfLiteParser/test/Activations.cpp @@ -130,4 +130,16 @@ TEST_CASE_FIXTURE(HardSwishFixture, "ParseHardSwish") { -0.0f, -0.0f, -0.04833334f, 0.84f, 1.90666667f, 3.0f, 4.0f }); } +struct GeluFixture : ActivationFixture +{ + GeluFixture() : ActivationFixture("GELU", "FLOAT32") {} +}; + +TEST_CASE_FIXTURE(GeluFixture, "ParseGelu") +{ + RunTest<2, armnn::DataType::Float32>(0, + { -4.0f, -3.0f, -2.9f, 1.2f, 2.2f, 3.0f, 4.0f }, + {-0.000126361847f, -0.00404950976f, -0.00541083235f, 1.06191647f, 2.16941237f, 2.9959507f, 3.99987364f }); +} + } |