Moritz Pflanzer | f6ad98a | 2017-07-21 17:19:58 +0100 | [diff] [blame] | 1 | /* |
Michalis Spyrou | d466c2d | 2018-01-30 10:54:39 +0000 | [diff] [blame] | 2 | * Copyright (c) 2017-2018 ARM Limited. |
Moritz Pflanzer | f6ad98a | 2017-07-21 17:19:58 +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_SHAPE_DATASETS_H__ |
| 25 | #define __ARM_COMPUTE_TEST_SHAPE_DATASETS_H__ |
| 26 | |
| 27 | #include "arm_compute/core/TensorShape.h" |
Moritz Pflanzer | a09de0c | 2017-09-01 20:41:12 +0100 | [diff] [blame] | 28 | #include "tests/framework/datasets/Datasets.h" |
Moritz Pflanzer | f6ad98a | 2017-07-21 17:19:58 +0100 | [diff] [blame] | 29 | |
| 30 | #include <type_traits> |
| 31 | |
| 32 | namespace arm_compute |
| 33 | { |
| 34 | namespace test |
| 35 | { |
| 36 | namespace datasets |
| 37 | { |
Gian Marco | 5420b28 | 2017-11-29 10:41:38 +0000 | [diff] [blame] | 38 | /** Parent type for all for shape datasets. */ |
| 39 | using ShapeDataset = framework::dataset::ContainerDataset<std::vector<TensorShape>>; |
| 40 | |
Michele Di Giorgio | 5daeffd | 2018-11-26 10:01:15 +0000 | [diff] [blame] | 41 | /** Data set containing tiny 1D tensor shapes. */ |
| 42 | class Tiny1DShapes final : public ShapeDataset |
| 43 | { |
| 44 | public: |
| 45 | Tiny1DShapes() |
| 46 | : ShapeDataset("Shape", |
| 47 | { |
| 48 | TensorShape{ 2U }, |
| 49 | TensorShape{ 3U }, |
| 50 | }) |
| 51 | { |
| 52 | } |
| 53 | }; |
| 54 | |
Gian Marco | 5420b28 | 2017-11-29 10:41:38 +0000 | [diff] [blame] | 55 | /** Data set containing small 1D tensor shapes. */ |
| 56 | class Small1DShapes final : public ShapeDataset |
Moritz Pflanzer | f6ad98a | 2017-07-21 17:19:58 +0100 | [diff] [blame] | 57 | { |
| 58 | public: |
Gian Marco | 5420b28 | 2017-11-29 10:41:38 +0000 | [diff] [blame] | 59 | Small1DShapes() |
| 60 | : ShapeDataset("Shape", |
| 61 | { |
Giorgio Arena | e3d24ce | 2018-08-24 14:44:08 +0100 | [diff] [blame] | 62 | TensorShape{ 128U }, |
| 63 | TensorShape{ 256U }, |
| 64 | TensorShape{ 512U }, |
| 65 | TensorShape{ 1024U } |
Gian Marco | 5420b28 | 2017-11-29 10:41:38 +0000 | [diff] [blame] | 66 | }) |
Moritz Pflanzer | f6ad98a | 2017-07-21 17:19:58 +0100 | [diff] [blame] | 67 | { |
| 68 | } |
| 69 | }; |
| 70 | |
Anthony Barbier | 1c0d0ff | 2018-01-31 13:05:09 +0000 | [diff] [blame] | 71 | /** Data set containing tiny 2D tensor shapes. */ |
| 72 | class Tiny2DShapes final : public ShapeDataset |
| 73 | { |
| 74 | public: |
| 75 | Tiny2DShapes() |
| 76 | : ShapeDataset("Shape", |
| 77 | { |
| 78 | TensorShape{ 7U, 7U }, |
| 79 | TensorShape{ 11U, 13U }, |
| 80 | }) |
| 81 | { |
| 82 | } |
| 83 | }; |
Moritz Pflanzer | b3d2579 | 2017-07-26 11:49:37 +0100 | [diff] [blame] | 84 | /** Data set containing small 2D tensor shapes. */ |
Moritz Pflanzer | f6ad98a | 2017-07-21 17:19:58 +0100 | [diff] [blame] | 85 | class Small2DShapes final : public ShapeDataset |
| 86 | { |
| 87 | public: |
| 88 | Small2DShapes() |
| 89 | : ShapeDataset("Shape", |
| 90 | { |
Moritz Pflanzer | 3ce3ff4 | 2017-07-21 17:41:02 +0100 | [diff] [blame] | 91 | TensorShape{ 7U, 7U }, |
| 92 | TensorShape{ 27U, 13U }, |
| 93 | TensorShape{ 128U, 64U } |
Moritz Pflanzer | f6ad98a | 2017-07-21 17:19:58 +0100 | [diff] [blame] | 94 | }) |
| 95 | { |
| 96 | } |
| 97 | }; |
| 98 | |
Anthony Barbier | 1c0d0ff | 2018-01-31 13:05:09 +0000 | [diff] [blame] | 99 | /** Data set containing tiny 3D tensor shapes. */ |
| 100 | class Tiny3DShapes final : public ShapeDataset |
| 101 | { |
| 102 | public: |
| 103 | Tiny3DShapes() |
| 104 | : ShapeDataset("Shape", |
| 105 | { |
| 106 | TensorShape{ 7U, 7U, 5U }, |
| 107 | TensorShape{ 23U, 13U, 9U }, |
| 108 | }) |
| 109 | { |
| 110 | } |
| 111 | }; |
| 112 | |
Gian Marco Iodice | 06b184a | 2017-08-29 16:05:25 +0100 | [diff] [blame] | 113 | /** Data set containing small 3D tensor shapes. */ |
| 114 | class Small3DShapes final : public ShapeDataset |
| 115 | { |
| 116 | public: |
| 117 | Small3DShapes() |
| 118 | : ShapeDataset("Shape", |
| 119 | { |
Georgios Pinitas | 02ee429 | 2018-02-15 17:22:36 +0000 | [diff] [blame] | 120 | TensorShape{ 1U, 7U, 7U }, |
Pablo Tello | 5430369 | 2018-11-22 16:14:36 +0000 | [diff] [blame] | 121 | TensorShape{ 2U, 5U, 4U }, |
| 122 | |
Georgios Pinitas | 02ee429 | 2018-02-15 17:22:36 +0000 | [diff] [blame] | 123 | TensorShape{ 7U, 7U, 5U }, |
Gian Marco Iodice | 06b184a | 2017-08-29 16:05:25 +0100 | [diff] [blame] | 124 | TensorShape{ 27U, 13U, 37U }, |
| 125 | TensorShape{ 128U, 64U, 21U } |
| 126 | }) |
| 127 | { |
| 128 | } |
| 129 | }; |
| 130 | |
Anthony Barbier | 1c0d0ff | 2018-01-31 13:05:09 +0000 | [diff] [blame] | 131 | /** Data set containing tiny 4D tensor shapes. */ |
| 132 | class Tiny4DShapes final : public ShapeDataset |
| 133 | { |
| 134 | public: |
| 135 | Tiny4DShapes() |
| 136 | : ShapeDataset("Shape", |
| 137 | { |
| 138 | TensorShape{ 7U, 7U, 5U, 3U }, |
| 139 | TensorShape{ 17U, 13U, 7U, 2U }, |
| 140 | }) |
| 141 | { |
| 142 | } |
| 143 | }; |
Gian Marco Iodice | 06b184a | 2017-08-29 16:05:25 +0100 | [diff] [blame] | 144 | /** Data set containing small 4D tensor shapes. */ |
| 145 | class Small4DShapes final : public ShapeDataset |
| 146 | { |
| 147 | public: |
| 148 | Small4DShapes() |
| 149 | : ShapeDataset("Shape", |
| 150 | { |
Georgios Pinitas | 02ee429 | 2018-02-15 17:22:36 +0000 | [diff] [blame] | 151 | TensorShape{ 1U, 7U, 1U, 3U }, |
| 152 | TensorShape{ 7U, 7U, 5U, 3U }, |
Gian Marco Iodice | 06b184a | 2017-08-29 16:05:25 +0100 | [diff] [blame] | 153 | TensorShape{ 27U, 13U, 37U, 2U }, |
| 154 | TensorShape{ 128U, 64U, 21U, 3U } |
| 155 | }) |
| 156 | { |
| 157 | } |
| 158 | }; |
| 159 | |
Moritz Pflanzer | f6ad98a | 2017-07-21 17:19:58 +0100 | [diff] [blame] | 160 | /** Data set containing small tensor shapes. */ |
Anthony Barbier | 1c0d0ff | 2018-01-31 13:05:09 +0000 | [diff] [blame] | 161 | class TinyShapes final : public ShapeDataset |
| 162 | { |
| 163 | public: |
| 164 | TinyShapes() |
| 165 | : ShapeDataset("Shape", |
| 166 | { |
| 167 | // Batch size 1 |
| 168 | TensorShape{ 9U, 9U }, |
| 169 | TensorShape{ 27U, 13U, 2U }, |
| 170 | }) |
| 171 | { |
| 172 | } |
| 173 | }; |
| 174 | /** Data set containing small tensor shapes. */ |
Moritz Pflanzer | f6ad98a | 2017-07-21 17:19:58 +0100 | [diff] [blame] | 175 | class SmallShapes final : public ShapeDataset |
| 176 | { |
| 177 | public: |
| 178 | SmallShapes() |
| 179 | : ShapeDataset("Shape", |
| 180 | { |
SiCong Li | caf8c5e | 2017-08-21 13:12:52 +0100 | [diff] [blame] | 181 | // Batch size 1 |
Gian Marco Iodice | 215b4ea | 2018-06-28 16:29:29 +0100 | [diff] [blame] | 182 | TensorShape{ 11U, 11U }, |
Georgios Pinitas | 64f1a90 | 2018-09-18 13:42:51 +0100 | [diff] [blame] | 183 | TensorShape{ 27U, 13U, 7U }, |
| 184 | TensorShape{ 31U, 27U, 17U, 2U }, |
SiCong Li | caf8c5e | 2017-08-21 13:12:52 +0100 | [diff] [blame] | 185 | // Batch size 4 |
Gian Marco Iodice | 215b4ea | 2018-06-28 16:29:29 +0100 | [diff] [blame] | 186 | TensorShape{ 11U, 11U, 3U, 4U }, |
SiCong Li | caf8c5e | 2017-08-21 13:12:52 +0100 | [diff] [blame] | 187 | TensorShape{ 27U, 13U, 2U, 4U }, |
SiCong Li | caf8c5e | 2017-08-21 13:12:52 +0100 | [diff] [blame] | 188 | // Arbitrary batch size |
Gian Marco Iodice | 215b4ea | 2018-06-28 16:29:29 +0100 | [diff] [blame] | 189 | TensorShape{ 11U, 11U, 3U, 5U } |
Moritz Pflanzer | f6ad98a | 2017-07-21 17:19:58 +0100 | [diff] [blame] | 190 | }) |
| 191 | { |
| 192 | } |
| 193 | }; |
| 194 | |
Diego Lopez Recas | 0021d75 | 2017-12-18 14:42:56 +0000 | [diff] [blame] | 195 | /** Data set containing pairs of small tensor shapes that are broadcast compatible. */ |
| 196 | class SmallShapesBroadcast final : public framework::dataset::ZipDataset<ShapeDataset, ShapeDataset> |
| 197 | { |
| 198 | public: |
| 199 | SmallShapesBroadcast() |
| 200 | : ZipDataset<ShapeDataset, ShapeDataset>( |
| 201 | ShapeDataset("Shape0", |
| 202 | { |
| 203 | TensorShape{ 9U, 9U }, |
| 204 | TensorShape{ 27U, 13U, 2U }, |
| 205 | TensorShape{ 128U, 1U, 5U, 3U }, |
| 206 | TensorShape{ 9U, 9U, 3U, 4U }, |
| 207 | TensorShape{ 27U, 13U, 2U, 4U }, |
| 208 | TensorShape{ 1U, 1U, 1U, 5U } |
| 209 | }), |
| 210 | ShapeDataset("Shape1", |
| 211 | { |
| 212 | TensorShape{ 9U, 1U, 2U }, |
| 213 | TensorShape{ 1U, 13U, 2U }, |
| 214 | TensorShape{ 128U, 64U, 1U, 3U }, |
| 215 | TensorShape{ 9U, 1U, 3U }, |
| 216 | TensorShape{ 1U }, |
| 217 | TensorShape{ 9U, 9U, 3U, 5U } |
| 218 | })) |
| 219 | { |
| 220 | } |
| 221 | }; |
| 222 | |
steniu01 | f81652d | 2017-09-11 15:29:12 +0100 | [diff] [blame] | 223 | /** Data set containing medium tensor shapes. */ |
| 224 | class MediumShapes final : public ShapeDataset |
| 225 | { |
| 226 | public: |
| 227 | MediumShapes() |
| 228 | : ShapeDataset("Shape", |
| 229 | { |
| 230 | // Batch size 1 |
| 231 | TensorShape{ 37U, 37U }, |
| 232 | TensorShape{ 27U, 33U, 2U }, |
| 233 | TensorShape{ 128U, 64U, 1U, 3U }, |
| 234 | // Batch size 4 |
| 235 | TensorShape{ 37U, 37U, 3U, 4U }, |
| 236 | TensorShape{ 27U, 33U, 2U, 4U }, |
| 237 | // Arbitrary batch size |
| 238 | TensorShape{ 37U, 37U, 3U, 5U } |
| 239 | }) |
| 240 | { |
| 241 | } |
| 242 | }; |
| 243 | |
Gian Marco | 37908d9 | 2017-11-07 14:38:22 +0000 | [diff] [blame] | 244 | /** Data set containing medium 2D tensor shapes. */ |
| 245 | class Medium2DShapes final : public ShapeDataset |
| 246 | { |
| 247 | public: |
| 248 | Medium2DShapes() |
| 249 | : ShapeDataset("Shape", |
| 250 | { |
| 251 | TensorShape{ 42U, 37U }, |
| 252 | TensorShape{ 57U, 60U }, |
| 253 | TensorShape{ 128U, 64U }, |
Gian Marco Iodice | 2abb216 | 2018-04-11 10:49:04 +0100 | [diff] [blame] | 254 | TensorShape{ 83U, 72U }, |
| 255 | TensorShape{ 40U, 40U } |
Gian Marco | 37908d9 | 2017-11-07 14:38:22 +0000 | [diff] [blame] | 256 | }) |
| 257 | { |
| 258 | } |
| 259 | }; |
| 260 | |
Gian Marco Iodice | 7e4b239 | 2018-02-22 16:17:20 +0000 | [diff] [blame] | 261 | /** Data set containing medium 3D tensor shapes. */ |
| 262 | class Medium3DShapes final : public ShapeDataset |
| 263 | { |
| 264 | public: |
| 265 | Medium3DShapes() |
| 266 | : ShapeDataset("Shape", |
| 267 | { |
| 268 | TensorShape{ 42U, 37U, 8U }, |
| 269 | TensorShape{ 57U, 60U, 13U }, |
| 270 | TensorShape{ 128U, 64U, 21U }, |
| 271 | TensorShape{ 83U, 72U, 14U } |
| 272 | }) |
| 273 | { |
| 274 | } |
| 275 | }; |
| 276 | |
| 277 | /** Data set containing medium 4D tensor shapes. */ |
| 278 | class Medium4DShapes final : public ShapeDataset |
| 279 | { |
| 280 | public: |
| 281 | Medium4DShapes() |
| 282 | : ShapeDataset("Shape", |
| 283 | { |
| 284 | TensorShape{ 42U, 37U, 8U, 15U }, |
| 285 | TensorShape{ 57U, 60U, 13U, 8U }, |
| 286 | TensorShape{ 128U, 64U, 21U, 13U }, |
| 287 | TensorShape{ 83U, 72U, 14U, 5U } |
| 288 | }) |
| 289 | { |
| 290 | } |
| 291 | }; |
| 292 | |
Moritz Pflanzer | f6ad98a | 2017-07-21 17:19:58 +0100 | [diff] [blame] | 293 | /** Data set containing large tensor shapes. */ |
| 294 | class LargeShapes final : public ShapeDataset |
| 295 | { |
| 296 | public: |
| 297 | LargeShapes() |
| 298 | : ShapeDataset("Shape", |
| 299 | { |
SiCong Li | caf8c5e | 2017-08-21 13:12:52 +0100 | [diff] [blame] | 300 | // Batch size 1 |
Gian Marco | 7f0f790 | 2017-12-07 09:26:56 +0000 | [diff] [blame] | 301 | TensorShape{ 1921U, 1083U }, |
| 302 | TensorShape{ 641U, 485U, 2U, 3U }, |
SiCong Li | caf8c5e | 2017-08-21 13:12:52 +0100 | [diff] [blame] | 303 | // Batch size 4 |
Gian Marco | 7f0f790 | 2017-12-07 09:26:56 +0000 | [diff] [blame] | 304 | TensorShape{ 799U, 595U, 1U, 4U }, |
Moritz Pflanzer | f6ad98a | 2017-07-21 17:19:58 +0100 | [diff] [blame] | 305 | }) |
| 306 | { |
| 307 | } |
| 308 | }; |
| 309 | |
Diego Lopez Recas | 0021d75 | 2017-12-18 14:42:56 +0000 | [diff] [blame] | 310 | /** Data set containing pairs of large tensor shapes that are broadcast compatible. */ |
| 311 | class LargeShapesBroadcast final : public framework::dataset::ZipDataset<ShapeDataset, ShapeDataset> |
| 312 | { |
| 313 | public: |
| 314 | LargeShapesBroadcast() |
| 315 | : ZipDataset<ShapeDataset, ShapeDataset>( |
| 316 | ShapeDataset("Shape0", |
| 317 | { |
| 318 | TensorShape{ 1921U, 541U }, |
| 319 | TensorShape{ 1U, 485U, 2U, 3U }, |
| 320 | TensorShape{ 4159U, 1U }, |
| 321 | TensorShape{ 799U } |
| 322 | }), |
| 323 | ShapeDataset("Shape1", |
| 324 | { |
| 325 | TensorShape{ 1921U, 1U, 2U }, |
| 326 | TensorShape{ 641U, 1U, 2U, 3U }, |
| 327 | TensorShape{ 1U, 127U, 25U }, |
| 328 | TensorShape{ 799U, 595U, 1U, 4U } |
| 329 | })) |
| 330 | { |
| 331 | } |
| 332 | }; |
| 333 | |
Gian Marco | 5420b28 | 2017-11-29 10:41:38 +0000 | [diff] [blame] | 334 | /** Data set containing large 1D tensor shapes. */ |
| 335 | class Large1DShapes final : public ShapeDataset |
| 336 | { |
| 337 | public: |
| 338 | Large1DShapes() |
| 339 | : ShapeDataset("Shape", |
| 340 | { |
| 341 | TensorShape{ 1921U }, |
| 342 | TensorShape{ 1245U }, |
| 343 | TensorShape{ 4160U } |
| 344 | }) |
| 345 | { |
| 346 | } |
| 347 | }; |
| 348 | |
Moritz Pflanzer | b3d2579 | 2017-07-26 11:49:37 +0100 | [diff] [blame] | 349 | /** Data set containing large 2D tensor shapes. */ |
Moritz Pflanzer | f6ad98a | 2017-07-21 17:19:58 +0100 | [diff] [blame] | 350 | class Large2DShapes final : public ShapeDataset |
| 351 | { |
| 352 | public: |
| 353 | Large2DShapes() |
| 354 | : ShapeDataset("Shape", |
| 355 | { |
| 356 | TensorShape{ 1920U, 1080U }, |
Moritz Pflanzer | 3ce3ff4 | 2017-07-21 17:41:02 +0100 | [diff] [blame] | 357 | TensorShape{ 1245U, 652U }, |
Moritz Pflanzer | f6ad98a | 2017-07-21 17:19:58 +0100 | [diff] [blame] | 358 | TensorShape{ 4160U, 3120U } |
| 359 | }) |
| 360 | { |
| 361 | } |
| 362 | }; |
Moritz Pflanzer | b3d2579 | 2017-07-26 11:49:37 +0100 | [diff] [blame] | 363 | |
Gian Marco Iodice | 06b184a | 2017-08-29 16:05:25 +0100 | [diff] [blame] | 364 | /** Data set containing large 3D tensor shapes. */ |
| 365 | class Large3DShapes final : public ShapeDataset |
| 366 | { |
| 367 | public: |
| 368 | Large3DShapes() |
| 369 | : ShapeDataset("Shape", |
| 370 | { |
| 371 | TensorShape{ 320U, 240U, 3U }, |
| 372 | TensorShape{ 383U, 653U, 2U }, |
| 373 | TensorShape{ 721U, 123U, 13U } |
| 374 | }) |
| 375 | { |
| 376 | } |
| 377 | }; |
| 378 | |
| 379 | /** Data set containing large 4D tensor shapes. */ |
| 380 | class Large4DShapes final : public ShapeDataset |
| 381 | { |
| 382 | public: |
| 383 | Large4DShapes() |
| 384 | : ShapeDataset("Shape", |
| 385 | { |
| 386 | TensorShape{ 320U, 123U, 3U, 3U }, |
| 387 | TensorShape{ 383U, 413U, 2U, 3U }, |
| 388 | TensorShape{ 517U, 123U, 13U, 2U } |
| 389 | }) |
| 390 | { |
| 391 | } |
| 392 | }; |
| 393 | |
Gian Marco Iodice | 247f52c | 2018-03-22 11:24:56 +0000 | [diff] [blame] | 394 | /** Data set containing small 3x3 tensor shapes. */ |
| 395 | class Small3x3Shapes final : public ShapeDataset |
| 396 | { |
| 397 | public: |
| 398 | Small3x3Shapes() |
| 399 | : ShapeDataset("Shape", |
| 400 | { |
| 401 | TensorShape{ 3U, 3U, 7U, 4U }, |
| 402 | TensorShape{ 3U, 3U, 4U, 13U }, |
| 403 | TensorShape{ 3U, 3U, 9U, 2U }, |
| 404 | TensorShape{ 3U, 3U, 3U, 5U }, |
| 405 | }) |
| 406 | { |
| 407 | } |
| 408 | }; |
| 409 | |
Gian Marco Iodice | f1c2bf0 | 2018-06-13 14:05:54 +0100 | [diff] [blame] | 410 | /** Data set containing small 3x1 tensor shapes. */ |
| 411 | class Small3x1Shapes final : public ShapeDataset |
| 412 | { |
| 413 | public: |
| 414 | Small3x1Shapes() |
| 415 | : ShapeDataset("Shape", |
| 416 | { |
| 417 | TensorShape{ 3U, 1U, 7U, 4U }, |
| 418 | TensorShape{ 3U, 1U, 4U, 13U }, |
| 419 | TensorShape{ 3U, 1U, 9U, 2U }, |
| 420 | TensorShape{ 3U, 1U, 3U, 5U }, |
| 421 | }) |
| 422 | { |
| 423 | } |
| 424 | }; |
| 425 | |
| 426 | /** Data set containing small 1x3 tensor shapes. */ |
| 427 | class Small1x3Shapes final : public ShapeDataset |
| 428 | { |
| 429 | public: |
| 430 | Small1x3Shapes() |
| 431 | : ShapeDataset("Shape", |
| 432 | { |
| 433 | TensorShape{ 1U, 3U, 7U, 4U }, |
| 434 | TensorShape{ 1U, 3U, 4U, 13U }, |
| 435 | TensorShape{ 1U, 3U, 9U, 2U }, |
| 436 | TensorShape{ 1U, 3U, 3U, 5U }, |
| 437 | }) |
| 438 | { |
| 439 | } |
| 440 | }; |
| 441 | |
Gian Marco Iodice | 247f52c | 2018-03-22 11:24:56 +0000 | [diff] [blame] | 442 | /** Data set containing large 3x3 tensor shapes. */ |
| 443 | class Large3x3Shapes final : public ShapeDataset |
| 444 | { |
| 445 | public: |
| 446 | Large3x3Shapes() |
| 447 | : ShapeDataset("Shape", |
| 448 | { |
| 449 | TensorShape{ 3U, 3U, 32U, 64U }, |
| 450 | TensorShape{ 3U, 3U, 51U, 13U }, |
| 451 | TensorShape{ 3U, 3U, 53U, 47U }, |
| 452 | TensorShape{ 3U, 3U, 128U, 384U }, |
| 453 | }) |
| 454 | { |
| 455 | } |
| 456 | }; |
| 457 | |
Gian Marco Iodice | f1c2bf0 | 2018-06-13 14:05:54 +0100 | [diff] [blame] | 458 | /** Data set containing large 3x1 tensor shapes. */ |
| 459 | class Large3x1Shapes final : public ShapeDataset |
| 460 | { |
| 461 | public: |
| 462 | Large3x1Shapes() |
| 463 | : ShapeDataset("Shape", |
| 464 | { |
| 465 | TensorShape{ 3U, 1U, 32U, 64U }, |
| 466 | TensorShape{ 3U, 1U, 51U, 13U }, |
| 467 | TensorShape{ 3U, 1U, 53U, 47U }, |
| 468 | TensorShape{ 3U, 1U, 128U, 384U }, |
| 469 | }) |
| 470 | { |
| 471 | } |
| 472 | }; |
| 473 | |
| 474 | /** Data set containing large 1x3 tensor shapes. */ |
| 475 | class Large1x3Shapes final : public ShapeDataset |
| 476 | { |
| 477 | public: |
| 478 | Large1x3Shapes() |
| 479 | : ShapeDataset("Shape", |
| 480 | { |
| 481 | TensorShape{ 1U, 3U, 32U, 64U }, |
| 482 | TensorShape{ 1U, 3U, 51U, 13U }, |
| 483 | TensorShape{ 1U, 3U, 53U, 47U }, |
| 484 | TensorShape{ 1U, 3U, 128U, 384U }, |
| 485 | }) |
| 486 | { |
| 487 | } |
| 488 | }; |
| 489 | |
Giorgio Arena | 9373c8b | 2018-04-11 19:07:17 +0100 | [diff] [blame] | 490 | /** Data set containing small 5x5 tensor shapes. */ |
| 491 | class Small5x5Shapes final : public ShapeDataset |
| 492 | { |
| 493 | public: |
| 494 | Small5x5Shapes() |
| 495 | : ShapeDataset("Shape", |
| 496 | { |
| 497 | TensorShape{ 5U, 5U, 7U, 4U }, |
| 498 | TensorShape{ 5U, 5U, 4U, 13U }, |
| 499 | TensorShape{ 5U, 5U, 9U, 2U }, |
| 500 | TensorShape{ 5U, 5U, 3U, 5U }, |
| 501 | }) |
| 502 | { |
| 503 | } |
| 504 | }; |
| 505 | |
| 506 | /** Data set containing large 5x5 tensor shapes. */ |
| 507 | class Large5x5Shapes final : public ShapeDataset |
| 508 | { |
| 509 | public: |
| 510 | Large5x5Shapes() |
| 511 | : ShapeDataset("Shape", |
| 512 | { |
| 513 | TensorShape{ 5U, 5U, 32U, 64U }, |
| 514 | TensorShape{ 5U, 5U, 51U, 13U }, |
| 515 | TensorShape{ 5U, 5U, 53U, 47U }, |
| 516 | TensorShape{ 5U, 5U, 128U, 384U }, |
| 517 | }) |
| 518 | { |
| 519 | } |
| 520 | }; |
| 521 | |
Gian Marco Iodice | 876be2a | 2018-07-03 12:22:09 +0100 | [diff] [blame] | 522 | /** Data set containing small 5x1 tensor shapes. */ |
| 523 | class Small5x1Shapes final : public ShapeDataset |
| 524 | { |
| 525 | public: |
| 526 | Small5x1Shapes() |
| 527 | : ShapeDataset("Shape", |
| 528 | { |
| 529 | TensorShape{ 5U, 1U, 7U, 4U }, |
| 530 | TensorShape{ 5U, 1U, 4U, 13U }, |
| 531 | TensorShape{ 5U, 1U, 9U, 2U }, |
| 532 | TensorShape{ 5U, 1U, 3U, 5U }, |
| 533 | }) |
| 534 | { |
| 535 | } |
| 536 | }; |
| 537 | |
| 538 | /** Data set containing large 5x1 tensor shapes. */ |
| 539 | class Large5x1Shapes final : public ShapeDataset |
| 540 | { |
| 541 | public: |
| 542 | Large5x1Shapes() |
| 543 | : ShapeDataset("Shape", |
| 544 | { |
| 545 | TensorShape{ 5U, 1U, 32U, 64U }, |
| 546 | TensorShape{ 5U, 1U, 51U, 13U }, |
| 547 | TensorShape{ 5U, 1U, 53U, 47U }, |
| 548 | TensorShape{ 5U, 1U, 128U, 384U }, |
| 549 | }) |
| 550 | { |
| 551 | } |
| 552 | }; |
| 553 | |
| 554 | /** Data set containing small 1x5 tensor shapes. */ |
| 555 | class Small1x5Shapes final : public ShapeDataset |
| 556 | { |
| 557 | public: |
| 558 | Small1x5Shapes() |
| 559 | : ShapeDataset("Shape", |
| 560 | { |
| 561 | TensorShape{ 1U, 5U, 7U, 4U }, |
| 562 | TensorShape{ 1U, 5U, 4U, 13U }, |
| 563 | TensorShape{ 1U, 5U, 9U, 2U }, |
| 564 | TensorShape{ 1U, 5U, 3U, 5U }, |
| 565 | }) |
| 566 | { |
| 567 | } |
| 568 | }; |
| 569 | |
| 570 | /** Data set containing large 1x5 tensor shapes. */ |
| 571 | class Large1x5Shapes final : public ShapeDataset |
| 572 | { |
| 573 | public: |
| 574 | Large1x5Shapes() |
| 575 | : ShapeDataset("Shape", |
| 576 | { |
| 577 | TensorShape{ 1U, 5U, 32U, 64U }, |
| 578 | TensorShape{ 1U, 5U, 51U, 13U }, |
| 579 | TensorShape{ 1U, 5U, 53U, 47U }, |
| 580 | TensorShape{ 1U, 5U, 128U, 384U }, |
| 581 | }) |
| 582 | { |
| 583 | } |
| 584 | }; |
| 585 | |
Pablo Tello | f5f34bb | 2017-08-22 13:34:13 +0100 | [diff] [blame] | 586 | /** Data set containing small tensor shapes for deconvolution. */ |
| 587 | class SmallDeconvolutionShapes final : public ShapeDataset |
| 588 | { |
| 589 | public: |
| 590 | SmallDeconvolutionShapes() |
| 591 | : ShapeDataset("InputShape", |
| 592 | { |
Georgios Pinitas | ced7a8d | 2018-02-01 16:31:33 +0000 | [diff] [blame] | 593 | TensorShape{ 5U, 4U, 3U, 2U }, |
Pablo Tello | f5f34bb | 2017-08-22 13:34:13 +0100 | [diff] [blame] | 594 | TensorShape{ 5U, 5U, 3U }, |
| 595 | TensorShape{ 11U, 13U, 4U, 3U } |
| 596 | }) |
| 597 | { |
| 598 | } |
| 599 | }; |
| 600 | |
Anthony Barbier | 1c0d0ff | 2018-01-31 13:05:09 +0000 | [diff] [blame] | 601 | /** Data set containing tiny tensor shapes for direct convolution. */ |
| 602 | class TinyDirectConvolutionShapes final : public ShapeDataset |
| 603 | { |
| 604 | public: |
| 605 | TinyDirectConvolutionShapes() |
| 606 | : ShapeDataset("InputShape", |
| 607 | { |
| 608 | // Batch size 1 |
| 609 | TensorShape{ 11U, 13U, 3U }, |
| 610 | TensorShape{ 7U, 27U, 3U } |
| 611 | }) |
| 612 | { |
| 613 | } |
| 614 | }; |
Moritz Pflanzer | b3d2579 | 2017-07-26 11:49:37 +0100 | [diff] [blame] | 615 | /** Data set containing small tensor shapes for direct convolution. */ |
| 616 | class SmallDirectConvolutionShapes final : public ShapeDataset |
| 617 | { |
| 618 | public: |
| 619 | SmallDirectConvolutionShapes() |
| 620 | : ShapeDataset("InputShape", |
| 621 | { |
SiCong Li | caf8c5e | 2017-08-21 13:12:52 +0100 | [diff] [blame] | 622 | // Batch size 1 |
steniu01 | f81652d | 2017-09-11 15:29:12 +0100 | [diff] [blame] | 623 | TensorShape{ 35U, 35U, 3U }, |
Moritz Pflanzer | b3d2579 | 2017-07-26 11:49:37 +0100 | [diff] [blame] | 624 | TensorShape{ 32U, 37U, 3U }, |
SiCong Li | caf8c5e | 2017-08-21 13:12:52 +0100 | [diff] [blame] | 625 | // Batch size 4 |
SiCong Li | caf8c5e | 2017-08-21 13:12:52 +0100 | [diff] [blame] | 626 | TensorShape{ 32U, 37U, 3U, 4U }, |
SiCong Li | caf8c5e | 2017-08-21 13:12:52 +0100 | [diff] [blame] | 627 | // Batch size 8 |
SiCong Li | caf8c5e | 2017-08-21 13:12:52 +0100 | [diff] [blame] | 628 | TensorShape{ 32U, 37U, 3U, 8U }, |
Michalis Spyrou | d466c2d | 2018-01-30 10:54:39 +0000 | [diff] [blame] | 629 | TensorShape{ 33U, 35U, 8U, 8U } |
Moritz Pflanzer | b3d2579 | 2017-07-26 11:49:37 +0100 | [diff] [blame] | 630 | }) |
| 631 | { |
| 632 | } |
| 633 | }; |
Gian Marco Iodice | b2833b8 | 2017-09-13 16:23:18 +0100 | [diff] [blame] | 634 | |
Xinghang Zhou | 33ff9ef | 2018-01-17 11:23:39 +0800 | [diff] [blame] | 635 | /** Data set containing small tensor shapes for direct convolution. */ |
| 636 | class SmallDirectConvolutionTensorShiftShapes final : public ShapeDataset |
| 637 | { |
| 638 | public: |
| 639 | SmallDirectConvolutionTensorShiftShapes() |
| 640 | : ShapeDataset("InputShape", |
| 641 | { |
| 642 | // Batch size 1 |
| 643 | TensorShape{ 35U, 35U, 3U }, |
| 644 | TensorShape{ 32U, 37U, 3U }, |
| 645 | // Batch size 4 |
| 646 | TensorShape{ 32U, 37U, 3U, 4U }, |
| 647 | // Batch size 8 |
| 648 | TensorShape{ 32U, 37U, 3U, 8U }, |
| 649 | TensorShape{ 33U, 35U, 3U, 8U }, |
| 650 | // Arbitrary batch size |
| 651 | TensorShape{ 32U, 37U, 3U, 8U } |
| 652 | }) |
| 653 | { |
| 654 | } |
| 655 | }; |
| 656 | |
Giorgio Arena | 0f17039 | 2018-07-18 16:13:12 +0100 | [diff] [blame] | 657 | /** Data set containing small grouped im2col tensor shapes. */ |
| 658 | class GroupedIm2ColSmallShapes final : public ShapeDataset |
| 659 | { |
| 660 | public: |
| 661 | GroupedIm2ColSmallShapes() |
| 662 | : ShapeDataset("Shape", |
| 663 | { |
| 664 | TensorShape{ 11U, 11U, 48U }, |
| 665 | TensorShape{ 27U, 13U, 24U }, |
| 666 | TensorShape{ 128U, 64U, 12U, 3U }, |
| 667 | TensorShape{ 11U, 11U, 48U, 4U }, |
| 668 | TensorShape{ 27U, 13U, 24U, 4U }, |
| 669 | TensorShape{ 11U, 11U, 48U, 5U } |
| 670 | }) |
| 671 | { |
| 672 | } |
| 673 | }; |
| 674 | |
| 675 | /** Data set containing large grouped im2col tensor shapes. */ |
| 676 | class GroupedIm2ColLargeShapes final : public ShapeDataset |
| 677 | { |
| 678 | public: |
| 679 | GroupedIm2ColLargeShapes() |
| 680 | : ShapeDataset("Shape", |
| 681 | { |
Georgios Pinitas | 2a51818 | 2018-08-13 15:53:31 +0100 | [diff] [blame] | 682 | TensorShape{ 153U, 231U, 12U }, |
| 683 | TensorShape{ 123U, 191U, 12U, 2U }, |
Giorgio Arena | 0f17039 | 2018-07-18 16:13:12 +0100 | [diff] [blame] | 684 | }) |
| 685 | { |
| 686 | } |
| 687 | }; |
| 688 | |
Giorgio Arena | c6aa49b | 2018-08-07 11:53:30 +0100 | [diff] [blame] | 689 | /** Data set containing small grouped weights tensor shapes. */ |
| 690 | class GroupedWeightsSmallShapes final : public ShapeDataset |
| 691 | { |
| 692 | public: |
| 693 | GroupedWeightsSmallShapes() |
| 694 | : ShapeDataset("Shape", |
| 695 | { |
| 696 | TensorShape{ 3U, 3U, 48U, 120U }, |
| 697 | TensorShape{ 1U, 3U, 24U, 240U }, |
| 698 | TensorShape{ 3U, 1U, 12U, 480U }, |
| 699 | TensorShape{ 5U, 5U, 48U, 120U }, |
| 700 | TensorShape{ 1U, 5U, 24U, 240U }, |
| 701 | TensorShape{ 5U, 1U, 48U, 480U } |
| 702 | }) |
| 703 | { |
| 704 | } |
| 705 | }; |
| 706 | |
| 707 | /** Data set containing large grouped weights tensor shapes. */ |
| 708 | class GroupedWeightsLargeShapes final : public ShapeDataset |
| 709 | { |
| 710 | public: |
| 711 | GroupedWeightsLargeShapes() |
| 712 | : ShapeDataset("Shape", |
| 713 | { |
| 714 | TensorShape{ 9U, 9U, 96U, 240U }, |
| 715 | TensorShape{ 7U, 9U, 48U, 480U }, |
| 716 | TensorShape{ 9U, 7U, 24U, 960U }, |
| 717 | TensorShape{ 13U, 13U, 96U, 240U }, |
| 718 | TensorShape{ 11U, 13U, 48U, 480U }, |
| 719 | TensorShape{ 13U, 11U, 24U, 960U } |
| 720 | }) |
| 721 | { |
| 722 | } |
| 723 | }; |
| 724 | |
Giorgio Arena | 04a8f8c | 2017-11-23 11:45:24 +0000 | [diff] [blame] | 725 | /** Data set containing 2D tensor shapes for DepthConcatenateLayer. */ |
| 726 | class DepthConcatenateLayerShapes final : public ShapeDataset |
Gian Marco Iodice | b2833b8 | 2017-09-13 16:23:18 +0100 | [diff] [blame] | 727 | { |
| 728 | public: |
Giorgio Arena | 04a8f8c | 2017-11-23 11:45:24 +0000 | [diff] [blame] | 729 | DepthConcatenateLayerShapes() |
Gian Marco Iodice | b2833b8 | 2017-09-13 16:23:18 +0100 | [diff] [blame] | 730 | : ShapeDataset("Shape", |
| 731 | { |
| 732 | TensorShape{ 322U, 243U }, |
| 733 | TensorShape{ 463U, 879U }, |
| 734 | TensorShape{ 416U, 651U } |
| 735 | }) |
| 736 | { |
| 737 | } |
| 738 | }; |
| 739 | |
Michalis Spyrou | 55b3d12 | 2018-05-09 09:59:23 +0100 | [diff] [blame] | 740 | /** Data set containing tensor shapes for WidthConcatenateLayer. */ |
| 741 | class WidthConcatenateLayerShapes final : public ShapeDataset |
| 742 | { |
| 743 | public: |
| 744 | WidthConcatenateLayerShapes() |
| 745 | : ShapeDataset("Shape", |
| 746 | { |
| 747 | TensorShape{ 232U, 65U, 3U }, |
| 748 | TensorShape{ 432U, 65U, 3U }, |
Michele Di Giorgio | e6dbde0 | 2018-10-19 15:46:19 +0100 | [diff] [blame] | 749 | TensorShape{ 124U, 65U, 3U }, |
| 750 | TensorShape{ 124U, 65U, 3U, 4U } |
Michalis Spyrou | 55b3d12 | 2018-05-09 09:59:23 +0100 | [diff] [blame] | 751 | }) |
| 752 | { |
| 753 | } |
| 754 | }; |
| 755 | |
Gian Marco Iodice | bf17955 | 2017-09-05 13:51:21 +0100 | [diff] [blame] | 756 | /** Data set containing global pooling tensor shapes. */ |
| 757 | class GlobalPoolingShapes final : public ShapeDataset |
| 758 | { |
| 759 | public: |
| 760 | GlobalPoolingShapes() |
| 761 | : ShapeDataset("Shape", |
| 762 | { |
| 763 | // Batch size 1 |
| 764 | TensorShape{ 9U, 9U }, |
| 765 | TensorShape{ 13U, 13U, 2U }, |
| 766 | TensorShape{ 27U, 27U, 1U, 3U }, |
| 767 | // Batch size 4 |
| 768 | TensorShape{ 31U, 31U, 3U, 4U }, |
| 769 | TensorShape{ 34U, 34U, 2U, 4U } |
| 770 | }) |
| 771 | { |
| 772 | } |
| 773 | }; |
Anthony Barbier | 1c0d0ff | 2018-01-31 13:05:09 +0000 | [diff] [blame] | 774 | /** Data set containing tiny softmax layer shapes. */ |
| 775 | class SoftmaxLayerTinyShapes final : public ShapeDataset |
| 776 | { |
| 777 | public: |
| 778 | SoftmaxLayerTinyShapes() |
| 779 | : ShapeDataset("Shape", |
| 780 | { |
| 781 | TensorShape{ 9U, 9U }, |
Georgios Pinitas | 17d6d3c | 2018-07-02 17:52:40 +0100 | [diff] [blame] | 782 | TensorShape{ 128U, 10U }, |
Anthony Barbier | 1c0d0ff | 2018-01-31 13:05:09 +0000 | [diff] [blame] | 783 | }) |
| 784 | { |
| 785 | } |
| 786 | }; |
Gian Marco Iodice | bf17955 | 2017-09-05 13:51:21 +0100 | [diff] [blame] | 787 | |
Chunosov | d6afedc | 2017-11-06 22:09:45 +0700 | [diff] [blame] | 788 | /** Data set containing small softmax layer shapes. */ |
| 789 | class SoftmaxLayerSmallShapes final : public ShapeDataset |
| 790 | { |
| 791 | public: |
| 792 | SoftmaxLayerSmallShapes() |
| 793 | : ShapeDataset("Shape", |
| 794 | { |
| 795 | TensorShape{ 9U, 9U }, |
Georgios Pinitas | 17d6d3c | 2018-07-02 17:52:40 +0100 | [diff] [blame] | 796 | TensorShape{ 256U, 10U }, |
| 797 | TensorShape{ 353U, 8U }, |
| 798 | TensorShape{ 781U, 5U }, |
Chunosov | d6afedc | 2017-11-06 22:09:45 +0700 | [diff] [blame] | 799 | }) |
| 800 | { |
| 801 | } |
| 802 | }; |
| 803 | |
| 804 | /** Data set containing large softmax layer shapes. */ |
| 805 | class SoftmaxLayerLargeShapes final : public ShapeDataset |
| 806 | { |
| 807 | public: |
| 808 | SoftmaxLayerLargeShapes() |
| 809 | : ShapeDataset("Shape", |
| 810 | { |
| 811 | TensorShape{ 1000U, 10U }, |
Georgios Pinitas | 17d6d3c | 2018-07-02 17:52:40 +0100 | [diff] [blame] | 812 | TensorShape{ 3989U, 10U }, |
Chunosov | d6afedc | 2017-11-06 22:09:45 +0700 | [diff] [blame] | 813 | TensorShape{ 7339U, 11U }, |
Giuseppe Rossini | 87e896a | 2018-08-24 10:24:12 +0100 | [diff] [blame] | 814 | |
| 815 | }) |
| 816 | { |
| 817 | } |
| 818 | }; |
| 819 | |
| 820 | /** Data set containing large and small softmax layer 4D shapes. */ |
| 821 | class SoftmaxLayer4DShapes final : public ShapeDataset |
| 822 | { |
| 823 | public: |
| 824 | SoftmaxLayer4DShapes() |
| 825 | : ShapeDataset("Shape", |
| 826 | { |
| 827 | TensorShape{ 9U, 9U, 9U, 9U }, |
| 828 | TensorShape{ 256U, 10U, 1U, 9U }, |
| 829 | TensorShape{ 353U, 8U, 2U }, |
| 830 | TensorShape{ 781U, 5U, 2U, 2U }, |
| 831 | TensorShape{ 781U, 11U, 1U, 2U }, |
Chunosov | d6afedc | 2017-11-06 22:09:45 +0700 | [diff] [blame] | 832 | }) |
| 833 | { |
| 834 | } |
| 835 | }; |
| 836 | |
Ioan-Cristian Szabo | 2c35018 | 2017-12-20 16:27:37 +0000 | [diff] [blame] | 837 | /** Data set containing 2D tensor shapes relative to an image size. */ |
| 838 | class SmallImageShapes final : public ShapeDataset |
| 839 | { |
| 840 | public: |
| 841 | SmallImageShapes() |
| 842 | : ShapeDataset("Shape", |
| 843 | { |
| 844 | TensorShape{ 640U, 480U }, |
| 845 | TensorShape{ 800U, 600U }, |
| 846 | TensorShape{ 1200U, 800U } |
| 847 | }) |
| 848 | { |
| 849 | } |
| 850 | }; |
| 851 | |
| 852 | /** Data set containing 2D tensor shapes relative to an image size. */ |
| 853 | class LargeImageShapes final : public ShapeDataset |
| 854 | { |
| 855 | public: |
| 856 | LargeImageShapes() |
| 857 | : ShapeDataset("Shape", |
| 858 | { |
| 859 | TensorShape{ 1920U, 1080U }, |
| 860 | TensorShape{ 2560U, 1536U }, |
| 861 | TensorShape{ 3584U, 2048U } |
| 862 | }) |
| 863 | { |
| 864 | } |
| 865 | }; |
Giorgio Arena | 7302302 | 2018-09-04 14:55:55 +0100 | [diff] [blame] | 866 | |
| 867 | /** Data set containing small YOLO tensor shapes. */ |
| 868 | class SmallYOLOShapes final : public ShapeDataset |
| 869 | { |
| 870 | public: |
| 871 | SmallYOLOShapes() |
| 872 | : ShapeDataset("Shape", |
| 873 | { |
| 874 | // Batch size 1 |
| 875 | TensorShape{ 11U, 11U, 270U }, |
| 876 | TensorShape{ 27U, 13U, 90U }, |
Gian Marco Iodice | 8e1f3c0 | 2018-09-13 15:56:47 +0100 | [diff] [blame] | 877 | TensorShape{ 13U, 12U, 45U, 2U }, |
Giorgio Arena | 7302302 | 2018-09-04 14:55:55 +0100 | [diff] [blame] | 878 | }) |
| 879 | { |
| 880 | } |
| 881 | }; |
| 882 | |
| 883 | /** Data set containing large YOLO tensor shapes. */ |
| 884 | class LargeYOLOShapes final : public ShapeDataset |
| 885 | { |
| 886 | public: |
| 887 | LargeYOLOShapes() |
| 888 | : ShapeDataset("Shape", |
| 889 | { |
| 890 | TensorShape{ 24U, 23U, 270U }, |
| 891 | TensorShape{ 51U, 63U, 90U, 2U }, |
| 892 | TensorShape{ 76U, 91U, 45U, 3U } |
| 893 | }) |
| 894 | { |
| 895 | } |
| 896 | }; |
Gian Marco Iodice | 5ba5e09 | 2018-12-06 17:13:09 +0000 | [diff] [blame] | 897 | |
| 898 | /** Data set containing small tensor shapes to be used with the GEMM reshaping kernel */ |
| 899 | class SmallGEMMReshape2DShapes final : public ShapeDataset |
| 900 | { |
| 901 | public: |
| 902 | SmallGEMMReshape2DShapes() |
| 903 | : ShapeDataset("Shape", |
| 904 | { |
| 905 | TensorShape{ 63U, 72U }, |
| 906 | }) |
| 907 | { |
| 908 | } |
| 909 | }; |
| 910 | |
| 911 | /** Data set containing small tensor shapes to be used with the GEMM reshaping kernel when the input has to be reinterpreted as 3D */ |
| 912 | class SmallGEMMReshape3DShapes final : public ShapeDataset |
| 913 | { |
| 914 | public: |
| 915 | SmallGEMMReshape3DShapes() |
| 916 | : ShapeDataset("Shape", |
| 917 | { |
| 918 | TensorShape{ 63U, 9U, 8U }, |
| 919 | }) |
| 920 | { |
| 921 | } |
| 922 | }; |
| 923 | |
| 924 | /** Data set containing large tensor shapes to be used with the GEMM reshaping kernel */ |
| 925 | class LargeGEMMReshape2DShapes final : public ShapeDataset |
| 926 | { |
| 927 | public: |
| 928 | LargeGEMMReshape2DShapes() |
| 929 | : ShapeDataset("Shape", |
| 930 | { |
| 931 | TensorShape{ 16U, 27U }, |
| 932 | TensorShape{ 533U, 171U }, |
| 933 | TensorShape{ 345U, 612U } |
| 934 | }) |
| 935 | { |
| 936 | } |
| 937 | }; |
| 938 | |
| 939 | /** Data set containing large tensor shapes to be used with the GEMM reshaping kernel when the input has to be reinterpreted as 3D */ |
| 940 | class LargeGEMMReshape3DShapes final : public ShapeDataset |
| 941 | { |
| 942 | public: |
| 943 | LargeGEMMReshape3DShapes() |
| 944 | : ShapeDataset("Shape", |
| 945 | { |
| 946 | TensorShape{ 16U, 3U, 9U }, |
| 947 | TensorShape{ 533U, 19U, 9U }, |
| 948 | TensorShape{ 345U, 34U, 18U } |
| 949 | }) |
| 950 | { |
| 951 | } |
| 952 | }; |
Moritz Pflanzer | f6ad98a | 2017-07-21 17:19:58 +0100 | [diff] [blame] | 953 | } // namespace datasets |
| 954 | } // namespace test |
| 955 | } // namespace arm_compute |
| 956 | #endif /* __ARM_COMPUTE_TEST_SHAPE_DATASETS_H__ */ |