diff options
author | Aron Virginas-Tar <Aron.Virginas-Tar@arm.com> | 2019-06-14 15:45:03 +0100 |
---|---|---|
committer | Áron Virginás-Tar <aron.virginas-tar@arm.com> | 2019-06-17 10:03:58 +0000 |
commit | 44cfd848c1913f87a77c0427450dba93ba47fb94 (patch) | |
tree | a0260bf155f06879042a30c2e8dafe66fc9718a4 /test/1.2 | |
parent | cd700e4f0db201bc3066605058dc1c87d483833f (diff) | |
download | android-nn-driver-44cfd848c1913f87a77c0427450dba93ba47fb94.tar.gz |
IVGCVSW-3283 Add test for converting CONV2D and DEPTHWISE_CONV2D operators with dilation params
Signed-off-by: Aron Virginas-Tar <Aron.Virginas-Tar@arm.com>
Change-Id: I51a9c71d7a277ab530ac35faea2e8a069c134f45
Diffstat (limited to 'test/1.2')
-rw-r--r-- | test/1.2/Dilation.cpp | 94 |
1 files changed, 94 insertions, 0 deletions
diff --git a/test/1.2/Dilation.cpp b/test/1.2/Dilation.cpp new file mode 100644 index 00000000..1a7ba4b4 --- /dev/null +++ b/test/1.2/Dilation.cpp @@ -0,0 +1,94 @@ +// +// Copyright © 2017 Arm Ltd. All rights reserved. +// SPDX-License-Identifier: MIT +// + +#include "../Dilation.hpp" + +#include "../../1.2/HalPolicy.hpp" + +#include <boost/test/data/test_case.hpp> + +BOOST_AUTO_TEST_SUITE(DilationTests) + +BOOST_AUTO_TEST_CASE(ConvolutionExplicitPaddingNoDilation) +{ + DilationTestOptions options; + options.m_IsDepthwiseConvolution = false; + options.m_IsPaddingExplicit = true; + options.m_HasDilation = false; + + DilationTestImpl<hal_1_2::HalPolicy>(options); +} + +BOOST_AUTO_TEST_CASE(ConvolutionExplicitPaddingDilation) +{ + DilationTestOptions options; + options.m_IsDepthwiseConvolution = false; + options.m_IsPaddingExplicit = true; + options.m_HasDilation = true; + + DilationTestImpl<hal_1_2::HalPolicy>(options); +} + +BOOST_AUTO_TEST_CASE(ConvolutionImplicitPaddingNoDilation) +{ + DilationTestOptions options; + options.m_IsDepthwiseConvolution = false; + options.m_IsPaddingExplicit = false; + options.m_HasDilation = false; + + DilationTestImpl<hal_1_2::HalPolicy>(options); +} + +BOOST_AUTO_TEST_CASE(ConvolutionImplicitPaddingDilation) +{ + DilationTestOptions options; + options.m_IsDepthwiseConvolution = false; + options.m_IsPaddingExplicit = false; + options.m_HasDilation = true; + + DilationTestImpl<hal_1_2::HalPolicy>(options); +} + +BOOST_AUTO_TEST_CASE(DepthwiseConvolutionExplicitPaddingNoDilation) +{ + DilationTestOptions options; + options.m_IsDepthwiseConvolution = true; + options.m_IsPaddingExplicit = true; + options.m_HasDilation = false; + + DilationTestImpl<hal_1_2::HalPolicy>(options); +} + +BOOST_AUTO_TEST_CASE(DepthwiseConvolutionExplicitPaddingDilation) +{ + DilationTestOptions options; + options.m_IsDepthwiseConvolution = true; + options.m_IsPaddingExplicit = true; + options.m_HasDilation = true; + + DilationTestImpl<hal_1_2::HalPolicy>(options); +} + +BOOST_AUTO_TEST_CASE(DepthwiseConvolutionImplicitPaddingNoDilation) +{ + DilationTestOptions options; + options.m_IsDepthwiseConvolution = true; + options.m_IsPaddingExplicit = false; + options.m_HasDilation = false; + + DilationTestImpl<hal_1_2::HalPolicy>(options); +} + +BOOST_AUTO_TEST_CASE(DepthwiseConvolutionImplicitPaddingDilation) +{ + DilationTestOptions options; + options.m_IsDepthwiseConvolution = true; + options.m_IsPaddingExplicit = false; + options.m_HasDilation = true; + + DilationTestImpl<hal_1_2::HalPolicy>(options); +} + +BOOST_AUTO_TEST_SUITE_END()
\ No newline at end of file |