diff options
Diffstat (limited to 'operators/control_flow/cond_if_binary/cond_if_binary_ERRORIF_CondIfInputListThenGraphMismatch_10_i32_cond0')
4 files changed, 227 insertions, 0 deletions
diff --git a/operators/control_flow/cond_if_binary/cond_if_binary_ERRORIF_CondIfInputListThenGraphMismatch_10_i32_cond0/desc.json b/operators/control_flow/cond_if_binary/cond_if_binary_ERRORIF_CondIfInputListThenGraphMismatch_10_i32_cond0/desc.json new file mode 100644 index 000000000..d11d8da43 --- /dev/null +++ b/operators/control_flow/cond_if_binary/cond_if_binary_ERRORIF_CondIfInputListThenGraphMismatch_10_i32_cond0/desc.json @@ -0,0 +1,24 @@ +{ + "tosa_file": "test.json", + "ifm_name": [ + "input-0", + "input-1" + ], + "ifm_file": [ + "input-0.npy", + "input-1.npy" + ], + "ofm_name": [ + "result-0" + ], + "ofm_file": [ + "result-0.npy" + ], + "expected_return_code": 2, + "expected_failure": true, + "expected_failure_desc": "Input list shape does not match then-graph shape", + "profile": [ + "tosa-bi", + "tosa-mi" + ] +}
\ No newline at end of file diff --git a/operators/control_flow/cond_if_binary/cond_if_binary_ERRORIF_CondIfInputListThenGraphMismatch_10_i32_cond0/input-0.json b/operators/control_flow/cond_if_binary/cond_if_binary_ERRORIF_CondIfInputListThenGraphMismatch_10_i32_cond0/input-0.json new file mode 100644 index 000000000..87ce31c6d --- /dev/null +++ b/operators/control_flow/cond_if_binary/cond_if_binary_ERRORIF_CondIfInputListThenGraphMismatch_10_i32_cond0/input-0.json @@ -0,0 +1,15 @@ +{ + "type": "int32", + "data": [ + 5607, + -30484, + 32580, + 22413, + -16420, + -22925, + 9289, + 26320, + -11723, + 30245 + ] +}
\ No newline at end of file diff --git a/operators/control_flow/cond_if_binary/cond_if_binary_ERRORIF_CondIfInputListThenGraphMismatch_10_i32_cond0/input-1.json b/operators/control_flow/cond_if_binary/cond_if_binary_ERRORIF_CondIfInputListThenGraphMismatch_10_i32_cond0/input-1.json new file mode 100644 index 000000000..9703d8c34 --- /dev/null +++ b/operators/control_flow/cond_if_binary/cond_if_binary_ERRORIF_CondIfInputListThenGraphMismatch_10_i32_cond0/input-1.json @@ -0,0 +1,15 @@ +{ + "type": "int32", + "data": [ + -2763, + -3819, + -10555, + -15029, + -10843, + -21434, + -8073, + -13778, + -29054, + -9005 + ] +}
\ No newline at end of file diff --git a/operators/control_flow/cond_if_binary/cond_if_binary_ERRORIF_CondIfInputListThenGraphMismatch_10_i32_cond0/test.json b/operators/control_flow/cond_if_binary/cond_if_binary_ERRORIF_CondIfInputListThenGraphMismatch_10_i32_cond0/test.json new file mode 100644 index 000000000..60fce5cb2 --- /dev/null +++ b/operators/control_flow/cond_if_binary/cond_if_binary_ERRORIF_CondIfInputListThenGraphMismatch_10_i32_cond0/test.json @@ -0,0 +1,173 @@ +{ + version: { + _major: 0, + _minor: 41, + _patch: 0, + _draft: true + }, + blocks: [ + { + name: "main", + operators: [ + { + op: "CONST", + attribute_type: "NONE", + inputs: [ + + ], + outputs: [ + "const-2" + ] + }, + { + op: "COND_IF", + attribute_type: "CondIfAttribute", + attribute: { + then_branch: "THEN_BLOCK", + else_branch: "ELSE_BLOCK" + }, + inputs: [ + "const-2", + "input-0", + "input-1" + ], + outputs: [ + "result-0" + ] + } + ], + tensors: [ + { + name: "input-0", + shape: [ + 10 + ], + type: "INT32" + }, + { + name: "input-1", + shape: [ + 10 + ], + type: "INT32" + }, + { + name: "const-2", + shape: [ + + ], + type: "BOOL", + data: [ + 0 + ] + }, + { + name: "result-0", + shape: [ + 10 + ], + type: "INT32" + } + ], + inputs: [ + "input-0", + "input-1" + ], + outputs: [ + "result-0" + ] + }, + { + name: "THEN_BLOCK", + operators: [ + { + op: "ADD", + attribute_type: "NONE", + inputs: [ + "input-0", + "input-1" + ], + outputs: [ + "result-1" + ] + } + ], + tensors: [ + { + name: "input-0", + shape: [ + 7 + ], + type: "INT32" + }, + { + name: "input-1", + shape: [ + 10 + ], + type: "INT32" + }, + { + name: "result-1", + shape: [ + 10 + ], + type: "INT32" + } + ], + inputs: [ + "input-0", + "input-1" + ], + outputs: [ + "result-1" + ] + }, + { + name: "ELSE_BLOCK", + operators: [ + { + op: "SUB", + attribute_type: "NONE", + inputs: [ + "input-0", + "input-1" + ], + outputs: [ + "result-2" + ] + } + ], + tensors: [ + { + name: "input-0", + shape: [ + 10 + ], + type: "INT32" + }, + { + name: "input-1", + shape: [ + 10 + ], + type: "INT32" + }, + { + name: "result-2", + shape: [ + 10 + ], + type: "INT32" + } + ], + inputs: [ + "input-0", + "input-1" + ], + outputs: [ + "result-2" + ] + } + ] +} |