Moritz Pflanzer | b3d2579 | 2017-07-26 11:49:37 +0100 | [diff] [blame] | 1 | /* |
Michele Di Giorgio | 223aba9 | 2021-04-28 16:03:32 +0100 | [diff] [blame] | 2 | * Copyright (c) 2017-2021 Arm Limited. |
Moritz Pflanzer | b3d2579 | 2017-07-26 11:49:37 +0100 | [diff] [blame] | 3 | * |
| 4 | * SPDX-License-Identifier: MIT |
| 5 | * |
| 6 | * Permission is hereby granted, free of charge, to any person obtaining a copy |
| 7 | * of this software and associated documentation files (the "Software"), to |
| 8 | * deal in the Software without restriction, including without limitation the |
| 9 | * rights to use, copy, modify, merge, publish, distribute, sublicense, and/or |
| 10 | * sell copies of the Software, and to permit persons to whom the Software is |
| 11 | * furnished to do so, subject to the following conditions: |
| 12 | * |
| 13 | * The above copyright notice and this permission notice shall be included in all |
| 14 | * copies or substantial portions of the Software. |
| 15 | * |
| 16 | * THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR |
| 17 | * IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, |
| 18 | * FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE |
| 19 | * AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER |
| 20 | * LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, |
| 21 | * OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE |
| 22 | * SOFTWARE. |
| 23 | */ |
| 24 | #ifndef ARM_COMPUTE_TEST_SMALL_CONVOLUTION_LAYER_DATASET |
| 25 | #define ARM_COMPUTE_TEST_SMALL_CONVOLUTION_LAYER_DATASET |
| 26 | |
Moritz Pflanzer | a09de0c | 2017-09-01 20:41:12 +0100 | [diff] [blame] | 27 | #include "tests/datasets/ConvolutionLayerDataset.h" |
Moritz Pflanzer | b3d2579 | 2017-07-26 11:49:37 +0100 | [diff] [blame] | 28 | |
Anthony Barbier | 2a07e18 | 2017-08-04 18:20:27 +0100 | [diff] [blame] | 29 | #include "utils/TypePrinter.h" |
Moritz Pflanzer | b3d2579 | 2017-07-26 11:49:37 +0100 | [diff] [blame] | 30 | |
| 31 | #include "arm_compute/core/TensorShape.h" |
| 32 | #include "arm_compute/core/Types.h" |
| 33 | |
| 34 | namespace arm_compute |
| 35 | { |
| 36 | namespace test |
| 37 | { |
| 38 | namespace datasets |
| 39 | { |
Gian Marco Iodice | d2fab73 | 2018-03-02 11:18:12 +0000 | [diff] [blame] | 40 | class SmallWinogradConvolutionLayer3x3Dataset final : public ConvolutionLayerDataset |
Pablo Tello | 8951933 | 2017-11-17 11:52:36 +0000 | [diff] [blame] | 41 | { |
| 42 | public: |
Gian Marco Iodice | d2fab73 | 2018-03-02 11:18:12 +0000 | [diff] [blame] | 43 | SmallWinogradConvolutionLayer3x3Dataset() |
Pablo Tello | 8951933 | 2017-11-17 11:52:36 +0000 | [diff] [blame] | 44 | { |
Pablo Tello | 79ffade | 2018-05-04 11:45:13 +0100 | [diff] [blame] | 45 | // Channel size big enough to force multithreaded execution of the input transform |
| 46 | add_config(TensorShape(8U, 8U, 32U), TensorShape(3U, 3U, 32U, 1U), TensorShape(1U), TensorShape(6U, 6U, 1U), PadStrideInfo(1, 1, 0, 0)); |
Pablo Tello | 8951933 | 2017-11-17 11:52:36 +0000 | [diff] [blame] | 47 | // Batch size 1 |
| 48 | add_config(TensorShape(8U, 8U, 2U), TensorShape(3U, 3U, 2U, 1U), TensorShape(1U), TensorShape(6U, 6U, 1U), PadStrideInfo(1, 1, 0, 0)); |
| 49 | // Batch size 4 |
| 50 | add_config(TensorShape(23U, 27U, 5U, 4U), TensorShape(3U, 3U, 5U, 21U), TensorShape(21U), TensorShape(21U, 25U, 21U, 4U), PadStrideInfo(1, 1, 0, 0)); |
Pablo Tello | 679463a | 2018-02-06 11:47:59 +0000 | [diff] [blame] | 51 | add_config(TensorShape(8U, 8U, 2U), TensorShape(3U, 3U, 2U, 1U), TensorShape(1U), TensorShape(8U, 8U, 1U), PadStrideInfo(1, 1, 1, 1)); |
giuros01 | f44fe3d | 2019-08-14 16:49:27 +0100 | [diff] [blame] | 52 | add_config(TensorShape(3U, 9U), TensorShape(3U, 3U), TensorShape(1), TensorShape(3U, 9U), PadStrideInfo(1, 1, 1, 1)); |
Gian Marco Iodice | d2fab73 | 2018-03-02 11:18:12 +0000 | [diff] [blame] | 53 | } |
| 54 | }; |
Pablo Tello | f6c572c | 2018-02-14 12:47:30 +0000 | [diff] [blame] | 55 | |
Gian Marco Iodice | f1c2bf0 | 2018-06-13 14:05:54 +0100 | [diff] [blame] | 56 | class SmallWinogradConvolutionLayer3x1Dataset final : public ConvolutionLayerDataset |
| 57 | { |
| 58 | public: |
| 59 | SmallWinogradConvolutionLayer3x1Dataset() |
| 60 | { |
| 61 | // Channel size big enough to force multithreaded execution of the input transform |
| 62 | add_config(TensorShape(8U, 8U, 32U), TensorShape(3U, 1U, 32U, 1U), TensorShape(1U), TensorShape(6U, 8U, 1U), PadStrideInfo(1, 1, 0, 0)); |
| 63 | // Batch size 1 |
| 64 | add_config(TensorShape(8U, 8U, 2U), TensorShape(3U, 1U, 2U, 1U), TensorShape(1U), TensorShape(6U, 8U, 1U), PadStrideInfo(1, 1, 0, 0)); |
| 65 | // Batch size 4 |
| 66 | add_config(TensorShape(23U, 27U, 5U, 4U), TensorShape(3U, 1U, 5U, 21U), TensorShape(21U), TensorShape(21U, 27U, 21U, 4U), PadStrideInfo(1, 1, 0, 0)); |
| 67 | add_config(TensorShape(8U, 8U, 2U), TensorShape(3U, 1U, 2U, 1U), TensorShape(1U), TensorShape(8U, 8U, 1U), PadStrideInfo(1, 1, 1, 0)); |
| 68 | } |
| 69 | }; |
| 70 | |
| 71 | class SmallWinogradConvolutionLayer1x3Dataset final : public ConvolutionLayerDataset |
| 72 | { |
| 73 | public: |
| 74 | SmallWinogradConvolutionLayer1x3Dataset() |
| 75 | { |
| 76 | // Channel size big enough to force multithreaded execution of the input transform |
| 77 | add_config(TensorShape(8U, 8U, 32U), TensorShape(1U, 3U, 32U, 1U), TensorShape(1U), TensorShape(8U, 6U, 1U), PadStrideInfo(1, 1, 0, 0)); |
| 78 | // Batch size 1 |
| 79 | add_config(TensorShape(8U, 8U, 2U), TensorShape(1U, 3U, 2U, 1U), TensorShape(1U), TensorShape(8U, 6U, 1U), PadStrideInfo(1, 1, 0, 0)); |
| 80 | // Batch size 4 |
| 81 | add_config(TensorShape(23U, 27U, 5U, 4U), TensorShape(1U, 3U, 5U, 21U), TensorShape(21U), TensorShape(23U, 25U, 21U, 4U), PadStrideInfo(1, 1, 0, 0)); |
| 82 | add_config(TensorShape(8U, 8U, 2U), TensorShape(1U, 3U, 2U, 1U), TensorShape(1U), TensorShape(8U, 8U, 1U), PadStrideInfo(1, 1, 0, 1)); |
| 83 | } |
| 84 | }; |
| 85 | |
Gian Marco Iodice | d2fab73 | 2018-03-02 11:18:12 +0000 | [diff] [blame] | 86 | class SmallWinogradConvolutionLayer5x5Dataset final : public ConvolutionLayerDataset |
| 87 | { |
| 88 | public: |
| 89 | SmallWinogradConvolutionLayer5x5Dataset() |
| 90 | { |
Pablo Tello | f6c572c | 2018-02-14 12:47:30 +0000 | [diff] [blame] | 91 | add_config(TensorShape(8U, 8U, 2U), TensorShape(5U, 5U, 2U, 1U), TensorShape(1U), TensorShape(4U, 4U, 1U), PadStrideInfo(1, 1, 0, 0)); |
Pablo Tello | d267b05 | 2018-02-19 16:46:03 +0000 | [diff] [blame] | 92 | add_config(TensorShape(8U, 8U, 2U), TensorShape(5U, 5U, 2U), TensorShape(1U), TensorShape(8U, 8U, 1U), PadStrideInfo(1, 1, 2, 2)); |
Pablo Tello | 8951933 | 2017-11-17 11:52:36 +0000 | [diff] [blame] | 93 | } |
| 94 | }; |
| 95 | |
Gian Marco Iodice | 876be2a | 2018-07-03 12:22:09 +0100 | [diff] [blame] | 96 | class SmallWinogradConvolutionLayer5x1Dataset final : public ConvolutionLayerDataset |
| 97 | { |
| 98 | public: |
| 99 | SmallWinogradConvolutionLayer5x1Dataset() |
| 100 | { |
| 101 | add_config(TensorShape(8U, 8U, 2U), TensorShape(5U, 1U, 2U, 1U), TensorShape(1U), TensorShape(4U, 8U, 1U), PadStrideInfo(1, 1, 0, 0)); |
| 102 | add_config(TensorShape(8U, 8U, 2U), TensorShape(5U, 1U, 2U), TensorShape(1U), TensorShape(8U, 8U, 1U), PadStrideInfo(1, 1, 2, 0)); |
| 103 | } |
| 104 | }; |
| 105 | |
| 106 | class SmallWinogradConvolutionLayer1x5Dataset final : public ConvolutionLayerDataset |
| 107 | { |
| 108 | public: |
| 109 | SmallWinogradConvolutionLayer1x5Dataset() |
| 110 | { |
| 111 | add_config(TensorShape(8U, 8U, 2U), TensorShape(1U, 5U, 2U, 1U), TensorShape(1U), TensorShape(8U, 4U, 1U), PadStrideInfo(1, 1, 0, 0)); |
| 112 | add_config(TensorShape(8U, 8U, 2U), TensorShape(1U, 5U, 2U), TensorShape(1U), TensorShape(8U, 8U, 1U), PadStrideInfo(1, 1, 0, 2)); |
| 113 | } |
| 114 | }; |
| 115 | |
Pablo Tello | 96e922e | 2018-09-26 11:25:15 +0100 | [diff] [blame] | 116 | class SmallWinogradConvolutionLayer7x1Dataset final : public ConvolutionLayerDataset |
| 117 | { |
| 118 | public: |
| 119 | SmallWinogradConvolutionLayer7x1Dataset() |
| 120 | { |
| 121 | add_config(TensorShape(14U, 14U, 2U), TensorShape(7U, 1U, 2U, 1U), TensorShape(1U), TensorShape(8U, 14U, 1U), PadStrideInfo(1, 1, 0, 0)); |
| 122 | add_config(TensorShape(14U, 14U, 2U), TensorShape(7U, 1U, 2U), TensorShape(1U), TensorShape(14U, 14U, 1U), PadStrideInfo(1, 1, 3, 0)); |
| 123 | } |
| 124 | }; |
| 125 | |
| 126 | class SmallWinogradConvolutionLayer1x7Dataset final : public ConvolutionLayerDataset |
| 127 | { |
| 128 | public: |
| 129 | SmallWinogradConvolutionLayer1x7Dataset() |
| 130 | { |
| 131 | add_config(TensorShape(14U, 14U, 2U), TensorShape(1U, 7U, 2U, 1U), TensorShape(1U), TensorShape(14U, 8U, 1U), PadStrideInfo(1, 1, 0, 0)); |
| 132 | add_config(TensorShape(14U, 14U, 2U), TensorShape(1U, 7U, 2U), TensorShape(1U), TensorShape(14U, 14U, 1U), PadStrideInfo(1, 1, 0, 3)); |
| 133 | } |
| 134 | }; |
| 135 | |
Georgios Pinitas | 8be9148 | 2019-03-26 17:23:28 +0000 | [diff] [blame] | 136 | class SmallFFTConvolutionLayerDataset final : public ConvolutionLayerDataset |
| 137 | { |
| 138 | public: |
| 139 | SmallFFTConvolutionLayerDataset() |
| 140 | { |
| 141 | add_config(TensorShape(8U, 7U, 3U), TensorShape(3U, 3U, 3U, 2U), TensorShape(2U), TensorShape(8U, 7U, 2U), PadStrideInfo(1, 1, 1, 1)); |
| 142 | add_config(TensorShape(64U, 32U, 5U), TensorShape(5U, 5U, 5U, 10U), TensorShape(10U), TensorShape(64U, 32U, 10U), PadStrideInfo(1, 1, 2, 2)); |
| 143 | add_config(TensorShape(192U, 128U, 8U), TensorShape(9U, 9U, 8U, 3U), TensorShape(3U), TensorShape(192U, 128U, 3U), PadStrideInfo(1, 1, 4, 4)); |
| 144 | } |
| 145 | }; |
| 146 | |
Moritz Pflanzer | b3d2579 | 2017-07-26 11:49:37 +0100 | [diff] [blame] | 147 | class SmallConvolutionLayerDataset final : public ConvolutionLayerDataset |
| 148 | { |
| 149 | public: |
| 150 | SmallConvolutionLayerDataset() |
| 151 | { |
Georgios Pinitas | 0e7210d | 2018-12-12 19:14:27 +0000 | [diff] [blame] | 152 | // 1D Kernel |
| 153 | add_config(TensorShape(1U, 5U, 2U), TensorShape(1U, 3U, 2U, 3U), TensorShape(3U), TensorShape(1U, 7U, 3U), PadStrideInfo(1, 1, 0, 0, 2, 2, DimensionRoundingType::FLOOR)); |
| 154 | |
Michele Di Giorgio | e37662a | 2020-04-29 15:14:18 +0100 | [diff] [blame] | 155 | // 1x1 Kernel with Stride (1, 1) and NHWC data layout in order to test skipping Im2Col |
| 156 | add_config(TensorShape(1U, 5U, 2U), TensorShape(1U, 1U, 2U, 3U), TensorShape(3U), TensorShape(1U, 5U, 3U), PadStrideInfo(1, 1, 0, 0)); |
| 157 | |
SiCong Li | caf8c5e | 2017-08-21 13:12:52 +0100 | [diff] [blame] | 158 | // Batch size 1 |
Michele Di Giorgio | e37662a | 2020-04-29 15:14:18 +0100 | [diff] [blame] | 159 | add_config(TensorShape(23U, 27U, 5U), TensorShape(3U, 3U, 5U, 2U), TensorShape(2U), TensorShape(11U, 25U, 2U), PadStrideInfo(2, 1, 0, 0)); |
| 160 | add_config(TensorShape(33U, 27U, 7U), TensorShape(5U, 5U, 7U, 3U), TensorShape(3U), TensorShape(11U, 12U, 3U), PadStrideInfo(3, 2, 1, 0)); |
| 161 | add_config(TensorShape(17U, 31U, 2U), TensorShape(5U, 5U, 2U, 4U), TensorShape(4U), TensorShape(15U, 15U, 4U), PadStrideInfo(1, 2, 1, 1)); |
| 162 | add_config(TensorShape(3U, 3U, 1U), TensorShape(2U, 2U, 1U, 5U), TensorShape(5U), TensorShape(2U, 2U, 5U), PadStrideInfo(1, 1, 0, 0)); |
| 163 | |
| 164 | // Batch size different than one |
SiCong Li | caf8c5e | 2017-08-21 13:12:52 +0100 | [diff] [blame] | 165 | add_config(TensorShape(23U, 27U, 5U, 4U), TensorShape(3U, 3U, 5U, 21U), TensorShape(21U), TensorShape(11U, 25U, 21U, 4U), PadStrideInfo(2, 1, 0, 0)); |
| 166 | add_config(TensorShape(33U, 27U, 7U, 4U), TensorShape(5U, 5U, 7U, 16U), TensorShape(16U), TensorShape(11U, 12U, 16U, 4U), PadStrideInfo(3, 2, 1, 0)); |
| 167 | add_config(TensorShape(17U, 31U, 2U, 4U), TensorShape(5U, 5U, 2U, 19U), TensorShape(19U), TensorShape(15U, 15U, 19U, 4U), PadStrideInfo(1, 2, 1, 1)); |
Michele Di Giorgio | e37662a | 2020-04-29 15:14:18 +0100 | [diff] [blame] | 168 | |
Georgios Pinitas | b660dcf | 2017-12-13 10:48:06 +0000 | [diff] [blame] | 169 | // FC convolution |
| 170 | add_config(TensorShape(1U, 1U, 1024U), TensorShape(1U, 1U, 1024U, 1001U), TensorShape(1001U), TensorShape(1U, 1U, 1001U), PadStrideInfo(1, 1, 0, 0)); |
Michele Di Giorgio | e37662a | 2020-04-29 15:14:18 +0100 | [diff] [blame] | 171 | |
Jaroslaw Rzepecki | a1ed41f | 2017-10-13 11:13:58 +0100 | [diff] [blame] | 172 | // Asymmetric padding |
Michele Di Giorgio | e37662a | 2020-04-29 15:14:18 +0100 | [diff] [blame] | 173 | add_config(TensorShape(33U, 27U, 3U), TensorShape(5U, 7U, 3U, 4U), TensorShape(4U), TensorShape(11U, 12U, 4U), PadStrideInfo(3, 2, 1, 1, 2, 0, DimensionRoundingType::FLOOR)); |
| 174 | add_config(TensorShape(33U, 27U, 3U), TensorShape(5U, 7U, 3U, 4U), TensorShape(4U), TensorShape(11U, 12U, 4U), PadStrideInfo(3, 2, 1, 1, 0, 2, DimensionRoundingType::FLOOR)); |
| 175 | add_config(TensorShape(33U, 27U, 3U), TensorShape(5U, 7U, 3U, 4U), TensorShape(4U), TensorShape(11U, 12U, 4U), PadStrideInfo(3, 2, 2, 1, 2, 0, DimensionRoundingType::FLOOR)); |
| 176 | add_config(TensorShape(33U, 27U, 3U), TensorShape(5U, 7U, 3U, 4U), TensorShape(4U), TensorShape(11U, 12U, 4U), PadStrideInfo(3, 2, 1, 3, 0, 2, DimensionRoundingType::FLOOR)); |
| 177 | add_config(TensorShape(33U, 27U, 3U), TensorShape(5U, 7U, 3U, 4U), TensorShape(4U), TensorShape(10U, 11U, 4U), PadStrideInfo(3, 2, 1, 0, 1, 0, DimensionRoundingType::FLOOR)); |
| 178 | add_config(TensorShape(33U, 27U, 3U), TensorShape(5U, 7U, 3U, 4U), TensorShape(4U), TensorShape(10U, 11U, 4U), PadStrideInfo(3, 2, 0, 1, 0, 1, DimensionRoundingType::FLOOR)); |
Gian Marco Iodice | 3139f03 | 2018-11-05 14:26:32 +0000 | [diff] [blame] | 179 | |
| 180 | add_config(TensorShape(5U, 4U, 3U, 2U), TensorShape(4U, 4U, 3U, 1U), TensorShape(1U), TensorShape(2U, 1U, 1U, 2U), PadStrideInfo(1, 1, 0, 0, 0, 0, DimensionRoundingType::FLOOR)); |
| 181 | } |
| 182 | }; |
| 183 | |
Gunes Bayir | cc171f9 | 2021-09-13 13:38:29 +0100 | [diff] [blame] | 184 | class SmallConvolutionLayerPrePaddingDataset final : public ConvolutionLayerDataset |
| 185 | { |
| 186 | public: |
| 187 | SmallConvolutionLayerPrePaddingDataset() |
| 188 | { |
| 189 | // output shape is calculated by accounting pre-padding layer as well -- all the data is in nchw |
| 190 | add_config(TensorShape(17U, 31U, 2U), TensorShape(5U, 5U, 2U, 19U), TensorShape(19U), TensorShape(17U, 16U, 19U), PadStrideInfo(1, 2, 1, 1)); |
| 191 | add_config(TensorShape(33U, 27U, 7U), TensorShape(5U, 5U, 7U, 16U), TensorShape(16U), TensorShape(12U, 13U, 16U), PadStrideInfo(3, 2, 2, 0)); |
| 192 | } |
| 193 | }; |
| 194 | |
Gian Marco Iodice | 3139f03 | 2018-11-05 14:26:32 +0000 | [diff] [blame] | 195 | class SmallConvolutionLayerReducedDataset final : public ConvolutionLayerDataset |
| 196 | { |
| 197 | public: |
| 198 | SmallConvolutionLayerReducedDataset() |
| 199 | { |
| 200 | // Batch size 1 |
| 201 | add_config(TensorShape(23U, 27U, 5U), TensorShape(3U, 3U, 5U, 21U), TensorShape(21U), TensorShape(11U, 25U, 21U), PadStrideInfo(2, 1, 0, 0)); |
| 202 | add_config(TensorShape(33U, 27U, 7U), TensorShape(5U, 5U, 7U, 16U), TensorShape(16U), TensorShape(11U, 12U, 16U), PadStrideInfo(3, 2, 1, 0)); |
| 203 | add_config(TensorShape(17U, 31U, 2U), TensorShape(5U, 5U, 2U, 19U), TensorShape(19U), TensorShape(15U, 15U, 19U), PadStrideInfo(1, 2, 1, 1)); |
| 204 | |
| 205 | // Asymmetric padding |
| 206 | add_config(TensorShape(33U, 27U, 7U, 5U), TensorShape(5U, 7U, 7U, 16U), TensorShape(16U), TensorShape(11U, 12U, 16U, 5U), PadStrideInfo(3, 2, 1, 1, 2, 0, DimensionRoundingType::FLOOR)); |
| 207 | add_config(TensorShape(33U, 27U, 7U, 5U), TensorShape(5U, 7U, 7U, 16U), TensorShape(16U), TensorShape(11U, 12U, 16U, 5U), PadStrideInfo(3, 2, 1, 1, 0, 2, DimensionRoundingType::FLOOR)); |
| 208 | add_config(TensorShape(33U, 27U, 7U, 5U), TensorShape(5U, 7U, 7U, 16U), TensorShape(16U), TensorShape(11U, 12U, 16U, 5U), PadStrideInfo(3, 2, 2, 1, 2, 0, DimensionRoundingType::FLOOR)); |
Moritz Pflanzer | b3d2579 | 2017-07-26 11:49:37 +0100 | [diff] [blame] | 209 | } |
| 210 | }; |
Gian Marco Iodice | 916d1bc | 2018-08-13 11:20:41 +0100 | [diff] [blame] | 211 | |
| 212 | class SmallGroupedConvolutionLayerDataset final : public ConvolutionLayerDataset |
| 213 | { |
| 214 | public: |
| 215 | SmallGroupedConvolutionLayerDataset() |
| 216 | { |
| 217 | // Batch size 1 |
| 218 | // Number of groups = 2 |
| 219 | add_config(TensorShape(23U, 27U, 8U), TensorShape(1U, 1U, 4U, 24U), TensorShape(24U), TensorShape(12U, 27U, 24U), PadStrideInfo(2, 1, 0, 0)); |
| 220 | add_config(TensorShape(33U, 27U, 12U), TensorShape(5U, 5U, 6U, 16U), TensorShape(16U), TensorShape(11U, 12U, 16U), PadStrideInfo(3, 2, 1, 0)); |
| 221 | // Number of groups = 4 |
| 222 | add_config(TensorShape(23U, 27U, 8U), TensorShape(1U, 1U, 2U, 24U), TensorShape(24U), TensorShape(12U, 27U, 24U), PadStrideInfo(2, 1, 0, 0)); |
| 223 | add_config(TensorShape(33U, 27U, 12U), TensorShape(5U, 5U, 4U, 15U), TensorShape(15U), TensorShape(11U, 12U, 15U), PadStrideInfo(3, 2, 1, 0)); |
| 224 | |
| 225 | // Batch size 4 |
| 226 | // Number of groups = 2 |
| 227 | add_config(TensorShape(23U, 27U, 8U, 4U), TensorShape(1U, 1U, 4U, 24U), TensorShape(24U), TensorShape(12U, 27U, 24U, 4U), PadStrideInfo(2, 1, 0, 0)); |
| 228 | add_config(TensorShape(33U, 27U, 12U, 4U), TensorShape(5U, 5U, 6U, 16U), TensorShape(16U), TensorShape(11U, 12U, 16U, 4U), PadStrideInfo(3, 2, 1, 0)); |
| 229 | // Number of groups = 4 |
| 230 | add_config(TensorShape(23U, 27U, 8U, 4U), TensorShape(1U, 1U, 2U, 24U), TensorShape(24U), TensorShape(12U, 27U, 24U, 4U), PadStrideInfo(2, 1, 0, 0)); |
| 231 | add_config(TensorShape(33U, 27U, 12U, 4U), TensorShape(5U, 5U, 4U, 15U), TensorShape(15U), TensorShape(11U, 12U, 15U, 4U), PadStrideInfo(3, 2, 1, 0)); |
| 232 | |
| 233 | // Arbitrary batch size |
| 234 | add_config(TensorShape(23U, 27U, 8U, 5U), TensorShape(1U, 1U, 4U, 24U), TensorShape(24U), TensorShape(12U, 27U, 24U, 5U), PadStrideInfo(2, 1, 0, 0)); |
| 235 | add_config(TensorShape(33U, 27U, 12U, 3U), TensorShape(5U, 5U, 6U, 16U), TensorShape(16U), TensorShape(11U, 12U, 16U, 3U), PadStrideInfo(3, 2, 1, 0)); |
| 236 | // Number of groups = 4 |
| 237 | add_config(TensorShape(23U, 27U, 8U, 2U), TensorShape(1U, 1U, 2U, 24U), TensorShape(24U), TensorShape(12U, 27U, 24U, 2U), PadStrideInfo(2, 1, 0, 0)); |
| 238 | add_config(TensorShape(33U, 27U, 12U, 5U), TensorShape(5U, 5U, 4U, 15U), TensorShape(15U), TensorShape(11U, 12U, 15U, 5U), PadStrideInfo(3, 2, 1, 0)); |
| 239 | |
| 240 | // Asymmetric padding |
| 241 | add_config(TensorShape(33U, 27U, 8U, 5U), TensorShape(5U, 7U, 2U, 16U), TensorShape(16U), TensorShape(11U, 12U, 16U, 5U), PadStrideInfo(3, 2, 1, 1, 2, 0, DimensionRoundingType::FLOOR)); |
| 242 | add_config(TensorShape(33U, 27U, 8U, 5U), TensorShape(5U, 7U, 4U, 16U), TensorShape(16U), TensorShape(11U, 12U, 16U, 5U), PadStrideInfo(3, 2, 1, 1, 0, 2, DimensionRoundingType::FLOOR)); |
| 243 | add_config(TensorShape(33U, 27U, 6U, 5U), TensorShape(5U, 7U, 3U, 16U), TensorShape(16U), TensorShape(11U, 12U, 16U, 5U), PadStrideInfo(3, 2, 2, 1, 2, 0, DimensionRoundingType::FLOOR)); |
| 244 | } |
| 245 | }; |
Moritz Pflanzer | b3d2579 | 2017-07-26 11:49:37 +0100 | [diff] [blame] | 246 | } // namespace datasets |
| 247 | } // namespace test |
| 248 | } // namespace arm_compute |
| 249 | #endif /* ARM_COMPUTE_TEST_SMALL_CONVOLUTION_LAYER_DATASET */ |