1 // clang-format off
2 // Generated file (from: heatmap_max_keypoint.mod.py). Do not edit
CreateModel_nhwc(Model * model)3 void CreateModel_nhwc(Model *model) {
4 OperandType type0(Type::BOOL, {});
5 OperandType type1(Type::TENSOR_FLOAT32, {6, 4, 4, 1});
6 OperandType type2(Type::TENSOR_FLOAT32, {6, 4});
7 OperandType type3(Type::TENSOR_FLOAT32, {6, 1});
8 OperandType type4(Type::TENSOR_FLOAT32, {6, 1, 2});
9 // Phase 1, operands
10 auto heatmap = model->addOperand(&type1);
11 auto boxes = model->addOperand(&type2);
12 auto layout = model->addOperand(&type0);
13 auto score = model->addOperand(&type3);
14 auto keypoint = model->addOperand(&type4);
15 // Phase 2, operations
16 static bool8 layout_init[] = {false};
17 model->setOperandValue(layout, layout_init, sizeof(bool8) * 1);
18 model->addOperation(ANEURALNETWORKS_HEATMAP_MAX_KEYPOINT, {heatmap, boxes, layout}, {score, keypoint});
19 // Phase 3, inputs and outputs
20 model->identifyInputsAndOutputs(
21 {heatmap, boxes},
22 {score, keypoint});
23 assert(model->isValid());
24 }
25
is_ignored_nhwc(int i)26 inline bool is_ignored_nhwc(int i) {
27 static std::set<int> ignore = {};
28 return ignore.find(i) != ignore.end();
29 }
30
CreateModel_nhwc_relaxed(Model * model)31 void CreateModel_nhwc_relaxed(Model *model) {
32 OperandType type0(Type::BOOL, {});
33 OperandType type1(Type::TENSOR_FLOAT32, {6, 4, 4, 1});
34 OperandType type2(Type::TENSOR_FLOAT32, {6, 4});
35 OperandType type3(Type::TENSOR_FLOAT32, {6, 1});
36 OperandType type4(Type::TENSOR_FLOAT32, {6, 1, 2});
37 // Phase 1, operands
38 auto heatmap = model->addOperand(&type1);
39 auto boxes = model->addOperand(&type2);
40 auto layout = model->addOperand(&type0);
41 auto score = model->addOperand(&type3);
42 auto keypoint = model->addOperand(&type4);
43 // Phase 2, operations
44 static bool8 layout_init[] = {false};
45 model->setOperandValue(layout, layout_init, sizeof(bool8) * 1);
46 model->addOperation(ANEURALNETWORKS_HEATMAP_MAX_KEYPOINT, {heatmap, boxes, layout}, {score, keypoint});
47 // Phase 3, inputs and outputs
48 model->identifyInputsAndOutputs(
49 {heatmap, boxes},
50 {score, keypoint});
51 // Phase 4: set relaxed execution
52 model->relaxComputationFloat32toFloat16(true);
53 assert(model->isValid());
54 }
55
is_ignored_nhwc_relaxed(int i)56 inline bool is_ignored_nhwc_relaxed(int i) {
57 static std::set<int> ignore = {};
58 return ignore.find(i) != ignore.end();
59 }
60
CreateModel_nhwc_float16(Model * model)61 void CreateModel_nhwc_float16(Model *model) {
62 OperandType type0(Type::BOOL, {});
63 OperandType type12(Type::TENSOR_FLOAT16, {6, 4});
64 OperandType type13(Type::TENSOR_FLOAT16, {6, 4, 4, 1});
65 OperandType type14(Type::TENSOR_FLOAT16, {6, 1, 2});
66 OperandType type15(Type::TENSOR_FLOAT16, {6, 1});
67 // Phase 1, operands
68 auto heatmap = model->addOperand(&type13);
69 auto boxes = model->addOperand(&type12);
70 auto layout = model->addOperand(&type0);
71 auto score = model->addOperand(&type15);
72 auto keypoint = model->addOperand(&type14);
73 // Phase 2, operations
74 static bool8 layout_init[] = {false};
75 model->setOperandValue(layout, layout_init, sizeof(bool8) * 1);
76 model->addOperation(ANEURALNETWORKS_HEATMAP_MAX_KEYPOINT, {heatmap, boxes, layout}, {score, keypoint});
77 // Phase 3, inputs and outputs
78 model->identifyInputsAndOutputs(
79 {heatmap, boxes},
80 {score, keypoint});
81 assert(model->isValid());
82 }
83
is_ignored_nhwc_float16(int i)84 inline bool is_ignored_nhwc_float16(int i) {
85 static std::set<int> ignore = {};
86 return ignore.find(i) != ignore.end();
87 }
88
CreateModel_nchw(Model * model)89 void CreateModel_nchw(Model *model) {
90 OperandType type0(Type::BOOL, {});
91 OperandType type16(Type::TENSOR_FLOAT32, {6, 1, 4, 4});
92 OperandType type2(Type::TENSOR_FLOAT32, {6, 4});
93 OperandType type3(Type::TENSOR_FLOAT32, {6, 1});
94 OperandType type4(Type::TENSOR_FLOAT32, {6, 1, 2});
95 // Phase 1, operands
96 auto heatmap = model->addOperand(&type16);
97 auto boxes = model->addOperand(&type2);
98 auto layout = model->addOperand(&type0);
99 auto score = model->addOperand(&type3);
100 auto keypoint = model->addOperand(&type4);
101 // Phase 2, operations
102 static bool8 layout_init[] = {true};
103 model->setOperandValue(layout, layout_init, sizeof(bool8) * 1);
104 model->addOperation(ANEURALNETWORKS_HEATMAP_MAX_KEYPOINT, {heatmap, boxes, layout}, {score, keypoint});
105 // Phase 3, inputs and outputs
106 model->identifyInputsAndOutputs(
107 {heatmap, boxes},
108 {score, keypoint});
109 assert(model->isValid());
110 }
111
is_ignored_nchw(int i)112 inline bool is_ignored_nchw(int i) {
113 static std::set<int> ignore = {};
114 return ignore.find(i) != ignore.end();
115 }
116
CreateModel_nchw_relaxed(Model * model)117 void CreateModel_nchw_relaxed(Model *model) {
118 OperandType type0(Type::BOOL, {});
119 OperandType type16(Type::TENSOR_FLOAT32, {6, 1, 4, 4});
120 OperandType type2(Type::TENSOR_FLOAT32, {6, 4});
121 OperandType type3(Type::TENSOR_FLOAT32, {6, 1});
122 OperandType type4(Type::TENSOR_FLOAT32, {6, 1, 2});
123 // Phase 1, operands
124 auto heatmap = model->addOperand(&type16);
125 auto boxes = model->addOperand(&type2);
126 auto layout = model->addOperand(&type0);
127 auto score = model->addOperand(&type3);
128 auto keypoint = model->addOperand(&type4);
129 // Phase 2, operations
130 static bool8 layout_init[] = {true};
131 model->setOperandValue(layout, layout_init, sizeof(bool8) * 1);
132 model->addOperation(ANEURALNETWORKS_HEATMAP_MAX_KEYPOINT, {heatmap, boxes, layout}, {score, keypoint});
133 // Phase 3, inputs and outputs
134 model->identifyInputsAndOutputs(
135 {heatmap, boxes},
136 {score, keypoint});
137 // Phase 4: set relaxed execution
138 model->relaxComputationFloat32toFloat16(true);
139 assert(model->isValid());
140 }
141
is_ignored_nchw_relaxed(int i)142 inline bool is_ignored_nchw_relaxed(int i) {
143 static std::set<int> ignore = {};
144 return ignore.find(i) != ignore.end();
145 }
146
CreateModel_nchw_float16(Model * model)147 void CreateModel_nchw_float16(Model *model) {
148 OperandType type0(Type::BOOL, {});
149 OperandType type12(Type::TENSOR_FLOAT16, {6, 4});
150 OperandType type14(Type::TENSOR_FLOAT16, {6, 1, 2});
151 OperandType type15(Type::TENSOR_FLOAT16, {6, 1});
152 OperandType type17(Type::TENSOR_FLOAT16, {6, 1, 4, 4});
153 // Phase 1, operands
154 auto heatmap = model->addOperand(&type17);
155 auto boxes = model->addOperand(&type12);
156 auto layout = model->addOperand(&type0);
157 auto score = model->addOperand(&type15);
158 auto keypoint = model->addOperand(&type14);
159 // Phase 2, operations
160 static bool8 layout_init[] = {true};
161 model->setOperandValue(layout, layout_init, sizeof(bool8) * 1);
162 model->addOperation(ANEURALNETWORKS_HEATMAP_MAX_KEYPOINT, {heatmap, boxes, layout}, {score, keypoint});
163 // Phase 3, inputs and outputs
164 model->identifyInputsAndOutputs(
165 {heatmap, boxes},
166 {score, keypoint});
167 assert(model->isValid());
168 }
169
is_ignored_nchw_float16(int i)170 inline bool is_ignored_nchw_float16(int i) {
171 static std::set<int> ignore = {};
172 return ignore.find(i) != ignore.end();
173 }
174
CreateModel_dynamic_output_shape_nhwc(Model * model)175 void CreateModel_dynamic_output_shape_nhwc(Model *model) {
176 OperandType type0(Type::BOOL, {});
177 OperandType type1(Type::TENSOR_FLOAT32, {6, 4, 4, 1});
178 OperandType type18(Type::TENSOR_FLOAT32, {0, 0});
179 OperandType type19(Type::TENSOR_FLOAT32, {0, 0, 0});
180 OperandType type2(Type::TENSOR_FLOAT32, {6, 4});
181 // Phase 1, operands
182 auto heatmap = model->addOperand(&type1);
183 auto boxes = model->addOperand(&type2);
184 auto layout = model->addOperand(&type0);
185 auto score = model->addOperand(&type18);
186 auto keypoint = model->addOperand(&type19);
187 // Phase 2, operations
188 static bool8 layout_init[] = {false};
189 model->setOperandValue(layout, layout_init, sizeof(bool8) * 1);
190 model->addOperation(ANEURALNETWORKS_HEATMAP_MAX_KEYPOINT, {heatmap, boxes, layout}, {score, keypoint});
191 // Phase 3, inputs and outputs
192 model->identifyInputsAndOutputs(
193 {heatmap, boxes},
194 {score, keypoint});
195 assert(model->isValid());
196 }
197
is_ignored_dynamic_output_shape_nhwc(int i)198 inline bool is_ignored_dynamic_output_shape_nhwc(int i) {
199 static std::set<int> ignore = {};
200 return ignore.find(i) != ignore.end();
201 }
202
CreateModel_dynamic_output_shape_nhwc_relaxed(Model * model)203 void CreateModel_dynamic_output_shape_nhwc_relaxed(Model *model) {
204 OperandType type0(Type::BOOL, {});
205 OperandType type1(Type::TENSOR_FLOAT32, {6, 4, 4, 1});
206 OperandType type18(Type::TENSOR_FLOAT32, {0, 0});
207 OperandType type19(Type::TENSOR_FLOAT32, {0, 0, 0});
208 OperandType type2(Type::TENSOR_FLOAT32, {6, 4});
209 // Phase 1, operands
210 auto heatmap = model->addOperand(&type1);
211 auto boxes = model->addOperand(&type2);
212 auto layout = model->addOperand(&type0);
213 auto score = model->addOperand(&type18);
214 auto keypoint = model->addOperand(&type19);
215 // Phase 2, operations
216 static bool8 layout_init[] = {false};
217 model->setOperandValue(layout, layout_init, sizeof(bool8) * 1);
218 model->addOperation(ANEURALNETWORKS_HEATMAP_MAX_KEYPOINT, {heatmap, boxes, layout}, {score, keypoint});
219 // Phase 3, inputs and outputs
220 model->identifyInputsAndOutputs(
221 {heatmap, boxes},
222 {score, keypoint});
223 // Phase 4: set relaxed execution
224 model->relaxComputationFloat32toFloat16(true);
225 assert(model->isValid());
226 }
227
is_ignored_dynamic_output_shape_nhwc_relaxed(int i)228 inline bool is_ignored_dynamic_output_shape_nhwc_relaxed(int i) {
229 static std::set<int> ignore = {};
230 return ignore.find(i) != ignore.end();
231 }
232
CreateModel_dynamic_output_shape_nhwc_float16(Model * model)233 void CreateModel_dynamic_output_shape_nhwc_float16(Model *model) {
234 OperandType type0(Type::BOOL, {});
235 OperandType type12(Type::TENSOR_FLOAT16, {6, 4});
236 OperandType type13(Type::TENSOR_FLOAT16, {6, 4, 4, 1});
237 OperandType type20(Type::TENSOR_FLOAT16, {0, 0});
238 OperandType type21(Type::TENSOR_FLOAT16, {0, 0, 0});
239 // Phase 1, operands
240 auto heatmap = model->addOperand(&type13);
241 auto boxes = model->addOperand(&type12);
242 auto layout = model->addOperand(&type0);
243 auto score = model->addOperand(&type20);
244 auto keypoint = model->addOperand(&type21);
245 // Phase 2, operations
246 static bool8 layout_init[] = {false};
247 model->setOperandValue(layout, layout_init, sizeof(bool8) * 1);
248 model->addOperation(ANEURALNETWORKS_HEATMAP_MAX_KEYPOINT, {heatmap, boxes, layout}, {score, keypoint});
249 // Phase 3, inputs and outputs
250 model->identifyInputsAndOutputs(
251 {heatmap, boxes},
252 {score, keypoint});
253 assert(model->isValid());
254 }
255
is_ignored_dynamic_output_shape_nhwc_float16(int i)256 inline bool is_ignored_dynamic_output_shape_nhwc_float16(int i) {
257 static std::set<int> ignore = {};
258 return ignore.find(i) != ignore.end();
259 }
260
CreateModel_dynamic_output_shape_nchw(Model * model)261 void CreateModel_dynamic_output_shape_nchw(Model *model) {
262 OperandType type0(Type::BOOL, {});
263 OperandType type16(Type::TENSOR_FLOAT32, {6, 1, 4, 4});
264 OperandType type18(Type::TENSOR_FLOAT32, {0, 0});
265 OperandType type19(Type::TENSOR_FLOAT32, {0, 0, 0});
266 OperandType type2(Type::TENSOR_FLOAT32, {6, 4});
267 // Phase 1, operands
268 auto heatmap = model->addOperand(&type16);
269 auto boxes = model->addOperand(&type2);
270 auto layout = model->addOperand(&type0);
271 auto score = model->addOperand(&type18);
272 auto keypoint = model->addOperand(&type19);
273 // Phase 2, operations
274 static bool8 layout_init[] = {true};
275 model->setOperandValue(layout, layout_init, sizeof(bool8) * 1);
276 model->addOperation(ANEURALNETWORKS_HEATMAP_MAX_KEYPOINT, {heatmap, boxes, layout}, {score, keypoint});
277 // Phase 3, inputs and outputs
278 model->identifyInputsAndOutputs(
279 {heatmap, boxes},
280 {score, keypoint});
281 assert(model->isValid());
282 }
283
is_ignored_dynamic_output_shape_nchw(int i)284 inline bool is_ignored_dynamic_output_shape_nchw(int i) {
285 static std::set<int> ignore = {};
286 return ignore.find(i) != ignore.end();
287 }
288
CreateModel_dynamic_output_shape_nchw_relaxed(Model * model)289 void CreateModel_dynamic_output_shape_nchw_relaxed(Model *model) {
290 OperandType type0(Type::BOOL, {});
291 OperandType type16(Type::TENSOR_FLOAT32, {6, 1, 4, 4});
292 OperandType type18(Type::TENSOR_FLOAT32, {0, 0});
293 OperandType type19(Type::TENSOR_FLOAT32, {0, 0, 0});
294 OperandType type2(Type::TENSOR_FLOAT32, {6, 4});
295 // Phase 1, operands
296 auto heatmap = model->addOperand(&type16);
297 auto boxes = model->addOperand(&type2);
298 auto layout = model->addOperand(&type0);
299 auto score = model->addOperand(&type18);
300 auto keypoint = model->addOperand(&type19);
301 // Phase 2, operations
302 static bool8 layout_init[] = {true};
303 model->setOperandValue(layout, layout_init, sizeof(bool8) * 1);
304 model->addOperation(ANEURALNETWORKS_HEATMAP_MAX_KEYPOINT, {heatmap, boxes, layout}, {score, keypoint});
305 // Phase 3, inputs and outputs
306 model->identifyInputsAndOutputs(
307 {heatmap, boxes},
308 {score, keypoint});
309 // Phase 4: set relaxed execution
310 model->relaxComputationFloat32toFloat16(true);
311 assert(model->isValid());
312 }
313
is_ignored_dynamic_output_shape_nchw_relaxed(int i)314 inline bool is_ignored_dynamic_output_shape_nchw_relaxed(int i) {
315 static std::set<int> ignore = {};
316 return ignore.find(i) != ignore.end();
317 }
318
CreateModel_dynamic_output_shape_nchw_float16(Model * model)319 void CreateModel_dynamic_output_shape_nchw_float16(Model *model) {
320 OperandType type0(Type::BOOL, {});
321 OperandType type12(Type::TENSOR_FLOAT16, {6, 4});
322 OperandType type17(Type::TENSOR_FLOAT16, {6, 1, 4, 4});
323 OperandType type20(Type::TENSOR_FLOAT16, {0, 0});
324 OperandType type21(Type::TENSOR_FLOAT16, {0, 0, 0});
325 // Phase 1, operands
326 auto heatmap = model->addOperand(&type17);
327 auto boxes = model->addOperand(&type12);
328 auto layout = model->addOperand(&type0);
329 auto score = model->addOperand(&type20);
330 auto keypoint = model->addOperand(&type21);
331 // Phase 2, operations
332 static bool8 layout_init[] = {true};
333 model->setOperandValue(layout, layout_init, sizeof(bool8) * 1);
334 model->addOperation(ANEURALNETWORKS_HEATMAP_MAX_KEYPOINT, {heatmap, boxes, layout}, {score, keypoint});
335 // Phase 3, inputs and outputs
336 model->identifyInputsAndOutputs(
337 {heatmap, boxes},
338 {score, keypoint});
339 assert(model->isValid());
340 }
341
is_ignored_dynamic_output_shape_nchw_float16(int i)342 inline bool is_ignored_dynamic_output_shape_nchw_float16(int i) {
343 static std::set<int> ignore = {};
344 return ignore.find(i) != ignore.end();
345 }
346
CreateModel_nhwc_2(Model * model)347 void CreateModel_nhwc_2(Model *model) {
348 OperandType type0(Type::BOOL, {});
349 OperandType type5(Type::TENSOR_FLOAT32, {2, 4, 4, 4});
350 OperandType type6(Type::TENSOR_FLOAT32, {2, 4});
351 OperandType type7(Type::TENSOR_FLOAT32, {2, 4, 2});
352 // Phase 1, operands
353 auto heatmap1 = model->addOperand(&type5);
354 auto boxes1 = model->addOperand(&type6);
355 auto layout = model->addOperand(&type0);
356 auto score1 = model->addOperand(&type6);
357 auto keypoint1 = model->addOperand(&type7);
358 // Phase 2, operations
359 static bool8 layout_init[] = {false};
360 model->setOperandValue(layout, layout_init, sizeof(bool8) * 1);
361 model->addOperation(ANEURALNETWORKS_HEATMAP_MAX_KEYPOINT, {heatmap1, boxes1, layout}, {score1, keypoint1});
362 // Phase 3, inputs and outputs
363 model->identifyInputsAndOutputs(
364 {heatmap1, boxes1},
365 {score1, keypoint1});
366 assert(model->isValid());
367 }
368
is_ignored_nhwc_2(int i)369 inline bool is_ignored_nhwc_2(int i) {
370 static std::set<int> ignore = {};
371 return ignore.find(i) != ignore.end();
372 }
373
CreateModel_nhwc_relaxed_2(Model * model)374 void CreateModel_nhwc_relaxed_2(Model *model) {
375 OperandType type0(Type::BOOL, {});
376 OperandType type5(Type::TENSOR_FLOAT32, {2, 4, 4, 4});
377 OperandType type6(Type::TENSOR_FLOAT32, {2, 4});
378 OperandType type7(Type::TENSOR_FLOAT32, {2, 4, 2});
379 // Phase 1, operands
380 auto heatmap1 = model->addOperand(&type5);
381 auto boxes1 = model->addOperand(&type6);
382 auto layout = model->addOperand(&type0);
383 auto score1 = model->addOperand(&type6);
384 auto keypoint1 = model->addOperand(&type7);
385 // Phase 2, operations
386 static bool8 layout_init[] = {false};
387 model->setOperandValue(layout, layout_init, sizeof(bool8) * 1);
388 model->addOperation(ANEURALNETWORKS_HEATMAP_MAX_KEYPOINT, {heatmap1, boxes1, layout}, {score1, keypoint1});
389 // Phase 3, inputs and outputs
390 model->identifyInputsAndOutputs(
391 {heatmap1, boxes1},
392 {score1, keypoint1});
393 // Phase 4: set relaxed execution
394 model->relaxComputationFloat32toFloat16(true);
395 assert(model->isValid());
396 }
397
is_ignored_nhwc_relaxed_2(int i)398 inline bool is_ignored_nhwc_relaxed_2(int i) {
399 static std::set<int> ignore = {};
400 return ignore.find(i) != ignore.end();
401 }
402
CreateModel_nhwc_float16_2(Model * model)403 void CreateModel_nhwc_float16_2(Model *model) {
404 OperandType type0(Type::BOOL, {});
405 OperandType type22(Type::TENSOR_FLOAT16, {2, 4});
406 OperandType type23(Type::TENSOR_FLOAT16, {2, 4, 4, 4});
407 OperandType type24(Type::TENSOR_FLOAT16, {2, 4, 2});
408 // Phase 1, operands
409 auto heatmap1 = model->addOperand(&type23);
410 auto boxes1 = model->addOperand(&type22);
411 auto layout = model->addOperand(&type0);
412 auto score1 = model->addOperand(&type22);
413 auto keypoint1 = model->addOperand(&type24);
414 // Phase 2, operations
415 static bool8 layout_init[] = {false};
416 model->setOperandValue(layout, layout_init, sizeof(bool8) * 1);
417 model->addOperation(ANEURALNETWORKS_HEATMAP_MAX_KEYPOINT, {heatmap1, boxes1, layout}, {score1, keypoint1});
418 // Phase 3, inputs and outputs
419 model->identifyInputsAndOutputs(
420 {heatmap1, boxes1},
421 {score1, keypoint1});
422 assert(model->isValid());
423 }
424
is_ignored_nhwc_float16_2(int i)425 inline bool is_ignored_nhwc_float16_2(int i) {
426 static std::set<int> ignore = {};
427 return ignore.find(i) != ignore.end();
428 }
429
CreateModel_nhwc_quant8(Model * model)430 void CreateModel_nhwc_quant8(Model *model) {
431 OperandType type0(Type::BOOL, {});
432 OperandType type25(Type::TENSOR_QUANT16_ASYMM, {2, 4}, 0.125f, 0);
433 OperandType type26(Type::TENSOR_QUANT8_ASYMM, {2, 4, 4, 4}, 0.01f, 128);
434 OperandType type27(Type::TENSOR_QUANT16_ASYMM, {2, 4, 2}, 0.125f, 0);
435 OperandType type28(Type::TENSOR_QUANT8_ASYMM, {2, 4}, 0.01f, 0);
436 // Phase 1, operands
437 auto heatmap1 = model->addOperand(&type26);
438 auto boxes1 = model->addOperand(&type25);
439 auto layout = model->addOperand(&type0);
440 auto score1 = model->addOperand(&type28);
441 auto keypoint1 = model->addOperand(&type27);
442 // Phase 2, operations
443 static bool8 layout_init[] = {false};
444 model->setOperandValue(layout, layout_init, sizeof(bool8) * 1);
445 model->addOperation(ANEURALNETWORKS_HEATMAP_MAX_KEYPOINT, {heatmap1, boxes1, layout}, {score1, keypoint1});
446 // Phase 3, inputs and outputs
447 model->identifyInputsAndOutputs(
448 {heatmap1, boxes1},
449 {score1, keypoint1});
450 assert(model->isValid());
451 }
452
is_ignored_nhwc_quant8(int i)453 inline bool is_ignored_nhwc_quant8(int i) {
454 static std::set<int> ignore = {};
455 return ignore.find(i) != ignore.end();
456 }
457
CreateModel_nchw_2(Model * model)458 void CreateModel_nchw_2(Model *model) {
459 OperandType type0(Type::BOOL, {});
460 OperandType type5(Type::TENSOR_FLOAT32, {2, 4, 4, 4});
461 OperandType type6(Type::TENSOR_FLOAT32, {2, 4});
462 OperandType type7(Type::TENSOR_FLOAT32, {2, 4, 2});
463 // Phase 1, operands
464 auto heatmap1 = model->addOperand(&type5);
465 auto boxes1 = model->addOperand(&type6);
466 auto layout = model->addOperand(&type0);
467 auto score1 = model->addOperand(&type6);
468 auto keypoint1 = model->addOperand(&type7);
469 // Phase 2, operations
470 static bool8 layout_init[] = {true};
471 model->setOperandValue(layout, layout_init, sizeof(bool8) * 1);
472 model->addOperation(ANEURALNETWORKS_HEATMAP_MAX_KEYPOINT, {heatmap1, boxes1, layout}, {score1, keypoint1});
473 // Phase 3, inputs and outputs
474 model->identifyInputsAndOutputs(
475 {heatmap1, boxes1},
476 {score1, keypoint1});
477 assert(model->isValid());
478 }
479
is_ignored_nchw_2(int i)480 inline bool is_ignored_nchw_2(int i) {
481 static std::set<int> ignore = {};
482 return ignore.find(i) != ignore.end();
483 }
484
CreateModel_nchw_relaxed_2(Model * model)485 void CreateModel_nchw_relaxed_2(Model *model) {
486 OperandType type0(Type::BOOL, {});
487 OperandType type5(Type::TENSOR_FLOAT32, {2, 4, 4, 4});
488 OperandType type6(Type::TENSOR_FLOAT32, {2, 4});
489 OperandType type7(Type::TENSOR_FLOAT32, {2, 4, 2});
490 // Phase 1, operands
491 auto heatmap1 = model->addOperand(&type5);
492 auto boxes1 = model->addOperand(&type6);
493 auto layout = model->addOperand(&type0);
494 auto score1 = model->addOperand(&type6);
495 auto keypoint1 = model->addOperand(&type7);
496 // Phase 2, operations
497 static bool8 layout_init[] = {true};
498 model->setOperandValue(layout, layout_init, sizeof(bool8) * 1);
499 model->addOperation(ANEURALNETWORKS_HEATMAP_MAX_KEYPOINT, {heatmap1, boxes1, layout}, {score1, keypoint1});
500 // Phase 3, inputs and outputs
501 model->identifyInputsAndOutputs(
502 {heatmap1, boxes1},
503 {score1, keypoint1});
504 // Phase 4: set relaxed execution
505 model->relaxComputationFloat32toFloat16(true);
506 assert(model->isValid());
507 }
508
is_ignored_nchw_relaxed_2(int i)509 inline bool is_ignored_nchw_relaxed_2(int i) {
510 static std::set<int> ignore = {};
511 return ignore.find(i) != ignore.end();
512 }
513
CreateModel_nchw_float16_2(Model * model)514 void CreateModel_nchw_float16_2(Model *model) {
515 OperandType type0(Type::BOOL, {});
516 OperandType type22(Type::TENSOR_FLOAT16, {2, 4});
517 OperandType type23(Type::TENSOR_FLOAT16, {2, 4, 4, 4});
518 OperandType type24(Type::TENSOR_FLOAT16, {2, 4, 2});
519 // Phase 1, operands
520 auto heatmap1 = model->addOperand(&type23);
521 auto boxes1 = model->addOperand(&type22);
522 auto layout = model->addOperand(&type0);
523 auto score1 = model->addOperand(&type22);
524 auto keypoint1 = model->addOperand(&type24);
525 // Phase 2, operations
526 static bool8 layout_init[] = {true};
527 model->setOperandValue(layout, layout_init, sizeof(bool8) * 1);
528 model->addOperation(ANEURALNETWORKS_HEATMAP_MAX_KEYPOINT, {heatmap1, boxes1, layout}, {score1, keypoint1});
529 // Phase 3, inputs and outputs
530 model->identifyInputsAndOutputs(
531 {heatmap1, boxes1},
532 {score1, keypoint1});
533 assert(model->isValid());
534 }
535
is_ignored_nchw_float16_2(int i)536 inline bool is_ignored_nchw_float16_2(int i) {
537 static std::set<int> ignore = {};
538 return ignore.find(i) != ignore.end();
539 }
540
CreateModel_nchw_quant8(Model * model)541 void CreateModel_nchw_quant8(Model *model) {
542 OperandType type0(Type::BOOL, {});
543 OperandType type25(Type::TENSOR_QUANT16_ASYMM, {2, 4}, 0.125f, 0);
544 OperandType type26(Type::TENSOR_QUANT8_ASYMM, {2, 4, 4, 4}, 0.01f, 128);
545 OperandType type27(Type::TENSOR_QUANT16_ASYMM, {2, 4, 2}, 0.125f, 0);
546 OperandType type28(Type::TENSOR_QUANT8_ASYMM, {2, 4}, 0.01f, 0);
547 // Phase 1, operands
548 auto heatmap1 = model->addOperand(&type26);
549 auto boxes1 = model->addOperand(&type25);
550 auto layout = model->addOperand(&type0);
551 auto score1 = model->addOperand(&type28);
552 auto keypoint1 = model->addOperand(&type27);
553 // Phase 2, operations
554 static bool8 layout_init[] = {true};
555 model->setOperandValue(layout, layout_init, sizeof(bool8) * 1);
556 model->addOperation(ANEURALNETWORKS_HEATMAP_MAX_KEYPOINT, {heatmap1, boxes1, layout}, {score1, keypoint1});
557 // Phase 3, inputs and outputs
558 model->identifyInputsAndOutputs(
559 {heatmap1, boxes1},
560 {score1, keypoint1});
561 assert(model->isValid());
562 }
563
is_ignored_nchw_quant8(int i)564 inline bool is_ignored_nchw_quant8(int i) {
565 static std::set<int> ignore = {};
566 return ignore.find(i) != ignore.end();
567 }
568
CreateModel_dynamic_output_shape_nhwc_2(Model * model)569 void CreateModel_dynamic_output_shape_nhwc_2(Model *model) {
570 OperandType type0(Type::BOOL, {});
571 OperandType type18(Type::TENSOR_FLOAT32, {0, 0});
572 OperandType type19(Type::TENSOR_FLOAT32, {0, 0, 0});
573 OperandType type5(Type::TENSOR_FLOAT32, {2, 4, 4, 4});
574 OperandType type6(Type::TENSOR_FLOAT32, {2, 4});
575 // Phase 1, operands
576 auto heatmap1 = model->addOperand(&type5);
577 auto boxes1 = model->addOperand(&type6);
578 auto layout = model->addOperand(&type0);
579 auto score1 = model->addOperand(&type18);
580 auto keypoint1 = model->addOperand(&type19);
581 // Phase 2, operations
582 static bool8 layout_init[] = {false};
583 model->setOperandValue(layout, layout_init, sizeof(bool8) * 1);
584 model->addOperation(ANEURALNETWORKS_HEATMAP_MAX_KEYPOINT, {heatmap1, boxes1, layout}, {score1, keypoint1});
585 // Phase 3, inputs and outputs
586 model->identifyInputsAndOutputs(
587 {heatmap1, boxes1},
588 {score1, keypoint1});
589 assert(model->isValid());
590 }
591
is_ignored_dynamic_output_shape_nhwc_2(int i)592 inline bool is_ignored_dynamic_output_shape_nhwc_2(int i) {
593 static std::set<int> ignore = {};
594 return ignore.find(i) != ignore.end();
595 }
596
CreateModel_dynamic_output_shape_nhwc_relaxed_2(Model * model)597 void CreateModel_dynamic_output_shape_nhwc_relaxed_2(Model *model) {
598 OperandType type0(Type::BOOL, {});
599 OperandType type18(Type::TENSOR_FLOAT32, {0, 0});
600 OperandType type19(Type::TENSOR_FLOAT32, {0, 0, 0});
601 OperandType type5(Type::TENSOR_FLOAT32, {2, 4, 4, 4});
602 OperandType type6(Type::TENSOR_FLOAT32, {2, 4});
603 // Phase 1, operands
604 auto heatmap1 = model->addOperand(&type5);
605 auto boxes1 = model->addOperand(&type6);
606 auto layout = model->addOperand(&type0);
607 auto score1 = model->addOperand(&type18);
608 auto keypoint1 = model->addOperand(&type19);
609 // Phase 2, operations
610 static bool8 layout_init[] = {false};
611 model->setOperandValue(layout, layout_init, sizeof(bool8) * 1);
612 model->addOperation(ANEURALNETWORKS_HEATMAP_MAX_KEYPOINT, {heatmap1, boxes1, layout}, {score1, keypoint1});
613 // Phase 3, inputs and outputs
614 model->identifyInputsAndOutputs(
615 {heatmap1, boxes1},
616 {score1, keypoint1});
617 // Phase 4: set relaxed execution
618 model->relaxComputationFloat32toFloat16(true);
619 assert(model->isValid());
620 }
621
is_ignored_dynamic_output_shape_nhwc_relaxed_2(int i)622 inline bool is_ignored_dynamic_output_shape_nhwc_relaxed_2(int i) {
623 static std::set<int> ignore = {};
624 return ignore.find(i) != ignore.end();
625 }
626
CreateModel_dynamic_output_shape_nhwc_float16_2(Model * model)627 void CreateModel_dynamic_output_shape_nhwc_float16_2(Model *model) {
628 OperandType type0(Type::BOOL, {});
629 OperandType type20(Type::TENSOR_FLOAT16, {0, 0});
630 OperandType type21(Type::TENSOR_FLOAT16, {0, 0, 0});
631 OperandType type22(Type::TENSOR_FLOAT16, {2, 4});
632 OperandType type23(Type::TENSOR_FLOAT16, {2, 4, 4, 4});
633 // Phase 1, operands
634 auto heatmap1 = model->addOperand(&type23);
635 auto boxes1 = model->addOperand(&type22);
636 auto layout = model->addOperand(&type0);
637 auto score1 = model->addOperand(&type20);
638 auto keypoint1 = model->addOperand(&type21);
639 // Phase 2, operations
640 static bool8 layout_init[] = {false};
641 model->setOperandValue(layout, layout_init, sizeof(bool8) * 1);
642 model->addOperation(ANEURALNETWORKS_HEATMAP_MAX_KEYPOINT, {heatmap1, boxes1, layout}, {score1, keypoint1});
643 // Phase 3, inputs and outputs
644 model->identifyInputsAndOutputs(
645 {heatmap1, boxes1},
646 {score1, keypoint1});
647 assert(model->isValid());
648 }
649
is_ignored_dynamic_output_shape_nhwc_float16_2(int i)650 inline bool is_ignored_dynamic_output_shape_nhwc_float16_2(int i) {
651 static std::set<int> ignore = {};
652 return ignore.find(i) != ignore.end();
653 }
654
CreateModel_dynamic_output_shape_nhwc_quant8(Model * model)655 void CreateModel_dynamic_output_shape_nhwc_quant8(Model *model) {
656 OperandType type0(Type::BOOL, {});
657 OperandType type25(Type::TENSOR_QUANT16_ASYMM, {2, 4}, 0.125f, 0);
658 OperandType type26(Type::TENSOR_QUANT8_ASYMM, {2, 4, 4, 4}, 0.01f, 128);
659 OperandType type29(Type::TENSOR_QUANT8_ASYMM, {0, 0}, 0.01f, 0);
660 OperandType type30(Type::TENSOR_QUANT16_ASYMM, {0, 0, 0}, 0.125f, 0);
661 // Phase 1, operands
662 auto heatmap1 = model->addOperand(&type26);
663 auto boxes1 = model->addOperand(&type25);
664 auto layout = model->addOperand(&type0);
665 auto score1 = model->addOperand(&type29);
666 auto keypoint1 = model->addOperand(&type30);
667 // Phase 2, operations
668 static bool8 layout_init[] = {false};
669 model->setOperandValue(layout, layout_init, sizeof(bool8) * 1);
670 model->addOperation(ANEURALNETWORKS_HEATMAP_MAX_KEYPOINT, {heatmap1, boxes1, layout}, {score1, keypoint1});
671 // Phase 3, inputs and outputs
672 model->identifyInputsAndOutputs(
673 {heatmap1, boxes1},
674 {score1, keypoint1});
675 assert(model->isValid());
676 }
677
is_ignored_dynamic_output_shape_nhwc_quant8(int i)678 inline bool is_ignored_dynamic_output_shape_nhwc_quant8(int i) {
679 static std::set<int> ignore = {};
680 return ignore.find(i) != ignore.end();
681 }
682
CreateModel_dynamic_output_shape_nchw_2(Model * model)683 void CreateModel_dynamic_output_shape_nchw_2(Model *model) {
684 OperandType type0(Type::BOOL, {});
685 OperandType type18(Type::TENSOR_FLOAT32, {0, 0});
686 OperandType type19(Type::TENSOR_FLOAT32, {0, 0, 0});
687 OperandType type5(Type::TENSOR_FLOAT32, {2, 4, 4, 4});
688 OperandType type6(Type::TENSOR_FLOAT32, {2, 4});
689 // Phase 1, operands
690 auto heatmap1 = model->addOperand(&type5);
691 auto boxes1 = model->addOperand(&type6);
692 auto layout = model->addOperand(&type0);
693 auto score1 = model->addOperand(&type18);
694 auto keypoint1 = model->addOperand(&type19);
695 // Phase 2, operations
696 static bool8 layout_init[] = {true};
697 model->setOperandValue(layout, layout_init, sizeof(bool8) * 1);
698 model->addOperation(ANEURALNETWORKS_HEATMAP_MAX_KEYPOINT, {heatmap1, boxes1, layout}, {score1, keypoint1});
699 // Phase 3, inputs and outputs
700 model->identifyInputsAndOutputs(
701 {heatmap1, boxes1},
702 {score1, keypoint1});
703 assert(model->isValid());
704 }
705
is_ignored_dynamic_output_shape_nchw_2(int i)706 inline bool is_ignored_dynamic_output_shape_nchw_2(int i) {
707 static std::set<int> ignore = {};
708 return ignore.find(i) != ignore.end();
709 }
710
CreateModel_dynamic_output_shape_nchw_relaxed_2(Model * model)711 void CreateModel_dynamic_output_shape_nchw_relaxed_2(Model *model) {
712 OperandType type0(Type::BOOL, {});
713 OperandType type18(Type::TENSOR_FLOAT32, {0, 0});
714 OperandType type19(Type::TENSOR_FLOAT32, {0, 0, 0});
715 OperandType type5(Type::TENSOR_FLOAT32, {2, 4, 4, 4});
716 OperandType type6(Type::TENSOR_FLOAT32, {2, 4});
717 // Phase 1, operands
718 auto heatmap1 = model->addOperand(&type5);
719 auto boxes1 = model->addOperand(&type6);
720 auto layout = model->addOperand(&type0);
721 auto score1 = model->addOperand(&type18);
722 auto keypoint1 = model->addOperand(&type19);
723 // Phase 2, operations
724 static bool8 layout_init[] = {true};
725 model->setOperandValue(layout, layout_init, sizeof(bool8) * 1);
726 model->addOperation(ANEURALNETWORKS_HEATMAP_MAX_KEYPOINT, {heatmap1, boxes1, layout}, {score1, keypoint1});
727 // Phase 3, inputs and outputs
728 model->identifyInputsAndOutputs(
729 {heatmap1, boxes1},
730 {score1, keypoint1});
731 // Phase 4: set relaxed execution
732 model->relaxComputationFloat32toFloat16(true);
733 assert(model->isValid());
734 }
735
is_ignored_dynamic_output_shape_nchw_relaxed_2(int i)736 inline bool is_ignored_dynamic_output_shape_nchw_relaxed_2(int i) {
737 static std::set<int> ignore = {};
738 return ignore.find(i) != ignore.end();
739 }
740
CreateModel_dynamic_output_shape_nchw_float16_2(Model * model)741 void CreateModel_dynamic_output_shape_nchw_float16_2(Model *model) {
742 OperandType type0(Type::BOOL, {});
743 OperandType type20(Type::TENSOR_FLOAT16, {0, 0});
744 OperandType type21(Type::TENSOR_FLOAT16, {0, 0, 0});
745 OperandType type22(Type::TENSOR_FLOAT16, {2, 4});
746 OperandType type23(Type::TENSOR_FLOAT16, {2, 4, 4, 4});
747 // Phase 1, operands
748 auto heatmap1 = model->addOperand(&type23);
749 auto boxes1 = model->addOperand(&type22);
750 auto layout = model->addOperand(&type0);
751 auto score1 = model->addOperand(&type20);
752 auto keypoint1 = model->addOperand(&type21);
753 // Phase 2, operations
754 static bool8 layout_init[] = {true};
755 model->setOperandValue(layout, layout_init, sizeof(bool8) * 1);
756 model->addOperation(ANEURALNETWORKS_HEATMAP_MAX_KEYPOINT, {heatmap1, boxes1, layout}, {score1, keypoint1});
757 // Phase 3, inputs and outputs
758 model->identifyInputsAndOutputs(
759 {heatmap1, boxes1},
760 {score1, keypoint1});
761 assert(model->isValid());
762 }
763
is_ignored_dynamic_output_shape_nchw_float16_2(int i)764 inline bool is_ignored_dynamic_output_shape_nchw_float16_2(int i) {
765 static std::set<int> ignore = {};
766 return ignore.find(i) != ignore.end();
767 }
768
CreateModel_dynamic_output_shape_nchw_quant8(Model * model)769 void CreateModel_dynamic_output_shape_nchw_quant8(Model *model) {
770 OperandType type0(Type::BOOL, {});
771 OperandType type25(Type::TENSOR_QUANT16_ASYMM, {2, 4}, 0.125f, 0);
772 OperandType type26(Type::TENSOR_QUANT8_ASYMM, {2, 4, 4, 4}, 0.01f, 128);
773 OperandType type29(Type::TENSOR_QUANT8_ASYMM, {0, 0}, 0.01f, 0);
774 OperandType type30(Type::TENSOR_QUANT16_ASYMM, {0, 0, 0}, 0.125f, 0);
775 // Phase 1, operands
776 auto heatmap1 = model->addOperand(&type26);
777 auto boxes1 = model->addOperand(&type25);
778 auto layout = model->addOperand(&type0);
779 auto score1 = model->addOperand(&type29);
780 auto keypoint1 = model->addOperand(&type30);
781 // Phase 2, operations
782 static bool8 layout_init[] = {true};
783 model->setOperandValue(layout, layout_init, sizeof(bool8) * 1);
784 model->addOperation(ANEURALNETWORKS_HEATMAP_MAX_KEYPOINT, {heatmap1, boxes1, layout}, {score1, keypoint1});
785 // Phase 3, inputs and outputs
786 model->identifyInputsAndOutputs(
787 {heatmap1, boxes1},
788 {score1, keypoint1});
789 assert(model->isValid());
790 }
791
is_ignored_dynamic_output_shape_nchw_quant8(int i)792 inline bool is_ignored_dynamic_output_shape_nchw_quant8(int i) {
793 static std::set<int> ignore = {};
794 return ignore.find(i) != ignore.end();
795 }
796
CreateModel_nhwc_quant8_2(Model * model)797 void CreateModel_nhwc_quant8_2(Model *model) {
798 OperandType type0(Type::BOOL, {});
799 OperandType type31(Type::TENSOR_QUANT16_ASYMM, {5, 4}, 0.125f, 0);
800 OperandType type32(Type::TENSOR_QUANT8_ASYMM, {5, 4, 4, 1}, 0.5f, 128);
801 OperandType type33(Type::TENSOR_QUANT16_ASYMM, {5, 1, 2}, 0.125f, 0);
802 OperandType type34(Type::TENSOR_QUANT8_ASYMM, {5, 1}, 0.1f, 10);
803 // Phase 1, operands
804 auto heatmap2 = model->addOperand(&type32);
805 auto boxes2 = model->addOperand(&type31);
806 auto layout = model->addOperand(&type0);
807 auto score2 = model->addOperand(&type34);
808 auto keypoint2 = model->addOperand(&type33);
809 // Phase 2, operations
810 static bool8 layout_init[] = {false};
811 model->setOperandValue(layout, layout_init, sizeof(bool8) * 1);
812 model->addOperation(ANEURALNETWORKS_HEATMAP_MAX_KEYPOINT, {heatmap2, boxes2, layout}, {score2, keypoint2});
813 // Phase 3, inputs and outputs
814 model->identifyInputsAndOutputs(
815 {heatmap2, boxes2},
816 {score2, keypoint2});
817 assert(model->isValid());
818 }
819
is_ignored_nhwc_quant8_2(int i)820 inline bool is_ignored_nhwc_quant8_2(int i) {
821 static std::set<int> ignore = {};
822 return ignore.find(i) != ignore.end();
823 }
824
CreateModel_nchw_quant8_2(Model * model)825 void CreateModel_nchw_quant8_2(Model *model) {
826 OperandType type0(Type::BOOL, {});
827 OperandType type31(Type::TENSOR_QUANT16_ASYMM, {5, 4}, 0.125f, 0);
828 OperandType type33(Type::TENSOR_QUANT16_ASYMM, {5, 1, 2}, 0.125f, 0);
829 OperandType type34(Type::TENSOR_QUANT8_ASYMM, {5, 1}, 0.1f, 10);
830 OperandType type36(Type::TENSOR_QUANT8_ASYMM, {5, 1, 4, 4}, 0.5f, 128);
831 // Phase 1, operands
832 auto heatmap2 = model->addOperand(&type36);
833 auto boxes2 = model->addOperand(&type31);
834 auto layout = model->addOperand(&type0);
835 auto score2 = model->addOperand(&type34);
836 auto keypoint2 = model->addOperand(&type33);
837 // Phase 2, operations
838 static bool8 layout_init[] = {true};
839 model->setOperandValue(layout, layout_init, sizeof(bool8) * 1);
840 model->addOperation(ANEURALNETWORKS_HEATMAP_MAX_KEYPOINT, {heatmap2, boxes2, layout}, {score2, keypoint2});
841 // Phase 3, inputs and outputs
842 model->identifyInputsAndOutputs(
843 {heatmap2, boxes2},
844 {score2, keypoint2});
845 assert(model->isValid());
846 }
847
is_ignored_nchw_quant8_2(int i)848 inline bool is_ignored_nchw_quant8_2(int i) {
849 static std::set<int> ignore = {};
850 return ignore.find(i) != ignore.end();
851 }
852
CreateModel_dynamic_output_shape_nhwc_quant8_2(Model * model)853 void CreateModel_dynamic_output_shape_nhwc_quant8_2(Model *model) {
854 OperandType type0(Type::BOOL, {});
855 OperandType type30(Type::TENSOR_QUANT16_ASYMM, {0, 0, 0}, 0.125f, 0);
856 OperandType type31(Type::TENSOR_QUANT16_ASYMM, {5, 4}, 0.125f, 0);
857 OperandType type32(Type::TENSOR_QUANT8_ASYMM, {5, 4, 4, 1}, 0.5f, 128);
858 OperandType type37(Type::TENSOR_QUANT8_ASYMM, {0, 0}, 0.1f, 10);
859 // Phase 1, operands
860 auto heatmap2 = model->addOperand(&type32);
861 auto boxes2 = model->addOperand(&type31);
862 auto layout = model->addOperand(&type0);
863 auto score2 = model->addOperand(&type37);
864 auto keypoint2 = model->addOperand(&type30);
865 // Phase 2, operations
866 static bool8 layout_init[] = {false};
867 model->setOperandValue(layout, layout_init, sizeof(bool8) * 1);
868 model->addOperation(ANEURALNETWORKS_HEATMAP_MAX_KEYPOINT, {heatmap2, boxes2, layout}, {score2, keypoint2});
869 // Phase 3, inputs and outputs
870 model->identifyInputsAndOutputs(
871 {heatmap2, boxes2},
872 {score2, keypoint2});
873 assert(model->isValid());
874 }
875
is_ignored_dynamic_output_shape_nhwc_quant8_2(int i)876 inline bool is_ignored_dynamic_output_shape_nhwc_quant8_2(int i) {
877 static std::set<int> ignore = {};
878 return ignore.find(i) != ignore.end();
879 }
880
CreateModel_dynamic_output_shape_nchw_quant8_2(Model * model)881 void CreateModel_dynamic_output_shape_nchw_quant8_2(Model *model) {
882 OperandType type0(Type::BOOL, {});
883 OperandType type30(Type::TENSOR_QUANT16_ASYMM, {0, 0, 0}, 0.125f, 0);
884 OperandType type31(Type::TENSOR_QUANT16_ASYMM, {5, 4}, 0.125f, 0);
885 OperandType type36(Type::TENSOR_QUANT8_ASYMM, {5, 1, 4, 4}, 0.5f, 128);
886 OperandType type37(Type::TENSOR_QUANT8_ASYMM, {0, 0}, 0.1f, 10);
887 // Phase 1, operands
888 auto heatmap2 = model->addOperand(&type36);
889 auto boxes2 = model->addOperand(&type31);
890 auto layout = model->addOperand(&type0);
891 auto score2 = model->addOperand(&type37);
892 auto keypoint2 = model->addOperand(&type30);
893 // Phase 2, operations
894 static bool8 layout_init[] = {true};
895 model->setOperandValue(layout, layout_init, sizeof(bool8) * 1);
896 model->addOperation(ANEURALNETWORKS_HEATMAP_MAX_KEYPOINT, {heatmap2, boxes2, layout}, {score2, keypoint2});
897 // Phase 3, inputs and outputs
898 model->identifyInputsAndOutputs(
899 {heatmap2, boxes2},
900 {score2, keypoint2});
901 assert(model->isValid());
902 }
903
is_ignored_dynamic_output_shape_nchw_quant8_2(int i)904 inline bool is_ignored_dynamic_output_shape_nchw_quant8_2(int i) {
905 static std::set<int> ignore = {};
906 return ignore.find(i) != ignore.end();
907 }
908
909