blob: df83727045b12515b1f8a3e86bb159415b6bf85d [file] [log] [blame]
I-Jui (Ray) Sungd8b6b502017-09-13 20:00:58 -07001// Generated code. Do not edit
2// Create the model
3Model createTestModel() {
4 const std::vector<Operand> operands = {
5 {
6 .type = OperandType::TENSOR_QUANT8_ASYMM,
Jean-Luc Brouillete68d9242017-10-04 00:49:53 -07007 .dimensions = {2, 64, 64, 2},
I-Jui (Ray) Sungd8b6b502017-09-13 20:00:58 -07008 .numberOfConsumers = 1,
9 .scale = 1.0f,
10 .zeroPoint = 128,
11 .lifetime = OperandLifeTime::MODEL_INPUT,
12 .location = {.poolIndex = 0, .offset = 0, .length = 0},
13 },
14 {
15 .type = OperandType::TENSOR_QUANT8_ASYMM,
Jean-Luc Brouillete68d9242017-10-04 00:49:53 -070016 .dimensions = {2, 64, 64, 2},
I-Jui (Ray) Sungd8b6b502017-09-13 20:00:58 -070017 .numberOfConsumers = 0,
18 .scale = 1.0f,
19 .zeroPoint = 128,
20 .lifetime = OperandLifeTime::MODEL_OUTPUT,
21 .location = {.poolIndex = 0, .offset = 0, .length = 0},
22 }
23 };
24
25 const std::vector<Operation> operations = {
26 {
Dong Chen224c01e2017-10-03 10:38:55 -070027 .type = OperationType::RELU1,
I-Jui (Ray) Sungd8b6b502017-09-13 20:00:58 -070028 .inputs = {0},
29 .outputs = {1},
30 }
31 };
32
33 const std::vector<uint32_t> inputIndexes = {0};
34 const std::vector<uint32_t> outputIndexes = {1};
35 std::vector<uint8_t> operandValues = {};
36 const std::vector<hidl_memory> pools = {};
37
38 return {
39 .operands = operands,
40 .operations = operations,
41 .inputIndexes = inputIndexes,
42 .outputIndexes = outputIndexes,
43 .operandValues = operandValues,
44 .pools = pools,
45 };
46}
I-Jui (Ray) Sungb6b3dc42017-09-13 18:50:37 -070047
Miao Wange8e5d342018-02-22 19:05:20 -080048
I-Jui (Ray) Sungb6b3dc42017-09-13 18:50:37 -070049bool is_ignored(int i) {
50 static std::set<int> ignore = {};
51 return ignore.find(i) != ignore.end();
52}