Laurent Carlier | 749294b | 2020-06-01 09:03:17 +0100 | [diff] [blame] | 1 | // |
Teresa Charlin | 686f45c | 2020-07-23 17:59:00 +0100 | [diff] [blame] | 2 | // Copyright © 2017 Arm Ltd and Contributors. All rights reserved. |
David Beck | ecb56cd | 2018-09-05 12:52:57 +0100 | [diff] [blame] | 3 | // SPDX-License-Identifier: MIT |
telsoa01 | 4fcda01 | 2018-03-09 14:13:49 +0000 | [diff] [blame] | 4 | // |
telsoa01 | 4fcda01 | 2018-03-09 14:13:49 +0000 | [diff] [blame] | 5 | |
Aron Virginas-Tar | 5605519 | 2018-11-12 18:10:43 +0000 | [diff] [blame] | 6 | #include "NeonWorkloadFactoryHelper.hpp" |
| 7 | |
Aron Virginas-Tar | c9cc804 | 2018-11-01 16:15:57 +0000 | [diff] [blame] | 8 | #include <test/TensorHelpers.hpp> |
| 9 | #include <test/UnitTests.hpp> |
telsoa01 | 4fcda01 | 2018-03-09 14:13:49 +0000 | [diff] [blame] | 10 | |
Aron Virginas-Tar | c9cc804 | 2018-11-01 16:15:57 +0000 | [diff] [blame] | 11 | #include <neon/NeonLayerSupport.hpp> |
| 12 | #include <neon/NeonWorkloadFactory.hpp> |
Aron Virginas-Tar | 00d306e | 2019-08-28 18:08:46 +0100 | [diff] [blame] | 13 | |
Aron Virginas-Tar | c9cc804 | 2018-11-01 16:15:57 +0000 | [diff] [blame] | 14 | #include <reference/RefWorkloadFactory.hpp> |
Aron Virginas-Tar | 00d306e | 2019-08-28 18:08:46 +0100 | [diff] [blame] | 15 | |
Aron Virginas-Tar | c9cc804 | 2018-11-01 16:15:57 +0000 | [diff] [blame] | 16 | #include <backendsCommon/test/ActivationFixture.hpp> |
| 17 | #include <backendsCommon/test/LayerTests.hpp> |
telsoa01 | 4fcda01 | 2018-03-09 14:13:49 +0000 | [diff] [blame] | 18 | |
arovir01 | 43095f3 | 2018-10-09 18:04:24 +0100 | [diff] [blame] | 19 | #include <boost/test/unit_test.hpp> |
telsoa01 | 4fcda01 | 2018-03-09 14:13:49 +0000 | [diff] [blame] | 20 | |
| 21 | BOOST_AUTO_TEST_SUITE(Compute_ArmComputeNeon) |
Sadik Armagan | 581742d | 2019-08-12 14:11:37 +0100 | [diff] [blame] | 22 | |
| 23 | using namespace armnn; |
| 24 | |
| 25 | using FactoryType = NeonWorkloadFactory; |
telsoa01 | 4fcda01 | 2018-03-09 14:13:49 +0000 | [diff] [blame] | 26 | |
| 27 | // ============================================================================ |
| 28 | // UNIT tests |
| 29 | |
Mike Kelly | 5685802 | 2020-01-27 12:14:47 +0000 | [diff] [blame] | 30 | // BatchToSpace |
Keith Davis | 33a626f | 2020-08-27 15:38:12 +0100 | [diff] [blame] | 31 | ARMNN_AUTO_TEST_CASE_WITH_THF(BatchToSpaceNdNhwcFloat321, BatchToSpaceNdNhwcTest1<DataType::Float32>) |
| 32 | ARMNN_AUTO_TEST_CASE_WITH_THF(BatchToSpaceNdNhwcFloat322, BatchToSpaceNdNhwcTest2<DataType::Float32>) |
| 33 | ARMNN_AUTO_TEST_CASE_WITH_THF(BatchToSpaceNdNhwcFloat323, BatchToSpaceNdNhwcTest3<DataType::Float32>) |
Mike Kelly | 5685802 | 2020-01-27 12:14:47 +0000 | [diff] [blame] | 34 | |
Keith Davis | 33a626f | 2020-08-27 15:38:12 +0100 | [diff] [blame] | 35 | ARMNN_AUTO_TEST_CASE_WITH_THF(BatchToSpaceNdNchwFloat321, BatchToSpaceNdNchwTest1<DataType::Float32>) |
| 36 | ARMNN_AUTO_TEST_CASE_WITH_THF(BatchToSpaceNdNchwFloat322, BatchToSpaceNdNchwTest2<DataType::Float32>) |
| 37 | ARMNN_AUTO_TEST_CASE_WITH_THF(BatchToSpaceNdNchwFloat323, BatchToSpaceNdNchwTest3<DataType::Float32>) |
Mike Kelly | 5685802 | 2020-01-27 12:14:47 +0000 | [diff] [blame] | 38 | |
Keith Davis | 33a626f | 2020-08-27 15:38:12 +0100 | [diff] [blame] | 39 | ARMNN_AUTO_TEST_CASE_WITH_THF(BatchToSpaceNdNhwcInt1, BatchToSpaceNdNhwcTest1<DataType::QAsymmS8>) |
| 40 | ARMNN_AUTO_TEST_CASE_WITH_THF(BatchToSpaceNdNhwcInt2, BatchToSpaceNdNhwcTest2<DataType::QAsymmS8>) |
| 41 | ARMNN_AUTO_TEST_CASE_WITH_THF(BatchToSpaceNdNhwcInt3, BatchToSpaceNdNhwcTest3<DataType::QAsymmS8>) |
Sadik Armagan | 303980c | 2020-04-17 12:45:14 +0100 | [diff] [blame] | 42 | |
Keith Davis | 33a626f | 2020-08-27 15:38:12 +0100 | [diff] [blame] | 43 | ARMNN_AUTO_TEST_CASE_WITH_THF(BatchToSpaceNdNchwInt1, BatchToSpaceNdNchwTest1<DataType::QAsymmS8>) |
| 44 | ARMNN_AUTO_TEST_CASE_WITH_THF(BatchToSpaceNdNchwInt2, BatchToSpaceNdNchwTest2<DataType::QAsymmS8>) |
| 45 | ARMNN_AUTO_TEST_CASE_WITH_THF(BatchToSpaceNdNchwInt3, BatchToSpaceNdNchwTest3<DataType::QAsymmS8>) |
Sadik Armagan | 303980c | 2020-04-17 12:45:14 +0100 | [diff] [blame] | 46 | |
Keith Davis | 33a626f | 2020-08-27 15:38:12 +0100 | [diff] [blame] | 47 | ARMNN_AUTO_TEST_CASE_WITH_THF(BatchToSpaceNdNhwcUint1, BatchToSpaceNdNhwcTest1<DataType::QAsymmU8>) |
| 48 | ARMNN_AUTO_TEST_CASE_WITH_THF(BatchToSpaceNdNhwcUint2, BatchToSpaceNdNhwcTest2<DataType::QAsymmU8>) |
| 49 | ARMNN_AUTO_TEST_CASE_WITH_THF(BatchToSpaceNdNhwcUint3, BatchToSpaceNdNhwcTest3<DataType::QAsymmU8>) |
Mike Kelly | 5685802 | 2020-01-27 12:14:47 +0000 | [diff] [blame] | 50 | |
Keith Davis | 33a626f | 2020-08-27 15:38:12 +0100 | [diff] [blame] | 51 | ARMNN_AUTO_TEST_CASE_WITH_THF(BatchToSpaceNdNchwUint1, BatchToSpaceNdNchwTest1<DataType::QAsymmU8>) |
| 52 | ARMNN_AUTO_TEST_CASE_WITH_THF(BatchToSpaceNdNchwUint2, BatchToSpaceNdNchwTest2<DataType::QAsymmU8>) |
| 53 | ARMNN_AUTO_TEST_CASE_WITH_THF(BatchToSpaceNdNchwUint3, BatchToSpaceNdNchwTest3<DataType::QAsymmU8>) |
Mike Kelly | 5685802 | 2020-01-27 12:14:47 +0000 | [diff] [blame] | 54 | |
telsoa01 | 4fcda01 | 2018-03-09 14:13:49 +0000 | [diff] [blame] | 55 | // Convolution |
Keith Davis | f500d6c | 2020-08-31 08:32:55 +0100 | [diff] [blame] | 56 | ARMNN_AUTO_TEST_CASE_WITH_THF(SimpleConvolution1d, Convolution1dTest, true) |
telsoa01 | 4fcda01 | 2018-03-09 14:13:49 +0000 | [diff] [blame] | 57 | |
Keith Davis | f500d6c | 2020-08-31 08:32:55 +0100 | [diff] [blame] | 58 | ARMNN_AUTO_TEST_CASE_WITH_THF(SimpleConvolution2d, SimpleConvolution2d3x5Test, true, DataLayout::NCHW) |
| 59 | ARMNN_AUTO_TEST_CASE_WITH_THF(SimpleConvolution2dNhwc, SimpleConvolution2d3x5Test, true, DataLayout::NHWC) |
| 60 | ARMNN_AUTO_TEST_CASE_WITH_THF(SimpleConvolution2d3x3Uint8, SimpleConvolution2d3x3Uint8Test, true, DataLayout::NCHW) |
| 61 | ARMNN_AUTO_TEST_CASE_WITH_THF(SimpleConvolution2d3x3Uint8Nhwc, SimpleConvolution2d3x3Uint8Test, true, DataLayout::NHWC) |
| 62 | ARMNN_AUTO_TEST_CASE_WITH_THF(UnbiasedConvolution2d, SimpleConvolution2d3x5Test, false, DataLayout::NCHW) |
| 63 | ARMNN_AUTO_TEST_CASE_WITH_THF(UnbiasedConvolution2dNhwc, SimpleConvolution2d3x5Test, false, DataLayout::NHWC) |
| 64 | ARMNN_AUTO_TEST_CASE_WITH_THF(UnbiasedConvolution2dStride2x2Nhwc, |
Sadik Armagan | 581742d | 2019-08-12 14:11:37 +0100 | [diff] [blame] | 65 | SimpleConvolution2d3x3Stride2x2Test, false, DataLayout::NHWC) |
jimfly01 | 0a088a6 | 2018-10-25 17:05:05 +0100 | [diff] [blame] | 66 | |
Keith Davis | f500d6c | 2020-08-31 08:32:55 +0100 | [diff] [blame] | 67 | ARMNN_AUTO_TEST_CASE_WITH_THF(UnbiasedConvolution2dSquare, SimpleConvolution2d3x3Test, false, DataLayout::NCHW) |
| 68 | ARMNN_AUTO_TEST_CASE_WITH_THF(SimpleConvolution2dAsymmetricPadding, |
| 69 | Convolution2dAsymmetricPaddingTest, |
| 70 | DataLayout::NCHW) |
narpra01 | 5f70318 | 2018-10-26 16:24:58 +0100 | [diff] [blame] | 71 | |
Keith Davis | f500d6c | 2020-08-31 08:32:55 +0100 | [diff] [blame] | 72 | ARMNN_AUTO_TEST_CASE_WITH_THF(UnbiasedConvolution2dSquareNhwc, SimpleConvolution2d3x3Test, false, DataLayout::NHWC) |
| 73 | ARMNN_AUTO_TEST_CASE_WITH_THF(SimpleConvolution2dAsymmetricPaddingNhwc, |
narpra01 | 5f70318 | 2018-10-26 16:24:58 +0100 | [diff] [blame] | 74 | Convolution2dAsymmetricPaddingTest, |
Sadik Armagan | 581742d | 2019-08-12 14:11:37 +0100 | [diff] [blame] | 75 | DataLayout::NHWC) |
telsoa01 | 4fcda01 | 2018-03-09 14:13:49 +0000 | [diff] [blame] | 76 | |
Keith Davis | f500d6c | 2020-08-31 08:32:55 +0100 | [diff] [blame] | 77 | ARMNN_AUTO_TEST_CASE_WITH_THF(SimpleConvolution2dSquareNhwc, SimpleConvolution2d3x3NhwcTest, false) |
telsoa01 | 4fcda01 | 2018-03-09 14:13:49 +0000 | [diff] [blame] | 78 | |
Keith Davis | f500d6c | 2020-08-31 08:32:55 +0100 | [diff] [blame] | 79 | ARMNN_AUTO_TEST_CASE_WITH_THF(Convolution2d3x3Dilation3x3, |
Sadik Armagan | 581742d | 2019-08-12 14:11:37 +0100 | [diff] [blame] | 80 | Convolution2d3x3Dilation3x3Test<DataType::Float32, DataType::Float32>, |
Jan Eilers | 59c6670 | 2019-07-11 10:22:36 +0100 | [diff] [blame] | 81 | false, |
Sadik Armagan | 581742d | 2019-08-12 14:11:37 +0100 | [diff] [blame] | 82 | DataLayout::NCHW) |
Keith Davis | f500d6c | 2020-08-31 08:32:55 +0100 | [diff] [blame] | 83 | ARMNN_AUTO_TEST_CASE_WITH_THF(Convolution2d3x3Dilation3x3Nhwc, |
Sadik Armagan | 581742d | 2019-08-12 14:11:37 +0100 | [diff] [blame] | 84 | Convolution2d3x3Dilation3x3Test<DataType::Float32, DataType::Float32>, |
Jan Eilers | 59c6670 | 2019-07-11 10:22:36 +0100 | [diff] [blame] | 85 | false, |
Sadik Armagan | 581742d | 2019-08-12 14:11:37 +0100 | [diff] [blame] | 86 | DataLayout::NHWC) |
Keith Davis | f500d6c | 2020-08-31 08:32:55 +0100 | [diff] [blame] | 87 | ARMNN_AUTO_TEST_CASE_WITH_THF(Convolution2d3x3Dilation3x3Int8, |
Sadik Armagan | 303980c | 2020-04-17 12:45:14 +0100 | [diff] [blame] | 88 | Convolution2d3x3Dilation3x3Test<DataType::QAsymmS8, DataType::Signed32>, |
| 89 | false, |
| 90 | DataLayout::NCHW) |
Keith Davis | f500d6c | 2020-08-31 08:32:55 +0100 | [diff] [blame] | 91 | ARMNN_AUTO_TEST_CASE_WITH_THF(Convolution2d3x3Dilation3x3NhwcInt8, |
Sadik Armagan | 303980c | 2020-04-17 12:45:14 +0100 | [diff] [blame] | 92 | Convolution2d3x3Dilation3x3Test<DataType::QAsymmS8, DataType::Signed32>, |
| 93 | false, |
| 94 | DataLayout::NHWC) |
Keith Davis | f500d6c | 2020-08-31 08:32:55 +0100 | [diff] [blame] | 95 | ARMNN_AUTO_TEST_CASE_WITH_THF(Convolution2d3x3Dilation3x3Uint8, |
Derek Lamberti | f90c56d | 2020-01-10 17:14:08 +0000 | [diff] [blame] | 96 | Convolution2d3x3Dilation3x3Test<DataType::QAsymmU8, DataType::Signed32>, |
Jan Eilers | 59c6670 | 2019-07-11 10:22:36 +0100 | [diff] [blame] | 97 | false, |
Sadik Armagan | 581742d | 2019-08-12 14:11:37 +0100 | [diff] [blame] | 98 | DataLayout::NCHW) |
Keith Davis | f500d6c | 2020-08-31 08:32:55 +0100 | [diff] [blame] | 99 | ARMNN_AUTO_TEST_CASE_WITH_THF(Convolution2d3x3Dilation3x3NhwcUint8, |
Derek Lamberti | f90c56d | 2020-01-10 17:14:08 +0000 | [diff] [blame] | 100 | Convolution2d3x3Dilation3x3Test<DataType::QAsymmU8, DataType::Signed32>, |
Jan Eilers | 59c6670 | 2019-07-11 10:22:36 +0100 | [diff] [blame] | 101 | false, |
Sadik Armagan | 581742d | 2019-08-12 14:11:37 +0100 | [diff] [blame] | 102 | DataLayout::NHWC) |
Keith Davis | f500d6c | 2020-08-31 08:32:55 +0100 | [diff] [blame] | 103 | ARMNN_AUTO_TEST_CASE_WITH_THF(Convolution2d2x3x3Dilation3x3, |
Sadik Armagan | 581742d | 2019-08-12 14:11:37 +0100 | [diff] [blame] | 104 | Convolution2d2x3x3Dilation3x3Test<DataType::Float32, DataType::Float32>, |
Jan Eilers | 59c6670 | 2019-07-11 10:22:36 +0100 | [diff] [blame] | 105 | false, |
Sadik Armagan | 581742d | 2019-08-12 14:11:37 +0100 | [diff] [blame] | 106 | DataLayout::NCHW) |
Keith Davis | f500d6c | 2020-08-31 08:32:55 +0100 | [diff] [blame] | 107 | ARMNN_AUTO_TEST_CASE_WITH_THF(Convolution2d2x3x3Dilation3x3Nhwc, |
Sadik Armagan | 581742d | 2019-08-12 14:11:37 +0100 | [diff] [blame] | 108 | Convolution2d2x3x3Dilation3x3Test<DataType::Float32, DataType::Float32>, |
Jan Eilers | 59c6670 | 2019-07-11 10:22:36 +0100 | [diff] [blame] | 109 | false, |
Sadik Armagan | 581742d | 2019-08-12 14:11:37 +0100 | [diff] [blame] | 110 | DataLayout::NHWC) |
Keith Davis | f500d6c | 2020-08-31 08:32:55 +0100 | [diff] [blame] | 111 | ARMNN_AUTO_TEST_CASE_WITH_THF(Convolution2d2x3x3Dilation3x3Int8, |
Sadik Armagan | 303980c | 2020-04-17 12:45:14 +0100 | [diff] [blame] | 112 | Convolution2d2x3x3Dilation3x3Test<DataType::QAsymmS8, DataType::Signed32>, |
| 113 | false, |
| 114 | DataLayout::NCHW) |
Keith Davis | f500d6c | 2020-08-31 08:32:55 +0100 | [diff] [blame] | 115 | ARMNN_AUTO_TEST_CASE_WITH_THF(Convolution2d2x3x3Dilation3x3NhwcInt8, |
Sadik Armagan | 303980c | 2020-04-17 12:45:14 +0100 | [diff] [blame] | 116 | Convolution2d2x3x3Dilation3x3Test<DataType::QAsymmS8, DataType::Signed32>, |
| 117 | false, |
| 118 | DataLayout::NHWC) |
Keith Davis | f500d6c | 2020-08-31 08:32:55 +0100 | [diff] [blame] | 119 | ARMNN_AUTO_TEST_CASE_WITH_THF(Convolution2d2x3x3Dilation3x3Uint8, |
Derek Lamberti | f90c56d | 2020-01-10 17:14:08 +0000 | [diff] [blame] | 120 | Convolution2d2x3x3Dilation3x3Test<DataType::QAsymmU8, DataType::Signed32>, |
Jan Eilers | 59c6670 | 2019-07-11 10:22:36 +0100 | [diff] [blame] | 121 | false, |
Sadik Armagan | 581742d | 2019-08-12 14:11:37 +0100 | [diff] [blame] | 122 | DataLayout::NCHW) |
Keith Davis | f500d6c | 2020-08-31 08:32:55 +0100 | [diff] [blame] | 123 | ARMNN_AUTO_TEST_CASE_WITH_THF(Convolution2d2x3x3Dilation3x3NhwcUint8, |
Derek Lamberti | f90c56d | 2020-01-10 17:14:08 +0000 | [diff] [blame] | 124 | Convolution2d2x3x3Dilation3x3Test<DataType::QAsymmU8, DataType::Signed32>, |
Jan Eilers | 59c6670 | 2019-07-11 10:22:36 +0100 | [diff] [blame] | 125 | false, |
Sadik Armagan | 581742d | 2019-08-12 14:11:37 +0100 | [diff] [blame] | 126 | DataLayout::NHWC) |
Keith Davis | f500d6c | 2020-08-31 08:32:55 +0100 | [diff] [blame] | 127 | ARMNN_AUTO_TEST_CASE_WITH_THF(Convolution2d2x2Dilation2x2Padding2x2Stride3x3, |
Jan Eilers | 59c6670 | 2019-07-11 10:22:36 +0100 | [diff] [blame] | 128 | Convolution2d2x2Dilation2x2Padding2x2Stride3x3Test |
Sadik Armagan | 581742d | 2019-08-12 14:11:37 +0100 | [diff] [blame] | 129 | <DataType::Float32, DataType::Float32>, |
Jan Eilers | 59c6670 | 2019-07-11 10:22:36 +0100 | [diff] [blame] | 130 | false, |
Sadik Armagan | 581742d | 2019-08-12 14:11:37 +0100 | [diff] [blame] | 131 | DataLayout::NCHW) |
Keith Davis | f500d6c | 2020-08-31 08:32:55 +0100 | [diff] [blame] | 132 | ARMNN_AUTO_TEST_CASE_WITH_THF(Convolution2d2x2Dilation2x2Padding2x2Stride3x3Nhwc, |
Jan Eilers | 59c6670 | 2019-07-11 10:22:36 +0100 | [diff] [blame] | 133 | Convolution2d2x2Dilation2x2Padding2x2Stride3x3Test |
Sadik Armagan | 581742d | 2019-08-12 14:11:37 +0100 | [diff] [blame] | 134 | <DataType::Float32, DataType::Float32>, |
Jan Eilers | 59c6670 | 2019-07-11 10:22:36 +0100 | [diff] [blame] | 135 | false, |
Sadik Armagan | 581742d | 2019-08-12 14:11:37 +0100 | [diff] [blame] | 136 | DataLayout::NHWC) |
Keith Davis | f500d6c | 2020-08-31 08:32:55 +0100 | [diff] [blame] | 137 | ARMNN_AUTO_TEST_CASE_WITH_THF(Convolution2d2x2Dilation2x2Padding2x2Stride3x3Int8, |
Sadik Armagan | 303980c | 2020-04-17 12:45:14 +0100 | [diff] [blame] | 138 | Convolution2d2x2Dilation2x2Padding2x2Stride3x3Test |
| 139 | <DataType::QAsymmS8, DataType::Signed32>, |
| 140 | false, |
| 141 | DataLayout::NCHW) |
Keith Davis | f500d6c | 2020-08-31 08:32:55 +0100 | [diff] [blame] | 142 | ARMNN_AUTO_TEST_CASE_WITH_THF(Convolution2d2x2Dilation2x2Padding2x2Stride3x3NhwcInt8, |
Sadik Armagan | 303980c | 2020-04-17 12:45:14 +0100 | [diff] [blame] | 143 | Convolution2d2x2Dilation2x2Padding2x2Stride3x3Test |
| 144 | <DataType::QAsymmS8, DataType::Signed32>, |
| 145 | false, |
| 146 | DataLayout::NHWC) |
Keith Davis | f500d6c | 2020-08-31 08:32:55 +0100 | [diff] [blame] | 147 | ARMNN_AUTO_TEST_CASE_WITH_THF(Convolution2d2x2Dilation2x2Padding2x2Stride3x3Uint8, |
Jan Eilers | 59c6670 | 2019-07-11 10:22:36 +0100 | [diff] [blame] | 148 | Convolution2d2x2Dilation2x2Padding2x2Stride3x3Test |
Derek Lamberti | f90c56d | 2020-01-10 17:14:08 +0000 | [diff] [blame] | 149 | <DataType::QAsymmU8, DataType::Signed32>, |
Jan Eilers | 59c6670 | 2019-07-11 10:22:36 +0100 | [diff] [blame] | 150 | false, |
Sadik Armagan | 581742d | 2019-08-12 14:11:37 +0100 | [diff] [blame] | 151 | DataLayout::NCHW) |
Keith Davis | f500d6c | 2020-08-31 08:32:55 +0100 | [diff] [blame] | 152 | ARMNN_AUTO_TEST_CASE_WITH_THF(Convolution2d2x2Dilation2x2Padding2x2Stride3x3NhwcUint8, |
Jan Eilers | 59c6670 | 2019-07-11 10:22:36 +0100 | [diff] [blame] | 153 | Convolution2d2x2Dilation2x2Padding2x2Stride3x3Test |
Derek Lamberti | f90c56d | 2020-01-10 17:14:08 +0000 | [diff] [blame] | 154 | <DataType::QAsymmU8, DataType::Signed32>, |
Jan Eilers | 59c6670 | 2019-07-11 10:22:36 +0100 | [diff] [blame] | 155 | false, |
Sadik Armagan | 581742d | 2019-08-12 14:11:37 +0100 | [diff] [blame] | 156 | DataLayout::NHWC) |
Keith Davis | f500d6c | 2020-08-31 08:32:55 +0100 | [diff] [blame] | 157 | ARMNN_AUTO_TEST_CASE_WITH_THF(DepthwiseConvolution2dMult4, |
Kevin May | 665a964a | 2019-08-21 16:53:50 +0100 | [diff] [blame] | 158 | DepthwiseConvolution2dMult4Test<armnn::DataType::Float32, armnn::DataType::Float32>, |
| 159 | false, |
| 160 | armnn::DataLayout::NCHW) |
Keith Davis | f500d6c | 2020-08-31 08:32:55 +0100 | [diff] [blame] | 161 | ARMNN_AUTO_TEST_CASE_WITH_THF(DepthwiseConvolution2dMult2, |
Kevin May | 665a964a | 2019-08-21 16:53:50 +0100 | [diff] [blame] | 162 | DepthwiseConvolution2dMult2Test<armnn::DataType::Float32, armnn::DataType::Float32>, |
| 163 | false, |
| 164 | armnn::DataLayout::NCHW) |
Jan Eilers | 59c6670 | 2019-07-11 10:22:36 +0100 | [diff] [blame] | 165 | |
Keith Davis | f500d6c | 2020-08-31 08:32:55 +0100 | [diff] [blame] | 166 | ARMNN_AUTO_TEST_CASE_WITH_THF(Convolution2dPerAxisQuantTestNchw, Convolution2dPerAxisQuantTest, DataLayout::NCHW); |
| 167 | ARMNN_AUTO_TEST_CASE_WITH_THF(Convolution2dPerAxisQuantTestNhwc, Convolution2dPerAxisQuantTest, DataLayout::NHWC); |
Aron Virginas-Tar | 21fc28b | 2019-11-26 14:04:54 +0000 | [diff] [blame] | 168 | |
Aron Virginas-Tar | 2f00b74 | 2019-09-30 13:28:08 +0100 | [diff] [blame] | 169 | // DepthToSpace |
| 170 | ARMNN_AUTO_TEST_CASE(DepthToSpaceNchwFloat32_1, DepthToSpaceTest1<DataType::Float32>, DataLayout::NCHW); |
| 171 | ARMNN_AUTO_TEST_CASE(DepthToSpaceNchwFloat32_2, DepthToSpaceTest2<DataType::Float32>, DataLayout::NCHW); |
| 172 | ARMNN_AUTO_TEST_CASE(DepthToSpaceNchwFloat32_3, DepthToSpaceTest3<DataType::Float32>, DataLayout::NCHW); |
| 173 | ARMNN_AUTO_TEST_CASE(DepthToSpaceNchwFloat32_4, DepthToSpaceTest4<DataType::Float32>, DataLayout::NCHW); |
| 174 | |
Aron Virginas-Tar | 99836d3 | 2019-09-30 16:34:31 +0100 | [diff] [blame] | 175 | ARMNN_AUTO_TEST_CASE(DepthToSpaceNchwFloat16_1, DepthToSpaceTest1<DataType::Float16>, DataLayout::NCHW); |
| 176 | ARMNN_AUTO_TEST_CASE(DepthToSpaceNchwFloat16_2, DepthToSpaceTest2<DataType::Float16>, DataLayout::NCHW); |
| 177 | ARMNN_AUTO_TEST_CASE(DepthToSpaceNchwFloat16_3, DepthToSpaceTest3<DataType::Float16>, DataLayout::NCHW); |
| 178 | ARMNN_AUTO_TEST_CASE(DepthToSpaceNchwFloat16_4, DepthToSpaceTest4<DataType::Float16>, DataLayout::NCHW); |
| 179 | |
Sadik Armagan | 303980c | 2020-04-17 12:45:14 +0100 | [diff] [blame] | 180 | ARMNN_AUTO_TEST_CASE(DepthToSpaceNchwInt8_1, DepthToSpaceTest1<DataType::QAsymmS8>, DataLayout::NCHW); |
| 181 | ARMNN_AUTO_TEST_CASE(DepthToSpaceNchwInt8_2, DepthToSpaceTest2<DataType::QAsymmS8>, DataLayout::NCHW); |
| 182 | ARMNN_AUTO_TEST_CASE(DepthToSpaceNchwInt8_3, DepthToSpaceTest3<DataType::QAsymmS8>, DataLayout::NCHW); |
| 183 | ARMNN_AUTO_TEST_CASE(DepthToSpaceNchwInt8_4, DepthToSpaceTest4<DataType::QAsymmS8>, DataLayout::NCHW); |
| 184 | |
Derek Lamberti | f90c56d | 2020-01-10 17:14:08 +0000 | [diff] [blame] | 185 | ARMNN_AUTO_TEST_CASE(DepthToSpaceNchwUint8_1, DepthToSpaceTest1<DataType::QAsymmU8>, DataLayout::NCHW); |
| 186 | ARMNN_AUTO_TEST_CASE(DepthToSpaceNchwUint8_2, DepthToSpaceTest2<DataType::QAsymmU8>, DataLayout::NCHW); |
| 187 | ARMNN_AUTO_TEST_CASE(DepthToSpaceNchwUint8_3, DepthToSpaceTest3<DataType::QAsymmU8>, DataLayout::NCHW); |
| 188 | ARMNN_AUTO_TEST_CASE(DepthToSpaceNchwUint8_4, DepthToSpaceTest4<DataType::QAsymmU8>, DataLayout::NCHW); |
Aron Virginas-Tar | 2f00b74 | 2019-09-30 13:28:08 +0100 | [diff] [blame] | 189 | |
Derek Lamberti | f90c56d | 2020-01-10 17:14:08 +0000 | [diff] [blame] | 190 | ARMNN_AUTO_TEST_CASE(DepthToSpaceNchwInt16_1, DepthToSpaceTest1<DataType::QSymmS16>, DataLayout::NCHW); |
| 191 | ARMNN_AUTO_TEST_CASE(DepthToSpaceNchwInt16_2, DepthToSpaceTest2<DataType::QSymmS16>, DataLayout::NCHW); |
| 192 | ARMNN_AUTO_TEST_CASE(DepthToSpaceNchwInt16_3, DepthToSpaceTest3<DataType::QSymmS16>, DataLayout::NCHW); |
| 193 | ARMNN_AUTO_TEST_CASE(DepthToSpaceNchwInt16_4, DepthToSpaceTest4<DataType::QSymmS16>, DataLayout::NCHW); |
Aron Virginas-Tar | 2f00b74 | 2019-09-30 13:28:08 +0100 | [diff] [blame] | 194 | |
| 195 | ARMNN_AUTO_TEST_CASE(DepthToSpaceNhwcFloat32_1, DepthToSpaceTest1<DataType::Float32>, DataLayout::NHWC); |
| 196 | ARMNN_AUTO_TEST_CASE(DepthToSpaceNhwcFloat32_2, DepthToSpaceTest2<DataType::Float32>, DataLayout::NHWC); |
| 197 | ARMNN_AUTO_TEST_CASE(DepthToSpaceNhwcFloat32_3, DepthToSpaceTest3<DataType::Float32>, DataLayout::NHWC); |
| 198 | ARMNN_AUTO_TEST_CASE(DepthToSpaceNhwcFloat32_4, DepthToSpaceTest4<DataType::Float32>, DataLayout::NHWC); |
| 199 | |
Aron Virginas-Tar | 99836d3 | 2019-09-30 16:34:31 +0100 | [diff] [blame] | 200 | ARMNN_AUTO_TEST_CASE(DepthToSpaceNhwcFloat16_1, DepthToSpaceTest1<DataType::Float16>, DataLayout::NHWC); |
| 201 | ARMNN_AUTO_TEST_CASE(DepthToSpaceNhwcFloat16_2, DepthToSpaceTest2<DataType::Float16>, DataLayout::NHWC); |
| 202 | ARMNN_AUTO_TEST_CASE(DepthToSpaceNhwcFloat16_3, DepthToSpaceTest3<DataType::Float16>, DataLayout::NHWC); |
| 203 | ARMNN_AUTO_TEST_CASE(DepthToSpaceNhwcFloat16_4, DepthToSpaceTest4<DataType::Float16>, DataLayout::NHWC); |
| 204 | |
Sadik Armagan | 303980c | 2020-04-17 12:45:14 +0100 | [diff] [blame] | 205 | ARMNN_AUTO_TEST_CASE(DepthToSpaceNhwcInt8_1, DepthToSpaceTest1<DataType::QAsymmS8>, DataLayout::NHWC); |
| 206 | ARMNN_AUTO_TEST_CASE(DepthToSpaceNhwcInt8_2, DepthToSpaceTest2<DataType::QAsymmS8>, DataLayout::NHWC); |
| 207 | ARMNN_AUTO_TEST_CASE(DepthToSpaceNhwcInt8_3, DepthToSpaceTest3<DataType::QAsymmS8>, DataLayout::NHWC); |
| 208 | ARMNN_AUTO_TEST_CASE(DepthToSpaceNhwcInt8_4, DepthToSpaceTest4<DataType::QAsymmS8>, DataLayout::NHWC); |
| 209 | |
Derek Lamberti | f90c56d | 2020-01-10 17:14:08 +0000 | [diff] [blame] | 210 | ARMNN_AUTO_TEST_CASE(DepthToSpaceNhwcUint8_1, DepthToSpaceTest1<DataType::QAsymmU8>, DataLayout::NHWC); |
| 211 | ARMNN_AUTO_TEST_CASE(DepthToSpaceNhwcUint8_2, DepthToSpaceTest2<DataType::QAsymmU8>, DataLayout::NHWC); |
| 212 | ARMNN_AUTO_TEST_CASE(DepthToSpaceNhwcUint8_3, DepthToSpaceTest3<DataType::QAsymmU8>, DataLayout::NHWC); |
| 213 | ARMNN_AUTO_TEST_CASE(DepthToSpaceNhwcUint8_4, DepthToSpaceTest4<DataType::QAsymmU8>, DataLayout::NHWC); |
Aron Virginas-Tar | 2f00b74 | 2019-09-30 13:28:08 +0100 | [diff] [blame] | 214 | |
Derek Lamberti | f90c56d | 2020-01-10 17:14:08 +0000 | [diff] [blame] | 215 | ARMNN_AUTO_TEST_CASE(DepthToSpaceNhwcInt16_1, DepthToSpaceTest1<DataType::QSymmS16>, DataLayout::NHWC); |
| 216 | ARMNN_AUTO_TEST_CASE(DepthToSpaceNhwcInt16_2, DepthToSpaceTest2<DataType::QSymmS16>, DataLayout::NHWC); |
| 217 | ARMNN_AUTO_TEST_CASE(DepthToSpaceNhwcInt16_3, DepthToSpaceTest3<DataType::QSymmS16>, DataLayout::NHWC); |
| 218 | ARMNN_AUTO_TEST_CASE(DepthToSpaceNhwcInt16_4, DepthToSpaceTest4<DataType::QSymmS16>, DataLayout::NHWC); |
Aron Virginas-Tar | 2f00b74 | 2019-09-30 13:28:08 +0100 | [diff] [blame] | 219 | |
telsoa01 | 4fcda01 | 2018-03-09 14:13:49 +0000 | [diff] [blame] | 220 | // Depthwise Convolution |
Keith Davis | f500d6c | 2020-08-31 08:32:55 +0100 | [diff] [blame] | 221 | ARMNN_AUTO_TEST_CASE_WITH_THF(DepthwiseConvolution2dDepthMul1, |
Sadik Armagan | 581742d | 2019-08-12 14:11:37 +0100 | [diff] [blame] | 222 | DepthwiseConvolution2dDepthMul1Test, true, DataLayout::NCHW) |
Keith Davis | f500d6c | 2020-08-31 08:32:55 +0100 | [diff] [blame] | 223 | ARMNN_AUTO_TEST_CASE_WITH_THF(UnbiasedDepthwiseConvolution2dDepthMul1, |
Sadik Armagan | 581742d | 2019-08-12 14:11:37 +0100 | [diff] [blame] | 224 | DepthwiseConvolution2dDepthMul1Test, false, DataLayout::NCHW) |
Keith Davis | f500d6c | 2020-08-31 08:32:55 +0100 | [diff] [blame] | 225 | ARMNN_AUTO_TEST_CASE_WITH_THF(DepthwiseConvolution2dDepthMul1Uint8, |
Sadik Armagan | 581742d | 2019-08-12 14:11:37 +0100 | [diff] [blame] | 226 | DepthwiseConvolution2dDepthMul1Uint8Test, true, DataLayout::NCHW) |
Keith Davis | f500d6c | 2020-08-31 08:32:55 +0100 | [diff] [blame] | 227 | ARMNN_AUTO_TEST_CASE_WITH_THF(UnbiasedDepthwiseConvolution2dDepthMul1Uint8, |
Sadik Armagan | 581742d | 2019-08-12 14:11:37 +0100 | [diff] [blame] | 228 | DepthwiseConvolution2dDepthMul1Uint8Test, false, DataLayout::NCHW) |
jimfly01 | b9c8963 | 2018-10-26 16:50:13 +0100 | [diff] [blame] | 229 | |
| 230 | // NHWC Depthwise Convolution |
Keith Davis | f500d6c | 2020-08-31 08:32:55 +0100 | [diff] [blame] | 231 | ARMNN_AUTO_TEST_CASE_WITH_THF(DepthwiseConvolution2dDepthMul1NHhwc, |
Sadik Armagan | 581742d | 2019-08-12 14:11:37 +0100 | [diff] [blame] | 232 | DepthwiseConvolution2dDepthMul1Test, true, DataLayout::NHWC) |
Keith Davis | f500d6c | 2020-08-31 08:32:55 +0100 | [diff] [blame] | 233 | ARMNN_AUTO_TEST_CASE_WITH_THF(UnbiasedDepthwiseConvolution2dDepthMul1Nhwc, |
Sadik Armagan | 581742d | 2019-08-12 14:11:37 +0100 | [diff] [blame] | 234 | DepthwiseConvolution2dDepthMul1Test, false, DataLayout::NHWC) |
Keith Davis | f500d6c | 2020-08-31 08:32:55 +0100 | [diff] [blame] | 235 | ARMNN_AUTO_TEST_CASE_WITH_THF(DepthwiseConvolution2dDepthMul1Uint8Nhwc, |
Sadik Armagan | 581742d | 2019-08-12 14:11:37 +0100 | [diff] [blame] | 236 | DepthwiseConvolution2dDepthMul1Uint8Test, true, DataLayout::NHWC) |
Keith Davis | f500d6c | 2020-08-31 08:32:55 +0100 | [diff] [blame] | 237 | ARMNN_AUTO_TEST_CASE_WITH_THF(UnbiasedDepthwiseConvolution2dDepthMul1Uint8Nhwc, |
Sadik Armagan | 581742d | 2019-08-12 14:11:37 +0100 | [diff] [blame] | 238 | DepthwiseConvolution2dDepthMul1Uint8Test, false, DataLayout::NHWC) |
jimfly01 | b9c8963 | 2018-10-26 16:50:13 +0100 | [diff] [blame] | 239 | |
Keith Davis | f500d6c | 2020-08-31 08:32:55 +0100 | [diff] [blame] | 240 | ARMNN_AUTO_TEST_CASE_WITH_THF(DepthwiseConvolution2dDepthNhwc, DepthwiseConvolution2dDepthNhwcTest, false) |
| 241 | ARMNN_AUTO_TEST_CASE_WITH_THF(SimpleDepthwiseConvolution2d3x3Dilation3x3Nhwc, |
Bruno Goncalves | 22972f0 | 2019-04-26 21:03:24 -0300 | [diff] [blame] | 242 | SimpleDepthwiseConvolution2d3x3Dilation3x3NhwcTest) |
jimfly01 | b9c8963 | 2018-10-26 16:50:13 +0100 | [diff] [blame] | 243 | |
telsoa01 | 4fcda01 | 2018-03-09 14:13:49 +0000 | [diff] [blame] | 244 | |
Keith Davis | f500d6c | 2020-08-31 08:32:55 +0100 | [diff] [blame] | 245 | ARMNN_AUTO_TEST_CASE_WITH_THF(DepthwiseConvolution2dAsymmetric, |
Sadik Armagan | 581742d | 2019-08-12 14:11:37 +0100 | [diff] [blame] | 246 | DepthwiseConvolution2dAsymmetricTest, true, DataLayout::NCHW) |
Keith Davis | f500d6c | 2020-08-31 08:32:55 +0100 | [diff] [blame] | 247 | ARMNN_AUTO_TEST_CASE_WITH_THF(UnbiasedDepthwiseConvolution2dAsymmetric, |
Sadik Armagan | 581742d | 2019-08-12 14:11:37 +0100 | [diff] [blame] | 248 | DepthwiseConvolution2dAsymmetricTest, false, DataLayout::NCHW) |
Keith Davis | f500d6c | 2020-08-31 08:32:55 +0100 | [diff] [blame] | 249 | ARMNN_AUTO_TEST_CASE_WITH_THF(DepthwiseConvolution2dAsymmetricNhwc, |
Sadik Armagan | 581742d | 2019-08-12 14:11:37 +0100 | [diff] [blame] | 250 | DepthwiseConvolution2dAsymmetricTest, true, DataLayout::NHWC) |
Keith Davis | f500d6c | 2020-08-31 08:32:55 +0100 | [diff] [blame] | 251 | ARMNN_AUTO_TEST_CASE_WITH_THF(UnbiasedDepthwiseConvolution2dAsymmetricNhwc, |
Sadik Armagan | 581742d | 2019-08-12 14:11:37 +0100 | [diff] [blame] | 252 | DepthwiseConvolution2dAsymmetricTest, false, DataLayout::NHWC) |
surmeh01 | 3537c2c | 2018-05-18 16:31:43 +0100 | [diff] [blame] | 253 | |
Keith Davis | f500d6c | 2020-08-31 08:32:55 +0100 | [diff] [blame] | 254 | ARMNN_AUTO_TEST_CASE_WITH_THF(DepthwiseConvolution2dDepthMul64, DepthwiseConvolution2dDepthMul64Test); |
Matthew Jackson | 9910792 | 2019-07-25 12:58:56 +0100 | [diff] [blame] | 255 | |
Keith Davis | f500d6c | 2020-08-31 08:32:55 +0100 | [diff] [blame] | 256 | ARMNN_AUTO_TEST_CASE_WITH_THF(DepthwiseConvolution2dPerAxisQuantTestNchw, DepthwiseConvolution2dPerAxisQuantTest, |
Aron Virginas-Tar | 2445744 | 2019-11-27 13:18:25 +0000 | [diff] [blame] | 257 | DataLayout::NCHW); |
Keith Davis | f500d6c | 2020-08-31 08:32:55 +0100 | [diff] [blame] | 258 | ARMNN_AUTO_TEST_CASE_WITH_THF(DepthwiseConvolution2dPerAxisQuantTestNhwc, DepthwiseConvolution2dPerAxisQuantTest, |
Aron Virginas-Tar | 2445744 | 2019-11-27 13:18:25 +0000 | [diff] [blame] | 259 | DataLayout::NHWC); |
| 260 | |
telsoa01 | 4fcda01 | 2018-03-09 14:13:49 +0000 | [diff] [blame] | 261 | namespace |
| 262 | { |
| 263 | |
Sadik Armagan | 581742d | 2019-08-12 14:11:37 +0100 | [diff] [blame] | 264 | DepthwiseConvolution2dDescriptor MakeDepthwiseConv2dDesc(uint32_t strideX, uint32_t strideY, |
telsoa01 | 4fcda01 | 2018-03-09 14:13:49 +0000 | [diff] [blame] | 265 | uint32_t depthMultiplier = 1, uint32_t padLeft = 0, uint32_t padRight = 0, |
| 266 | uint32_t padTop = 0, uint32_t padBottom = 0) |
| 267 | { |
Jan Eilers | 8eb2560 | 2020-03-09 12:13:48 +0000 | [diff] [blame] | 268 | IgnoreUnused(depthMultiplier); |
telsoa01 | c577f2c | 2018-08-31 09:22:23 +0100 | [diff] [blame] | 269 | |
Sadik Armagan | 581742d | 2019-08-12 14:11:37 +0100 | [diff] [blame] | 270 | DepthwiseConvolution2dDescriptor desc; |
telsoa01 | c577f2c | 2018-08-31 09:22:23 +0100 | [diff] [blame] | 271 | |
telsoa01 | 4fcda01 | 2018-03-09 14:13:49 +0000 | [diff] [blame] | 272 | desc.m_PadLeft = padLeft; |
| 273 | desc.m_PadRight = padRight; |
telsoa01 | c577f2c | 2018-08-31 09:22:23 +0100 | [diff] [blame] | 274 | |
telsoa01 | 4fcda01 | 2018-03-09 14:13:49 +0000 | [diff] [blame] | 275 | desc.m_PadTop = padTop; |
| 276 | desc.m_PadBottom = padBottom; |
| 277 | desc.m_StrideX = strideX; |
| 278 | desc.m_StrideY = strideY; |
telsoa01 | c577f2c | 2018-08-31 09:22:23 +0100 | [diff] [blame] | 279 | desc.m_BiasEnabled = false; |
| 280 | |
telsoa01 | 4fcda01 | 2018-03-09 14:13:49 +0000 | [diff] [blame] | 281 | return desc; |
| 282 | } |
| 283 | |
Sadik Armagan | 581742d | 2019-08-12 14:11:37 +0100 | [diff] [blame] | 284 | TensorInfo CreateOutputTensorInfo(const TensorInfo& inputInfo, |
| 285 | const TensorInfo& weightsInfo, |
| 286 | const DepthwiseConvolution2dDescriptor& descriptor, |
| 287 | DataType dataType) |
telsoa01 | c577f2c | 2018-08-31 09:22:23 +0100 | [diff] [blame] | 288 | { |
Sadik Armagan | 581742d | 2019-08-12 14:11:37 +0100 | [diff] [blame] | 289 | const TensorShape& inputShape = inputInfo.GetShape(); |
| 290 | const TensorShape& filterShape = weightsInfo.GetShape(); |
telsoa01 | c577f2c | 2018-08-31 09:22:23 +0100 | [diff] [blame] | 291 | |
| 292 | unsigned int inWidth = inputShape[3]; |
| 293 | unsigned int inHeight = inputShape[2]; |
| 294 | unsigned int inBatchSize = inputShape[0]; |
| 295 | |
| 296 | unsigned int filterWidth = filterShape[3]; |
| 297 | unsigned int readWidth = (inWidth + descriptor.m_PadLeft + descriptor.m_PadRight) - (filterWidth); |
| 298 | unsigned int outWidth = 1u + (readWidth / descriptor.m_StrideX); |
| 299 | |
| 300 | unsigned int filterHeight = filterShape[2]; |
| 301 | unsigned int readHeight = (inHeight + descriptor.m_PadTop + descriptor.m_PadBottom) - (filterHeight); |
| 302 | unsigned int outHeight = 1u + (readHeight / descriptor.m_StrideY); |
| 303 | unsigned int depthMultiplier = filterShape[0]; |
| 304 | |
| 305 | unsigned int outChannels = filterShape[1] * depthMultiplier; |
| 306 | unsigned int outBatchSize = inBatchSize; |
| 307 | |
Sadik Armagan | 581742d | 2019-08-12 14:11:37 +0100 | [diff] [blame] | 308 | TensorShape outputShape({outBatchSize, outChannels, outHeight, outWidth}); |
| 309 | return TensorInfo(outputShape, dataType); |
telsoa01 | c577f2c | 2018-08-31 09:22:23 +0100 | [diff] [blame] | 310 | } |
telsoa01 | 4fcda01 | 2018-03-09 14:13:49 +0000 | [diff] [blame] | 311 | } |
| 312 | |
| 313 | BOOST_AUTO_TEST_CASE(DepthwiseConv2dUtils) |
| 314 | { |
Sadik Armagan | 581742d | 2019-08-12 14:11:37 +0100 | [diff] [blame] | 315 | const DataType dataType = DataType::Float32; |
telsoa01 | c577f2c | 2018-08-31 09:22:23 +0100 | [diff] [blame] | 316 | |
Sadik Armagan | 581742d | 2019-08-12 14:11:37 +0100 | [diff] [blame] | 317 | TensorInfo inputInfo({1, 1, 10, 10 }, dataType); |
| 318 | TensorInfo outputInfo; |
| 319 | TensorInfo weightsInfo3x3({ 1, 1, 3, 3 }, dataType); |
| 320 | TensorInfo biasesInfo; |
telsoa01 | c577f2c | 2018-08-31 09:22:23 +0100 | [diff] [blame] | 321 | |
Sadik Armagan | 581742d | 2019-08-12 14:11:37 +0100 | [diff] [blame] | 322 | DepthwiseConvolution2dDescriptor descriptor; |
| 323 | NeonLayerSupport layerSupport; |
telsoa01 | 4fcda01 | 2018-03-09 14:13:49 +0000 | [diff] [blame] | 324 | |
| 325 | // Strides supported: 1,2,3 |
telsoa01 | c577f2c | 2018-08-31 09:22:23 +0100 | [diff] [blame] | 326 | descriptor = MakeDepthwiseConv2dDesc(1, 1); |
| 327 | outputInfo = CreateOutputTensorInfo(inputInfo, weightsInfo3x3, descriptor, dataType); |
Aron Virginas-Tar | fc82431 | 2018-10-15 15:00:13 +0100 | [diff] [blame] | 328 | BOOST_TEST(layerSupport.IsDepthwiseConvolutionSupported(inputInfo, outputInfo, descriptor, |
| 329 | weightsInfo3x3, biasesInfo)); |
telsoa01 | 4fcda01 | 2018-03-09 14:13:49 +0000 | [diff] [blame] | 330 | |
telsoa01 | c577f2c | 2018-08-31 09:22:23 +0100 | [diff] [blame] | 331 | descriptor = MakeDepthwiseConv2dDesc(1, 2); |
| 332 | outputInfo = CreateOutputTensorInfo(inputInfo, weightsInfo3x3, descriptor, dataType); |
Aron Virginas-Tar | fc82431 | 2018-10-15 15:00:13 +0100 | [diff] [blame] | 333 | BOOST_TEST(layerSupport.IsDepthwiseConvolutionSupported(inputInfo, outputInfo, descriptor, |
| 334 | weightsInfo3x3, biasesInfo)); |
telsoa01 | c577f2c | 2018-08-31 09:22:23 +0100 | [diff] [blame] | 335 | |
| 336 | descriptor = MakeDepthwiseConv2dDesc(1, 3); |
| 337 | outputInfo = CreateOutputTensorInfo(inputInfo, weightsInfo3x3, descriptor, dataType); |
Aron Virginas-Tar | fc82431 | 2018-10-15 15:00:13 +0100 | [diff] [blame] | 338 | BOOST_TEST(layerSupport.IsDepthwiseConvolutionSupported(inputInfo, outputInfo, descriptor, |
| 339 | weightsInfo3x3, biasesInfo)); |
telsoa01 | c577f2c | 2018-08-31 09:22:23 +0100 | [diff] [blame] | 340 | |
| 341 | descriptor = MakeDepthwiseConv2dDesc(2, 1); |
| 342 | outputInfo = CreateOutputTensorInfo(inputInfo, weightsInfo3x3, descriptor, dataType); |
Aron Virginas-Tar | fc82431 | 2018-10-15 15:00:13 +0100 | [diff] [blame] | 343 | BOOST_TEST(layerSupport.IsDepthwiseConvolutionSupported(inputInfo, outputInfo, descriptor, |
| 344 | weightsInfo3x3, biasesInfo)); |
telsoa01 | c577f2c | 2018-08-31 09:22:23 +0100 | [diff] [blame] | 345 | |
| 346 | descriptor = MakeDepthwiseConv2dDesc(2, 2); |
| 347 | outputInfo = CreateOutputTensorInfo(inputInfo, weightsInfo3x3, descriptor, dataType); |
Aron Virginas-Tar | fc82431 | 2018-10-15 15:00:13 +0100 | [diff] [blame] | 348 | BOOST_TEST(layerSupport.IsDepthwiseConvolutionSupported(inputInfo, outputInfo, descriptor, |
| 349 | weightsInfo3x3, biasesInfo)); |
telsoa01 | c577f2c | 2018-08-31 09:22:23 +0100 | [diff] [blame] | 350 | |
| 351 | descriptor = MakeDepthwiseConv2dDesc(2, 3); |
| 352 | outputInfo = CreateOutputTensorInfo(inputInfo, weightsInfo3x3, descriptor, dataType); |
Aron Virginas-Tar | fc82431 | 2018-10-15 15:00:13 +0100 | [diff] [blame] | 353 | BOOST_TEST(layerSupport.IsDepthwiseConvolutionSupported(inputInfo, outputInfo, descriptor, |
| 354 | weightsInfo3x3, biasesInfo)); |
telsoa01 | c577f2c | 2018-08-31 09:22:23 +0100 | [diff] [blame] | 355 | |
| 356 | descriptor = MakeDepthwiseConv2dDesc(3, 1); |
| 357 | outputInfo = CreateOutputTensorInfo(inputInfo, weightsInfo3x3, descriptor, dataType); |
Aron Virginas-Tar | fc82431 | 2018-10-15 15:00:13 +0100 | [diff] [blame] | 358 | BOOST_TEST(layerSupport.IsDepthwiseConvolutionSupported(inputInfo, outputInfo, descriptor, |
| 359 | weightsInfo3x3, biasesInfo)); |
telsoa01 | c577f2c | 2018-08-31 09:22:23 +0100 | [diff] [blame] | 360 | |
| 361 | descriptor = MakeDepthwiseConv2dDesc(3, 2); |
| 362 | outputInfo = CreateOutputTensorInfo(inputInfo, weightsInfo3x3, descriptor, dataType); |
Aron Virginas-Tar | fc82431 | 2018-10-15 15:00:13 +0100 | [diff] [blame] | 363 | BOOST_TEST(layerSupport.IsDepthwiseConvolutionSupported(inputInfo, outputInfo, descriptor, |
| 364 | weightsInfo3x3, biasesInfo)); |
telsoa01 | c577f2c | 2018-08-31 09:22:23 +0100 | [diff] [blame] | 365 | |
| 366 | descriptor = MakeDepthwiseConv2dDesc(3, 3); |
| 367 | outputInfo = CreateOutputTensorInfo(inputInfo, weightsInfo3x3, descriptor, dataType); |
Aron Virginas-Tar | fc82431 | 2018-10-15 15:00:13 +0100 | [diff] [blame] | 368 | BOOST_TEST(layerSupport.IsDepthwiseConvolutionSupported(inputInfo, outputInfo, descriptor, |
| 369 | weightsInfo3x3, biasesInfo)); |
telsoa01 | c577f2c | 2018-08-31 09:22:23 +0100 | [diff] [blame] | 370 | |
| 371 | // Supported stride 4 |
| 372 | descriptor = MakeDepthwiseConv2dDesc(4, 1); |
| 373 | outputInfo = CreateOutputTensorInfo(inputInfo, weightsInfo3x3, descriptor, dataType); |
Aron Virginas-Tar | fc82431 | 2018-10-15 15:00:13 +0100 | [diff] [blame] | 374 | BOOST_TEST(layerSupport.IsDepthwiseConvolutionSupported(inputInfo, outputInfo, descriptor, |
| 375 | weightsInfo3x3, biasesInfo)); |
telsoa01 | 4fcda01 | 2018-03-09 14:13:49 +0000 | [diff] [blame] | 376 | |
| 377 | // Supported weights shape 1x1 |
Sadik Armagan | 581742d | 2019-08-12 14:11:37 +0100 | [diff] [blame] | 378 | TensorInfo weightsInfo1x1({ 1, 1, 1, 1 }, DataType::Float32); |
telsoa01 | c577f2c | 2018-08-31 09:22:23 +0100 | [diff] [blame] | 379 | descriptor = MakeDepthwiseConv2dDesc(1, 1); |
| 380 | outputInfo = CreateOutputTensorInfo(inputInfo, weightsInfo1x1, descriptor, dataType); |
Aron Virginas-Tar | fc82431 | 2018-10-15 15:00:13 +0100 | [diff] [blame] | 381 | BOOST_TEST(layerSupport.IsDepthwiseConvolutionSupported(inputInfo, outputInfo, descriptor, |
| 382 | weightsInfo1x1, biasesInfo)); |
telsoa01 | 4fcda01 | 2018-03-09 14:13:49 +0000 | [diff] [blame] | 383 | |
| 384 | // Supported shape 2x2 |
Sadik Armagan | 581742d | 2019-08-12 14:11:37 +0100 | [diff] [blame] | 385 | TensorInfo weightsInfo2x2({ 1, 1, 2, 2 }, DataType::Float32); |
telsoa01 | c577f2c | 2018-08-31 09:22:23 +0100 | [diff] [blame] | 386 | descriptor = MakeDepthwiseConv2dDesc(1, 1); |
| 387 | outputInfo = CreateOutputTensorInfo(inputInfo, weightsInfo2x2, descriptor, dataType); |
Aron Virginas-Tar | fc82431 | 2018-10-15 15:00:13 +0100 | [diff] [blame] | 388 | BOOST_TEST(layerSupport.IsDepthwiseConvolutionSupported(inputInfo, outputInfo, descriptor, |
| 389 | weightsInfo2x2, biasesInfo)); |
surmeh01 | 3537c2c | 2018-05-18 16:31:43 +0100 | [diff] [blame] | 390 | |
| 391 | // Asymmetric padding |
telsoa01 | c577f2c | 2018-08-31 09:22:23 +0100 | [diff] [blame] | 392 | descriptor = MakeDepthwiseConv2dDesc(1, 1, 1, 1, 2, 1, 2); |
| 393 | outputInfo = CreateOutputTensorInfo(inputInfo, weightsInfo3x3, descriptor, dataType); |
Aron Virginas-Tar | fc82431 | 2018-10-15 15:00:13 +0100 | [diff] [blame] | 394 | BOOST_TEST(layerSupport.IsDepthwiseConvolutionSupported(inputInfo, outputInfo, descriptor, |
| 395 | weightsInfo3x3, biasesInfo)); |
telsoa01 | 4fcda01 | 2018-03-09 14:13:49 +0000 | [diff] [blame] | 396 | } |
| 397 | |
Narumol Prangnawarat | 01961a7 | 2019-05-30 16:47:12 +0100 | [diff] [blame] | 398 | // Dequantize |
Jan Eilers | f710793 | 2019-11-01 11:09:36 +0000 | [diff] [blame] | 399 | // Fp16 is only supported if __ARM_FEATURE_FP16_VECTOR_ARITHMETIC is enabled |
Narumol Prangnawarat | 01961a7 | 2019-05-30 16:47:12 +0100 | [diff] [blame] | 400 | ARMNN_AUTO_TEST_CASE(DequantizeSimpleUint8, DequantizeSimpleUint8Test) |
| 401 | ARMNN_AUTO_TEST_CASE(DequantizeOffsetUint8, DequantizeOffsetUint8Test) |
Jan Eilers | f710793 | 2019-11-01 11:09:36 +0000 | [diff] [blame] | 402 | ARMNN_AUTO_TEST_CASE(DequantizeSimpleInt16, DequantizeSimpleInt16Test) |
Narumol Prangnawarat | 01961a7 | 2019-05-30 16:47:12 +0100 | [diff] [blame] | 403 | |
telsoa01 | 4fcda01 | 2018-03-09 14:13:49 +0000 | [diff] [blame] | 404 | // Pooling |
Finn Williams | 826a543 | 2020-08-27 16:15:20 +0100 | [diff] [blame] | 405 | ARMNN_AUTO_TEST_CASE_WITH_THF(SimpleMaxPooling2dSize3x3Stride2x4, |
| 406 | SimpleMaxPooling2dSize3x3Stride2x4Test, true) |
| 407 | ARMNN_AUTO_TEST_CASE_WITH_THF(SimpleMaxPooling2dSize3x3Stride2x4Uint8, |
| 408 | SimpleMaxPooling2dSize3x3Stride2x4Uint8Test, true) |
James Conroy | 45a9b77 | 2018-10-31 11:47:53 +0000 | [diff] [blame] | 409 | |
Finn Williams | 826a543 | 2020-08-27 16:15:20 +0100 | [diff] [blame] | 410 | ARMNN_AUTO_TEST_CASE_WITH_THF(SimpleMaxPooling2d, SimpleMaxPooling2dTest, DataLayout::NCHW) |
| 411 | ARMNN_AUTO_TEST_CASE_WITH_THF(SimpleMaxPooling2dNhwc, SimpleMaxPooling2dTest, DataLayout::NHWC) |
| 412 | ARMNN_AUTO_TEST_CASE_WITH_THF(SimpleMaxPooling2dUint8, SimpleMaxPooling2dUint8Test, DataLayout::NCHW) |
| 413 | ARMNN_AUTO_TEST_CASE_WITH_THF(SimpleMaxPooling2dUint8Nhwc, SimpleMaxPooling2dUint8Test, DataLayout::NHWC) |
James Conroy | 45a9b77 | 2018-10-31 11:47:53 +0000 | [diff] [blame] | 414 | |
Finn Williams | 826a543 | 2020-08-27 16:15:20 +0100 | [diff] [blame] | 415 | ARMNN_AUTO_TEST_CASE_WITH_THF(SimpleAveragePooling2d, SimpleAveragePooling2dTest, DataLayout::NCHW) |
| 416 | ARMNN_AUTO_TEST_CASE_WITH_THF(SimpleAveragePooling2dNhwc, SimpleAveragePooling2dTest, DataLayout::NCHW) |
| 417 | ARMNN_AUTO_TEST_CASE_WITH_THF(SimpleAveragePooling2dUint8, |
| 418 | SimpleAveragePooling2dUint8Test, DataLayout::NCHW) |
| 419 | ARMNN_AUTO_TEST_CASE_WITH_THF(SimpleAveragePooling2dUint8Nhwc, |
| 420 | SimpleAveragePooling2dUint8Test, DataLayout::NHWC) |
surmeh01 | bceff2f | 2018-03-29 16:29:27 +0100 | [diff] [blame] | 421 | |
Finn Williams | 826a543 | 2020-08-27 16:15:20 +0100 | [diff] [blame] | 422 | ARMNN_AUTO_TEST_CASE_WITH_THF(LargeTensorsAveragePooling2d, LargeTensorsAveragePooling2dTest) |
| 423 | ARMNN_AUTO_TEST_CASE_WITH_THF(LargeTensorsAveragePooling2dUint8, LargeTensorsAveragePooling2dUint8Test) |
telsoa01 | 4fcda01 | 2018-03-09 14:13:49 +0000 | [diff] [blame] | 424 | |
Finn Williams | 826a543 | 2020-08-27 16:15:20 +0100 | [diff] [blame] | 425 | ARMNN_AUTO_TEST_CASE_WITH_THF(SimpleL2Pooling2d, SimpleL2Pooling2dTest, DataLayout::NCHW) |
| 426 | ARMNN_AUTO_TEST_CASE_WITH_THF(SimpleL2Pooling2dNeon, SimpleL2Pooling2dTest, DataLayout::NHWC) |
| 427 | ARMNN_AUTO_TEST_CASE_WITH_THF(UNSUPPORTED_SimpleL2Pooling2dUint8, SimpleL2Pooling2dUint8Test, DataLayout::NCHW) |
James Conroy | 45a9b77 | 2018-10-31 11:47:53 +0000 | [diff] [blame] | 428 | |
Finn Williams | 826a543 | 2020-08-27 16:15:20 +0100 | [diff] [blame] | 429 | ARMNN_AUTO_TEST_CASE_WITH_THF(L2Pooling2dSize3Stride1, L2Pooling2dSize3Stride1Test) |
| 430 | ARMNN_AUTO_TEST_CASE_WITH_THF(UNSUPPORTED_L2Pooling2dSize3Stride1Uint8, L2Pooling2dSize3Stride1Uint8Test) |
| 431 | ARMNN_AUTO_TEST_CASE_WITH_THF(L2Pooling2dSize3Stride3, L2Pooling2dSize3Stride3Test) |
| 432 | ARMNN_AUTO_TEST_CASE_WITH_THF(UNSUPPORTED_L2Pooling2dSize3Stride3Uint8, L2Pooling2dSize3Stride3Uint8Test) |
| 433 | ARMNN_AUTO_TEST_CASE_WITH_THF(L2Pooling2dSize3Stride4, L2Pooling2dSize3Stride4Test) |
| 434 | ARMNN_AUTO_TEST_CASE_WITH_THF(UNSUPPORTED_L2Pooling2dSize3Stride4Uint8, L2Pooling2dSize3Stride4Uint8Test) |
| 435 | ARMNN_AUTO_TEST_CASE_WITH_THF(L2Pooling2dSize7, L2Pooling2dSize7Test) |
| 436 | ARMNN_AUTO_TEST_CASE_WITH_THF(UNSUPPORTED_L2Pooling2dSize7Uint8, L2Pooling2dSize7Uint8Test) |
| 437 | ARMNN_AUTO_TEST_CASE_WITH_THF(L2Pooling2dSize9, L2Pooling2dSize9Test) |
| 438 | ARMNN_AUTO_TEST_CASE_WITH_THF(UNSUPPORTED_L2Pooling2dSize9Uint8, L2Pooling2dSize9Uint8Test) |
telsoa01 | 4fcda01 | 2018-03-09 14:13:49 +0000 | [diff] [blame] | 439 | |
| 440 | // Ignore padding values for pooling but count padding fields into the divisor |
Finn Williams | 826a543 | 2020-08-27 16:15:20 +0100 | [diff] [blame] | 441 | ARMNN_AUTO_TEST_CASE_WITH_THF(IgnorePaddingSimpleMaxPooling2d, IgnorePaddingSimpleMaxPooling2dTest) |
| 442 | ARMNN_AUTO_TEST_CASE_WITH_THF(IgnorePaddingSimpleMaxPooling2dUint8, IgnorePaddingSimpleMaxPooling2dUint8Test) |
| 443 | ARMNN_AUTO_TEST_CASE_WITH_THF(IgnorePaddingMaxPooling2dSize3, IgnorePaddingMaxPooling2dSize3Test) |
| 444 | ARMNN_AUTO_TEST_CASE_WITH_THF(IgnorePaddingMaxPooling2dSize3Uint8, IgnorePaddingMaxPooling2dSize3Uint8Test) |
telsoa01 | 4fcda01 | 2018-03-09 14:13:49 +0000 | [diff] [blame] | 445 | |
Finn Williams | 826a543 | 2020-08-27 16:15:20 +0100 | [diff] [blame] | 446 | ARMNN_AUTO_TEST_CASE_WITH_THF(IgnorePaddingSimpleAveragePooling2d, IgnorePaddingSimpleAveragePooling2dTest) |
| 447 | ARMNN_AUTO_TEST_CASE_WITH_THF(IgnorePaddingSimpleAveragePooling2dUint8, IgnorePaddingSimpleAveragePooling2dUint8Test) |
| 448 | ARMNN_AUTO_TEST_CASE_WITH_THF(IgnorePaddingSimpleAveragePooling2dNoPadding, |
| 449 | IgnorePaddingSimpleAveragePooling2dNoPaddingTest) |
| 450 | ARMNN_AUTO_TEST_CASE_WITH_THF(IgnorePaddingSimpleAveragePooling2dNoPaddingUint8, |
| 451 | IgnorePaddingSimpleAveragePooling2dNoPaddingUint8Test) |
| 452 | ARMNN_AUTO_TEST_CASE_WITH_THF(IgnorePaddingAveragePooling2dSize3, IgnorePaddingAveragePooling2dSize3Test) |
| 453 | ARMNN_AUTO_TEST_CASE_WITH_THF(IgnorePaddingAveragePooling2dSize3Uint8, |
| 454 | IgnorePaddingAveragePooling2dSize3Uint8Test) |
| 455 | ARMNN_AUTO_TEST_CASE_WITH_THF(IgnorePaddingAveragePooling2dSize3x2Stride2x2, |
| 456 | IgnorePaddingAveragePooling2dSize3x2Stride2x2Test, false) |
| 457 | ARMNN_AUTO_TEST_CASE_WITH_THF(IgnorePaddingAveragePooling2dSize3x2Stride2x2NoPadding, |
| 458 | IgnorePaddingAveragePooling2dSize3x2Stride2x2Test, |
| 459 | true) |
telsoa01 | 4fcda01 | 2018-03-09 14:13:49 +0000 | [diff] [blame] | 460 | |
Finn Williams | 826a543 | 2020-08-27 16:15:20 +0100 | [diff] [blame] | 461 | ARMNN_AUTO_TEST_CASE_WITH_THF(IgnorePaddingSimpleL2Pooling2d, IgnorePaddingSimpleL2Pooling2dTest) |
| 462 | ARMNN_AUTO_TEST_CASE_WITH_THF(UNSUPPORTED_IgnorePaddingSimpleL2Pooling2dUint8, |
| 463 | IgnorePaddingSimpleL2Pooling2dUint8Test) |
| 464 | ARMNN_AUTO_TEST_CASE_WITH_THF(IgnorePaddingL2Pooling2dSize3, IgnorePaddingL2Pooling2dSize3Test) |
| 465 | ARMNN_AUTO_TEST_CASE_WITH_THF(UNSUPPORTED_IgnorePaddingL2Pooling2dSize3Uint8, |
| 466 | IgnorePaddingL2Pooling2dSize3Uint8Test) |
telsoa01 | 4fcda01 | 2018-03-09 14:13:49 +0000 | [diff] [blame] | 467 | |
| 468 | // Activation |
Keith Davis | 33a626f | 2020-08-27 15:38:12 +0100 | [diff] [blame] | 469 | ARMNN_AUTO_TEST_CASE_WITH_THF(ConstantLinearActivation, ConstantLinearActivationTest) |
telsoa01 | 4fcda01 | 2018-03-09 14:13:49 +0000 | [diff] [blame] | 470 | |
Teresa Charlin | e32c844 | 2020-03-05 14:41:50 +0000 | [diff] [blame] | 471 | // Sigmoid Activation / Logistic |
Keith Davis | 33a626f | 2020-08-27 15:38:12 +0100 | [diff] [blame] | 472 | ARMNN_AUTO_TEST_CASE_WITH_THF(SimpleSigmoid, SimpleSigmoidTest) |
| 473 | ARMNN_AUTO_TEST_CASE_WITH_THF(SimpleSigmoidUint8, SimpleSigmoidUint8Test) |
Teresa Charlin | e32c844 | 2020-03-05 14:41:50 +0000 | [diff] [blame] | 474 | |
| 475 | // BoundedReLU Activation |
Keith Davis | 33a626f | 2020-08-27 15:38:12 +0100 | [diff] [blame] | 476 | ARMNN_AUTO_TEST_CASE_WITH_THF(ReLu1, BoundedReLuUpperAndLowerBoundTest) |
| 477 | ARMNN_AUTO_TEST_CASE_WITH_THF(ReLu6, BoundedReLuUpperBoundOnlyTest) |
| 478 | ARMNN_AUTO_TEST_CASE_WITH_THF(ReLu1Uint8, BoundedReLuUint8UpperAndLowerBoundTest) |
| 479 | ARMNN_AUTO_TEST_CASE_WITH_THF(ReLu6Uint8, BoundedReLuUint8UpperBoundOnlyTest) |
Narumol Prangnawarat | 65d3096 | 2019-03-14 11:55:03 +0000 | [diff] [blame] | 480 | |
Teresa Charlin | e32c844 | 2020-03-05 14:41:50 +0000 | [diff] [blame] | 481 | // ReLU Activation |
Keith Davis | 33a626f | 2020-08-27 15:38:12 +0100 | [diff] [blame] | 482 | ARMNN_AUTO_TEST_CASE_WITH_THF(ReLu, ReLuTest) |
| 483 | ARMNN_AUTO_TEST_CASE_WITH_THF(ReLuUint8, ReLuUint8Test) |
David Monahan | 3b3c381 | 2020-02-25 09:03:29 +0000 | [diff] [blame] | 484 | |
Teresa Charlin | e32c844 | 2020-03-05 14:41:50 +0000 | [diff] [blame] | 485 | // SoftReLU Activation |
Keith Davis | 33a626f | 2020-08-27 15:38:12 +0100 | [diff] [blame] | 486 | ARMNN_AUTO_TEST_CASE_WITH_THF(SoftReLu, SoftReLuTest) |
Teresa Charlin | e32c844 | 2020-03-05 14:41:50 +0000 | [diff] [blame] | 487 | |
| 488 | // LeakyReLU Activation |
Keith Davis | 33a626f | 2020-08-27 15:38:12 +0100 | [diff] [blame] | 489 | ARMNN_AUTO_TEST_CASE_WITH_THF(LeakyReLu, LeakyReLuTest) |
Teresa Charlin | e32c844 | 2020-03-05 14:41:50 +0000 | [diff] [blame] | 490 | |
| 491 | // Abs Activation |
Keith Davis | 33a626f | 2020-08-27 15:38:12 +0100 | [diff] [blame] | 492 | ARMNN_AUTO_TEST_CASE_WITH_THF(Abs, AbsTest) |
Narumol Prangnawarat | b98bbcf | 2019-04-15 14:14:27 +0100 | [diff] [blame] | 493 | |
Sadik Armagan | 6095ba5 | 2019-09-13 17:07:19 +0100 | [diff] [blame] | 494 | // Sqrt Activation |
Keith Davis | 33a626f | 2020-08-27 15:38:12 +0100 | [diff] [blame] | 495 | ARMNN_AUTO_TEST_CASE_WITH_THF(Sqrt, SqrtTest) |
| 496 | ARMNN_AUTO_TEST_CASE_WITH_THF(SqrtNN, SqrtNNTest) |
Sadik Armagan | 6095ba5 | 2019-09-13 17:07:19 +0100 | [diff] [blame] | 497 | |
Teresa Charlin | e32c844 | 2020-03-05 14:41:50 +0000 | [diff] [blame] | 498 | // Square Activation |
Keith Davis | 33a626f | 2020-08-27 15:38:12 +0100 | [diff] [blame] | 499 | ARMNN_AUTO_TEST_CASE_WITH_THF(Square, SquareTest) |
Teresa Charlin | e32c844 | 2020-03-05 14:41:50 +0000 | [diff] [blame] | 500 | |
| 501 | // Tanh Activation |
Keith Davis | 33a626f | 2020-08-27 15:38:12 +0100 | [diff] [blame] | 502 | ARMNN_AUTO_TEST_CASE_WITH_THF(Tanh, TanhTest) |
Teresa Charlin | e32c844 | 2020-03-05 14:41:50 +0000 | [diff] [blame] | 503 | |
| 504 | // Elu Activation |
Keith Davis | 33a626f | 2020-08-27 15:38:12 +0100 | [diff] [blame] | 505 | ARMNN_AUTO_TEST_CASE_WITH_THF(Elu, EluTest) |
Teresa Charlin | e32c844 | 2020-03-05 14:41:50 +0000 | [diff] [blame] | 506 | |
Narumol Prangnawarat | 65d3096 | 2019-03-14 11:55:03 +0000 | [diff] [blame] | 507 | // Softmax |
Sadik Armagan | 56785c7 | 2020-08-27 12:57:20 +0100 | [diff] [blame] | 508 | ARMNN_AUTO_TEST_CASE_WITH_THF(SimpleSoftmaxBeta1, SimpleSoftmaxTest, 1.0f) |
| 509 | ARMNN_AUTO_TEST_CASE_WITH_THF(SimpleSoftmaxBeta2, SimpleSoftmaxTest, 2.0f) |
| 510 | ARMNN_AUTO_TEST_CASE_WITH_THF(SimpleSoftmaxBeta1Uint8, SimpleSoftmaxUint8Test, 1.0f) |
| 511 | ARMNN_AUTO_TEST_CASE_WITH_THF(SimpleSoftmaxBeta2Uint8, SimpleSoftmaxUint8Test, 2.0f) |
telsoa01 | 4fcda01 | 2018-03-09 14:13:49 +0000 | [diff] [blame] | 512 | |
Keith Davis | 69e653f | 2020-07-02 11:49:26 +0100 | [diff] [blame] | 513 | // LogSoftmax |
Finn Williams | c43de6a | 2020-08-27 11:13:25 +0100 | [diff] [blame] | 514 | ARMNN_AUTO_TEST_CASE_WITH_THF(LogSoftmaxFloat32_1, LogSoftmaxTest1<DataType::Float32>) |
Keith Davis | 69e653f | 2020-07-02 11:49:26 +0100 | [diff] [blame] | 515 | |
Mike Kelly | 0be3a88 | 2020-01-24 11:27:50 +0000 | [diff] [blame] | 516 | // Space To Batch Nd |
Sadik Armagan | 714fe5b | 2020-08-27 12:46:36 +0100 | [diff] [blame] | 517 | ARMNN_AUTO_TEST_CASE_WITH_THF(SpaceToBatchNdSimpleFloat32, SpaceToBatchNdSimpleFloat32Test) |
| 518 | ARMNN_AUTO_TEST_CASE_WITH_THF(SpaceToBatchNdMultiChannelsFloat32, SpaceToBatchNdMultiChannelsFloat32Test) |
| 519 | ARMNN_AUTO_TEST_CASE_WITH_THF(SpaceToBatchNdMultiBlockFloat32, SpaceToBatchNdMultiBlockFloat32Test) |
| 520 | ARMNN_AUTO_TEST_CASE_WITH_THF(SpaceToBatchNdPaddingFloat32, SpaceToBatchNdPaddingFloat32Test) |
Mike Kelly | 0be3a88 | 2020-01-24 11:27:50 +0000 | [diff] [blame] | 521 | |
Sadik Armagan | 714fe5b | 2020-08-27 12:46:36 +0100 | [diff] [blame] | 522 | ARMNN_AUTO_TEST_CASE_WITH_THF(SpaceToBatchNdSimpleUint8, SpaceToBatchNdSimpleUint8Test) |
| 523 | ARMNN_AUTO_TEST_CASE_WITH_THF(SpaceToBatchNdMultiChannelsUint8, SpaceToBatchNdMultiChannelsUint8Test) |
| 524 | ARMNN_AUTO_TEST_CASE_WITH_THF(SpaceToBatchNdMultiBlockUint8, SpaceToBatchNdMultiBlockUint8Test) |
| 525 | ARMNN_AUTO_TEST_CASE_WITH_THF(SpaceToBatchNdPaddingUint8, SpaceToBatchNdPaddingUint8Test) |
Mike Kelly | 0be3a88 | 2020-01-24 11:27:50 +0000 | [diff] [blame] | 526 | |
Sadik Armagan | 714fe5b | 2020-08-27 12:46:36 +0100 | [diff] [blame] | 527 | ARMNN_AUTO_TEST_CASE_WITH_THF(SpaceToBatchNdSimpleNhwcFloat32, SpaceToBatchNdSimpleNhwcFloat32Test) |
Finn Williams | 826a543 | 2020-08-27 16:15:20 +0100 | [diff] [blame] | 528 | ARMNN_AUTO_TEST_CASE_WITH_THF(SpaceToBatchNdMultiChannelsNhwcFloat32, |
| 529 | SpaceToBatchNdMultiChannelsNhwcFloat32Test) |
Sadik Armagan | 714fe5b | 2020-08-27 12:46:36 +0100 | [diff] [blame] | 530 | ARMNN_AUTO_TEST_CASE_WITH_THF(SpaceToBatchNdMultiBlockNhwcFloat32, SpaceToBatchNdMultiBlockNhwcFloat32Test) |
| 531 | ARMNN_AUTO_TEST_CASE_WITH_THF(SpaceToBatchNdPaddingNhwcFloat32, SpaceToBatchNdPaddingNhwcFloat32Test) |
Mike Kelly | 0be3a88 | 2020-01-24 11:27:50 +0000 | [diff] [blame] | 532 | |
Sadik Armagan | 714fe5b | 2020-08-27 12:46:36 +0100 | [diff] [blame] | 533 | ARMNN_AUTO_TEST_CASE_WITH_THF(SpaceToBatchNdSimpleNhwcUint8, SpaceToBatchNdSimpleNhwcUint8Test) |
Finn Williams | 826a543 | 2020-08-27 16:15:20 +0100 | [diff] [blame] | 534 | ARMNN_AUTO_TEST_CASE_WITH_THF(SpaceToBatchNdMultiChannelsNhwcUint8, |
| 535 | SpaceToBatchNdMultiChannelsNhwcUint8Test) |
Sadik Armagan | 714fe5b | 2020-08-27 12:46:36 +0100 | [diff] [blame] | 536 | ARMNN_AUTO_TEST_CASE_WITH_THF(SpaceToBatchNdMultiBlockNhwcUint8, SpaceToBatchNdMultiBlockNhwcUint8Test) |
| 537 | ARMNN_AUTO_TEST_CASE_WITH_THF(SpaceToBatchNdPaddingNhwcUint8, SpaceToBatchNdPaddingNhwcUint8Test) |
Mike Kelly | 0be3a88 | 2020-01-24 11:27:50 +0000 | [diff] [blame] | 538 | |
Ellen Norris-Thompson | 2979457 | 2019-06-26 16:40:36 +0100 | [diff] [blame] | 539 | // SpaceToDepth |
Sadik Armagan | 5e71984 | 2020-08-28 12:17:33 +0100 | [diff] [blame] | 540 | ARMNN_AUTO_TEST_CASE_WITH_THF(SpaceToDepthNchwAsymmQ8, SpaceToDepthNchwAsymmQ8Test) |
| 541 | ARMNN_AUTO_TEST_CASE_WITH_THF(SpaceToDepthNhwcsymmQ8, SpaceToDepthNhwcAsymmQ8Test) |
Ellen Norris-Thompson | 2979457 | 2019-06-26 16:40:36 +0100 | [diff] [blame] | 542 | |
Sadik Armagan | 5e71984 | 2020-08-28 12:17:33 +0100 | [diff] [blame] | 543 | ARMNN_AUTO_TEST_CASE_WITH_THF(SpaceToDepthNhwc1Float32, SpaceToDepthNhwcFloat32Test1) |
| 544 | ARMNN_AUTO_TEST_CASE_WITH_THF(SpaceToDepthNchw1Float32, SpaceToDepthNchwFloat32Test1) |
Ellen Norris-Thompson | 2979457 | 2019-06-26 16:40:36 +0100 | [diff] [blame] | 545 | |
Sadik Armagan | 5e71984 | 2020-08-28 12:17:33 +0100 | [diff] [blame] | 546 | ARMNN_AUTO_TEST_CASE_WITH_THF(SpaceToDepthNhwc2Float32, SpaceToDepthNhwcFloat32Test2) |
| 547 | ARMNN_AUTO_TEST_CASE_WITH_THF(SpaceToDepthNchw2Float32, SpaceToDepthNchwFloat32Test2) |
Ellen Norris-Thompson | 2979457 | 2019-06-26 16:40:36 +0100 | [diff] [blame] | 548 | |
Sadik Armagan | 5e71984 | 2020-08-28 12:17:33 +0100 | [diff] [blame] | 549 | ARMNN_AUTO_TEST_CASE_WITH_THF(SpaceToDepthNhwcQSymm16, SpaceToDepthNhwcQSymm16Test) |
| 550 | ARMNN_AUTO_TEST_CASE_WITH_THF(SpaceToDepthNchwQSymm16, SpaceToDepthNchwQSymm16Test) |
Ellen Norris-Thompson | 2979457 | 2019-06-26 16:40:36 +0100 | [diff] [blame] | 551 | |
telsoa01 | c577f2c | 2018-08-31 09:22:23 +0100 | [diff] [blame] | 552 | // Splitter |
Sadik Armagan | 5e71984 | 2020-08-28 12:17:33 +0100 | [diff] [blame] | 553 | ARMNN_AUTO_TEST_CASE_WITH_THF(SimpleSplitterFloat32, SplitterFloat32Test) |
| 554 | ARMNN_AUTO_TEST_CASE_WITH_THF(SimpleSplitterUint8, SplitterUint8Test) |
telsoa01 | 4fcda01 | 2018-03-09 14:13:49 +0000 | [diff] [blame] | 555 | |
Sadik Armagan | 5e71984 | 2020-08-28 12:17:33 +0100 | [diff] [blame] | 556 | ARMNN_AUTO_TEST_CASE_WITH_THF(CopyViaSplitterFloat32, CopyViaSplitterFloat32Test) |
| 557 | ARMNN_AUTO_TEST_CASE_WITH_THF(CopyViaSplitterUint8, CopyViaSplitterUint8Test) |
telsoa01 | 4fcda01 | 2018-03-09 14:13:49 +0000 | [diff] [blame] | 558 | |
Jim Flynn | 4ed6c83 | 2019-05-20 11:02:46 +0100 | [diff] [blame] | 559 | // Concat |
Keith Davis | f500d6c | 2020-08-31 08:32:55 +0100 | [diff] [blame] | 560 | ARMNN_AUTO_TEST_CASE_WITH_THF(SimpleConcat, ConcatTest) |
| 561 | ARMNN_AUTO_TEST_CASE_WITH_THF(ConcatUint8, ConcatUint8Test) |
| 562 | ARMNN_AUTO_TEST_CASE_WITH_THF(ConcatUint8DifferentInputOutputQParam, |
Derek Lamberti | f90c56d | 2020-01-10 17:14:08 +0000 | [diff] [blame] | 563 | ConcatDifferentInputOutputQParamTest<DataType::QAsymmU8>, false) |
telsoa01 | 4fcda01 | 2018-03-09 14:13:49 +0000 | [diff] [blame] | 564 | |
Narumol Prangnawarat | 250d392 | 2020-03-30 16:11:04 +0100 | [diff] [blame] | 565 | // Convert from BFloat16 to Float32 |
Keith Davis | f500d6c | 2020-08-31 08:32:55 +0100 | [diff] [blame] | 566 | ARMNN_AUTO_TEST_CASE_WITH_THF(ConvertBf16ToFp32, ConvertBf16ToFp32Test) |
Narumol Prangnawarat | 250d392 | 2020-03-30 16:11:04 +0100 | [diff] [blame] | 567 | |
| 568 | // Convert from Float32 to BFloat16 |
Keith Davis | f500d6c | 2020-08-31 08:32:55 +0100 | [diff] [blame] | 569 | ARMNN_AUTO_TEST_CASE_WITH_THF(ConvertFp32ToBf16, ConvertFp32ToBf16Test) |
Narumol Prangnawarat | 250d392 | 2020-03-30 16:11:04 +0100 | [diff] [blame] | 570 | |
telsoa01 | 4fcda01 | 2018-03-09 14:13:49 +0000 | [diff] [blame] | 571 | // Fully Connected |
Finn Williams | 7faf9a8 | 2020-08-27 10:37:36 +0100 | [diff] [blame] | 572 | ARMNN_AUTO_TEST_CASE_WITH_THF(SimpleFullyConnected, FullyConnectedFloat32Test, false, false) |
| 573 | ARMNN_AUTO_TEST_CASE_WITH_THF(SimpleFullyConnectedWithBias, FullyConnectedFloat32Test, true, false) |
| 574 | ARMNN_AUTO_TEST_CASE_WITH_THF(SimpleFullyConnectedWithTranspose, FullyConnectedFloat32Test, false, true) |
| 575 | ARMNN_AUTO_TEST_CASE_WITH_THF(FullyConnectedLarge, FullyConnectedLargeTest, false) |
| 576 | ARMNN_AUTO_TEST_CASE_WITH_THF(FullyConnectedLargeTransposed, FullyConnectedLargeTest, true) |
| 577 | ARMNN_AUTO_TEST_CASE_WITH_THF(FullyConnectedUint8, FullyConnectedTest<DataType::QAsymmU8>, false) |
| 578 | ARMNN_AUTO_TEST_CASE_WITH_THF(FullyConnectedBiasedUint8, FullyConnectedTest<DataType::QAsymmU8>, true) |
telsoa01 | 4fcda01 | 2018-03-09 14:13:49 +0000 | [diff] [blame] | 579 | |
| 580 | // Add |
Keith Davis | 33a626f | 2020-08-27 15:38:12 +0100 | [diff] [blame] | 581 | ARMNN_AUTO_TEST_CASE_WITH_THF(SimpleAdd, AdditionTest) |
| 582 | ARMNN_AUTO_TEST_CASE_WITH_THF(Add5d, Addition5dTest) |
| 583 | ARMNN_AUTO_TEST_CASE_WITH_THF(AddBroadcast, AdditionBroadcastTest) |
| 584 | ARMNN_AUTO_TEST_CASE_WITH_THF(AddBroadcast1Element, AdditionBroadcast1ElementTest) |
telsoa01 | 4fcda01 | 2018-03-09 14:13:49 +0000 | [diff] [blame] | 585 | |
David Beck | bc39245 | 2018-09-10 14:47:28 +0100 | [diff] [blame] | 586 | // Sub |
Keith Davis | 33a626f | 2020-08-27 15:38:12 +0100 | [diff] [blame] | 587 | ARMNN_AUTO_TEST_CASE_WITH_THF(SimpleSub, SubtractionTest) |
| 588 | ARMNN_AUTO_TEST_CASE_WITH_THF(SubBroadcast1Element, SubtractionBroadcast1ElementTest) |
| 589 | ARMNN_AUTO_TEST_CASE_WITH_THF(SubBroadcast, SubtractionBroadcastTest) |
| 590 | ARMNN_AUTO_TEST_CASE_WITH_THF(SubtractionUint8, SubtractionUint8Test) |
| 591 | ARMNN_AUTO_TEST_CASE_WITH_THF(SubBroadcastUint8, SubtractionBroadcastUint8Test) |
| 592 | ARMNN_AUTO_TEST_CASE_WITH_THF(SubBroadcast1ElementUint8, SubtractionBroadcast1ElementUint8Test) |
David Beck | bc39245 | 2018-09-10 14:47:28 +0100 | [diff] [blame] | 593 | |
Pablo Tello | e61f071 | 2020-01-23 10:37:17 +0000 | [diff] [blame] | 594 | // Div |
Keith Davis | 33a626f | 2020-08-27 15:38:12 +0100 | [diff] [blame] | 595 | ARMNN_AUTO_TEST_CASE_WITH_THF(SimpleDivision, DivisionTest) |
| 596 | ARMNN_AUTO_TEST_CASE_WITH_THF(DivisionByZero, DivisionByZeroTest) |
| 597 | ARMNN_AUTO_TEST_CASE_WITH_THF(DivisionBroadcast1Element, DivisionBroadcast1ElementTest) |
| 598 | ARMNN_AUTO_TEST_CASE_WITH_THF(DivisionBroadcast1DVector, DivisionBroadcast1DVectorTest) |
Pablo Tello | e61f071 | 2020-01-23 10:37:17 +0000 | [diff] [blame] | 599 | |
telsoa01 | 4fcda01 | 2018-03-09 14:13:49 +0000 | [diff] [blame] | 600 | // Mul |
Keith Davis | 33a626f | 2020-08-27 15:38:12 +0100 | [diff] [blame] | 601 | ARMNN_AUTO_TEST_CASE_WITH_THF(SimpleMultiplication, MultiplicationTest) |
| 602 | ARMNN_AUTO_TEST_CASE_WITH_THF(MultiplicationBroadcast1Element, MultiplicationBroadcast1ElementTest) |
| 603 | ARMNN_AUTO_TEST_CASE_WITH_THF(MultiplicationBroadcast1DVector, MultiplicationBroadcast1DVectorTest) |
| 604 | ARMNN_AUTO_TEST_CASE_WITH_THF(MultiplicationUint8, MultiplicationUint8Test) |
| 605 | ARMNN_AUTO_TEST_CASE_WITH_THF(MultiplicationBroadcast1ElementUint8, MultiplicationBroadcast1ElementUint8Test) |
| 606 | ARMNN_AUTO_TEST_CASE_WITH_THF(MultiplicationBroadcast1DVectorUint8, MultiplicationBroadcast1DVectorUint8Test) |
| 607 | ARMNN_AUTO_TEST_CASE_WITH_THF(Multiplication5d, Multiplication5dTest) |
telsoa01 | 4fcda01 | 2018-03-09 14:13:49 +0000 | [diff] [blame] | 608 | |
| 609 | // Batch Norm |
Keith Davis | 33a626f | 2020-08-27 15:38:12 +0100 | [diff] [blame] | 610 | ARMNN_AUTO_TEST_CASE_WITH_THF(BatchNormFloat32, BatchNormFloat32Test) |
| 611 | ARMNN_AUTO_TEST_CASE_WITH_THF(BatchNormFloat32Nhwc, BatchNormFloat32NhwcTest) |
telsoa01 | 4fcda01 | 2018-03-09 14:13:49 +0000 | [diff] [blame] | 612 | |
David Monahan | 97451b4 | 2020-12-03 09:48:06 +0000 | [diff] [blame] | 613 | // Rank |
| 614 | ARMNN_AUTO_TEST_CASE_WITH_THF(RankDimSize1Float16, RankDimSize1Test<DataType::Float16>) |
| 615 | ARMNN_AUTO_TEST_CASE_WITH_THF(RankDimSize1Float32, RankDimSize1Test<DataType::Float32>) |
| 616 | ARMNN_AUTO_TEST_CASE_WITH_THF(RankDimSize1QAsymmU8, RankDimSize1Test<DataType::QAsymmU8>) |
| 617 | ARMNN_AUTO_TEST_CASE_WITH_THF(RankDimSize1Signed32, RankDimSize1Test<DataType::Signed32>) |
| 618 | ARMNN_AUTO_TEST_CASE_WITH_THF(RankDimSize1QSymmS16, RankDimSize1Test<DataType::QSymmS16>) |
| 619 | ARMNN_AUTO_TEST_CASE_WITH_THF(RankDimSize1QAsymmS8, RankDimSize1Test<DataType::QAsymmS8>) |
| 620 | ARMNN_AUTO_TEST_CASE_WITH_THF(RankDimSize1BFloat16, RankDimSize1Test<DataType::BFloat16>) |
| 621 | |
| 622 | ARMNN_AUTO_TEST_CASE_WITH_THF(RankDimSize2Float16, RankDimSize2Test<DataType::Float16>) |
| 623 | ARMNN_AUTO_TEST_CASE_WITH_THF(RankDimSize2Float32, RankDimSize2Test<DataType::Float32>) |
| 624 | ARMNN_AUTO_TEST_CASE_WITH_THF(RankDimSize2QAsymmU8, RankDimSize2Test<DataType::QAsymmU8>) |
| 625 | ARMNN_AUTO_TEST_CASE_WITH_THF(RankDimSize2Signed32, RankDimSize2Test<DataType::Signed32>) |
| 626 | ARMNN_AUTO_TEST_CASE_WITH_THF(RankDimSize2QSymmS16, RankDimSize2Test<DataType::QSymmS16>) |
| 627 | ARMNN_AUTO_TEST_CASE_WITH_THF(RankDimSize2QAsymmS8, RankDimSize2Test<DataType::QAsymmS8>) |
| 628 | ARMNN_AUTO_TEST_CASE_WITH_THF(RankDimSize2BFloat16, RankDimSize2Test<DataType::BFloat16>) |
| 629 | |
| 630 | ARMNN_AUTO_TEST_CASE_WITH_THF(RankDimSize3Float16, RankDimSize3Test<DataType::Float16>) |
| 631 | ARMNN_AUTO_TEST_CASE_WITH_THF(RankDimSize3Float32, RankDimSize3Test<DataType::Float32>) |
| 632 | ARMNN_AUTO_TEST_CASE_WITH_THF(RankDimSize3QAsymmU8, RankDimSize3Test<DataType::QAsymmU8>) |
| 633 | ARMNN_AUTO_TEST_CASE_WITH_THF(RankDimSize3Signed32, RankDimSize3Test<DataType::Signed32>) |
| 634 | ARMNN_AUTO_TEST_CASE_WITH_THF(RankDimSize3QSymmS16, RankDimSize3Test<DataType::QSymmS16>) |
| 635 | ARMNN_AUTO_TEST_CASE_WITH_THF(RankDimSize3QAsymmS8, RankDimSize3Test<DataType::QAsymmS8>) |
| 636 | ARMNN_AUTO_TEST_CASE_WITH_THF(RankDimSize3BFloat16, RankDimSize3Test<DataType::BFloat16>) |
| 637 | |
| 638 | ARMNN_AUTO_TEST_CASE_WITH_THF(RankDimSize4Float16, RankDimSize4Test<DataType::Float16>) |
| 639 | ARMNN_AUTO_TEST_CASE_WITH_THF(RankDimSize4Float32, RankDimSize4Test<DataType::Float32>) |
| 640 | ARMNN_AUTO_TEST_CASE_WITH_THF(RankDimSize4QAsymmU8, RankDimSize4Test<DataType::QAsymmU8>) |
| 641 | ARMNN_AUTO_TEST_CASE_WITH_THF(RankDimSize4Signed32, RankDimSize4Test<DataType::Signed32>) |
| 642 | ARMNN_AUTO_TEST_CASE_WITH_THF(RankDimSize4QSymmS16, RankDimSize4Test<DataType::QSymmS16>) |
| 643 | ARMNN_AUTO_TEST_CASE_WITH_THF(RankDimSize4QAsymmS8, RankDimSize4Test<DataType::QAsymmS8>) |
| 644 | ARMNN_AUTO_TEST_CASE_WITH_THF(RankDimSize4BFloat16, RankDimSize4Test<DataType::BFloat16>) |
| 645 | |
Sadik Armagan | 0d4863d | 2019-10-09 14:26:32 +0100 | [diff] [blame] | 646 | // InstanceNormalization |
Finn Williams | c43de6a | 2020-08-27 11:13:25 +0100 | [diff] [blame] | 647 | ARMNN_AUTO_TEST_CASE_WITH_THF(InstanceNormFloat32Nchw, InstanceNormFloat32Test, DataLayout::NCHW); |
| 648 | ARMNN_AUTO_TEST_CASE_WITH_THF(InstanceNormFloat32Nhwc, InstanceNormFloat32Test, DataLayout::NHWC); |
Sadik Armagan | 0d4863d | 2019-10-09 14:26:32 +0100 | [diff] [blame] | 649 | |
Finn Williams | c43de6a | 2020-08-27 11:13:25 +0100 | [diff] [blame] | 650 | ARMNN_AUTO_TEST_CASE_WITH_THF(InstanceNormFloat32Nchw2, InstanceNormFloat32Test2, DataLayout::NCHW); |
| 651 | ARMNN_AUTO_TEST_CASE_WITH_THF(InstanceNormFloat32Nhwc2, InstanceNormFloat32Test2, DataLayout::NHWC); |
Sadik Armagan | 0d4863d | 2019-10-09 14:26:32 +0100 | [diff] [blame] | 652 | |
telsoa01 | 4fcda01 | 2018-03-09 14:13:49 +0000 | [diff] [blame] | 653 | // Constant |
Keith Davis | f500d6c | 2020-08-31 08:32:55 +0100 | [diff] [blame] | 654 | ARMNN_AUTO_TEST_CASE_WITH_THF(Constant, ConstantTest) |
| 655 | ARMNN_AUTO_TEST_CASE_WITH_THF(ConstantUint8, ConstantUint8SimpleQuantizationScaleNoOffsetTest) |
telsoa01 | 4fcda01 | 2018-03-09 14:13:49 +0000 | [diff] [blame] | 656 | |
Aron Virginas-Tar | 00d306e | 2019-08-28 18:08:46 +0100 | [diff] [blame] | 657 | // Concat |
Keith Davis | f500d6c | 2020-08-31 08:32:55 +0100 | [diff] [blame] | 658 | ARMNN_AUTO_TEST_CASE_WITH_THF(Concat1d, Concat1dTest) |
| 659 | ARMNN_AUTO_TEST_CASE_WITH_THF(Concat1dUint8, Concat1dUint8Test) |
telsoa01 | 4fcda01 | 2018-03-09 14:13:49 +0000 | [diff] [blame] | 660 | |
Keith Davis | f500d6c | 2020-08-31 08:32:55 +0100 | [diff] [blame] | 661 | ARMNN_AUTO_TEST_CASE_WITH_THF(Concat2dDim0, Concat2dDim0Test) |
| 662 | ARMNN_AUTO_TEST_CASE_WITH_THF(Concat2dDim0Uint8, Concat2dDim0Uint8Test) |
| 663 | ARMNN_AUTO_TEST_CASE_WITH_THF(Concat2dDim1, Concat2dDim1Test) |
| 664 | ARMNN_AUTO_TEST_CASE_WITH_THF(Concat2dDim1Uint8, Concat2dDim1Uint8Test) |
telsoa01 | 4fcda01 | 2018-03-09 14:13:49 +0000 | [diff] [blame] | 665 | |
Keith Davis | f500d6c | 2020-08-31 08:32:55 +0100 | [diff] [blame] | 666 | ARMNN_AUTO_TEST_CASE_WITH_THF(Concat2dDim0DiffInputDims, Concat2dDim0DiffInputDimsTest) |
| 667 | ARMNN_AUTO_TEST_CASE_WITH_THF(Concat2dDim0DiffInputDimsUint8, Concat2dDim0DiffInputDimsUint8Test) |
| 668 | ARMNN_AUTO_TEST_CASE_WITH_THF(Concat2dDim1DiffInputDims, Concat2dDim1DiffInputDimsTest) |
| 669 | ARMNN_AUTO_TEST_CASE_WITH_THF(Concat2dDim1DiffInputDimsUint8, Concat2dDim1DiffInputDimsUint8Test) |
telsoa01 | 4fcda01 | 2018-03-09 14:13:49 +0000 | [diff] [blame] | 670 | |
Keith Davis | f500d6c | 2020-08-31 08:32:55 +0100 | [diff] [blame] | 671 | ARMNN_AUTO_TEST_CASE_WITH_THF(Concat3dDim0, Concat3dDim0Test) |
| 672 | ARMNN_AUTO_TEST_CASE_WITH_THF(Concat3dDim0Uint8, Concat3dDim0Uint8Test) |
| 673 | ARMNN_AUTO_TEST_CASE_WITH_THF(Concat3dDim1, Concat3dDim1Test) |
| 674 | ARMNN_AUTO_TEST_CASE_WITH_THF(Concat3dDim1Uint8, Concat3dDim1Uint8Test) |
| 675 | ARMNN_AUTO_TEST_CASE_WITH_THF(Concat3dDim2, Concat3dDim2Test, false) |
| 676 | ARMNN_AUTO_TEST_CASE_WITH_THF(Concat3dDim2Uint8, Concat3dDim2Uint8Test, false) |
telsoa01 | 4fcda01 | 2018-03-09 14:13:49 +0000 | [diff] [blame] | 677 | |
Keith Davis | f500d6c | 2020-08-31 08:32:55 +0100 | [diff] [blame] | 678 | ARMNN_AUTO_TEST_CASE_WITH_THF(Concat3dDim0DiffInputDims, Concat3dDim0DiffInputDimsTest) |
| 679 | ARMNN_AUTO_TEST_CASE_WITH_THF(Concat3dDim0DiffInputDimsUint8, Concat3dDim0DiffInputDimsUint8Test) |
| 680 | ARMNN_AUTO_TEST_CASE_WITH_THF(Concat3dDim1DiffInputDims, Concat3dDim1DiffInputDimsTest) |
| 681 | ARMNN_AUTO_TEST_CASE_WITH_THF(Concat3dDim1DiffInputDimsUint8, Concat3dDim1DiffInputDimsUint8Test) |
| 682 | ARMNN_AUTO_TEST_CASE_WITH_THF(Concat3dDim2DiffInputDims, Concat3dDim2DiffInputDimsTest, false) |
| 683 | ARMNN_AUTO_TEST_CASE_WITH_THF(Concat3dDim2DiffInputDimsUint8, Concat3dDim2DiffInputDimsUint8Test, false) |
telsoa01 | 4fcda01 | 2018-03-09 14:13:49 +0000 | [diff] [blame] | 684 | |
Keith Davis | f500d6c | 2020-08-31 08:32:55 +0100 | [diff] [blame] | 685 | ARMNN_AUTO_TEST_CASE_WITH_THF(Concat4dDim0, Concat4dDim0Test) |
| 686 | ARMNN_AUTO_TEST_CASE_WITH_THF(Concat4dDim1, Concat4dDim1Test) |
| 687 | ARMNN_AUTO_TEST_CASE_WITH_THF(Concat4dDim3, Concat4dDim3Test, false) |
| 688 | ARMNN_AUTO_TEST_CASE_WITH_THF(Concat4dDim0Uint8, Concat4dDim0Uint8Test) |
| 689 | ARMNN_AUTO_TEST_CASE_WITH_THF(Concat4dDim1Uint8, Concat4dDim1Uint8Test) |
| 690 | ARMNN_AUTO_TEST_CASE_WITH_THF(Concat4dDim3Uint8, Concat4dDim3Uint8Test, false) |
narpra01 | 5cdda35 | 2018-11-19 15:30:27 +0000 | [diff] [blame] | 691 | |
Keith Davis | f500d6c | 2020-08-31 08:32:55 +0100 | [diff] [blame] | 692 | ARMNN_AUTO_TEST_CASE_WITH_THF(Concat4dDiffShapeDim0, Concat4dDiffShapeDim0Test) |
| 693 | ARMNN_AUTO_TEST_CASE_WITH_THF(Concat4dDiffShapeDim1, Concat4dDiffShapeDim1Test) |
| 694 | ARMNN_AUTO_TEST_CASE_WITH_THF(Concat4dDiffShapeDim3, Concat4dDiffShapeDim3Test, false) |
| 695 | ARMNN_AUTO_TEST_CASE_WITH_THF(Concat4dDiffShapeDim0Uint8, Concat4dDiffShapeDim0Uint8Test) |
| 696 | ARMNN_AUTO_TEST_CASE_WITH_THF(Concat4dDiffShapeDim1Uint8, Concat4dDiffShapeDim1Uint8Test) |
| 697 | ARMNN_AUTO_TEST_CASE_WITH_THF(Concat4dDiffShapeDim3Uint8, Concat4dDiffShapeDim3Uint8Test, false) |
Sadik Armagan | 0d4863d | 2019-10-09 14:26:32 +0100 | [diff] [blame] | 698 | |
telsoa01 | 4fcda01 | 2018-03-09 14:13:49 +0000 | [diff] [blame] | 699 | // L2 Normalization |
Finn Williams | c43de6a | 2020-08-27 11:13:25 +0100 | [diff] [blame] | 700 | ARMNN_AUTO_TEST_CASE_WITH_THF(L2Normalization1d, L2Normalization1dTest, DataLayout::NCHW) |
| 701 | ARMNN_AUTO_TEST_CASE_WITH_THF(L2Normalization2d, L2Normalization2dTest, DataLayout::NCHW) |
| 702 | ARMNN_AUTO_TEST_CASE_WITH_THF(L2Normalization3d, L2Normalization3dTest, DataLayout::NCHW) |
| 703 | ARMNN_AUTO_TEST_CASE_WITH_THF(L2Normalization4d, L2Normalization4dTest, DataLayout::NCHW) |
Matteo Martincigh | 539b44d | 2018-10-01 09:26:39 +0100 | [diff] [blame] | 704 | |
Finn Williams | c43de6a | 2020-08-27 11:13:25 +0100 | [diff] [blame] | 705 | ARMNN_AUTO_TEST_CASE_WITH_THF(L2Normalization1dNhwc, L2Normalization1dTest, DataLayout::NHWC) |
| 706 | ARMNN_AUTO_TEST_CASE_WITH_THF(L2Normalization2dNhwc, L2Normalization2dTest, DataLayout::NHWC) |
| 707 | ARMNN_AUTO_TEST_CASE_WITH_THF(L2Normalization3dNhwc, L2Normalization3dTest, DataLayout::NHWC) |
| 708 | ARMNN_AUTO_TEST_CASE_WITH_THF(L2Normalization4dNhwc, L2Normalization4dTest, DataLayout::NHWC) |
telsoa01 | 4fcda01 | 2018-03-09 14:13:49 +0000 | [diff] [blame] | 709 | |
Finn Williams | c43de6a | 2020-08-27 11:13:25 +0100 | [diff] [blame] | 710 | ARMNN_AUTO_TEST_CASE_WITH_THF(L2Normalization2dShape, L2Normalization2dShapeTest); |
Matthew Jackson | 82b15ed | 2019-07-25 16:14:30 +0100 | [diff] [blame] | 711 | |
Finn Williams | c43de6a | 2020-08-27 11:13:25 +0100 | [diff] [blame] | 712 | ARMNN_AUTO_TEST_CASE_WITH_THF(L2NormalizationDefaultEpsilon, L2NormalizationDefaultEpsilonTest, DataLayout::NCHW) |
| 713 | ARMNN_AUTO_TEST_CASE_WITH_THF(L2NormalizationNonDefaultEpsilon, L2NormalizationNonDefaultEpsilonTest, DataLayout::NCHW) |
Ferran Balaguer | 0c64f46 | 2019-06-18 16:32:30 +0100 | [diff] [blame] | 714 | |
telsoa01 | 4fcda01 | 2018-03-09 14:13:49 +0000 | [diff] [blame] | 715 | // Floor |
Finn Williams | 7faf9a8 | 2020-08-27 10:37:36 +0100 | [diff] [blame] | 716 | ARMNN_AUTO_TEST_CASE_WITH_THF(SimpleFloor, SimpleFloorTest<DataType::Float32>) |
telsoa01 | 4fcda01 | 2018-03-09 14:13:49 +0000 | [diff] [blame] | 717 | |
Teresa Charlin | f540eb8 | 2020-04-10 19:24:55 +0100 | [diff] [blame] | 718 | // Gather |
Finn Williams | c43de6a | 2020-08-27 11:13:25 +0100 | [diff] [blame] | 719 | ARMNN_AUTO_TEST_CASE_WITH_THF(Gather1dParamsFloat32, Gather1dParamsFloat32Test) |
| 720 | ARMNN_AUTO_TEST_CASE_WITH_THF(Gather1dParamsUint8, Gather1dParamsUint8Test) |
| 721 | ARMNN_AUTO_TEST_CASE_WITH_THF(GatherMultiDimParamsFloat32, GatherMultiDimParamsFloat32Test) |
| 722 | ARMNN_AUTO_TEST_CASE_WITH_THF(GatherMultiDimParamsUint8, GatherMultiDimParamsUint8Test) |
Teresa Charlin | f540eb8 | 2020-04-10 19:24:55 +0100 | [diff] [blame] | 723 | |
Teresa Charlin | cedd34f | 2020-03-30 11:17:30 +0100 | [diff] [blame] | 724 | // Equal |
Keith Davis | f500d6c | 2020-08-31 08:32:55 +0100 | [diff] [blame] | 725 | ARMNN_AUTO_TEST_CASE_WITH_THF(EqualSimple, EqualSimpleTest) |
| 726 | ARMNN_AUTO_TEST_CASE_WITH_THF(EqualBroadcast1Element, EqualBroadcast1ElementTest) |
| 727 | ARMNN_AUTO_TEST_CASE_WITH_THF(EqualBroadcast1dVector, EqualBroadcast1dVectorTest) |
Teresa Charlin | cedd34f | 2020-03-30 11:17:30 +0100 | [diff] [blame] | 728 | |
Keith Davis | f500d6c | 2020-08-31 08:32:55 +0100 | [diff] [blame] | 729 | ARMNN_AUTO_TEST_CASE_WITH_THF(EqualSimpleUint8, EqualSimpleUint8Test) |
| 730 | ARMNN_AUTO_TEST_CASE_WITH_THF(EqualBroadcast1ElementUint8, EqualBroadcast1ElementUint8Test) |
| 731 | ARMNN_AUTO_TEST_CASE_WITH_THF(EqualBroadcast1dVectorUint8, EqualBroadcast1dVectorUint8Test) |
Teresa Charlin | cedd34f | 2020-03-30 11:17:30 +0100 | [diff] [blame] | 732 | |
kevmay01 | eed8592 | 2019-01-28 08:37:25 +0000 | [diff] [blame] | 733 | // Greater |
Keith Davis | f500d6c | 2020-08-31 08:32:55 +0100 | [diff] [blame] | 734 | ARMNN_AUTO_TEST_CASE_WITH_THF(GreaterSimple, GreaterSimpleTest) |
| 735 | ARMNN_AUTO_TEST_CASE_WITH_THF(GreaterBroadcast1Element, GreaterBroadcast1ElementTest) |
| 736 | ARMNN_AUTO_TEST_CASE_WITH_THF(GreaterBroadcast1dVector, GreaterBroadcast1dVectorTest) |
Aron Virginas-Tar | 3bc00ec | 2019-10-18 15:42:58 +0100 | [diff] [blame] | 737 | |
Keith Davis | f500d6c | 2020-08-31 08:32:55 +0100 | [diff] [blame] | 738 | ARMNN_AUTO_TEST_CASE_WITH_THF(GreaterSimpleUint8, GreaterSimpleUint8Test) |
| 739 | ARMNN_AUTO_TEST_CASE_WITH_THF(GreaterBroadcast1ElementUint8, GreaterBroadcast1ElementUint8Test) |
| 740 | ARMNN_AUTO_TEST_CASE_WITH_THF(GreaterBroadcast1dVectorUint8, GreaterBroadcast1dVectorUint8Test) |
kevmay01 | eed8592 | 2019-01-28 08:37:25 +0000 | [diff] [blame] | 741 | |
Teresa Charlin | cedd34f | 2020-03-30 11:17:30 +0100 | [diff] [blame] | 742 | // GreaterOrEqual |
Keith Davis | f500d6c | 2020-08-31 08:32:55 +0100 | [diff] [blame] | 743 | ARMNN_AUTO_TEST_CASE_WITH_THF(GreaterOrEqualSimple, GreaterOrEqualSimpleTest) |
| 744 | ARMNN_AUTO_TEST_CASE_WITH_THF(GreaterOrEqualBroadcast1Element, GreaterOrEqualBroadcast1ElementTest) |
| 745 | ARMNN_AUTO_TEST_CASE_WITH_THF(GreaterOrEqualBroadcast1dVector, GreaterOrEqualBroadcast1dVectorTest) |
Teresa Charlin | cedd34f | 2020-03-30 11:17:30 +0100 | [diff] [blame] | 746 | |
Keith Davis | f500d6c | 2020-08-31 08:32:55 +0100 | [diff] [blame] | 747 | ARMNN_AUTO_TEST_CASE_WITH_THF(GreaterOrEqualSimpleUint8, GreaterOrEqualSimpleUint8Test) |
| 748 | ARMNN_AUTO_TEST_CASE_WITH_THF(GreaterOrEqualBroadcast1ElementUint8, GreaterOrEqualBroadcast1ElementUint8Test) |
| 749 | ARMNN_AUTO_TEST_CASE_WITH_THF(GreaterOrEqualBroadcast1dVectorUint8, GreaterOrEqualBroadcast1dVectorUint8Test) |
Teresa Charlin | cedd34f | 2020-03-30 11:17:30 +0100 | [diff] [blame] | 750 | |
| 751 | // Less |
Keith Davis | f500d6c | 2020-08-31 08:32:55 +0100 | [diff] [blame] | 752 | ARMNN_AUTO_TEST_CASE_WITH_THF(LessSimple, LessSimpleTest) |
| 753 | ARMNN_AUTO_TEST_CASE_WITH_THF(LessBroadcast1Element, LessBroadcast1ElementTest) |
| 754 | ARMNN_AUTO_TEST_CASE_WITH_THF(LessBroadcast1dVector, LessBroadcast1dVectorTest) |
Teresa Charlin | cedd34f | 2020-03-30 11:17:30 +0100 | [diff] [blame] | 755 | |
Keith Davis | f500d6c | 2020-08-31 08:32:55 +0100 | [diff] [blame] | 756 | ARMNN_AUTO_TEST_CASE_WITH_THF(LessSimpleUint8, LessSimpleUint8Test) |
| 757 | ARMNN_AUTO_TEST_CASE_WITH_THF(LessBroadcast1ElementUint8, LessBroadcast1ElementUint8Test) |
| 758 | ARMNN_AUTO_TEST_CASE_WITH_THF(LessBroadcast1dVectorUint8, LessBroadcast1dVectorUint8Test) |
Teresa Charlin | cedd34f | 2020-03-30 11:17:30 +0100 | [diff] [blame] | 759 | |
| 760 | // LessOrEqual |
Keith Davis | f500d6c | 2020-08-31 08:32:55 +0100 | [diff] [blame] | 761 | ARMNN_AUTO_TEST_CASE_WITH_THF(LessOrEqualSimple, LessOrEqualSimpleTest) |
| 762 | ARMNN_AUTO_TEST_CASE_WITH_THF(LessOrEqualBroadcast1Element, LessOrEqualBroadcast1ElementTest) |
| 763 | ARMNN_AUTO_TEST_CASE_WITH_THF(LessOrEqualBroadcast1dVector, LessOrEqualBroadcast1dVectorTest) |
Teresa Charlin | cedd34f | 2020-03-30 11:17:30 +0100 | [diff] [blame] | 764 | |
Keith Davis | f500d6c | 2020-08-31 08:32:55 +0100 | [diff] [blame] | 765 | ARMNN_AUTO_TEST_CASE_WITH_THF(LessOrEqualSimpleUint8, LessOrEqualSimpleUint8Test) |
| 766 | ARMNN_AUTO_TEST_CASE_WITH_THF(LessOrEqualBroadcast1ElementUint8, LessOrEqualBroadcast1ElementUint8Test) |
| 767 | ARMNN_AUTO_TEST_CASE_WITH_THF(LessOrEqualBroadcast1dVectorUint8, LessOrEqualBroadcast1dVectorUint8Test) |
Teresa Charlin | cedd34f | 2020-03-30 11:17:30 +0100 | [diff] [blame] | 768 | |
| 769 | // NotEqual |
Keith Davis | f500d6c | 2020-08-31 08:32:55 +0100 | [diff] [blame] | 770 | ARMNN_AUTO_TEST_CASE_WITH_THF(NotEqualSimple, NotEqualSimpleTest) |
| 771 | ARMNN_AUTO_TEST_CASE_WITH_THF(NotEqualBroadcast1Element, NotEqualBroadcast1ElementTest) |
| 772 | ARMNN_AUTO_TEST_CASE_WITH_THF(NotEqualBroadcast1dVector, NotEqualBroadcast1dVectorTest) |
Teresa Charlin | cedd34f | 2020-03-30 11:17:30 +0100 | [diff] [blame] | 773 | |
Keith Davis | f500d6c | 2020-08-31 08:32:55 +0100 | [diff] [blame] | 774 | ARMNN_AUTO_TEST_CASE_WITH_THF(NotEqualSimpleUint8, NotEqualSimpleUint8Test) |
| 775 | ARMNN_AUTO_TEST_CASE_WITH_THF(NotEqualBroadcast1ElementUint8, NotEqualBroadcast1ElementUint8Test) |
| 776 | ARMNN_AUTO_TEST_CASE_WITH_THF(NotEqualBroadcast1dVectorUint8, NotEqualBroadcast1dVectorUint8Test) |
Teresa Charlin | cedd34f | 2020-03-30 11:17:30 +0100 | [diff] [blame] | 777 | |
telsoa01 | 4fcda01 | 2018-03-09 14:13:49 +0000 | [diff] [blame] | 778 | // Reshape |
Finn Williams | ec36d3e | 2020-08-28 13:17:05 +0100 | [diff] [blame] | 779 | ARMNN_AUTO_TEST_CASE_WITH_THF(SimpleReshapeFloat32, SimpleReshapeTest<armnn::DataType::Float32>) |
| 780 | ARMNN_AUTO_TEST_CASE_WITH_THF(SimpleReshapeInt8, SimpleReshapeTest<armnn::DataType::QAsymmS8>) |
| 781 | ARMNN_AUTO_TEST_CASE_WITH_THF(SimpleReshapeUint8, SimpleReshapeTest<armnn::DataType::QAsymmU8>) |
| 782 | ARMNN_AUTO_TEST_CASE_WITH_THF(Reshape5d, Reshape5dTest<armnn::DataType::Float32>) |
Narumol Prangnawarat | 0c95f4c | 2020-11-18 16:52:07 +0000 | [diff] [blame] | 783 | ARMNN_AUTO_TEST_CASE_WITH_THF(ReshapeBoolean, ReshapeBooleanTest) |
telsoa01 | 4fcda01 | 2018-03-09 14:13:49 +0000 | [diff] [blame] | 784 | |
Éanna Ó Catháin | 1205574 | 2019-01-25 10:01:40 +0000 | [diff] [blame] | 785 | // Pad |
Finn Williams | 826a543 | 2020-08-27 16:15:20 +0100 | [diff] [blame] | 786 | ARMNN_AUTO_TEST_CASE_WITH_THF(PadFloat322d, PadFloat322dTest) |
| 787 | ARMNN_AUTO_TEST_CASE_WITH_THF(PadFloat322dCustomPadding, PadFloat322dCustomPaddingTest) |
| 788 | ARMNN_AUTO_TEST_CASE_WITH_THF(PadFloat323d, PadFloat323dTest) |
| 789 | ARMNN_AUTO_TEST_CASE_WITH_THF(PadFloat324d, PadFloat324dTest) |
Éanna Ó Catháin | 1205574 | 2019-01-25 10:01:40 +0000 | [diff] [blame] | 790 | |
Finn Williams | 826a543 | 2020-08-27 16:15:20 +0100 | [diff] [blame] | 791 | ARMNN_AUTO_TEST_CASE_WITH_THF(PadUint82d, PadUint82dTest) |
| 792 | ARMNN_AUTO_TEST_CASE_WITH_THF(PadUint82dCustomPadding, PadUint82dCustomPaddingTest) |
| 793 | ARMNN_AUTO_TEST_CASE_WITH_THF(PadUint83d, PadUint83dTest) |
| 794 | ARMNN_AUTO_TEST_CASE_WITH_THF(PadUint84d, PadUint84dTest) |
Teresa Charlin | ec8e198 | 2019-07-02 16:24:09 +0100 | [diff] [blame] | 795 | |
Finn Williams | 826a543 | 2020-08-27 16:15:20 +0100 | [diff] [blame] | 796 | ARMNN_AUTO_TEST_CASE_WITH_THF(Pad2dQSymm16, Pad2dTestCommon<DataType::QSymmS16>, 2.0f, 0, 0.0f) |
| 797 | ARMNN_AUTO_TEST_CASE_WITH_THF(Pad2dQSymm16CustomPadding, Pad2dTestCommon<DataType::QSymmS16>, 2.0f, 0, 1.0f) |
| 798 | ARMNN_AUTO_TEST_CASE_WITH_THF(Pad3dQSymm16, Pad3dTestCommon<DataType::QSymmS16>, 2.0f, 0) |
| 799 | ARMNN_AUTO_TEST_CASE_WITH_THF(Pad4dQSymm16, Pad4dTestCommon<DataType::QSymmS16>, 2.0f, 0) |
FinnWilliamsArm | 8b797a8 | 2019-07-09 16:01:41 +0100 | [diff] [blame] | 800 | |
telsoa01 | 4fcda01 | 2018-03-09 14:13:49 +0000 | [diff] [blame] | 801 | // Permute |
Finn Williams | 826a543 | 2020-08-27 16:15:20 +0100 | [diff] [blame] | 802 | ARMNN_AUTO_TEST_CASE_WITH_THF(SimplePermuteFloat32, SimplePermuteTest<DataType::Float32>) |
| 803 | ARMNN_AUTO_TEST_CASE_WITH_THF(PermuteFloat32ValueSet1Test, PermuteValueSet1Test<DataType::Float32>) |
| 804 | ARMNN_AUTO_TEST_CASE_WITH_THF(PermuteFloat32ValueSet2Test, PermuteValueSet2Test<DataType::Float32>) |
| 805 | ARMNN_AUTO_TEST_CASE_WITH_THF(PermuteFloat32ValueSet3Test, PermuteValueSet3Test<DataType::Float32>) |
| 806 | ARMNN_AUTO_TEST_CASE_WITH_THF(SimplePermuteQASymmS8, SimplePermuteTest<DataType::QAsymmS8>) |
| 807 | ARMNN_AUTO_TEST_CASE_WITH_THF(PermuteQASymmS8ValueSet1Test, PermuteValueSet1Test<DataType::QAsymmS8>) |
| 808 | ARMNN_AUTO_TEST_CASE_WITH_THF(PermuteQASymmS8ValueSet2Test, PermuteValueSet2Test<DataType::QAsymmS8>) |
| 809 | ARMNN_AUTO_TEST_CASE_WITH_THF(PermuteQASymmS8ValueSet3Test, PermuteValueSet3Test<DataType::QAsymmS8>) |
| 810 | ARMNN_AUTO_TEST_CASE_WITH_THF(SimplePermuteQASymm8, SimplePermuteTest<DataType::QAsymmU8>) |
| 811 | ARMNN_AUTO_TEST_CASE_WITH_THF(PermuteQASymm8ValueSet1Test, PermuteValueSet1Test<DataType::QAsymmU8>) |
| 812 | ARMNN_AUTO_TEST_CASE_WITH_THF(PermuteQASymm8ValueSet2Test, PermuteValueSet2Test<DataType::QAsymmU8>) |
| 813 | ARMNN_AUTO_TEST_CASE_WITH_THF(PermuteQASymm8ValueSet3Test, PermuteValueSet3Test<DataType::QAsymmU8>) |
surmeh01 | bceff2f | 2018-03-29 16:29:27 +0100 | [diff] [blame] | 814 | |
Les Bell | de9011b | 2018-10-03 10:37:52 +0100 | [diff] [blame] | 815 | // Lstm |
Finn Williams | c43de6a | 2020-08-27 11:13:25 +0100 | [diff] [blame] | 816 | ARMNN_AUTO_TEST_CASE_WITH_THF(LstmLayerFloat32WithCifgWithPeepholeNoProjection, |
| 817 | LstmLayerFloat32WithCifgWithPeepholeNoProjectionTest) |
| 818 | ARMNN_AUTO_TEST_CASE_WITH_THF(LstmLayerFloat32NoCifgNoPeepholeNoProjection, |
| 819 | LstmLayerFloat32NoCifgNoPeepholeNoProjectionTest) |
| 820 | ARMNN_AUTO_TEST_CASE_WITH_THF(LstmLayerFloat32NoCifgWithPeepholeWithProjection, |
| 821 | LstmLayerFloat32NoCifgWithPeepholeWithProjectionTest) |
| 822 | ARMNN_AUTO_TEST_CASE_WITH_THF(LstmLayerFloat32NoCifgWithPeepholeWithProjectionWithLayerNorm, |
| 823 | LstmLayerFloat32NoCifgWithPeepholeWithProjectionWithLayerNormTest) |
Les Bell | de9011b | 2018-10-03 10:37:52 +0100 | [diff] [blame] | 824 | |
James Conroy | cc34093 | 2020-05-12 18:08:52 +0100 | [diff] [blame] | 825 | // QLstm |
Finn Williams | c43de6a | 2020-08-27 11:13:25 +0100 | [diff] [blame] | 826 | ARMNN_AUTO_TEST_CASE_WITH_THF(QLstm, QLstmTest) |
| 827 | ARMNN_AUTO_TEST_CASE_WITH_THF(QLstm1, QLstmTest1) |
| 828 | ARMNN_AUTO_TEST_CASE_WITH_THF(QLstm2, QLstmTest2) |
James Conroy | cc34093 | 2020-05-12 18:08:52 +0100 | [diff] [blame] | 829 | |
| 830 | // QuantizedLstm |
Finn Williams | c43de6a | 2020-08-27 11:13:25 +0100 | [diff] [blame] | 831 | ARMNN_AUTO_TEST_CASE_WITH_THF(QuantizedLstm, QuantizedLstmTest) |
Francis Murtagh | 4fc3c48 | 2019-08-02 13:20:54 +0100 | [diff] [blame] | 832 | |
Matthew Bentham | fd89996 | 2018-12-31 15:49:42 +0000 | [diff] [blame] | 833 | // Mean |
Finn Williams | 826a543 | 2020-08-27 16:15:20 +0100 | [diff] [blame] | 834 | ARMNN_AUTO_TEST_CASE_WITH_THF(MeanSimpleFloat32, MeanSimpleTest<DataType::Float32>) |
| 835 | ARMNN_AUTO_TEST_CASE_WITH_THF(MeanSimpleAxisFloat32, MeanSimpleAxisTest<DataType::Float32>) |
| 836 | ARMNN_AUTO_TEST_CASE_WITH_THF(MeanKeepDimsFloat32, MeanKeepDimsTest<DataType::Float32>) |
| 837 | ARMNN_AUTO_TEST_CASE_WITH_THF(MeanMultipleDimsFloat32, MeanMultipleDimsTest<DataType::Float32>) |
| 838 | ARMNN_AUTO_TEST_CASE_WITH_THF(MeanVts1Float32, MeanVts1Test<DataType::Float32>) |
| 839 | ARMNN_AUTO_TEST_CASE_WITH_THF(MeanVts2Float32, MeanVts2Test<DataType::Float32>) |
| 840 | ARMNN_AUTO_TEST_CASE_WITH_THF(MeanVts3Float32, MeanVts3Test<DataType::Float32>) |
Matthew Bentham | fd89996 | 2018-12-31 15:49:42 +0000 | [diff] [blame] | 841 | |
Finn Williams | 826a543 | 2020-08-27 16:15:20 +0100 | [diff] [blame] | 842 | ARMNN_AUTO_TEST_CASE_WITH_THF(MeanSimpleQuantisedAsymmS8, MeanSimpleTest<DataType::QAsymmS8>) |
| 843 | ARMNN_AUTO_TEST_CASE_WITH_THF(MeanSimpleAxisQuantisedAsymmS8, MeanSimpleAxisTest<DataType::QAsymmS8>) |
| 844 | ARMNN_AUTO_TEST_CASE_WITH_THF(MeanKeepDimsQuantisedAsymmS8, MeanKeepDimsTest<DataType::QAsymmS8>) |
| 845 | ARMNN_AUTO_TEST_CASE_WITH_THF(MeanMultipleDimsQuantisedAsymmS8, MeanMultipleDimsTest<DataType::QAsymmS8>) |
| 846 | ARMNN_AUTO_TEST_CASE_WITH_THF(MeanVts1QuantisedAsymmS8, MeanVts1Test<DataType::QAsymmS8>) |
| 847 | ARMNN_AUTO_TEST_CASE_WITH_THF(MeanVts2QuantisedAsymmS8, MeanVts2Test<DataType::QAsymmS8>) |
| 848 | ARMNN_AUTO_TEST_CASE_WITH_THF(MeanVts3QuantisedAsymmS8, MeanVts3Test<DataType::QAsymmS8>) |
Sadik Armagan | 303980c | 2020-04-17 12:45:14 +0100 | [diff] [blame] | 849 | |
Finn Williams | 826a543 | 2020-08-27 16:15:20 +0100 | [diff] [blame] | 850 | ARMNN_AUTO_TEST_CASE_WITH_THF(MeanSimpleQuantisedAsymm8, MeanSimpleTest<DataType::QAsymmU8>) |
| 851 | ARMNN_AUTO_TEST_CASE_WITH_THF(MeanSimpleAxisQuantisedAsymm8, MeanSimpleAxisTest<DataType::QAsymmU8>) |
| 852 | ARMNN_AUTO_TEST_CASE_WITH_THF(MeanKeepDimsQuantisedAsymm8, MeanKeepDimsTest<DataType::QAsymmU8>) |
| 853 | ARMNN_AUTO_TEST_CASE_WITH_THF(MeanMultipleDimsQuantisedAsymm8, MeanMultipleDimsTest<DataType::QAsymmU8>) |
| 854 | ARMNN_AUTO_TEST_CASE_WITH_THF(MeanVts1QuantisedAsymm8, MeanVts1Test<DataType::QAsymmU8>) |
| 855 | ARMNN_AUTO_TEST_CASE_WITH_THF(MeanVts2QuantisedAsymm8, MeanVts2Test<DataType::QAsymmU8>) |
| 856 | ARMNN_AUTO_TEST_CASE_WITH_THF(MeanVts3QuantisedAsymm8, MeanVts3Test<DataType::QAsymmU8>) |
Matthew Bentham | fd89996 | 2018-12-31 15:49:42 +0000 | [diff] [blame] | 857 | |
Nattapat Chaimanowong | 4e6597a | 2018-12-20 14:14:06 +0000 | [diff] [blame] | 858 | // Max |
Keith Davis | 33a626f | 2020-08-27 15:38:12 +0100 | [diff] [blame] | 859 | ARMNN_AUTO_TEST_CASE_WITH_THF(SimpleMaximum, MaximumSimpleTest) |
| 860 | ARMNN_AUTO_TEST_CASE_WITH_THF(MaximumBroadcast1Element, MaximumBroadcast1ElementTest) |
| 861 | ARMNN_AUTO_TEST_CASE_WITH_THF(MaximumBroadcast1DVector, MaximumBroadcast1DVectorTest) |
| 862 | ARMNN_AUTO_TEST_CASE_WITH_THF(MaximumUint8, MaximumUint8Test) |
| 863 | ARMNN_AUTO_TEST_CASE_WITH_THF(MaximumBroadcast1ElementUint8, MaximumBroadcast1ElementUint8Test) |
| 864 | ARMNN_AUTO_TEST_CASE_WITH_THF(MaximumBroadcast1DVectorUint8, MaximumBroadcast1DVectorUint8Test) |
Nattapat Chaimanowong | 4e6597a | 2018-12-20 14:14:06 +0000 | [diff] [blame] | 865 | |
Conor Kennedy | 54b2169 | 2019-01-09 07:57:38 +0000 | [diff] [blame] | 866 | // Min |
Keith Davis | 33a626f | 2020-08-27 15:38:12 +0100 | [diff] [blame] | 867 | ARMNN_AUTO_TEST_CASE_WITH_THF(SimpleMinimum1, MinimumBroadcast1ElementTest1) |
| 868 | ARMNN_AUTO_TEST_CASE_WITH_THF(SimpleMinimum2, MinimumBroadcast1ElementTest2) |
| 869 | ARMNN_AUTO_TEST_CASE_WITH_THF(Minimum1DVectorUint8, MinimumBroadcast1DVectorUint8Test) |
Conor Kennedy | 54b2169 | 2019-01-09 07:57:38 +0000 | [diff] [blame] | 870 | |
narpra01 | 55a97bc | 2018-10-02 14:35:53 +0100 | [diff] [blame] | 871 | // Normalization |
Finn Williams | 826a543 | 2020-08-27 16:15:20 +0100 | [diff] [blame] | 872 | ARMNN_AUTO_TEST_CASE_WITH_THF(SimpleNormalizationAcross, SimpleNormalizationAcrossTest) |
| 873 | ARMNN_AUTO_TEST_CASE_WITH_THF(SimpleNormalizationWithin, SimpleNormalizationWithinTest) |
| 874 | ARMNN_AUTO_TEST_CASE_WITH_THF(SimpleNormalizationAcrossNhwc, SimpleNormalizationAcrossNhwcTest) |
narpra01 | 55a97bc | 2018-10-02 14:35:53 +0100 | [diff] [blame] | 875 | |
Sadik Armagan | c625f00 | 2018-12-17 11:32:16 +0000 | [diff] [blame] | 876 | // Resize Bilinear - NCHW data layout |
Finn Williams | ec36d3e | 2020-08-28 13:17:05 +0100 | [diff] [blame] | 877 | ARMNN_AUTO_TEST_CASE_WITH_THF(SimpleResizeBilinear, SimpleResizeBilinearTest<DataType::Float32>, DataLayout::NCHW) |
| 878 | ARMNN_AUTO_TEST_CASE_WITH_THF(ResizeBilinearNop, ResizeBilinearNopTest<DataType::Float32>, DataLayout::NCHW) |
| 879 | ARMNN_AUTO_TEST_CASE_WITH_THF(ResizeBilinearSqMin, ResizeBilinearSqMinTest<DataType::Float32>, DataLayout::NCHW) |
| 880 | ARMNN_AUTO_TEST_CASE_WITH_THF(ResizeBilinearMin, ResizeBilinearMinTest<DataType::Float32>, DataLayout::NCHW) |
| 881 | ARMNN_AUTO_TEST_CASE_WITH_THF(ResizeBilinearMag, ResizeBilinearMagTest<DataType::Float32>, DataLayout::NCHW) |
Sadik Armagan | c625f00 | 2018-12-17 11:32:16 +0000 | [diff] [blame] | 882 | |
Finn Williams | ec36d3e | 2020-08-28 13:17:05 +0100 | [diff] [blame] | 883 | ARMNN_AUTO_TEST_CASE_WITH_THF(SimpleResizeBilinearUint8, |
| 884 | SimpleResizeBilinearTest<DataType::QAsymmU8>, |
| 885 | DataLayout::NCHW) |
| 886 | ARMNN_AUTO_TEST_CASE_WITH_THF(ResizeBilinearNopUint8, |
| 887 | ResizeBilinearNopTest<DataType::QAsymmU8>, |
| 888 | DataLayout::NCHW) |
| 889 | ARMNN_AUTO_TEST_CASE_WITH_THF(ResizeBilinearSqMinUint8, |
| 890 | ResizeBilinearSqMinTest<DataType::QAsymmU8>, |
| 891 | DataLayout::NCHW) |
| 892 | ARMNN_AUTO_TEST_CASE_WITH_THF(ResizeBilinearMinUint8, |
| 893 | ResizeBilinearMinTest<DataType::QAsymmU8>, |
| 894 | DataLayout::NCHW) |
| 895 | ARMNN_AUTO_TEST_CASE_WITH_THF(ResizeBilinearMagUint8, |
| 896 | ResizeBilinearMagTest<DataType::QAsymmU8>, |
| 897 | DataLayout::NCHW) |
Conor Kennedy | dc1c082 | 2019-02-01 07:23:17 +0000 | [diff] [blame] | 898 | |
Finn Williams | ec36d3e | 2020-08-28 13:17:05 +0100 | [diff] [blame] | 899 | ARMNN_AUTO_TEST_CASE_WITH_THF(HalfPixelCentersResizeBilinear, |
| 900 | HalfPixelCentersResizeBilinearTest<DataType::Float32>, |
| 901 | DataLayout::NCHW) |
| 902 | ARMNN_AUTO_TEST_CASE_WITH_THF(AlignCornersResizeBilinear, |
| 903 | AlignCornersResizeBilinearTest<DataType::Float32>, |
| 904 | DataLayout::NCHW) |
| 905 | ARMNN_AUTO_TEST_CASE_WITH_THF(HalfPixelCentersResizeBilinearInt8, |
| 906 | HalfPixelCentersResizeBilinearTest<DataType::QAsymmS8>, |
| 907 | DataLayout::NCHW) |
| 908 | ARMNN_AUTO_TEST_CASE_WITH_THF(AlignCornersResizeBilinearInt8, |
| 909 | AlignCornersResizeBilinearTest<DataType::QAsymmS8>, |
| 910 | DataLayout::NCHW) |
| 911 | ARMNN_AUTO_TEST_CASE_WITH_THF(HalfPixelCentersResizeBilinearUint8, |
| 912 | HalfPixelCentersResizeBilinearTest<DataType::QAsymmU8>, |
| 913 | DataLayout::NCHW) |
| 914 | ARMNN_AUTO_TEST_CASE_WITH_THF(AlignCornersResizeBilinearUint8, |
| 915 | AlignCornersResizeBilinearTest<DataType::QAsymmU8>, |
| 916 | DataLayout::NCHW) |
Teresa Charlin | 686f45c | 2020-07-23 17:59:00 +0100 | [diff] [blame] | 917 | |
Sadik Armagan | c625f00 | 2018-12-17 11:32:16 +0000 | [diff] [blame] | 918 | // Resize Bilinear - NHWC data layout |
Finn Williams | ec36d3e | 2020-08-28 13:17:05 +0100 | [diff] [blame] | 919 | ARMNN_AUTO_TEST_CASE_WITH_THF(ResizeBilinearNopNhwc, |
| 920 | ResizeBilinearNopTest<DataType::Float32>, |
| 921 | DataLayout::NHWC) |
| 922 | ARMNN_AUTO_TEST_CASE_WITH_THF(SimpleResizeBilinearNhwc, |
| 923 | SimpleResizeBilinearTest<DataType::Float32>, |
| 924 | DataLayout::NHWC) |
| 925 | ARMNN_AUTO_TEST_CASE_WITH_THF(ResizeBilinearSqMinNhwc, |
| 926 | ResizeBilinearSqMinTest<DataType::Float32>, |
| 927 | DataLayout::NHWC) |
| 928 | ARMNN_AUTO_TEST_CASE_WITH_THF(ResizeBilinearMinNhwc, |
| 929 | ResizeBilinearMinTest<DataType::Float32>, |
| 930 | DataLayout::NHWC) |
| 931 | ARMNN_AUTO_TEST_CASE_WITH_THF(ResizeBilinearMagNhwc, |
| 932 | ResizeBilinearMagTest<DataType::Float32>, |
| 933 | DataLayout::NHWC) |
Ellen Norris-Thompson | c4223d1 | 2019-06-10 14:15:12 +0100 | [diff] [blame] | 934 | |
Finn Williams | ec36d3e | 2020-08-28 13:17:05 +0100 | [diff] [blame] | 935 | ARMNN_AUTO_TEST_CASE_WITH_THF(ResizeBilinearNopUint8Nhwc, |
| 936 | ResizeBilinearNopTest<DataType::QAsymmU8>, |
| 937 | DataLayout::NHWC) |
| 938 | ARMNN_AUTO_TEST_CASE_WITH_THF(SimpleResizeBilinearUint8Nhwc, |
| 939 | SimpleResizeBilinearTest<DataType::QAsymmU8>, |
| 940 | DataLayout::NHWC) |
| 941 | ARMNN_AUTO_TEST_CASE_WITH_THF(ResizeBilinearSqMinUint8Nhwc, |
| 942 | ResizeBilinearSqMinTest<DataType::QAsymmU8>, |
| 943 | DataLayout::NHWC) |
| 944 | ARMNN_AUTO_TEST_CASE_WITH_THF(ResizeBilinearMinUint8Nhwc, |
| 945 | ResizeBilinearMinTest<DataType::QAsymmU8>, |
| 946 | DataLayout::NHWC) |
| 947 | ARMNN_AUTO_TEST_CASE_WITH_THF(ResizeBilinearMagUint8Nhwc, |
| 948 | ResizeBilinearMagTest<DataType::QAsymmU8>, |
| 949 | DataLayout::NHWC) |
Sadik Armagan | c625f00 | 2018-12-17 11:32:16 +0000 | [diff] [blame] | 950 | |
Finn Williams | ec36d3e | 2020-08-28 13:17:05 +0100 | [diff] [blame] | 951 | ARMNN_AUTO_TEST_CASE_WITH_THF(HalfPixelCentersResizeBilinearNhwc, |
| 952 | HalfPixelCentersResizeBilinearTest<DataType::Float32>, |
| 953 | DataLayout::NHWC) |
| 954 | ARMNN_AUTO_TEST_CASE_WITH_THF(AlignCornersResizeBilinearNhwc, |
| 955 | AlignCornersResizeBilinearTest<DataType::Float32>, |
| 956 | DataLayout::NHWC) |
| 957 | ARMNN_AUTO_TEST_CASE_WITH_THF(HalfPixelCentersResizeBilinearInt8Nhwc, |
| 958 | HalfPixelCentersResizeBilinearTest<DataType::QAsymmS8>, |
| 959 | DataLayout::NHWC) |
| 960 | ARMNN_AUTO_TEST_CASE_WITH_THF(AlignCornersResizeBilinearInt8Nhwc, |
| 961 | AlignCornersResizeBilinearTest<DataType::QAsymmS8>, |
| 962 | DataLayout::NHWC) |
| 963 | ARMNN_AUTO_TEST_CASE_WITH_THF(HalfPixelCentersResizeBilinearUint8Nhwc, |
| 964 | HalfPixelCentersResizeBilinearTest<DataType::QAsymmU8>, |
| 965 | DataLayout::NHWC) |
| 966 | ARMNN_AUTO_TEST_CASE_WITH_THF(AlignCornersResizeBilinearUint8Nhwc, |
| 967 | AlignCornersResizeBilinearTest<DataType::QAsymmU8>, |
| 968 | DataLayout::NHWC) |
Teresa Charlin | 686f45c | 2020-07-23 17:59:00 +0100 | [diff] [blame] | 969 | |
Ellen Norris-Thompson | 37e6868 | 2019-07-15 14:23:30 +0100 | [diff] [blame] | 970 | // Resize NearestNeighbor - NCHW |
Finn Williams | ec36d3e | 2020-08-28 13:17:05 +0100 | [diff] [blame] | 971 | ARMNN_AUTO_TEST_CASE_WITH_THF(SimpleResizeNearestNeighbor, |
| 972 | SimpleResizeNearestNeighborTest<DataType::Float32>, |
| 973 | DataLayout::NCHW) |
| 974 | ARMNN_AUTO_TEST_CASE_WITH_THF(ResizeNearestNeighborNop, |
| 975 | ResizeNearestNeighborNopTest<DataType::Float32>, |
| 976 | DataLayout::NCHW) |
| 977 | ARMNN_AUTO_TEST_CASE_WITH_THF(ResizeNearestNeighborSqMin, |
| 978 | ResizeNearestNeighborSqMinTest<DataType::Float32>, |
| 979 | DataLayout::NCHW) |
| 980 | ARMNN_AUTO_TEST_CASE_WITH_THF(ResizeNearestNeighborMin, |
| 981 | ResizeNearestNeighborMinTest<DataType::Float32>, |
| 982 | DataLayout::NCHW) |
| 983 | ARMNN_AUTO_TEST_CASE_WITH_THF(ResizeNearestNeighborMag, |
| 984 | ResizeNearestNeighborMagTest<DataType::Float32>, |
| 985 | DataLayout::NCHW, 0.1f, 50, 0.1f, 50) |
Ellen Norris-Thompson | 37e6868 | 2019-07-15 14:23:30 +0100 | [diff] [blame] | 986 | |
Finn Williams | ec36d3e | 2020-08-28 13:17:05 +0100 | [diff] [blame] | 987 | ARMNN_AUTO_TEST_CASE_WITH_THF(SimpleResizeNearestNeighborUint8, |
| 988 | SimpleResizeNearestNeighborTest<DataType::QAsymmU8>, |
| 989 | DataLayout::NCHW) |
| 990 | ARMNN_AUTO_TEST_CASE_WITH_THF(ResizeNearestNeighborNopUint8, |
| 991 | ResizeNearestNeighborNopTest<DataType::QAsymmU8>, |
| 992 | DataLayout::NCHW) |
| 993 | ARMNN_AUTO_TEST_CASE_WITH_THF(ResizeNearestNeighborSqMinUint8, |
| 994 | ResizeNearestNeighborSqMinTest<DataType::QAsymmU8>, |
| 995 | DataLayout::NCHW) |
| 996 | ARMNN_AUTO_TEST_CASE_WITH_THF(ResizeNearestNeighborMinUint8, |
| 997 | ResizeNearestNeighborMinTest<DataType::QAsymmU8>, |
| 998 | DataLayout::NCHW) |
| 999 | ARMNN_AUTO_TEST_CASE_WITH_THF(ResizeNearestNeighborMagUint8, |
| 1000 | ResizeNearestNeighborMagTest<DataType::QAsymmU8>, |
| 1001 | DataLayout::NCHW, 0.1f, 50, 0.1f, 50) |
Ellen Norris-Thompson | 37e6868 | 2019-07-15 14:23:30 +0100 | [diff] [blame] | 1002 | |
Finn Williams | ec36d3e | 2020-08-28 13:17:05 +0100 | [diff] [blame] | 1003 | ARMNN_AUTO_TEST_CASE_WITH_THF(HalfPixelCentersResizeNearestNeighbour, |
| 1004 | HalfPixelCentersResizeNearestNeighbourTest<DataType::Float32>, |
| 1005 | DataLayout::NCHW) |
| 1006 | ARMNN_AUTO_TEST_CASE_WITH_THF(AlignCornersResizeNearestNeighbour, |
| 1007 | AlignCornersResizeNearestNeighbourTest<DataType::Float32>, |
| 1008 | DataLayout::NCHW) |
| 1009 | ARMNN_AUTO_TEST_CASE_WITH_THF(HalfPixelCentersResizeNearestNeighbourInt8, |
| 1010 | HalfPixelCentersResizeNearestNeighbourTest<DataType::QAsymmS8>, |
| 1011 | DataLayout::NCHW) |
| 1012 | ARMNN_AUTO_TEST_CASE_WITH_THF(AlignCornersResizeNearestNeighbourInt8, |
| 1013 | AlignCornersResizeNearestNeighbourTest<DataType::QAsymmS8>, |
| 1014 | DataLayout::NCHW) |
| 1015 | ARMNN_AUTO_TEST_CASE_WITH_THF(HalfPixelCentersResizeNearestNeighbourUint8, |
| 1016 | HalfPixelCentersResizeNearestNeighbourTest<DataType::QAsymmU8>, |
| 1017 | DataLayout::NCHW) |
| 1018 | ARMNN_AUTO_TEST_CASE_WITH_THF(AlignCornersResizeNearestNeighbourUint8, |
| 1019 | AlignCornersResizeNearestNeighbourTest<DataType::QAsymmU8>, |
| 1020 | DataLayout::NCHW) |
Teresa Charlin | 686f45c | 2020-07-23 17:59:00 +0100 | [diff] [blame] | 1021 | |
Ellen Norris-Thompson | 37e6868 | 2019-07-15 14:23:30 +0100 | [diff] [blame] | 1022 | // Resize NearestNeighbor - NHWC |
Finn Williams | ec36d3e | 2020-08-28 13:17:05 +0100 | [diff] [blame] | 1023 | ARMNN_AUTO_TEST_CASE_WITH_THF(ResizeNearestNeighborNopNhwc, |
| 1024 | ResizeNearestNeighborNopTest<DataType::Float32>, |
| 1025 | DataLayout::NHWC) |
| 1026 | ARMNN_AUTO_TEST_CASE_WITH_THF(SimpleResizeNearestNeighborNhwc, |
| 1027 | SimpleResizeNearestNeighborTest<DataType::Float32>, |
| 1028 | DataLayout::NHWC) |
| 1029 | ARMNN_AUTO_TEST_CASE_WITH_THF(ResizeNearestNeighborSqMinNhwc, |
| 1030 | ResizeNearestNeighborSqMinTest<DataType::Float32>, |
| 1031 | DataLayout::NHWC) |
| 1032 | ARMNN_AUTO_TEST_CASE_WITH_THF(ResizeNearestNeighborMinNhwc, |
| 1033 | ResizeNearestNeighborMinTest<DataType::Float32>, |
| 1034 | DataLayout::NHWC) |
| 1035 | ARMNN_AUTO_TEST_CASE_WITH_THF(ResizeNearestNeighborMagNhwc, |
| 1036 | ResizeNearestNeighborMagTest<DataType::Float32>, |
| 1037 | DataLayout::NHWC, 0.1f, 50, 0.1f, 50) |
Ellen Norris-Thompson | 37e6868 | 2019-07-15 14:23:30 +0100 | [diff] [blame] | 1038 | |
Finn Williams | ec36d3e | 2020-08-28 13:17:05 +0100 | [diff] [blame] | 1039 | ARMNN_AUTO_TEST_CASE_WITH_THF(ResizeNearestNeighborNopUint8Nhwc, |
| 1040 | ResizeNearestNeighborNopTest<DataType::QAsymmU8>, |
| 1041 | DataLayout::NHWC) |
| 1042 | ARMNN_AUTO_TEST_CASE_WITH_THF(SimpleResizeNearestNeighborUint8Nhwc, |
| 1043 | SimpleResizeNearestNeighborTest<DataType::QAsymmU8>, |
| 1044 | DataLayout::NHWC) |
| 1045 | ARMNN_AUTO_TEST_CASE_WITH_THF(ResizeNearestNeighborSqMinUint8Nhwc, |
| 1046 | ResizeNearestNeighborSqMinTest<DataType::QAsymmU8>, |
| 1047 | DataLayout::NHWC) |
| 1048 | ARMNN_AUTO_TEST_CASE_WITH_THF(ResizeNearestNeighborMinUint8Nhwc, |
| 1049 | ResizeNearestNeighborMinTest<DataType::QAsymmU8>, |
| 1050 | DataLayout::NHWC) |
| 1051 | ARMNN_AUTO_TEST_CASE_WITH_THF(ResizeNearestNeighborMagUint8Nhwc, |
| 1052 | ResizeNearestNeighborMagTest<DataType::QAsymmU8>, |
| 1053 | DataLayout::NHWC, 0.1f, 50, 0.1f, 50) |
Ellen Norris-Thompson | 37e6868 | 2019-07-15 14:23:30 +0100 | [diff] [blame] | 1054 | |
Finn Williams | ec36d3e | 2020-08-28 13:17:05 +0100 | [diff] [blame] | 1055 | ARMNN_AUTO_TEST_CASE_WITH_THF(HalfPixelCentersResizeNearestNeighbourNhwc, |
| 1056 | HalfPixelCentersResizeNearestNeighbourTest<DataType::Float32>, |
| 1057 | DataLayout::NHWC) |
| 1058 | ARMNN_AUTO_TEST_CASE_WITH_THF(AlignCornersResizeNearestNeighbourNhwc, |
| 1059 | AlignCornersResizeNearestNeighbourTest<DataType::Float32>, |
| 1060 | DataLayout::NHWC) |
| 1061 | ARMNN_AUTO_TEST_CASE_WITH_THF(HalfPixelCentersResizeNearestNeighbourInt8Nhwc, |
| 1062 | HalfPixelCentersResizeNearestNeighbourTest<DataType::QAsymmS8>, |
| 1063 | DataLayout::NHWC) |
| 1064 | ARMNN_AUTO_TEST_CASE_WITH_THF(AlignCornersResizeNearestNeighbourInt8Nhwc, |
| 1065 | AlignCornersResizeNearestNeighbourTest<DataType::QAsymmS8>, |
| 1066 | DataLayout::NHWC) |
| 1067 | ARMNN_AUTO_TEST_CASE_WITH_THF(HalfPixelCentersResizeNearestNeighbourUint8Nhwc, |
| 1068 | HalfPixelCentersResizeNearestNeighbourTest<DataType::QAsymmU8>, |
| 1069 | DataLayout::NHWC) |
| 1070 | ARMNN_AUTO_TEST_CASE_WITH_THF(AlignCornersResizeNearestNeighbourUint8Nhwc, |
| 1071 | AlignCornersResizeNearestNeighbourTest<DataType::QAsymmU8>, |
| 1072 | DataLayout::NHWC) |
Teresa Charlin | 686f45c | 2020-07-23 17:59:00 +0100 | [diff] [blame] | 1073 | |
josh minor | 036f02d | 2019-11-15 14:53:22 -0600 | [diff] [blame] | 1074 | // Slice |
| 1075 | ARMNN_AUTO_TEST_CASE(Slice4dFloat32, Slice4dFloat32Test) |
| 1076 | ARMNN_AUTO_TEST_CASE(Slice3dFloat32, Slice3dFloat32Test) |
| 1077 | ARMNN_AUTO_TEST_CASE(Slice2dFloat32, Slice2dFloat32Test) |
| 1078 | ARMNN_AUTO_TEST_CASE(Slice1dFloat32, Slice1dFloat32Test) |
| 1079 | ARMNN_AUTO_TEST_CASE(Slice4dUint8, Slice4dUint8Test) |
| 1080 | ARMNN_AUTO_TEST_CASE(Slice3dUint8, Slice3dUint8Test) |
| 1081 | ARMNN_AUTO_TEST_CASE(Slice2dUint8, Slice2dUint8Test) |
| 1082 | ARMNN_AUTO_TEST_CASE(Slice1dUint8, Slice1dUint8Test) |
| 1083 | ARMNN_AUTO_TEST_CASE(Slice4dInt16, Slice4dInt16Test) |
| 1084 | ARMNN_AUTO_TEST_CASE(Slice3dInt16, Slice3dInt16Test) |
| 1085 | ARMNN_AUTO_TEST_CASE(Slice2dInt16, Slice2dInt16Test) |
| 1086 | ARMNN_AUTO_TEST_CASE(Slice1dInt16, Slice1dInt16Test) |
| 1087 | |
FinnWilliamsArm | 1fa1919 | 2019-08-02 17:26:31 +0100 | [diff] [blame] | 1088 | // Strided Slice |
Sadik Armagan | 5e71984 | 2020-08-28 12:17:33 +0100 | [diff] [blame] | 1089 | ARMNN_AUTO_TEST_CASE_WITH_THF(StridedSlice4dFloat32, StridedSlice4dFloat32Test) |
| 1090 | ARMNN_AUTO_TEST_CASE_WITH_THF(StridedSlice4dReverseFloat32, StridedSlice4dReverseFloat32Test) |
| 1091 | ARMNN_AUTO_TEST_CASE_WITH_THF(StridedSliceSimpleStrideFloat32, StridedSliceSimpleStrideFloat32Test) |
| 1092 | ARMNN_AUTO_TEST_CASE_WITH_THF(StridedSliceSimpleRangeMaskFloat32, StridedSliceSimpleRangeMaskFloat32Test) |
| 1093 | ARMNN_AUTO_TEST_CASE_WITH_THF(StridedSliceShrinkAxisMaskFloat32, StridedSliceShrinkAxisMaskFloat32Test) |
Finn Williams | 826a543 | 2020-08-27 16:15:20 +0100 | [diff] [blame] | 1094 | ARMNN_AUTO_TEST_CASE_WITH_THF(StridedSliceShrinkAxisMaskCTSFloat32, |
| 1095 | StridedSliceShrinkAxisMaskCTSFloat32Test) |
Sadik Armagan | 5e71984 | 2020-08-28 12:17:33 +0100 | [diff] [blame] | 1096 | ARMNN_AUTO_TEST_CASE_WITH_THF( |
| 1097 | StridedSliceShrinkAxisMaskBitPosition0Dim3Float32, StridedSliceShrinkAxisMaskBitPosition0Dim3Float32Test) |
| 1098 | ARMNN_AUTO_TEST_CASE_WITH_THF( |
| 1099 | StridedSliceShrinkAxisMaskBitPosition0Float32, StridedSliceShrinkAxisMaskBitPosition0Float32Test) |
| 1100 | ARMNN_AUTO_TEST_CASE_WITH_THF( |
| 1101 | StridedSliceShrinkAxisMaskBitPosition1Float32, StridedSliceShrinkAxisMaskBitPosition1Float32Test) |
| 1102 | ARMNN_AUTO_TEST_CASE_WITH_THF( |
| 1103 | StridedSliceShrinkAxisMaskBitPosition2Float32, StridedSliceShrinkAxisMaskBitPosition2Float32Test) |
| 1104 | ARMNN_AUTO_TEST_CASE_WITH_THF( |
| 1105 | StridedSliceShrinkAxisMaskBitPosition3Float32, StridedSliceShrinkAxisMaskBitPosition3Float32Test) |
| 1106 | ARMNN_AUTO_TEST_CASE_WITH_THF( |
| 1107 | StridedSliceShrinkAxisMaskBitPosition0And1Float32, StridedSliceShrinkAxisMaskBitPosition0And1Float32Test) |
| 1108 | ARMNN_AUTO_TEST_CASE_WITH_THF( |
| 1109 | StridedSliceShrinkAxisMaskBitPosition0And2Float32, StridedSliceShrinkAxisMaskBitPosition0And2Float32Test) |
| 1110 | ARMNN_AUTO_TEST_CASE_WITH_THF( |
| 1111 | StridedSliceShrinkAxisMaskBitPosition0And3Float32, StridedSliceShrinkAxisMaskBitPosition0And3Float32Test) |
| 1112 | ARMNN_AUTO_TEST_CASE_WITH_THF( |
| 1113 | StridedSliceShrinkAxisMaskBitPosition0And1And3Float32, StridedSliceShrinkAxisMaskBitPosition0And1And3Float32Test) |
| 1114 | ARMNN_AUTO_TEST_CASE_WITH_THF(StridedSlice3dFloat32, StridedSlice3dFloat32Test) |
| 1115 | ARMNN_AUTO_TEST_CASE_WITH_THF(StridedSlice3dReverseFloat32, StridedSlice3dReverseFloat32Test) |
| 1116 | ARMNN_AUTO_TEST_CASE_WITH_THF(StridedSlice2dFloat32, StridedSlice2dFloat32Test) |
| 1117 | ARMNN_AUTO_TEST_CASE_WITH_THF(StridedSlice2dReverseFloat32, StridedSlice2dReverseFloat32Test) |
FinnWilliamsArm | 1fa1919 | 2019-08-02 17:26:31 +0100 | [diff] [blame] | 1118 | |
Sadik Armagan | 5e71984 | 2020-08-28 12:17:33 +0100 | [diff] [blame] | 1119 | ARMNN_AUTO_TEST_CASE_WITH_THF(StridedSlice4dUint8, StridedSlice4dUint8Test) |
| 1120 | ARMNN_AUTO_TEST_CASE_WITH_THF(StridedSlice4dReverseUint8, StridedSlice4dReverseUint8Test) |
| 1121 | ARMNN_AUTO_TEST_CASE_WITH_THF(StridedSliceSimpleStrideUint8, StridedSliceSimpleStrideUint8Test) |
| 1122 | ARMNN_AUTO_TEST_CASE_WITH_THF(StridedSliceSimpleRangeMaskUint8, StridedSliceSimpleRangeMaskUint8Test) |
| 1123 | ARMNN_AUTO_TEST_CASE_WITH_THF(StridedSliceShrinkAxisMaskUint8, StridedSliceShrinkAxisMaskUint8Test) |
| 1124 | ARMNN_AUTO_TEST_CASE_WITH_THF( |
| 1125 | StridedSliceShrinkAxisMaskBitPosition0Dim3Uint8, StridedSliceShrinkAxisMaskBitPosition0Dim3Uint8Test) |
| 1126 | ARMNN_AUTO_TEST_CASE_WITH_THF( |
| 1127 | StridedSliceShrinkAxisMaskBitPosition0Uint8, StridedSliceShrinkAxisMaskBitPosition0Uint8Test) |
| 1128 | ARMNN_AUTO_TEST_CASE_WITH_THF( |
| 1129 | StridedSliceShrinkAxisMaskBitPosition1Uint8, StridedSliceShrinkAxisMaskBitPosition1Uint8Test) |
| 1130 | ARMNN_AUTO_TEST_CASE_WITH_THF( |
| 1131 | StridedSliceShrinkAxisMaskBitPosition2Uint8, StridedSliceShrinkAxisMaskBitPosition2Uint8Test) |
| 1132 | ARMNN_AUTO_TEST_CASE_WITH_THF( |
| 1133 | StridedSliceShrinkAxisMaskBitPosition3Uint8, StridedSliceShrinkAxisMaskBitPosition3Uint8Test) |
| 1134 | ARMNN_AUTO_TEST_CASE_WITH_THF( |
| 1135 | StridedSliceShrinkAxisMaskBitPosition0And1Uint8, StridedSliceShrinkAxisMaskBitPosition0And1Uint8Test) |
| 1136 | ARMNN_AUTO_TEST_CASE_WITH_THF( |
| 1137 | StridedSliceShrinkAxisMaskBitPosition0And2Uint8, StridedSliceShrinkAxisMaskBitPosition0And2Uint8Test) |
| 1138 | ARMNN_AUTO_TEST_CASE_WITH_THF( |
| 1139 | StridedSliceShrinkAxisMaskBitPosition0And3Uint8, StridedSliceShrinkAxisMaskBitPosition0And3Uint8Test) |
| 1140 | ARMNN_AUTO_TEST_CASE_WITH_THF( |
| 1141 | StridedSliceShrinkAxisMaskBitPosition0And1And3Uint8, StridedSliceShrinkAxisMaskBitPosition0And1And3Uint8Test) |
| 1142 | ARMNN_AUTO_TEST_CASE_WITH_THF(StridedSlice3dUint8, StridedSlice3dUint8Test) |
| 1143 | ARMNN_AUTO_TEST_CASE_WITH_THF(StridedSlice3dReverseUint8, StridedSlice3dReverseUint8Test) |
| 1144 | ARMNN_AUTO_TEST_CASE_WITH_THF(StridedSlice2dUint8, StridedSlice2dUint8Test) |
| 1145 | ARMNN_AUTO_TEST_CASE_WITH_THF(StridedSlice2dReverseUint8, StridedSlice2dReverseUint8Test) |
FinnWilliamsArm | 1fa1919 | 2019-08-02 17:26:31 +0100 | [diff] [blame] | 1146 | |
Sadik Armagan | fabc289 | 2019-05-31 09:05:11 +0100 | [diff] [blame] | 1147 | // Quantize |
Finn Williams | ec36d3e | 2020-08-28 13:17:05 +0100 | [diff] [blame] | 1148 | ARMNN_AUTO_TEST_CASE_WITH_THF(QuantizeSimpleUint8, QuantizeSimpleUint8Test) |
| 1149 | ARMNN_AUTO_TEST_CASE_WITH_THF(QuantizeClampUint8, QuantizeClampUint8Test) |
Sadik Armagan | fabc289 | 2019-05-31 09:05:11 +0100 | [diff] [blame] | 1150 | |
Nikhil Raj | 9b46148 | 2019-07-03 15:58:31 +0100 | [diff] [blame] | 1151 | // PReLU |
Finn Williams | 826a543 | 2020-08-27 16:15:20 +0100 | [diff] [blame] | 1152 | ARMNN_AUTO_TEST_CASE_WITH_THF(PreluFloat32, PreluTest<DataType::Float32>) |
| 1153 | ARMNN_AUTO_TEST_CASE_WITH_THF(PreluUint8, PreluTest<DataType::QAsymmU8>) |
Nikhil Raj | 9b46148 | 2019-07-03 15:58:31 +0100 | [diff] [blame] | 1154 | |
Matthew Jackson | 87f65ea | 2019-08-01 10:01:34 +0100 | [diff] [blame] | 1155 | // Stack |
Sadik Armagan | 5e71984 | 2020-08-28 12:17:33 +0100 | [diff] [blame] | 1156 | ARMNN_AUTO_TEST_CASE_WITH_THF(Stack0Axis, StackAxis0Float32Test) |
| 1157 | ARMNN_AUTO_TEST_CASE_WITH_THF(StackOutput4DAxis1, StackOutput4DAxis1Float32Test) |
| 1158 | ARMNN_AUTO_TEST_CASE_WITH_THF(StackOutput4DAxis2, StackOutput4DAxis2Float32Test) |
| 1159 | ARMNN_AUTO_TEST_CASE_WITH_THF(StackOutput4DAxis3, StackOutput4DAxis3Float32Test) |
| 1160 | ARMNN_AUTO_TEST_CASE_WITH_THF(StackOutput3DInputs3, StackOutput3DInputs3Float32Test) |
| 1161 | ARMNN_AUTO_TEST_CASE_WITH_THF(StackOutput5D, StackOutput5DFloat32Test) |
Matthew Jackson | 87f65ea | 2019-08-01 10:01:34 +0100 | [diff] [blame] | 1162 | |
Mike Kelly | c9ea45a | 2020-02-28 18:11:58 +0000 | [diff] [blame] | 1163 | // Transpose |
Finn Williams | ec36d3e | 2020-08-28 13:17:05 +0100 | [diff] [blame] | 1164 | ARMNN_AUTO_TEST_CASE_WITH_THF(SimpleTransposeFloat32, SimpleTransposeTest<DataType::Float32>) |
| 1165 | ARMNN_AUTO_TEST_CASE_WITH_THF(TransposeFloat32ValueSet1Test, TransposeValueSet1Test<DataType::Float32>) |
| 1166 | ARMNN_AUTO_TEST_CASE_WITH_THF(TransposeFloat32ValueSet2Test, TransposeValueSet2Test<DataType::Float32>) |
| 1167 | ARMNN_AUTO_TEST_CASE_WITH_THF(TransposeFloat32ValueSet3Test, TransposeValueSet3Test<DataType::Float32>) |
| 1168 | ARMNN_AUTO_TEST_CASE_WITH_THF(SimpleTransposeQASymms8, SimpleTransposeTest<DataType::QAsymmS8>) |
| 1169 | ARMNN_AUTO_TEST_CASE_WITH_THF(TransposeQASymmS8ValueSet1Test, TransposeValueSet1Test<DataType::QAsymmS8>) |
| 1170 | ARMNN_AUTO_TEST_CASE_WITH_THF(TransposeQASymmS8ValueSet2Test, TransposeValueSet2Test<DataType::QAsymmS8>) |
| 1171 | ARMNN_AUTO_TEST_CASE_WITH_THF(TransposeQASymmS8ValueSet3Test, TransposeValueSet3Test<DataType::QAsymmS8>) |
| 1172 | ARMNN_AUTO_TEST_CASE_WITH_THF(SimpleTransposeQASymm8, SimpleTransposeTest<DataType::QAsymmU8>) |
| 1173 | ARMNN_AUTO_TEST_CASE_WITH_THF(TransposeQASymm8ValueSet1Test, TransposeValueSet1Test<DataType::QAsymmU8>) |
| 1174 | ARMNN_AUTO_TEST_CASE_WITH_THF(TransposeQASymm8ValueSet2Test, TransposeValueSet2Test<DataType::QAsymmU8>) |
| 1175 | ARMNN_AUTO_TEST_CASE_WITH_THF(TransposeQASymm8ValueSet3Test, TransposeValueSet3Test<DataType::QAsymmU8>) |
| 1176 | ARMNN_AUTO_TEST_CASE_WITH_THF(SimpleTransposeQSymm16, SimpleTransposeTest<DataType::QSymmS16>) |
| 1177 | ARMNN_AUTO_TEST_CASE_WITH_THF(TransposeQSymm16ValueSet1Test, TransposeValueSet1Test<DataType::QSymmS16>) |
| 1178 | ARMNN_AUTO_TEST_CASE_WITH_THF(TransposeQSymm16ValueSet2Test, TransposeValueSet2Test<DataType::QSymmS16>) |
| 1179 | ARMNN_AUTO_TEST_CASE_WITH_THF(TransposeQSymm16ValueSet3Test, TransposeValueSet3Test<DataType::QSymmS16>) |
Mike Kelly | c9ea45a | 2020-02-28 18:11:58 +0000 | [diff] [blame] | 1180 | |
Sadik Armagan | 581742d | 2019-08-12 14:11:37 +0100 | [diff] [blame] | 1181 | // TransposeConvolution2d |
Finn Williams | ec36d3e | 2020-08-28 13:17:05 +0100 | [diff] [blame] | 1182 | ARMNN_AUTO_TEST_CASE_WITH_THF(SimpleTransposeConvolution2dFloatNchw, |
| 1183 | SimpleTransposeConvolution2dTest<DataType::Float32, DataType::Float32>, |
| 1184 | true, |
| 1185 | DataLayout::NCHW) |
| 1186 | ARMNN_AUTO_TEST_CASE_WITH_THF(SimpleTransposeConvolution2dFloatNhwc, |
| 1187 | SimpleTransposeConvolution2dTest<DataType::Float32, DataType::Float32>, |
| 1188 | true, |
| 1189 | DataLayout::NHWC) |
| 1190 | ARMNN_AUTO_TEST_CASE_WITH_THF(SimpleTransposeConvolution2dUint8Nchw, |
| 1191 | SimpleTransposeConvolution2dTest<DataType::QAsymmU8, DataType::Signed32>, |
| 1192 | true, |
| 1193 | DataLayout::NCHW) |
| 1194 | ARMNN_AUTO_TEST_CASE_WITH_THF(SimpleTransposeConvolution2dUint8Nhwc, |
| 1195 | SimpleTransposeConvolution2dTest<DataType::QAsymmU8, DataType::Signed32>, |
| 1196 | true, |
| 1197 | DataLayout::NHWC) |
Sadik Armagan | 581742d | 2019-08-12 14:11:37 +0100 | [diff] [blame] | 1198 | |
Finn Williams | ec36d3e | 2020-08-28 13:17:05 +0100 | [diff] [blame] | 1199 | ARMNN_AUTO_TEST_CASE_WITH_THF(UnbiasedSimpleTransposeConvolution2dFloatNchw, |
| 1200 | SimpleTransposeConvolution2dTest<DataType::Float32, DataType::Float32>, |
| 1201 | false, |
| 1202 | DataLayout::NCHW) |
| 1203 | ARMNN_AUTO_TEST_CASE_WITH_THF(UnbiasedSimpleTransposeConvolution2dFloatNhwc, |
| 1204 | SimpleTransposeConvolution2dTest<DataType::Float32, DataType::Float32>, |
| 1205 | true, |
| 1206 | DataLayout::NHWC) |
| 1207 | ARMNN_AUTO_TEST_CASE_WITH_THF(UnbiasedSimpleTransposeConvolution2dUint8Nchw, |
| 1208 | SimpleTransposeConvolution2dTest<DataType::QAsymmU8, DataType::Signed32>, |
| 1209 | true, |
| 1210 | DataLayout::NCHW) |
| 1211 | ARMNN_AUTO_TEST_CASE_WITH_THF(UnbiasedSimpleTransposeConvolution2dUint8Nhwc, |
| 1212 | SimpleTransposeConvolution2dTest<DataType::QAsymmU8, DataType::Signed32>, |
| 1213 | true, |
| 1214 | DataLayout::NHWC) |
Sadik Armagan | 581742d | 2019-08-12 14:11:37 +0100 | [diff] [blame] | 1215 | |
Finn Williams | ec36d3e | 2020-08-28 13:17:05 +0100 | [diff] [blame] | 1216 | ARMNN_AUTO_TEST_CASE_WITH_THF(PaddedTransposeConvolution2dFloatNchw, |
| 1217 | PaddedTransposeConvolution2dTest<DataType::Float32, DataType::Float32>, |
| 1218 | true, |
| 1219 | DataLayout::NCHW) |
| 1220 | ARMNN_AUTO_TEST_CASE_WITH_THF(PaddedTransposeConvolution2dFloatNhwc, |
| 1221 | PaddedTransposeConvolution2dTest<DataType::Float32, DataType::Float32>, |
| 1222 | true, |
| 1223 | DataLayout::NHWC) |
| 1224 | ARMNN_AUTO_TEST_CASE_WITH_THF(PaddedTransposeConvolution2dUint8Nchw, |
| 1225 | PaddedTransposeConvolution2dTest<DataType::QAsymmU8, DataType::Signed32>, |
| 1226 | true, |
| 1227 | DataLayout::NCHW) |
| 1228 | ARMNN_AUTO_TEST_CASE_WITH_THF(PaddedTransposeConvolution2dUint8Nhwc, |
| 1229 | PaddedTransposeConvolution2dTest<DataType::QAsymmU8, DataType::Signed32>, |
| 1230 | true, |
| 1231 | DataLayout::NHWC) |
Sadik Armagan | 581742d | 2019-08-12 14:11:37 +0100 | [diff] [blame] | 1232 | |
Finn Williams | ec36d3e | 2020-08-28 13:17:05 +0100 | [diff] [blame] | 1233 | ARMNN_AUTO_TEST_CASE_WITH_THF(UnbiasedPaddedTransposeConvolution2dFloatNchw, |
| 1234 | PaddedTransposeConvolution2dTest<DataType::Float32, DataType::Float32>, |
| 1235 | false, |
| 1236 | DataLayout::NCHW) |
| 1237 | ARMNN_AUTO_TEST_CASE_WITH_THF(UnbiasedPaddedTransposeConvolution2dFloatNhwc, |
| 1238 | PaddedTransposeConvolution2dTest<DataType::Float32, DataType::Float32>, |
| 1239 | true, |
| 1240 | DataLayout::NHWC) |
| 1241 | ARMNN_AUTO_TEST_CASE_WITH_THF(UnbiasedPaddedTransposeConvolution2dInt8Nchw, |
| 1242 | PaddedTransposeConvolution2dTest<DataType::QAsymmS8, DataType::Signed32>, |
| 1243 | true, |
| 1244 | DataLayout::NCHW) |
| 1245 | ARMNN_AUTO_TEST_CASE_WITH_THF(UnbiasedPaddedTransposeConvolution2dInt8Nhwc, |
| 1246 | PaddedTransposeConvolution2dTest<DataType::QAsymmS8, DataType::Signed32>, |
| 1247 | true, |
| 1248 | DataLayout::NHWC) |
| 1249 | ARMNN_AUTO_TEST_CASE_WITH_THF(UnbiasedPaddedTransposeConvolution2dUint8Nchw, |
| 1250 | PaddedTransposeConvolution2dTest<DataType::QAsymmU8, DataType::Signed32>, |
| 1251 | true, |
| 1252 | DataLayout::NCHW) |
| 1253 | ARMNN_AUTO_TEST_CASE_WITH_THF(UnbiasedPaddedTransposeConvolution2dUint8Nhwc, |
| 1254 | PaddedTransposeConvolution2dTest<DataType::QAsymmU8, DataType::Signed32>, |
| 1255 | true, |
| 1256 | DataLayout::NHWC) |
Sadik Armagan | 581742d | 2019-08-12 14:11:37 +0100 | [diff] [blame] | 1257 | |
Finn Williams | ec36d3e | 2020-08-28 13:17:05 +0100 | [diff] [blame] | 1258 | ARMNN_AUTO_TEST_CASE_WITH_THF(StridedTransposeConvolution2dFloatNchw, |
| 1259 | StridedTransposeConvolution2dTest<DataType::Float32, DataType::Float32>, |
| 1260 | true, |
| 1261 | DataLayout::NCHW) |
| 1262 | ARMNN_AUTO_TEST_CASE_WITH_THF(StridedTransposeConvolution2dFloatNhwc, |
| 1263 | StridedTransposeConvolution2dTest<DataType::Float32, DataType::Float32>, |
| 1264 | true, |
| 1265 | DataLayout::NHWC) |
| 1266 | ARMNN_AUTO_TEST_CASE_WITH_THF(StridedTransposeConvolution2dUint8Nchw, |
| 1267 | StridedTransposeConvolution2dTest<DataType::QAsymmU8, DataType::Signed32>, |
| 1268 | true, |
| 1269 | DataLayout::NCHW) |
| 1270 | ARMNN_AUTO_TEST_CASE_WITH_THF(StridedTransposeConvolution2dUint8Nhwc, |
| 1271 | StridedTransposeConvolution2dTest<DataType::QAsymmU8, DataType::Signed32>, |
| 1272 | true, |
| 1273 | DataLayout::NHWC) |
Sadik Armagan | 581742d | 2019-08-12 14:11:37 +0100 | [diff] [blame] | 1274 | |
Finn Williams | ec36d3e | 2020-08-28 13:17:05 +0100 | [diff] [blame] | 1275 | ARMNN_AUTO_TEST_CASE_WITH_THF(UnbiasedStridedTransposeConvolution2dFloatNchw, |
| 1276 | StridedTransposeConvolution2dTest<DataType::Float32, DataType::Float32>, |
| 1277 | false, |
| 1278 | DataLayout::NCHW) |
| 1279 | ARMNN_AUTO_TEST_CASE_WITH_THF(UnbiasedStridedTransposeConvolution2dFloatNhwc, |
| 1280 | StridedTransposeConvolution2dTest<DataType::Float32, DataType::Float32>, |
| 1281 | true, |
| 1282 | DataLayout::NHWC) |
| 1283 | ARMNN_AUTO_TEST_CASE_WITH_THF(UnbiasedStridedTransposeConvolution2dUint8Nchw, |
| 1284 | StridedTransposeConvolution2dTest<DataType::QAsymmU8, DataType::Signed32>, |
| 1285 | true, |
| 1286 | DataLayout::NCHW) |
| 1287 | ARMNN_AUTO_TEST_CASE_WITH_THF(UnbiasedStridedTransposeConvolution2dUint8Nhwc, |
| 1288 | StridedTransposeConvolution2dTest<DataType::QAsymmU8, DataType::Signed32>, |
| 1289 | true, |
| 1290 | DataLayout::NHWC) |
Sadik Armagan | 581742d | 2019-08-12 14:11:37 +0100 | [diff] [blame] | 1291 | |
Finn Williams | ec36d3e | 2020-08-28 13:17:05 +0100 | [diff] [blame] | 1292 | ARMNN_AUTO_TEST_CASE_WITH_THF(MultiChannelTransposeConvolution2dFloatNchw, |
| 1293 | MultiChannelTransposeConvolution2dTest<DataType::Float32, DataType::Float32>, |
| 1294 | DataLayout::NCHW) |
| 1295 | ARMNN_AUTO_TEST_CASE_WITH_THF(MultiChannelTransposeConvolution2dFloatNhwc, |
| 1296 | MultiChannelTransposeConvolution2dTest<DataType::Float32, DataType::Float32>, |
| 1297 | DataLayout::NHWC) |
| 1298 | ARMNN_AUTO_TEST_CASE_WITH_THF(MultiChannelTransposeConvolution2dUint8Nchw, |
| 1299 | MultiChannelTransposeConvolution2dTest<DataType::QAsymmU8, DataType::Signed32>, |
| 1300 | DataLayout::NCHW) |
| 1301 | ARMNN_AUTO_TEST_CASE_WITH_THF(MultiChannelTransposeConvolution2dUint8Nhwc, |
| 1302 | MultiChannelTransposeConvolution2dTest<DataType::QAsymmU8, DataType::Signed32>, |
| 1303 | DataLayout::NHWC) |
Aron Virginas-Tar | 7599aa4 | 2019-08-20 15:30:04 +0100 | [diff] [blame] | 1304 | |
Aron Virginas-Tar | 914e4db | 2019-09-09 13:36:45 +0100 | [diff] [blame] | 1305 | // Abs |
Keith Davis | 33a626f | 2020-08-27 15:38:12 +0100 | [diff] [blame] | 1306 | ARMNN_AUTO_TEST_CASE_WITH_THF(Abs2d, Abs2dTest<DataType::Float32>) |
| 1307 | ARMNN_AUTO_TEST_CASE_WITH_THF(Abs3d, Abs3dTest<DataType::Float32>) |
| 1308 | ARMNN_AUTO_TEST_CASE_WITH_THF(AbsZero, AbsZeroTest<DataType::Float32>) |
Aron Virginas-Tar | 914e4db | 2019-09-09 13:36:45 +0100 | [diff] [blame] | 1309 | |
Keith Davis | 33a626f | 2020-08-27 15:38:12 +0100 | [diff] [blame] | 1310 | ARMNN_AUTO_TEST_CASE_WITH_THF(Abs2dSigned32, Abs2dTest<DataType::Signed32>) |
| 1311 | ARMNN_AUTO_TEST_CASE_WITH_THF(Abs3dSigned32, Abs3dTest<DataType::Signed32>) |
| 1312 | ARMNN_AUTO_TEST_CASE_WITH_THF(AbsZeroSigned32, AbsZeroTest<DataType::Signed32>) |
Kevin May | ec52c3a | 2020-04-24 09:42:31 +0100 | [diff] [blame] | 1313 | |
Aron Virginas-Tar | 0dd3b43 | 2019-09-10 13:55:09 +0100 | [diff] [blame] | 1314 | // Rsqrt |
Keith Davis | 33a626f | 2020-08-27 15:38:12 +0100 | [diff] [blame] | 1315 | ARMNN_AUTO_TEST_CASE_WITH_THF(Rsqrt2d, Rsqrt2dTest<DataType::Float32>) |
| 1316 | ARMNN_AUTO_TEST_CASE_WITH_THF(Rsqrt3d, Rsqrt3dTest<DataType::Float32>) |
| 1317 | ARMNN_AUTO_TEST_CASE_WITH_THF(RsqrtZero, RsqrtZeroTest<DataType::Float32>) |
| 1318 | ARMNN_AUTO_TEST_CASE_WITH_THF(RsqrtNegative, RsqrtNegativeTest<DataType::Float32>) |
Aron Virginas-Tar | 0dd3b43 | 2019-09-10 13:55:09 +0100 | [diff] [blame] | 1319 | |
James Conroy | d47a064 | 2019-09-17 14:22:06 +0100 | [diff] [blame] | 1320 | // ArgMinMax |
Sadik Armagan | 43528ac | 2020-08-27 09:06:40 +0100 | [diff] [blame] | 1321 | ARMNN_AUTO_TEST_CASE_WITH_THF(ArgMinFloat32, ArgMinSimpleTest<DataType::Float32>) |
| 1322 | ARMNN_AUTO_TEST_CASE_WITH_THF(ArgMaxFloat32, ArgMaxSimpleTest<DataType::Float32>) |
| 1323 | ARMNN_AUTO_TEST_CASE_WITH_THF(ArgMinChannel, ArgMinChannelTest<DataType::Float32>) |
| 1324 | ARMNN_AUTO_TEST_CASE_WITH_THF(ArgMaxChannel, ArgMaxChannelTest<DataType::Float32>) |
| 1325 | ARMNN_AUTO_TEST_CASE_WITH_THF(ArgMaxHeight, ArgMaxHeightTest<DataType::Float32>) |
| 1326 | ARMNN_AUTO_TEST_CASE_WITH_THF(ArgMinWidth, ArgMinWidthTest<DataType::Float32>) |
James Conroy | d47a064 | 2019-09-17 14:22:06 +0100 | [diff] [blame] | 1327 | |
Sadik Armagan | 43528ac | 2020-08-27 09:06:40 +0100 | [diff] [blame] | 1328 | ARMNN_AUTO_TEST_CASE_WITH_THF(ArgMinQAsymmS8, ArgMinSimpleTest<DataType::QAsymmS8>) |
| 1329 | ARMNN_AUTO_TEST_CASE_WITH_THF(ArgMaxQAsymmS8, ArgMaxSimpleTest<DataType::QAsymmS8>) |
| 1330 | ARMNN_AUTO_TEST_CASE_WITH_THF(ArgMinChannelQAsymmS8, ArgMinChannelTest<DataType::QAsymmS8>) |
| 1331 | ARMNN_AUTO_TEST_CASE_WITH_THF(ArgMaxChannelQAsymmS8, ArgMaxChannelTest<DataType::QAsymmS8>) |
| 1332 | ARMNN_AUTO_TEST_CASE_WITH_THF(ArgMaxHeightQAsymmS8, ArgMaxHeightTest<DataType::QAsymmS8>) |
| 1333 | ARMNN_AUTO_TEST_CASE_WITH_THF(ArgMinWidthQAsymmS8, ArgMinWidthTest<DataType::QAsymmS8>) |
Sadik Armagan | 303980c | 2020-04-17 12:45:14 +0100 | [diff] [blame] | 1334 | |
Sadik Armagan | 43528ac | 2020-08-27 09:06:40 +0100 | [diff] [blame] | 1335 | ARMNN_AUTO_TEST_CASE_WITH_THF(ArgMinQAsymm8, ArgMinSimpleTest<DataType::QAsymmU8>) |
| 1336 | ARMNN_AUTO_TEST_CASE_WITH_THF(ArgMaxQAsymm8, ArgMaxSimpleTest<DataType::QAsymmU8>) |
| 1337 | ARMNN_AUTO_TEST_CASE_WITH_THF(ArgMinChannelQAsymm8, ArgMinChannelTest<DataType::QAsymmU8>) |
| 1338 | ARMNN_AUTO_TEST_CASE_WITH_THF(ArgMaxChannelQAsymm8, ArgMaxChannelTest<DataType::QAsymmU8>) |
| 1339 | ARMNN_AUTO_TEST_CASE_WITH_THF(ArgMaxHeightQAsymm8, ArgMaxHeightTest<DataType::QAsymmU8>) |
| 1340 | ARMNN_AUTO_TEST_CASE_WITH_THF(ArgMinWidthQAsymm8, ArgMinWidthTest<DataType::QAsymmU8>) |
Francis Murtagh | 52ec346 | 2019-11-19 12:24:19 +0000 | [diff] [blame] | 1341 | |
Sadik Armagan | ac47210 | 2020-03-24 09:54:36 +0000 | [diff] [blame] | 1342 | // Neg |
Keith Davis | 33a626f | 2020-08-27 15:38:12 +0100 | [diff] [blame] | 1343 | ARMNN_AUTO_TEST_CASE_WITH_THF(Neg2d, Neg2dTest<DataType::Float32>) |
| 1344 | ARMNN_AUTO_TEST_CASE_WITH_THF(Neg3d, Neg3dTest<DataType::Float32>) |
| 1345 | ARMNN_AUTO_TEST_CASE_WITH_THF(NegZero, NegZeroTest<DataType::Float32>) |
| 1346 | ARMNN_AUTO_TEST_CASE_WITH_THF(NegNegative, NegNegativeTest<DataType::Float32>) |
Sadik Armagan | ac47210 | 2020-03-24 09:54:36 +0000 | [diff] [blame] | 1347 | |
Sadik Armagan | 9fabf43 | 2020-05-27 13:40:58 +0100 | [diff] [blame] | 1348 | // Exp |
Keith Davis | 33a626f | 2020-08-27 15:38:12 +0100 | [diff] [blame] | 1349 | ARMNN_AUTO_TEST_CASE_WITH_THF(Exp2d, Exp2dTest<DataType::Float32>) |
| 1350 | ARMNN_AUTO_TEST_CASE_WITH_THF(Exo3d, Exp3dTest<DataType::Float32>) |
| 1351 | ARMNN_AUTO_TEST_CASE_WITH_THF(ExpZero, ExpZeroTest<DataType::Float32>) |
| 1352 | ARMNN_AUTO_TEST_CASE_WITH_THF(ExpNegative, ExpNegativeTest<DataType::Float32>) |
Sadik Armagan | 9fabf43 | 2020-05-27 13:40:58 +0100 | [diff] [blame] | 1353 | |
Sadik Armagan | a792a05 | 2020-06-23 16:22:23 +0100 | [diff] [blame] | 1354 | // Fill |
Finn Williams | 8702007 | 2020-08-26 16:19:15 +0100 | [diff] [blame] | 1355 | ARMNN_AUTO_TEST_CASE_WITH_THF(SimpleFill, SimpleFillTest<DataType::Float32>) |
| 1356 | ARMNN_AUTO_TEST_CASE_WITH_THF(SimpleFillF16, SimpleFillTest<DataType::Float16>) |
| 1357 | ARMNN_AUTO_TEST_CASE_WITH_THF(SimpleFillS32, SimpleFillTest<DataType::Signed32>) |
Sadik Armagan | a792a05 | 2020-06-23 16:22:23 +0100 | [diff] [blame] | 1358 | |
James Conroy | 177df1e | 2020-11-13 10:18:51 +0000 | [diff] [blame] | 1359 | // Logical |
| 1360 | ARMNN_AUTO_TEST_CASE_WITH_THF(LogicalNot, LogicalNotTest) |
| 1361 | ARMNN_AUTO_TEST_CASE_WITH_THF(LogicalNotInt, LogicalNotIntTest) |
| 1362 | |
| 1363 | ARMNN_AUTO_TEST_CASE_WITH_THF(LogicalAnd, LogicalAndTest) |
| 1364 | ARMNN_AUTO_TEST_CASE_WITH_THF(LogicalAndInt, LogicalAndIntTest) |
| 1365 | ARMNN_AUTO_TEST_CASE_WITH_THF(LogicalAndBroadcast1, LogicalAndBroadcast1Test) |
| 1366 | ARMNN_AUTO_TEST_CASE_WITH_THF(LogicalAndBroadcast2, LogicalAndBroadcast2Test) |
| 1367 | ARMNN_AUTO_TEST_CASE_WITH_THF(LogicalAndBroadcast3, LogicalAndBroadcast3Test) |
| 1368 | |
| 1369 | ARMNN_AUTO_TEST_CASE_WITH_THF(LogicalOr, LogicalOrTest) |
| 1370 | ARMNN_AUTO_TEST_CASE_WITH_THF(LogicalOrInt, LogicalOrIntTest) |
| 1371 | ARMNN_AUTO_TEST_CASE_WITH_THF(LogicalOrBroadcast1, LogicalOrBroadcast1Test) |
| 1372 | ARMNN_AUTO_TEST_CASE_WITH_THF(LogicalOrBroadcast2, LogicalOrBroadcast2Test) |
| 1373 | ARMNN_AUTO_TEST_CASE_WITH_THF(LogicalOrBroadcast3, LogicalOrBroadcast3Test) |
| 1374 | |
Sadik Armagan | a274748 | 2021-02-09 10:28:54 +0000 | [diff] [blame] | 1375 | // ReduceSum |
| 1376 | ARMNN_AUTO_TEST_CASE_WITH_THF(ReduceSumFloat32, ReduceSumSimpleTest<DataType::Float32>) |
| 1377 | ARMNN_AUTO_TEST_CASE_WITH_THF(ReduceSumSingleAxisFloat32_1, ReduceSumSingleAxisTest1<DataType::Float32>) |
| 1378 | ARMNN_AUTO_TEST_CASE_WITH_THF(ReduceSumSingleAxisFloat32_2, ReduceSumSingleAxisTest2<DataType::Float32>) |
| 1379 | ARMNN_AUTO_TEST_CASE_WITH_THF(ReduceSumSingleAxisFloat32_3, ReduceSumSingleAxisTest3<DataType::Float32>) |
| 1380 | |
| 1381 | // ReduceMax |
| 1382 | ARMNN_AUTO_TEST_CASE_WITH_THF(ReduceMaxFloat32, ReduceMaxSimpleTest<DataType::Float32>) |
| 1383 | ARMNN_AUTO_TEST_CASE_WITH_THF(ReduceMaxNegativeAxisFloat32, ReduceMaxNegativeAxisTest<DataType::Float32>) |
| 1384 | ARMNN_AUTO_TEST_CASE_WITH_THF(ReduceMax2Float32, ReduceMaxSimpleTest2<DataType::Float32>) |
| 1385 | |
| 1386 | // ReduceMin |
| 1387 | ARMNN_AUTO_TEST_CASE_WITH_THF(ReduceMinFloat32, ReduceMinSimpleTest<DataType::Float32>) |
| 1388 | ARMNN_AUTO_TEST_CASE_WITH_THF(ReduceMinNegativeAxisFloat32, ReduceMinNegativeAxisTest<DataType::Float32>) |
| 1389 | |
Matteo Martincigh | db16dd3 | 2019-08-27 16:41:11 +0100 | [diff] [blame] | 1390 | #if defined(ARMNNREF_ENABLED) |
Matteo Martincigh | e67edb2 | 2019-08-14 14:05:46 +0100 | [diff] [blame] | 1391 | |
| 1392 | // The ARMNN_COMPARE_REF_AUTO_TEST_CASE and the ARMNN_COMPARE_REF_FIXTURE_TEST_CASE test units are not available |
| 1393 | // if the reference backend is not built |
| 1394 | |
telsoa01 | 4fcda01 | 2018-03-09 14:13:49 +0000 | [diff] [blame] | 1395 | // ============================================================================ |
| 1396 | // COMPARE tests |
| 1397 | |
Keith Davis | f500d6c | 2020-08-31 08:32:55 +0100 | [diff] [blame] | 1398 | ARMNN_COMPARE_REF_AUTO_TEST_CASE_WITH_THF(CompareConv2dWithReference, CompareConvolution2dTest) |
telsoa01 | 4fcda01 | 2018-03-09 14:13:49 +0000 | [diff] [blame] | 1399 | |
Keith Davis | f500d6c | 2020-08-31 08:32:55 +0100 | [diff] [blame] | 1400 | ARMNN_COMPARE_REF_AUTO_TEST_CASE_WITH_THF(CompareDepthwiseConv2dWithReferenceFloat32, |
Nattapat Chaimanowong | 649dd95 | 2019-01-22 16:10:44 +0000 | [diff] [blame] | 1401 | CompareDepthwiseConvolution2dFloatTest, |
Sadik Armagan | 581742d | 2019-08-12 14:11:37 +0100 | [diff] [blame] | 1402 | DataLayout::NCHW) |
Keith Davis | f500d6c | 2020-08-31 08:32:55 +0100 | [diff] [blame] | 1403 | ARMNN_COMPARE_REF_AUTO_TEST_CASE_WITH_THF(CompareDepthwiseConv2dWithReferenceUint8, |
Nattapat Chaimanowong | 649dd95 | 2019-01-22 16:10:44 +0000 | [diff] [blame] | 1404 | CompareDepthwiseConvolution2dUint8Test, |
Sadik Armagan | 581742d | 2019-08-12 14:11:37 +0100 | [diff] [blame] | 1405 | DataLayout::NCHW) |
jimfly01 | 7af00da | 2018-10-31 14:43:53 +0000 | [diff] [blame] | 1406 | |
Keith Davis | f500d6c | 2020-08-31 08:32:55 +0100 | [diff] [blame] | 1407 | ARMNN_COMPARE_REF_AUTO_TEST_CASE_WITH_THF(CompareDepthwiseConv2dWithReferenceFloat32Nhwc, |
Nattapat Chaimanowong | 649dd95 | 2019-01-22 16:10:44 +0000 | [diff] [blame] | 1408 | CompareDepthwiseConvolution2dFloatTest, |
Sadik Armagan | 581742d | 2019-08-12 14:11:37 +0100 | [diff] [blame] | 1409 | DataLayout::NHWC) |
Keith Davis | f500d6c | 2020-08-31 08:32:55 +0100 | [diff] [blame] | 1410 | ARMNN_COMPARE_REF_AUTO_TEST_CASE_WITH_THF(CompareDepthwiseConv2dWithReferenceUint8Nhwc, |
Nattapat Chaimanowong | 649dd95 | 2019-01-22 16:10:44 +0000 | [diff] [blame] | 1411 | CompareDepthwiseConvolution2dUint8Test, |
Sadik Armagan | 581742d | 2019-08-12 14:11:37 +0100 | [diff] [blame] | 1412 | DataLayout::NHWC) |
telsoa01 | 4fcda01 | 2018-03-09 14:13:49 +0000 | [diff] [blame] | 1413 | |
Finn Williams | 826a543 | 2020-08-27 16:15:20 +0100 | [diff] [blame] | 1414 | ARMNN_COMPARE_REF_AUTO_TEST_CASE_WITH_THF(CompareNormalizationWithinWithReference, CompareNormalizationTest, |
| 1415 | NormalizationAlgorithmChannel::Within, |
| 1416 | NormalizationAlgorithmMethod::LocalBrightness) |
| 1417 | ARMNN_COMPARE_REF_AUTO_TEST_CASE_WITH_THF(CompareNormalizationAcrossWithReference, CompareNormalizationTest, |
| 1418 | NormalizationAlgorithmChannel::Across, |
| 1419 | NormalizationAlgorithmMethod::LocalBrightness) |
telsoa01 | 4fcda01 | 2018-03-09 14:13:49 +0000 | [diff] [blame] | 1420 | |
Finn Williams | 826a543 | 2020-08-27 16:15:20 +0100 | [diff] [blame] | 1421 | ARMNN_COMPARE_REF_AUTO_TEST_CASE_WITH_THF(CompareMaxPooling2dWithReference, ComparePooling2dTest, PoolingAlgorithm::Max) |
| 1422 | ARMNN_COMPARE_REF_AUTO_TEST_CASE_WITH_THF(CompareMaxPooling2dWithReferenceUint8, ComparePooling2dUint8Test, |
| 1423 | PoolingAlgorithm::Max) |
| 1424 | ARMNN_COMPARE_REF_AUTO_TEST_CASE_WITH_THF(CompareAveragePooling2dWithReference, ComparePooling2dTest, |
| 1425 | PoolingAlgorithm::Average) |
| 1426 | ARMNN_COMPARE_REF_AUTO_TEST_CASE_WITH_THF(CompareAveragePooling2dWithReferenceUint8, ComparePooling2dUint8Test, |
| 1427 | PoolingAlgorithm::Average) |
| 1428 | ARMNN_COMPARE_REF_AUTO_TEST_CASE_WITH_THF(CompareL2Pooling2dWithReference, ComparePooling2dTest, PoolingAlgorithm::L2) |
| 1429 | ARMNN_COMPARE_REF_AUTO_TEST_CASE_WITH_THF(UNSUPPORTED_CompareL2Pooling2dWithReferenceUint8, ComparePooling2dUint8Test, |
| 1430 | PoolingAlgorithm::L2) |
telsoa01 | 4fcda01 | 2018-03-09 14:13:49 +0000 | [diff] [blame] | 1431 | |
Sadik Armagan | 56785c7 | 2020-08-27 12:57:20 +0100 | [diff] [blame] | 1432 | ARMNN_COMPARE_REF_AUTO_TEST_CASE_WITH_THF(CompareSoftmaxBeta1WithReference, CompareSoftmaxTest, 1.0f) |
| 1433 | ARMNN_COMPARE_REF_AUTO_TEST_CASE_WITH_THF(CompareSoftmaxBeta2WithReference, CompareSoftmaxTest, 2.0f) |
telsoa01 | 4fcda01 | 2018-03-09 14:13:49 +0000 | [diff] [blame] | 1434 | |
Sadik Armagan | 56785c7 | 2020-08-27 12:57:20 +0100 | [diff] [blame] | 1435 | ARMNN_COMPARE_REF_AUTO_TEST_CASE_WITH_THF(CompareSoftmaxUint8Beta1WithReference, CompareSoftmaxUint8Test, 1.0f) |
| 1436 | ARMNN_COMPARE_REF_AUTO_TEST_CASE_WITH_THF(CompareSoftmaxUint8Beta2WithReference, CompareSoftmaxUint8Test, 2.0f) |
telsoa01 | 4fcda01 | 2018-03-09 14:13:49 +0000 | [diff] [blame] | 1437 | |
Keith Davis | 33a626f | 2020-08-27 15:38:12 +0100 | [diff] [blame] | 1438 | ARMNN_COMPARE_REF_AUTO_TEST_CASE_WITH_THF(CompareAddition, CompareAdditionTest) |
telsoa01 | 4fcda01 | 2018-03-09 14:13:49 +0000 | [diff] [blame] | 1439 | |
Keith Davis | 33a626f | 2020-08-27 15:38:12 +0100 | [diff] [blame] | 1440 | ARMNN_COMPARE_REF_AUTO_TEST_CASE_WITH_THF(CompareMultiplicationWithReference, CompareMultiplicationTest) |
telsoa01 | 4fcda01 | 2018-03-09 14:13:49 +0000 | [diff] [blame] | 1441 | |
Keith Davis | 33a626f | 2020-08-27 15:38:12 +0100 | [diff] [blame] | 1442 | ARMNN_COMPARE_REF_AUTO_TEST_CASE_WITH_THF(CompareBatchNorm, CompareBatchNormTest) |
telsoa01 | 4fcda01 | 2018-03-09 14:13:49 +0000 | [diff] [blame] | 1443 | |
Keith Davis | 33a626f | 2020-08-27 15:38:12 +0100 | [diff] [blame] | 1444 | ARMNN_COMPARE_REF_AUTO_TEST_CASE_WITH_THF(CompareReLu1, CompareBoundedReLuTest, 1.0f, -1.0f) |
| 1445 | ARMNN_COMPARE_REF_AUTO_TEST_CASE_WITH_THF(CompareReLu6, CompareBoundedReLuTest, 6.0f, 0.0f) |
telsoa01 | 4fcda01 | 2018-03-09 14:13:49 +0000 | [diff] [blame] | 1446 | |
| 1447 | // ============================================================================ |
| 1448 | // FIXTURE tests |
| 1449 | |
Keith Davis | 33a626f | 2020-08-27 15:38:12 +0100 | [diff] [blame] | 1450 | ARMNN_COMPARE_REF_FIXTURE_TEST_CASE_WITH_THF(CompareSigmoidActivationWithReference, ActivationFixture, |
Sadik Armagan | 581742d | 2019-08-12 14:11:37 +0100 | [diff] [blame] | 1451 | CompareActivationTest, ActivationFunction::Sigmoid, 5u) |
telsoa01 | 4fcda01 | 2018-03-09 14:13:49 +0000 | [diff] [blame] | 1452 | |
Keith Davis | 33a626f | 2020-08-27 15:38:12 +0100 | [diff] [blame] | 1453 | ARMNN_COMPARE_REF_FIXTURE_TEST_CASE_WITH_THF(CompareTanhActivationWithReference, ActivationFixture, |
Sadik Armagan | 581742d | 2019-08-12 14:11:37 +0100 | [diff] [blame] | 1454 | CompareActivationTest, ActivationFunction::TanH, 5u) |
telsoa01 | 4fcda01 | 2018-03-09 14:13:49 +0000 | [diff] [blame] | 1455 | |
Keith Davis | 33a626f | 2020-08-27 15:38:12 +0100 | [diff] [blame] | 1456 | ARMNN_COMPARE_REF_FIXTURE_TEST_CASE_WITH_THF(CompareLinearActivationWithReference, ActivationFixture, |
Sadik Armagan | 581742d | 2019-08-12 14:11:37 +0100 | [diff] [blame] | 1457 | CompareActivationTest, ActivationFunction::Linear, 5u) |
telsoa01 | 4fcda01 | 2018-03-09 14:13:49 +0000 | [diff] [blame] | 1458 | |
Keith Davis | 33a626f | 2020-08-27 15:38:12 +0100 | [diff] [blame] | 1459 | ARMNN_COMPARE_REF_FIXTURE_TEST_CASE_WITH_THF(CompareReLuActivationWithReference, ActivationFixture, |
Sadik Armagan | 581742d | 2019-08-12 14:11:37 +0100 | [diff] [blame] | 1460 | CompareActivationTest, ActivationFunction::ReLu, 5u) |
telsoa01 | 4fcda01 | 2018-03-09 14:13:49 +0000 | [diff] [blame] | 1461 | |
Keith Davis | 33a626f | 2020-08-27 15:38:12 +0100 | [diff] [blame] | 1462 | ARMNN_COMPARE_REF_FIXTURE_TEST_CASE_WITH_THF(CompareBoundedReLuActivationWithReference, ActivationFixture, |
Sadik Armagan | 581742d | 2019-08-12 14:11:37 +0100 | [diff] [blame] | 1463 | CompareActivationTest, ActivationFunction::BoundedReLu, 5u) |
Keith Davis | 33a626f | 2020-08-27 15:38:12 +0100 | [diff] [blame] | 1464 | ARMNN_COMPARE_REF_FIXTURE_TEST_CASE_WITH_THF(CompareBoundedReLuActivationWithReferenceUint8, ActivationFixture, |
Sadik Armagan | 581742d | 2019-08-12 14:11:37 +0100 | [diff] [blame] | 1465 | CompareActivationUint8Test, ActivationFunction::BoundedReLu) |
telsoa01 | 4fcda01 | 2018-03-09 14:13:49 +0000 | [diff] [blame] | 1466 | |
Keith Davis | 33a626f | 2020-08-27 15:38:12 +0100 | [diff] [blame] | 1467 | ARMNN_COMPARE_REF_FIXTURE_TEST_CASE_WITH_THF(CompareSoftReLuActivationWithReference, ActivationFixture, |
Sadik Armagan | 581742d | 2019-08-12 14:11:37 +0100 | [diff] [blame] | 1468 | CompareActivationTest, ActivationFunction::SoftReLu, 1u) |
telsoa01 | 4fcda01 | 2018-03-09 14:13:49 +0000 | [diff] [blame] | 1469 | |
Keith Davis | 33a626f | 2020-08-27 15:38:12 +0100 | [diff] [blame] | 1470 | ARMNN_COMPARE_REF_FIXTURE_TEST_CASE_WITH_THF(CompareLeakyReLuActivationWithReference, ActivationFixture, |
Sadik Armagan | 581742d | 2019-08-12 14:11:37 +0100 | [diff] [blame] | 1471 | CompareActivationTest, ActivationFunction::LeakyReLu, 5u) |
telsoa01 | 4fcda01 | 2018-03-09 14:13:49 +0000 | [diff] [blame] | 1472 | |
Keith Davis | 33a626f | 2020-08-27 15:38:12 +0100 | [diff] [blame] | 1473 | ARMNN_COMPARE_REF_FIXTURE_TEST_CASE_WITH_THF(CompareAbsActivationWithReference, ActivationFixture, |
Sadik Armagan | 581742d | 2019-08-12 14:11:37 +0100 | [diff] [blame] | 1474 | CompareActivationTest, ActivationFunction::Abs, 5u) |
telsoa01 | 4fcda01 | 2018-03-09 14:13:49 +0000 | [diff] [blame] | 1475 | |
Keith Davis | 33a626f | 2020-08-27 15:38:12 +0100 | [diff] [blame] | 1476 | ARMNN_COMPARE_REF_FIXTURE_TEST_CASE_WITH_THF(CompareSqrtActivationWithReference, PositiveActivationFixture, |
Sadik Armagan | 581742d | 2019-08-12 14:11:37 +0100 | [diff] [blame] | 1477 | CompareActivationTest, ActivationFunction::Sqrt, 5u) |
telsoa01 | 4fcda01 | 2018-03-09 14:13:49 +0000 | [diff] [blame] | 1478 | |
Keith Davis | 33a626f | 2020-08-27 15:38:12 +0100 | [diff] [blame] | 1479 | ARMNN_COMPARE_REF_FIXTURE_TEST_CASE_WITH_THF(CompareSquareActivationWithReference, ActivationFixture, |
Sadik Armagan | 581742d | 2019-08-12 14:11:37 +0100 | [diff] [blame] | 1480 | CompareActivationTest, ActivationFunction::Square, 5u) |
Matteo Martincigh | e67edb2 | 2019-08-14 14:05:46 +0100 | [diff] [blame] | 1481 | |
Keith Davis | 33a626f | 2020-08-27 15:38:12 +0100 | [diff] [blame] | 1482 | ARMNN_COMPARE_REF_FIXTURE_TEST_CASE_WITH_THF(CompareEluActivationWithReference, ActivationFixture, |
Teresa Charlin | e32c844 | 2020-03-05 14:41:50 +0000 | [diff] [blame] | 1483 | CompareActivationTest, ActivationFunction::Elu, 5u) |
| 1484 | |
Matteo Martincigh | e67edb2 | 2019-08-14 14:05:46 +0100 | [diff] [blame] | 1485 | #endif |
| 1486 | |
telsoa01 | 4fcda01 | 2018-03-09 14:13:49 +0000 | [diff] [blame] | 1487 | BOOST_AUTO_TEST_SUITE_END() |