1 // Generated code. Do not edit
2 // Create the model
createTestModel()3 Model createTestModel() {
4 const std::vector<Operand> operands = {
5 {
6 .type = OperandType::TENSOR_QUANT8_ASYMM,
7 .dimensions = {1, 2, 2, 1},
8 .numberOfConsumers = 1,
9 .scale = 1.0f,
10 .zeroPoint = 0,
11 .lifetime = OperandLifeTime::MODEL_INPUT,
12 .location = {.poolIndex = 0, .offset = 0, .length = 0},
13 },
14 {
15 .type = OperandType::TENSOR_FLOAT32,
16 .dimensions = {1, 2, 2, 1},
17 .numberOfConsumers = 0,
18 .scale = 0.0f,
19 .zeroPoint = 0,
20 .lifetime = OperandLifeTime::MODEL_OUTPUT,
21 .location = {.poolIndex = 0, .offset = 0, .length = 0},
22 }
23 };
24
25 const std::vector<Operation> operations = {
26 {
27 .type = OperationType::DEQUANTIZE,
28 .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 }
47
is_ignored(int i)48 bool is_ignored(int i) {
49 static std::set<int> ignore = {};
50 return ignore.find(i) != ignore.end();
51 }
52