diff options
Diffstat (limited to 'runtimes/tests/neural_networks_test/specs/V1_1')
54 files changed, 1114 insertions, 0 deletions
diff --git a/runtimes/tests/neural_networks_test/specs/V1_1/batch_to_space.mod.py b/runtimes/tests/neural_networks_test/specs/V1_1/batch_to_space.mod.py new file mode 100644 index 000000000..bf8f56ac5 --- /dev/null +++ b/runtimes/tests/neural_networks_test/specs/V1_1/batch_to_space.mod.py @@ -0,0 +1,16 @@ +model = Model() +i1 = Input("input", "TENSOR_FLOAT32", "{4, 1, 1, 2}") +block = Parameter("block_size", "TENSOR_INT32", "{2}", [2, 2]) +output = Output("output", "TENSOR_FLOAT32", "{1, 2, 2, 2}") + +model = model.Operation("BATCH_TO_SPACE_ND", i1, block).To(output) + +# Example 1. Input in operand 0, +input0 = {i1: # input 0 + [1.4, 2.3, 3.2, 4.1, 5.4, 6.3, 7.2, 8.1]} + +output0 = {output: # output 0 + [1.4, 2.3, 3.2, 4.1, 5.4, 6.3, 7.2, 8.1]} + +# Instantiate an example +Example((input0, output0)) diff --git a/runtimes/tests/neural_networks_test/specs/V1_1/batch_to_space_float_1.mod.py b/runtimes/tests/neural_networks_test/specs/V1_1/batch_to_space_float_1.mod.py new file mode 100644 index 000000000..019242a68 --- /dev/null +++ b/runtimes/tests/neural_networks_test/specs/V1_1/batch_to_space_float_1.mod.py @@ -0,0 +1,16 @@ +model = Model() +i1 = Input("input", "TENSOR_FLOAT32", "{4, 2, 2, 1}") +block = Parameter("block_size", "TENSOR_INT32", "{2}", [2, 2]) +output = Output("output", "TENSOR_FLOAT32", "{1, 4, 4, 1}") + +model = model.Operation("BATCH_TO_SPACE_ND", i1, block).To(output) + +# Example 1. Input in operand 0, +input0 = {i1: # input 0 + [1, 2, 3, 4, 5, 6, 7, 8, 9, 10, 11, 12, 13, 14, 15, 16]} + +output0 = {output: # output 0 + [1, 5, 2, 6, 9, 13, 10, 14, 3, 7, 4, 8, 11, 15, 12, 16]} + +# Instantiate an example +Example((input0, output0))
\ No newline at end of file diff --git a/runtimes/tests/neural_networks_test/specs/V1_1/batch_to_space_quant8_1.mod.py b/runtimes/tests/neural_networks_test/specs/V1_1/batch_to_space_quant8_1.mod.py new file mode 100644 index 000000000..8c6a72793 --- /dev/null +++ b/runtimes/tests/neural_networks_test/specs/V1_1/batch_to_space_quant8_1.mod.py @@ -0,0 +1,16 @@ +model = Model() +i1 = Input("input", "TENSOR_QUANT8_ASYMM", "{4, 2, 2, 1}, 1.0, 0") +block = Parameter("block_size", "TENSOR_INT32", "{2}", [2, 2]) +output = Output("output", "TENSOR_QUANT8_ASYMM", "{1, 4, 4, 1}, 1.0, 0") + +model = model.Operation("BATCH_TO_SPACE_ND", i1, block).To(output) + +# Example 1. Input in operand 0, +input0 = {i1: # input 0 + [1, 2, 3, 4, 5, 6, 7, 8, 9, 10, 11, 12, 13, 14, 15, 16]} + +output0 = {output: # output 0 + [1, 5, 2, 6, 9, 13, 10, 14, 3, 7, 4, 8, 11, 15, 12, 16]} + +# Instantiate an example +Example((input0, output0))
\ No newline at end of file diff --git a/runtimes/tests/neural_networks_test/specs/V1_1/div_.mod.py b/runtimes/tests/neural_networks_test/specs/V1_1/div_.mod.py new file mode 100644 index 000000000..e012f79f0 --- /dev/null +++ b/runtimes/tests/neural_networks_test/specs/V1_1/div_.mod.py @@ -0,0 +1,19 @@ +# model +model = Model() +i1 = Input("op1", "TENSOR_FLOAT32", "{1, 2, 2, 1}") +i2 = Input("op2", "TENSOR_FLOAT32", "{1, 2, 2, 1}") +act = Int32Scalar("act", 0) # an int32_t scalar fuse_activation +i3 = Output("op3", "TENSOR_FLOAT32", "{1, 2, 2, 1}") +model = model.Operation("DIV", i1, i2, act).To(i3) + +# Example 1. Input in operand 0, +input0 = {i1: # input 0 + [2.0, -4.0, 8.0, -16.0], + i2: # input 1 + [2.0, -2.0, -4.0, 4.0]} + +output0 = {i3: # output 0 + [1.0, 2.0, -2.0, -4.0]} + +# Instantiate an example +Example((input0, output0)) diff --git a/runtimes/tests/neural_networks_test/specs/V1_1/div_broadcast_float.mod.py b/runtimes/tests/neural_networks_test/specs/V1_1/div_broadcast_float.mod.py new file mode 100644 index 000000000..d4e0ea91d --- /dev/null +++ b/runtimes/tests/neural_networks_test/specs/V1_1/div_broadcast_float.mod.py @@ -0,0 +1,19 @@ +# model +model = Model() +i1 = Input("op1", "TENSOR_FLOAT32", "{1, 2}") +i2 = Input("op2", "TENSOR_FLOAT32", "{2, 2}") +act = Int32Scalar("act", 0) +i3 = Output("op3", "TENSOR_FLOAT32", "{2, 2}") +model = model.Operation("DIV", i1, i2, act).To(i3) + +# Example 1. Input in operand 0, +input0 = {i1: # input 0 + [1, 2], + i2: # input 1 + [1, 1, 2, 2]} + +output0 = {i3: # output 0 + [1, 2, 0.5, 1]} + +# Instantiate an example +Example((input0, output0)) diff --git a/runtimes/tests/neural_networks_test/specs/V1_1/fully_connected_float_4d_simple.mod.py b/runtimes/tests/neural_networks_test/specs/V1_1/fully_connected_float_4d_simple.mod.py new file mode 100644 index 000000000..b9a629025 --- /dev/null +++ b/runtimes/tests/neural_networks_test/specs/V1_1/fully_connected_float_4d_simple.mod.py @@ -0,0 +1,42 @@ +# +# Copyright (C) 2018 The Android Open Source Project +# +# Licensed under the Apache License, Version 2.0 (the "License"); +# you may not use this file except in compliance with the License. +# You may obtain a copy of the License at +# +# http://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. +# + +# This test is for testing the input requirements of Fully Connected Op: +# the input's first dimension doesn't have to be the batch size, the +# input is reshaped as needed. + +model = Model() +in0 = Input("op1", "TENSOR_FLOAT32", "{4, 1, 5, 1}") +weights = Parameter("op2", "TENSOR_FLOAT32", "{3, 10}", [ + 1, 2, 3, 4, 5, 6, 7, 8, 9, 10, # u = 0 + 1, 2, 3, 4, 5, 6, 7, 8, 9, 10, # u = 1 + 1, 2, 3, 4, 5, 6, 7, 8, 9, 10, # u = 1 +]) +bias = Parameter("b0", "TENSOR_FLOAT32", "{3}", [1, 2, 3]) +out0 = Output("op3", "TENSOR_FLOAT32", "{2, 3}") +act = Int32Scalar("act", 0) +model = model.Operation("FULLY_CONNECTED", in0, weights, bias, act).To(out0) + +# Example 1. Input in operand 0, +input0 = {in0: # input 0 + [1, 2, 3, 4, 5, 6, 7, 8, -9, -10, + 1, 2, 3, 4, 5, 6, 7, -8, 9, -10]} +output0 = {out0: # output 0 + [24, 25, 26, + 58, 59, 60]} + +# Instantiate an example +Example((input0, output0)) diff --git a/runtimes/tests/neural_networks_test/specs/V1_1/mean.mod.py b/runtimes/tests/neural_networks_test/specs/V1_1/mean.mod.py new file mode 100644 index 000000000..28bd6af03 --- /dev/null +++ b/runtimes/tests/neural_networks_test/specs/V1_1/mean.mod.py @@ -0,0 +1,19 @@ +model = Model() +i1 = Input("input", "TENSOR_FLOAT32", "{1, 2, 2, 1}") +axis = Parameter("axis", "TENSOR_INT32", "{1}", [2]) +keepDims = Int32Scalar("keepDims", 0) +output = Output("output", "TENSOR_FLOAT32", "{1, 2, 1}") + +model = model.Operation("MEAN", i1, axis, keepDims).To(output) + +# Example 1. Input in operand 0, +input0 = {i1: # input 0 + [1.0, 2.0, + 3.0, 4.0]} + +output0 = {output: # output 0 + [1.5, + 3.5]} + +# Instantiate an example +Example((input0, output0)) diff --git a/runtimes/tests/neural_networks_test/specs/V1_1/mean_axis01_1_nnfw.mod.py b/runtimes/tests/neural_networks_test/specs/V1_1/mean_axis01_1_nnfw.mod.py new file mode 100644 index 000000000..00b63a59c --- /dev/null +++ b/runtimes/tests/neural_networks_test/specs/V1_1/mean_axis01_1_nnfw.mod.py @@ -0,0 +1,18 @@ +model = Model() +i1 = Input("input", "TENSOR_FLOAT32", "{1, 4, 3, 2}") +axis = Parameter("axis", "TENSOR_INT32", "{2}", [1, 2]) +keepDims = Int32Scalar("keepDims", 1) +output = Output("output", "TENSOR_FLOAT32", "{1, 1, 1, 2}") + +model = model.Operation("MEAN", i1, axis, keepDims).To(output) + +# Example 1. Input in operand 0, +input0 = {i1: # input 0 + [1.0, 1.0, 1.0, 1.0, 1.0, 1.0, 1.0, 1.0, 1.0, 1.0, 1.0, 1.0, + 1.0, 1.0, 1.0, 1.0, 1.0, 1.0, 1.0, 1.0, 1.0, 1.0, 1.0, 1.0]} + +output0 = {output: # output 0 + [1.0, 1.0]} + +# Instantiate an example +Example((input0, output0)) diff --git a/runtimes/tests/neural_networks_test/specs/V1_1/mean_axis01_2_nnfw.mod.py b/runtimes/tests/neural_networks_test/specs/V1_1/mean_axis01_2_nnfw.mod.py new file mode 100644 index 000000000..1f0eb9c00 --- /dev/null +++ b/runtimes/tests/neural_networks_test/specs/V1_1/mean_axis01_2_nnfw.mod.py @@ -0,0 +1,17 @@ +model = Model() +i1 = Input("input", "TENSOR_FLOAT32", "{1, 4, 3, 2}") +axis = Parameter("axis", "TENSOR_INT32", "{4}", [1, 2, -3, -3]) +keepDims = Int32Scalar("keepDims", 1) +output = Output("output", "TENSOR_FLOAT32", "{1, 1, 1, 2}") +model = model.Operation("MEAN", i1, axis, keepDims).To(output) + +# Example 1. Input in operand 0, +input0 = {i1: # input 0 + [1.0, 2.0, 3.0, 4.0, 5.0, 6.0, 7.0, 8.0, 9.0, 10.0, 11.0, 12.0, + 13.0, 14.0, 15.0, 16.0, 17.0, 18.0, 19.0, 20.0, 21.0, 22.0, 23.0, 24.0]} + +output0 = {output: # output 0 + [12.0, 13.0]} + +# Instantiate an example +Example((input0, output0)) diff --git a/runtimes/tests/neural_networks_test/specs/V1_1/mean_float_1.mod.py b/runtimes/tests/neural_networks_test/specs/V1_1/mean_float_1.mod.py new file mode 100644 index 000000000..5fde65d40 --- /dev/null +++ b/runtimes/tests/neural_networks_test/specs/V1_1/mean_float_1.mod.py @@ -0,0 +1,18 @@ +model = Model() +i1 = Input("input", "TENSOR_FLOAT32", "{4, 3, 2}") +axis = Parameter("axis", "TENSOR_INT32", "{4}", [1, 0, -3, -3]) +keepDims = Int32Scalar("keepDims", 0) +output = Output("output", "TENSOR_FLOAT32", "{2}") + +model = model.Operation("MEAN", i1, axis, keepDims).To(output) + +# Example 1. Input in operand 0, +input0 = {i1: # input 0 + [1.0, 2.0, 3.0, 4.0, 5.0, 6.0, 7.0, 8.0, 9.0, 10.0, 11.0, 12.0, + 13.0, 14.0, 15.0, 16.0, 17.0, 18.0, 19.0, 20.0, 21.0, 22.0, 23.0, 24.0]} + +output0 = {output: # output 0 + [12.0, 13.0]} + +# Instantiate an example +Example((input0, output0)) diff --git a/runtimes/tests/neural_networks_test/specs/V1_1/mean_float_2.mod.py b/runtimes/tests/neural_networks_test/specs/V1_1/mean_float_2.mod.py new file mode 100644 index 000000000..4b71d472a --- /dev/null +++ b/runtimes/tests/neural_networks_test/specs/V1_1/mean_float_2.mod.py @@ -0,0 +1,18 @@ +model = Model() +i1 = Input("input", "TENSOR_FLOAT32", "{4, 3, 2}") +axis = Parameter("axis", "TENSOR_INT32", "{2}", [0, 2]) +keepDims = Int32Scalar("keepDims", 1) +output = Output("output", "TENSOR_FLOAT32", "{1, 3, 1}") + +model = model.Operation("MEAN", i1, axis, keepDims).To(output) + +# Example 1. Input in operand 0, +input0 = {i1: # input 0 + [1.0, 2.0, 3.0, 4.0, 5.0, 6.0, 7.0, 8.0, 9.0, 10.0, 11.0, 12.0, + 13.0, 14.0, 15.0, 16.0, 17.0, 18.0, 19.0, 20.0, 21.0, 22.0, 23.0, 24.0]} + +output0 = {output: # output 0 + [10.5, 12.5, 14.5]} + +# Instantiate an example +Example((input0, output0)) diff --git a/runtimes/tests/neural_networks_test/specs/V1_1/mean_quant8_1.mod.py b/runtimes/tests/neural_networks_test/specs/V1_1/mean_quant8_1.mod.py new file mode 100644 index 000000000..666b0c28f --- /dev/null +++ b/runtimes/tests/neural_networks_test/specs/V1_1/mean_quant8_1.mod.py @@ -0,0 +1,19 @@ +model = Model() +i1 = Input("input", "TENSOR_QUANT8_ASYMM", "{4, 3, 2}, 0.8, 5") +axis = Parameter("axis", "TENSOR_INT32", "{4}", [1, 0, -3, -3]) +keepDims = Int32Scalar("keepDims", 0) +output = Output("output", "TENSOR_QUANT8_ASYMM", "{2}, 0.8, 5") + +model = model.Operation("MEAN", i1, axis, keepDims).To(output) + +# Example 1. Input in operand 0, +input0 = {i1: # input 0 + [1, 2, 3, 4, 5, 6, 7, 8, + 9, 10, 11, 12, 13, 14, 15, 16, + 17, 18, 19, 20, 21, 22, 23, 24]} + +output0 = {output: # output 0 + [12, 13]} + +# Instantiate an example +Example((input0, output0)) diff --git a/runtimes/tests/neural_networks_test/specs/V1_1/mean_quant8_2.mod.py b/runtimes/tests/neural_networks_test/specs/V1_1/mean_quant8_2.mod.py new file mode 100644 index 000000000..23fd87c63 --- /dev/null +++ b/runtimes/tests/neural_networks_test/specs/V1_1/mean_quant8_2.mod.py @@ -0,0 +1,19 @@ +model = Model() +i1 = Input("input", "TENSOR_QUANT8_ASYMM", "{4, 3, 2}, 0.8, 5") +axis = Parameter("axis", "TENSOR_INT32", "{2}", [0, 2]) +keepDims = Int32Scalar("keepDims", 1) +output = Output("output", "TENSOR_QUANT8_ASYMM", "{1, 3, 1}, 0.8, 5") + +model = model.Operation("MEAN", i1, axis, keepDims).To(output) + +# Example 1. Input in operand 0, +input0 = {i1: # input 0 + [1, 2, 3, 4, 5, 6, 7, 8, + 9, 10, 11, 12, 13, 14, 15, 16, + 17, 18, 19, 20, 21, 22, 23, 24]} + +output0 = {output: # output 0 + [10, 12, 14]} + +# Instantiate an example +Example((input0, output0)) diff --git a/runtimes/tests/neural_networks_test/specs/V1_1/pad.mod.py b/runtimes/tests/neural_networks_test/specs/V1_1/pad.mod.py new file mode 100644 index 000000000..54a5a469d --- /dev/null +++ b/runtimes/tests/neural_networks_test/specs/V1_1/pad.mod.py @@ -0,0 +1,20 @@ +# model +model = Model() +i1 = Input("op1", "TENSOR_FLOAT32", "{1, 2, 2, 1}") +i2 = Parameter("op2", "TENSOR_INT32", "{4, 2}", [0, 0, 1, 1, 1, 1, 0, 0]) +i3 = Output("op3", "TENSOR_FLOAT32", "{1, 4, 4, 1}") +model = model.Operation("PAD", i1, i2).To(i3) + +# Example 1. Input in operand 0, +input0 = {i1: # input 0 + [1.0, 2.0, + 3.0, 4.0,]} + +output0 = {i3: # output 0 + [0.0, 0.0, 0.0, 0.0, + 0.0, 1.0, 2.0, 0.0, + 0.0, 3.0, 4.0, 0.0, + 0.0, 0.0, 0.0, 0.0]} + +# Instantiate an example +Example((input0, output0)) diff --git a/runtimes/tests/neural_networks_test/specs/V1_1/pad_float_1.mod.py b/runtimes/tests/neural_networks_test/specs/V1_1/pad_float_1.mod.py new file mode 100644 index 000000000..081712769 --- /dev/null +++ b/runtimes/tests/neural_networks_test/specs/V1_1/pad_float_1.mod.py @@ -0,0 +1,18 @@ +# model +model = Model() +i1 = Input("op1", "TENSOR_FLOAT32", "{1, 2, 3, 1}") +i2 = Parameter("op2", "TENSOR_INT32", "{4, 2}", [0, 0, 0, 2, 1, 3, 0, 0]) +i3 = Output("op3", "TENSOR_FLOAT32", "{1, 4, 7, 1}") +model = model.Operation("PAD", i1, i2).To(i3) + +# Example 1. Input in operand 0, +input0 = {i1: # input 0 + [1.0, 2.0, 3.0, + 4.0, 5.0, 6.0]} + +output0 = {i3: # output 0 + [0, 1, 2, 3, 0, 0, 0, 0, 4, 5, 6, 0, 0, 0, + 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0]} + +# Instantiate an example +Example((input0, output0)) diff --git a/runtimes/tests/neural_networks_test/specs/V1_1/space_to_batch.mod.py b/runtimes/tests/neural_networks_test/specs/V1_1/space_to_batch.mod.py new file mode 100644 index 000000000..8c10231f0 --- /dev/null +++ b/runtimes/tests/neural_networks_test/specs/V1_1/space_to_batch.mod.py @@ -0,0 +1,17 @@ +model = Model() +i1 = Input("input", "TENSOR_FLOAT32", "{1, 2, 2, 2}") +block = Parameter("block_size", "TENSOR_INT32", "{2}", [2, 2]) +paddings = Parameter("paddings", "TENSOR_INT32", "{2, 2}", [0, 0, 0, 0]) +output = Output("output", "TENSOR_FLOAT32", "{4, 1, 1, 2}") + +model = model.Operation("SPACE_TO_BATCH_ND", i1, block, paddings).To(output) + +# Example 1. Input in operand 0, +input0 = {i1: # input 0 + [1.4, 2.3, 3.2, 4.1, 5.4, 6.3, 7.2, 8.1]} + +output0 = {output: # output 0 + [1.4, 2.3, 3.2, 4.1, 5.4, 6.3, 7.2, 8.1]} + +# Instantiate an example +Example((input0, output0)) diff --git a/runtimes/tests/neural_networks_test/specs/V1_1/space_to_batch_float_1.mod.py b/runtimes/tests/neural_networks_test/specs/V1_1/space_to_batch_float_1.mod.py new file mode 100644 index 000000000..890ced869 --- /dev/null +++ b/runtimes/tests/neural_networks_test/specs/V1_1/space_to_batch_float_1.mod.py @@ -0,0 +1,17 @@ +model = Model() +i1 = Input("input", "TENSOR_FLOAT32", "{1, 4, 4, 1}") +block = Parameter("block_size", "TENSOR_INT32", "{2}", [2, 2]) +paddings = Parameter("paddings", "TENSOR_INT32", "{2, 2}", [0, 0, 0, 0]) +output = Output("output", "TENSOR_FLOAT32", "{4, 2, 2, 1}") + +model = model.Operation("SPACE_TO_BATCH_ND", i1, block, paddings).To(output) + +# Example 1. Input in operand 0, +input0 = {i1: # input 0 + [1, 2, 3, 4, 5, 6, 7, 8, 9, 10, 11, 12, 13, 14, 15, 16]} + +output0 = {output: # output 0 + [1, 3, 9, 11, 2, 4, 10, 12, 5, 7, 13, 15, 6, 8, 14, 16]} + +# Instantiate an example +Example((input0, output0)) diff --git a/runtimes/tests/neural_networks_test/specs/V1_1/space_to_batch_float_2.mod.py b/runtimes/tests/neural_networks_test/specs/V1_1/space_to_batch_float_2.mod.py new file mode 100644 index 000000000..c6259005a --- /dev/null +++ b/runtimes/tests/neural_networks_test/specs/V1_1/space_to_batch_float_2.mod.py @@ -0,0 +1,18 @@ +model = Model() +i1 = Input("input", "TENSOR_FLOAT32", "{1, 5, 2, 1}") +block = Parameter("block_size", "TENSOR_INT32", "{2}", [3, 2]) +paddings = Parameter("paddings", "TENSOR_INT32", "{2, 2}", [1, 0, 2, 0]) +output = Output("output", "TENSOR_FLOAT32", "{6, 2, 2, 1}") + +model = model.Operation("SPACE_TO_BATCH_ND", i1, block, paddings).To(output) + +# Example 1. Input in operand 0, +input0 = {i1: # input 0 + [1, 2, 3, 4, 5, 6, 7, 8, 9, 10]} + +output0 = {output: # output 0 + [0, 0, 0, 5, 0, 0, 0, 6, 0, 1, 0, 7, + 0, 2, 0, 8, 0, 3, 0, 9, 0, 4, 0, 10]} + +# Instantiate an example +Example((input0, output0)) diff --git a/runtimes/tests/neural_networks_test/specs/V1_1/space_to_batch_float_3.mod.py b/runtimes/tests/neural_networks_test/specs/V1_1/space_to_batch_float_3.mod.py new file mode 100644 index 000000000..9d7c8b313 --- /dev/null +++ b/runtimes/tests/neural_networks_test/specs/V1_1/space_to_batch_float_3.mod.py @@ -0,0 +1,19 @@ +model = Model() +i1 = Input("input", "TENSOR_FLOAT32", "{1, 4, 2, 1}") +block = Parameter("block_size", "TENSOR_INT32", "{2}", [3, 2]) +paddings = Parameter("paddings", "TENSOR_INT32", "{2, 2}", [1, 1, 2, 4]) +output = Output("output", "TENSOR_FLOAT32", "{6, 2, 4, 1}") + +model = model.Operation("SPACE_TO_BATCH_ND", i1, block, paddings).To(output) + +# Example 1. Input in operand 0, +input0 = {i1: # input 0 + [1, 2, 3, 4, 5, 6, 7, 8]} + +output0 = {output: # output 0 + [0, 0, 0, 0, 0, 5, 0, 0, 0, 0, 0, 0, 0, 6, 0, 0, + 0, 1, 0, 0, 0, 7, 0, 0, 0, 2, 0, 0, 0, 8, 0, 0, + 0, 3, 0, 0, 0, 0, 0, 0, 0, 4, 0, 0, 0, 0, 0, 0]} + +# Instantiate an example +Example((input0, output0)) diff --git a/runtimes/tests/neural_networks_test/specs/V1_1/space_to_batch_quant8_1.mod.py b/runtimes/tests/neural_networks_test/specs/V1_1/space_to_batch_quant8_1.mod.py new file mode 100644 index 000000000..726250d3f --- /dev/null +++ b/runtimes/tests/neural_networks_test/specs/V1_1/space_to_batch_quant8_1.mod.py @@ -0,0 +1,17 @@ +model = Model() +i1 = Input("input", "TENSOR_QUANT8_ASYMM", "{1, 4, 4, 1}, 1.0, 0") +block = Parameter("block_size", "TENSOR_INT32", "{2}", [2, 2]) +paddings = Parameter("paddings", "TENSOR_INT32", "{2, 2}", [0, 0, 0, 0]) +output = Output("output", "TENSOR_QUANT8_ASYMM", "{4, 2, 2, 1}, 1.0, 0") + +model = model.Operation("SPACE_TO_BATCH_ND", i1, block, paddings).To(output) + +# Example 1. Input in operand 0, +input0 = {i1: # input 0 + [1, 2, 3, 4, 5, 6, 7, 8, 9, 10, 11, 12, 13, 14, 15, 16]} + +output0 = {output: # output 0 + [1, 3, 9, 11, 2, 4, 10, 12, 5, 7, 13, 15, 6, 8, 14, 16]} + +# Instantiate an example +Example((input0, output0)) diff --git a/runtimes/tests/neural_networks_test/specs/V1_1/space_to_batch_quant8_2.mod.py b/runtimes/tests/neural_networks_test/specs/V1_1/space_to_batch_quant8_2.mod.py new file mode 100644 index 000000000..8adc2623a --- /dev/null +++ b/runtimes/tests/neural_networks_test/specs/V1_1/space_to_batch_quant8_2.mod.py @@ -0,0 +1,18 @@ +model = Model() +i1 = Input("input", "TENSOR_QUANT8_ASYMM", "{1, 5, 2, 1}, 1.0, 0") +block = Parameter("block_size", "TENSOR_INT32", "{2}", [3, 2]) +paddings = Parameter("paddings", "TENSOR_INT32", "{2, 2}", [1, 0, 2, 0]) +output = Output("output", "TENSOR_QUANT8_ASYMM", "{6, 2, 2, 1}, 1.0, 0") + +model = model.Operation("SPACE_TO_BATCH_ND", i1, block, paddings).To(output) + +# Example 1. Input in operand 0, +input0 = {i1: # input 0 + [1, 2, 3, 4, 5, 6, 7, 8, 9, 10]} + +output0 = {output: # output 0 + [0, 0, 0, 5, 0, 0, 0, 6, 0, 1, 0, 7, + 0, 2, 0, 8, 0, 3, 0, 9, 0, 4, 0, 10]} + +# Instantiate an example +Example((input0, output0)) diff --git a/runtimes/tests/neural_networks_test/specs/V1_1/space_to_batch_quant8_3.mod.py b/runtimes/tests/neural_networks_test/specs/V1_1/space_to_batch_quant8_3.mod.py new file mode 100644 index 000000000..e9e88bbd6 --- /dev/null +++ b/runtimes/tests/neural_networks_test/specs/V1_1/space_to_batch_quant8_3.mod.py @@ -0,0 +1,19 @@ +model = Model() +i1 = Input("input", "TENSOR_QUANT8_ASYMM", "{1, 4, 2, 1}, 1.0, 0") +block = Parameter("block_size", "TENSOR_INT32", "{2}", [3, 2]) +paddings = Parameter("paddings", "TENSOR_INT32", "{2, 2}", [1, 1, 2, 4]) +output = Output("output", "TENSOR_QUANT8_ASYMM", "{6, 2, 4, 1}, 1.0, 0") + +model = model.Operation("SPACE_TO_BATCH_ND", i1, block, paddings).To(output) + +# Example 1. Input in operand 0, +input0 = {i1: # input 0 + [1, 2, 3, 4, 5, 6, 7, 8]} + +output0 = {output: # output 0 + [0, 0, 0, 0, 0, 5, 0, 0, 0, 0, 0, 0, 0, 6, 0, 0, + 0, 1, 0, 0, 0, 7, 0, 0, 0, 2, 0, 0, 0, 8, 0, 0, + 0, 3, 0, 0, 0, 0, 0, 0, 0, 4, 0, 0, 0, 0, 0, 0]} + +# Instantiate an example +Example((input0, output0)) diff --git a/runtimes/tests/neural_networks_test/specs/V1_1/squeeze.mod.py b/runtimes/tests/neural_networks_test/specs/V1_1/squeeze.mod.py new file mode 100644 index 000000000..4bf3189fa --- /dev/null +++ b/runtimes/tests/neural_networks_test/specs/V1_1/squeeze.mod.py @@ -0,0 +1,16 @@ +model = Model() +i1 = Input("input", "TENSOR_FLOAT32", "{4, 1, 1, 2}") +squeezeDims = Parameter("squeezeDims", "TENSOR_INT32", "{2}", [1, 2]) +output = Output("output", "TENSOR_FLOAT32", "{4, 2}") + +model = model.Operation("SQUEEZE", i1, squeezeDims).To(output) + +# Example 1. Input in operand 0, +input0 = {i1: # input 0 + [1.4, 2.3, 3.2, 4.1, 5.4, 6.3, 7.2, 8.1]} + +output0 = {output: # output 0 + [1.4, 2.3, 3.2, 4.1, 5.4, 6.3, 7.2, 8.1]} + +# Instantiate an example +Example((input0, output0)) diff --git a/runtimes/tests/neural_networks_test/specs/V1_1/squeeze_2D_float_1_nnfw.mod.py b/runtimes/tests/neural_networks_test/specs/V1_1/squeeze_2D_float_1_nnfw.mod.py new file mode 100644 index 000000000..8397902e3 --- /dev/null +++ b/runtimes/tests/neural_networks_test/specs/V1_1/squeeze_2D_float_1_nnfw.mod.py @@ -0,0 +1,16 @@ +model = Model() +i1 = Input("input", "TENSOR_FLOAT32", "{4, 1}") +squeezeDims = Parameter("squeezeDims", "TENSOR_INT32", "{1}", [1]) +output = Output("output", "TENSOR_FLOAT32", "{4}") + +model = model.Operation("SQUEEZE", i1, squeezeDims).To(output) + +# Example 1. Input in operand 0, +input0 = {i1: # input 0 + [1.4, 2.3, 3.2, 4.1]} + +output0 = {output: # output 0 + [1.4, 2.3, 3.2, 4.1]} + +# Instantiate an example +Example((input0, output0)) diff --git a/runtimes/tests/neural_networks_test/specs/V1_1/squeeze_float_1.mod.py b/runtimes/tests/neural_networks_test/specs/V1_1/squeeze_float_1.mod.py new file mode 100644 index 000000000..1a54ae7a1 --- /dev/null +++ b/runtimes/tests/neural_networks_test/specs/V1_1/squeeze_float_1.mod.py @@ -0,0 +1,18 @@ +model = Model() +i1 = Input("input", "TENSOR_FLOAT32", "{1, 24, 1}") +squeezeDims = Parameter("squeezeDims", "TENSOR_INT32", "{1}", [2]) +output = Output("output", "TENSOR_FLOAT32", "{1, 24}") + +model = model.Operation("SQUEEZE", i1, squeezeDims).To(output) + +# Example 1. Input in operand 0, +input0 = {i1: # input 0 + [1, 2, 3, 4, 5, 6, 7, 8, 9, 10, 11, 12, + 13, 14, 15, 16, 17, 18, 19, 20, 21, 22, 23, 24]} + +output0 = {output: # output 0 + [1, 2, 3, 4, 5, 6, 7, 8, 9, 10, 11, 12, + 13, 14, 15, 16, 17, 18, 19, 20, 21, 22, 23, 24]} + +# Instantiate an example +Example((input0, output0)) diff --git a/runtimes/tests/neural_networks_test/specs/V1_1/squeeze_quant8_1.mod.py b/runtimes/tests/neural_networks_test/specs/V1_1/squeeze_quant8_1.mod.py new file mode 100644 index 000000000..5710c1d9a --- /dev/null +++ b/runtimes/tests/neural_networks_test/specs/V1_1/squeeze_quant8_1.mod.py @@ -0,0 +1,18 @@ +model = Model() +i1 = Input("input", "TENSOR_QUANT8_ASYMM", "{1, 24, 1}, 1.0, 0") +squeezeDims = Parameter("squeezeDims", "TENSOR_INT32", "{1}", [2]) +output = Output("output", "TENSOR_QUANT8_ASYMM", "{1, 24}, 1.0, 0") + +model = model.Operation("SQUEEZE", i1, squeezeDims).To(output) + +# Example 1. Input in operand 0, +input0 = {i1: # input 0 + [1, 2, 3, 4, 5, 6, 7, 8, 9, 10, 11, 12, + 13, 14, 15, 16, 17, 18, 19, 20, 21, 22, 23, 24]} + +output0 = {output: # output 0 + [1, 2, 3, 4, 5, 6, 7, 8, 9, 10, 11, 12, + 13, 14, 15, 16, 17, 18, 19, 20, 21, 22, 23, 24]} + +# Instantiate an example +Example((input0, output0)) diff --git a/runtimes/tests/neural_networks_test/specs/V1_1/strided_slice.mod.py b/runtimes/tests/neural_networks_test/specs/V1_1/strided_slice.mod.py new file mode 100644 index 000000000..9bc94d110 --- /dev/null +++ b/runtimes/tests/neural_networks_test/specs/V1_1/strided_slice.mod.py @@ -0,0 +1,23 @@ +model = Model() +i1 = Input("input", "TENSOR_FLOAT32", "{2, 3}") +begins = Parameter("begins", "TENSOR_INT32", "{2}", [0, 0]) +ends = Parameter("ends", "TENSOR_INT32", "{2}", [2, 3]) +strides = Parameter("strides", "TENSOR_INT32", "{2}", [2, 2]) +beginMask = Int32Scalar("beginMask", 0) +endMask = Int32Scalar("endMask", 0) +shrinkAxisMask = Int32Scalar("shrinkAxisMask", 0) + +output = Output("output", "TENSOR_FLOAT32", "{1, 2}") + +model = model.Operation("STRIDED_SLICE", i1, begins, ends, strides, beginMask, endMask, shrinkAxisMask).To(output) + +# Example 1. Input in operand 0, +input0 = {i1: # input 0 + [1.0, 2.0, 3.0, + 4.0, 5.0, 6.0]} + +output0 = {output: # output 0 + [1.0, 3.0]} + +# Instantiate an example +Example((input0, output0)) diff --git a/runtimes/tests/neural_networks_test/specs/V1_1/strided_slice_float_1.mod.py b/runtimes/tests/neural_networks_test/specs/V1_1/strided_slice_float_1.mod.py new file mode 100644 index 000000000..0725cff30 --- /dev/null +++ b/runtimes/tests/neural_networks_test/specs/V1_1/strided_slice_float_1.mod.py @@ -0,0 +1,22 @@ +model = Model() +i1 = Input("input", "TENSOR_FLOAT32", "{4}") +begins = Parameter("begins", "TENSOR_INT32", "{1}", [1]) +ends = Parameter("ends", "TENSOR_INT32", "{1}", [3]) +strides = Parameter("strides", "TENSOR_INT32", "{1}", [1]) +beginMask = Int32Scalar("beginMask", 0) +endMask = Int32Scalar("endMask", 0) +shrinkAxisMask = Int32Scalar("shrinkAxisMask", 0) + +output = Output("output", "TENSOR_FLOAT32", "{2}") + +model = model.Operation("STRIDED_SLICE", i1, begins, ends, strides, beginMask, endMask, shrinkAxisMask).To(output) + +# Example 1. Input in operand 0, +input0 = {i1: # input 0 + [1, 2, 3, 4]} + +output0 = {output: # output 0 + [2, 3]} + +# Instantiate an example +Example((input0, output0)) diff --git a/runtimes/tests/neural_networks_test/specs/V1_1/strided_slice_float_10.mod.py b/runtimes/tests/neural_networks_test/specs/V1_1/strided_slice_float_10.mod.py new file mode 100644 index 000000000..178421f53 --- /dev/null +++ b/runtimes/tests/neural_networks_test/specs/V1_1/strided_slice_float_10.mod.py @@ -0,0 +1,22 @@ +model = Model() +i1 = Input("input", "TENSOR_FLOAT32", "{2, 3}") +begins = Parameter("begins", "TENSOR_INT32", "{2}", [1, 0]) +ends = Parameter("ends", "TENSOR_INT32", "{2}", [2, 2]) +strides = Parameter("strides", "TENSOR_INT32", "{2}", [1, 1]) +beginMask = Int32Scalar("beginMask", 0) +endMask = Int32Scalar("endMask", 2) +shrinkAxisMask = Int32Scalar("shrinkAxisMask", 0) + +output = Output("output", "TENSOR_FLOAT32", "{1, 3}") + +model = model.Operation("STRIDED_SLICE", i1, begins, ends, strides, beginMask, endMask, shrinkAxisMask).To(output) + +# Example 1. Input in operand 0, +input0 = {i1: # input 0 + [1, 2, 3, 4, 5, 6]} + +output0 = {output: # output 0 + [4, 5, 6]} + +# Instantiate an example +Example((input0, output0)) diff --git a/runtimes/tests/neural_networks_test/specs/V1_1/strided_slice_float_11.mod.py b/runtimes/tests/neural_networks_test/specs/V1_1/strided_slice_float_11.mod.py new file mode 100644 index 000000000..444ae63b6 --- /dev/null +++ b/runtimes/tests/neural_networks_test/specs/V1_1/strided_slice_float_11.mod.py @@ -0,0 +1,22 @@ +model = Model() +i1 = Input("input", "TENSOR_FLOAT32", "{2, 3}") +begins = Parameter("begins", "TENSOR_INT32", "{2}", [0, 0]) +ends = Parameter("ends", "TENSOR_INT32", "{2}", [1, 3]) +strides = Parameter("strides", "TENSOR_INT32", "{2}", [1, 1]) +beginMask = Int32Scalar("beginMask", 0) +endMask = Int32Scalar("endMask", 0) +shrinkAxisMask = Int32Scalar("shrinkAxisMask", 1) + +output = Output("output", "TENSOR_FLOAT32", "{3}") + +model = model.Operation("STRIDED_SLICE", i1, begins, ends, strides, beginMask, endMask, shrinkAxisMask).To(output) + +# Example 1. Input in operand 0, +input0 = {i1: # input 0 + [1, 2, 3, 4, 5, 6]} + +output0 = {output: # output 0 + [1, 2, 3]} + +# Instantiate an example +Example((input0, output0)) diff --git a/runtimes/tests/neural_networks_test/specs/V1_1/strided_slice_float_2.mod.py b/runtimes/tests/neural_networks_test/specs/V1_1/strided_slice_float_2.mod.py new file mode 100644 index 000000000..7dd3d8399 --- /dev/null +++ b/runtimes/tests/neural_networks_test/specs/V1_1/strided_slice_float_2.mod.py @@ -0,0 +1,22 @@ +model = Model() +i1 = Input("input", "TENSOR_FLOAT32", "{4}") +begins = Parameter("begins", "TENSOR_INT32", "{1}", [-3]) +ends = Parameter("ends", "TENSOR_INT32", "{1}", [3]) +strides = Parameter("strides", "TENSOR_INT32", "{1}", [1]) +beginMask = Int32Scalar("beginMask", 0) +endMask = Int32Scalar("endMask", 0) +shrinkAxisMask = Int32Scalar("shrinkAxisMask", 0) + +output = Output("output", "TENSOR_FLOAT32", "{2}") + +model = model.Operation("STRIDED_SLICE", i1, begins, ends, strides, beginMask, endMask, shrinkAxisMask).To(output) + +# Example 1. Input in operand 0, +input0 = {i1: # input 0 + [1, 2, 3, 4]} + +output0 = {output: # output 0 + [2, 3]} + +# Instantiate an example +Example((input0, output0)) diff --git a/runtimes/tests/neural_networks_test/specs/V1_1/strided_slice_float_3.mod.py b/runtimes/tests/neural_networks_test/specs/V1_1/strided_slice_float_3.mod.py new file mode 100644 index 000000000..e476bca08 --- /dev/null +++ b/runtimes/tests/neural_networks_test/specs/V1_1/strided_slice_float_3.mod.py @@ -0,0 +1,22 @@ +model = Model() +i1 = Input("input", "TENSOR_FLOAT32", "{4}") +begins = Parameter("begins", "TENSOR_INT32", "{1}", [-5]) +ends = Parameter("ends", "TENSOR_INT32", "{1}", [3]) +strides = Parameter("strides", "TENSOR_INT32", "{1}", [1]) +beginMask = Int32Scalar("beginMask", 0) +endMask = Int32Scalar("endMask", 0) +shrinkAxisMask = Int32Scalar("shrinkAxisMask", 0) + +output = Output("output", "TENSOR_FLOAT32", "{3}") + +model = model.Operation("STRIDED_SLICE", i1, begins, ends, strides, beginMask, endMask, shrinkAxisMask).To(output) + +# Example 1. Input in operand 0, +input0 = {i1: # input 0 + [1, 2, 3, 4]} + +output0 = {output: # output 0 + [1, 2, 3]} + +# Instantiate an example +Example((input0, output0)) diff --git a/runtimes/tests/neural_networks_test/specs/V1_1/strided_slice_float_4.mod.py b/runtimes/tests/neural_networks_test/specs/V1_1/strided_slice_float_4.mod.py new file mode 100644 index 000000000..939cc1457 --- /dev/null +++ b/runtimes/tests/neural_networks_test/specs/V1_1/strided_slice_float_4.mod.py @@ -0,0 +1,22 @@ +model = Model() +i1 = Input("input", "TENSOR_FLOAT32", "{4}") +begins = Parameter("begins", "TENSOR_INT32", "{1}", [1]) +ends = Parameter("ends", "TENSOR_INT32", "{1}", [-2]) +strides = Parameter("strides", "TENSOR_INT32", "{1}", [1]) +beginMask = Int32Scalar("beginMask", 0) +endMask = Int32Scalar("endMask", 0) +shrinkAxisMask = Int32Scalar("shrinkAxisMask", 0) + +output = Output("output", "TENSOR_FLOAT32", "{1}") + +model = model.Operation("STRIDED_SLICE", i1, begins, ends, strides, beginMask, endMask, shrinkAxisMask).To(output) + +# Example 1. Input in operand 0, +input0 = {i1: # input 0 + [1, 2, 3, 4]} + +output0 = {output: # output 0 + [2]} + +# Instantiate an example +Example((input0, output0)) diff --git a/runtimes/tests/neural_networks_test/specs/V1_1/strided_slice_float_5.mod.py b/runtimes/tests/neural_networks_test/specs/V1_1/strided_slice_float_5.mod.py new file mode 100644 index 000000000..db7372708 --- /dev/null +++ b/runtimes/tests/neural_networks_test/specs/V1_1/strided_slice_float_5.mod.py @@ -0,0 +1,22 @@ +model = Model() +i1 = Input("input", "TENSOR_FLOAT32", "{4}") +begins = Parameter("begins", "TENSOR_INT32", "{1}", [1]) +ends = Parameter("ends", "TENSOR_INT32", "{1}", [3]) +strides = Parameter("strides", "TENSOR_INT32", "{1}", [1]) +beginMask = Int32Scalar("beginMask", 1) +endMask = Int32Scalar("endMask", 0) +shrinkAxisMask = Int32Scalar("shrinkAxisMask", 0) + +output = Output("output", "TENSOR_FLOAT32", "{3}") + +model = model.Operation("STRIDED_SLICE", i1, begins, ends, strides, beginMask, endMask, shrinkAxisMask).To(output) + +# Example 1. Input in operand 0, +input0 = {i1: # input 0 + [1, 2, 3, 4]} + +output0 = {output: # output 0 + [1, 2, 3]} + +# Instantiate an example +Example((input0, output0)) diff --git a/runtimes/tests/neural_networks_test/specs/V1_1/strided_slice_float_6.mod.py b/runtimes/tests/neural_networks_test/specs/V1_1/strided_slice_float_6.mod.py new file mode 100644 index 000000000..c8d42d95a --- /dev/null +++ b/runtimes/tests/neural_networks_test/specs/V1_1/strided_slice_float_6.mod.py @@ -0,0 +1,22 @@ +model = Model() +i1 = Input("input", "TENSOR_FLOAT32", "{4}") +begins = Parameter("begins", "TENSOR_INT32", "{1}", [1]) +ends = Parameter("ends", "TENSOR_INT32", "{1}", [3]) +strides = Parameter("strides", "TENSOR_INT32", "{1}", [1]) +beginMask = Int32Scalar("beginMask", 0) +endMask = Int32Scalar("endMask", 1) +shrinkAxisMask = Int32Scalar("shrinkAxisMask", 0) + +output = Output("output", "TENSOR_FLOAT32", "{3}") + +model = model.Operation("STRIDED_SLICE", i1, begins, ends, strides, beginMask, endMask, shrinkAxisMask).To(output) + +# Example 1. Input in operand 0, +input0 = {i1: # input 0 + [1, 2, 3, 4]} + +output0 = {output: # output 0 + [2, 3, 4]} + +# Instantiate an example +Example((input0, output0)) diff --git a/runtimes/tests/neural_networks_test/specs/V1_1/strided_slice_float_7.mod.py b/runtimes/tests/neural_networks_test/specs/V1_1/strided_slice_float_7.mod.py new file mode 100644 index 000000000..668748a91 --- /dev/null +++ b/runtimes/tests/neural_networks_test/specs/V1_1/strided_slice_float_7.mod.py @@ -0,0 +1,22 @@ +model = Model() +i1 = Input("input", "TENSOR_FLOAT32", "{3}") +begins = Parameter("begins", "TENSOR_INT32", "{1}", [-1]) +ends = Parameter("ends", "TENSOR_INT32", "{1}", [-4]) +strides = Parameter("strides", "TENSOR_INT32", "{1}", [-1]) +beginMask = Int32Scalar("beginMask", 0) +endMask = Int32Scalar("endMask", 0) +shrinkAxisMask = Int32Scalar("shrinkAxisMask", 0) + +output = Output("output", "TENSOR_FLOAT32", "{3}") + +model = model.Operation("STRIDED_SLICE", i1, begins, ends, strides, beginMask, endMask, shrinkAxisMask).To(output) + +# Example 1. Input in operand 0, +input0 = {i1: # input 0 + [1, 2, 3]} + +output0 = {output: # output 0 + [3, 2, 1]} + +# Instantiate an example +Example((input0, output0)) diff --git a/runtimes/tests/neural_networks_test/specs/V1_1/strided_slice_float_8.mod.py b/runtimes/tests/neural_networks_test/specs/V1_1/strided_slice_float_8.mod.py new file mode 100644 index 000000000..2c1cc9416 --- /dev/null +++ b/runtimes/tests/neural_networks_test/specs/V1_1/strided_slice_float_8.mod.py @@ -0,0 +1,22 @@ +model = Model() +i1 = Input("input", "TENSOR_FLOAT32", "{2, 3}") +begins = Parameter("begins", "TENSOR_INT32", "{2}", [1, -1]) +ends = Parameter("ends", "TENSOR_INT32", "{2}", [2, -4]) +strides = Parameter("strides", "TENSOR_INT32", "{2}", [2, -1]) +beginMask = Int32Scalar("beginMask", 0) +endMask = Int32Scalar("endMask", 0) +shrinkAxisMask = Int32Scalar("shrinkAxisMask", 0) + +output = Output("output", "TENSOR_FLOAT32", "{1, 3}") + +model = model.Operation("STRIDED_SLICE", i1, begins, ends, strides, beginMask, endMask, shrinkAxisMask).To(output) + +# Example 1. Input in operand 0, +input0 = {i1: # input 0 + [1, 2, 3, 4, 5, 6]} + +output0 = {output: # output 0 + [6, 5, 4]} + +# Instantiate an example +Example((input0, output0)) diff --git a/runtimes/tests/neural_networks_test/specs/V1_1/strided_slice_float_9.mod.py b/runtimes/tests/neural_networks_test/specs/V1_1/strided_slice_float_9.mod.py new file mode 100644 index 000000000..4bafd3da6 --- /dev/null +++ b/runtimes/tests/neural_networks_test/specs/V1_1/strided_slice_float_9.mod.py @@ -0,0 +1,22 @@ +model = Model() +i1 = Input("input", "TENSOR_FLOAT32", "{2, 3}") +begins = Parameter("begins", "TENSOR_INT32", "{2}", [1, 0]) +ends = Parameter("ends", "TENSOR_INT32", "{2}", [2, 2]) +strides = Parameter("strides", "TENSOR_INT32", "{2}", [1, 1]) +beginMask = Int32Scalar("beginMask", 1) +endMask = Int32Scalar("endMask", 0) +shrinkAxisMask = Int32Scalar("shrinkAxisMask", 0) + +output = Output("output", "TENSOR_FLOAT32", "{2, 2}") + +model = model.Operation("STRIDED_SLICE", i1, begins, ends, strides, beginMask, endMask, shrinkAxisMask).To(output) + +# Example 1. Input in operand 0, +input0 = {i1: # input 0 + [1, 2, 3, 4, 5, 6]} + +output0 = {output: # output 0 + [1, 2, 4, 5]} + +# Instantiate an example +Example((input0, output0)) diff --git a/runtimes/tests/neural_networks_test/specs/V1_1/strided_slice_qaunt8_10.mod.py b/runtimes/tests/neural_networks_test/specs/V1_1/strided_slice_qaunt8_10.mod.py new file mode 100644 index 000000000..fc29552ac --- /dev/null +++ b/runtimes/tests/neural_networks_test/specs/V1_1/strided_slice_qaunt8_10.mod.py @@ -0,0 +1,22 @@ +model = Model() +i1 = Input("input", "TENSOR_QUANT8_ASYMM", "{2, 3}, 1.0, 0") +begins = Parameter("begins", "TENSOR_INT32", "{2}", [1, 0]) +ends = Parameter("ends", "TENSOR_INT32", "{2}", [2, 2]) +strides = Parameter("strides", "TENSOR_INT32", "{2}", [1, 1]) +beginMask = Int32Scalar("beginMask", 0) +endMask = Int32Scalar("endMask", 2) +shrinkAxisMask = Int32Scalar("shrinkAxisMask", 0) + +output = Output("output", "TENSOR_QUANT8_ASYMM", "{1, 3}, 1.0, 0") + +model = model.Operation("STRIDED_SLICE", i1, begins, ends, strides, beginMask, endMask, shrinkAxisMask).To(output) + +# Example 1. Input in operand 0, +input0 = {i1: # input 0 + [1, 2, 3, 4, 5, 6]} + +output0 = {output: # output 0 + [4, 5, 6]} + +# Instantiate an example +Example((input0, output0)) diff --git a/runtimes/tests/neural_networks_test/specs/V1_1/strided_slice_qaunt8_11.mod.py b/runtimes/tests/neural_networks_test/specs/V1_1/strided_slice_qaunt8_11.mod.py new file mode 100644 index 000000000..d7374ab29 --- /dev/null +++ b/runtimes/tests/neural_networks_test/specs/V1_1/strided_slice_qaunt8_11.mod.py @@ -0,0 +1,22 @@ +model = Model() +i1 = Input("input", "TENSOR_QUANT8_ASYMM", "{2, 3}, 1.0, 0") +begins = Parameter("begins", "TENSOR_INT32", "{2}", [0, 0]) +ends = Parameter("ends", "TENSOR_INT32", "{2}", [1, 3]) +strides = Parameter("strides", "TENSOR_INT32", "{2}", [1, 1]) +beginMask = Int32Scalar("beginMask", 0) +endMask = Int32Scalar("endMask", 0) +shrinkAxisMask = Int32Scalar("shrinkAxisMask", 1) + +output = Output("output", "TENSOR_QUANT8_ASYMM", "{3}, 1.0, 0") + +model = model.Operation("STRIDED_SLICE", i1, begins, ends, strides, beginMask, endMask, shrinkAxisMask).To(output) + +# Example 1. Input in operand 0, +input0 = {i1: # input 0 + [1, 2, 3, 4, 5, 6]} + +output0 = {output: # output 0 + [1, 2, 3]} + +# Instantiate an example +Example((input0, output0)) diff --git a/runtimes/tests/neural_networks_test/specs/V1_1/strided_slice_quant8_1.mod.py b/runtimes/tests/neural_networks_test/specs/V1_1/strided_slice_quant8_1.mod.py new file mode 100644 index 000000000..4b76de27b --- /dev/null +++ b/runtimes/tests/neural_networks_test/specs/V1_1/strided_slice_quant8_1.mod.py @@ -0,0 +1,22 @@ +model = Model() +i1 = Input("input", "TENSOR_QUANT8_ASYMM", "{4}, 1.0, 0") +begins = Parameter("begins", "TENSOR_INT32", "{1}", [1]) +ends = Parameter("ends", "TENSOR_INT32", "{1}", [3]) +strides = Parameter("strides", "TENSOR_INT32", "{1}", [1]) +beginMask = Int32Scalar("beginMask", 0) +endMask = Int32Scalar("endMask", 0) +shrinkAxisMask = Int32Scalar("shrinkAxisMask", 0) + +output = Output("output", "TENSOR_QUANT8_ASYMM", "{2}, 1.0, 0") + +model = model.Operation("STRIDED_SLICE", i1, begins, ends, strides, beginMask, endMask, shrinkAxisMask).To(output) + +# Example 1. Input in operand 0, +input0 = {i1: # input 0 + [1, 2, 3, 4]} + +output0 = {output: # output 0 + [2, 3]} + +# Instantiate an example +Example((input0, output0)) diff --git a/runtimes/tests/neural_networks_test/specs/V1_1/strided_slice_quant8_2.mod.py b/runtimes/tests/neural_networks_test/specs/V1_1/strided_slice_quant8_2.mod.py new file mode 100644 index 000000000..d6cd6aa6f --- /dev/null +++ b/runtimes/tests/neural_networks_test/specs/V1_1/strided_slice_quant8_2.mod.py @@ -0,0 +1,22 @@ +model = Model() +i1 = Input("input", "TENSOR_QUANT8_ASYMM", "{4}, 1.0, 0") +begins = Parameter("begins", "TENSOR_INT32", "{1}", [-3]) +ends = Parameter("ends", "TENSOR_INT32", "{1}", [3]) +strides = Parameter("strides", "TENSOR_INT32", "{1}", [1]) +beginMask = Int32Scalar("beginMask", 0) +endMask = Int32Scalar("endMask", 0) +shrinkAxisMask = Int32Scalar("shrinkAxisMask", 0) + +output = Output("output", "TENSOR_QUANT8_ASYMM", "{2}, 1.0, 0") + +model = model.Operation("STRIDED_SLICE", i1, begins, ends, strides, beginMask, endMask, shrinkAxisMask).To(output) + +# Example 1. Input in operand 0, +input0 = {i1: # input 0 + [1, 2, 3, 4]} + +output0 = {output: # output 0 + [2, 3]} + +# Instantiate an example +Example((input0, output0)) diff --git a/runtimes/tests/neural_networks_test/specs/V1_1/strided_slice_quant8_3.mod.py b/runtimes/tests/neural_networks_test/specs/V1_1/strided_slice_quant8_3.mod.py new file mode 100644 index 000000000..411a6fa88 --- /dev/null +++ b/runtimes/tests/neural_networks_test/specs/V1_1/strided_slice_quant8_3.mod.py @@ -0,0 +1,22 @@ +model = Model() +i1 = Input("input", "TENSOR_QUANT8_ASYMM", "{4}, 1.0, 0") +begins = Parameter("begins", "TENSOR_INT32", "{1}", [-5]) +ends = Parameter("ends", "TENSOR_INT32", "{1}", [3]) +strides = Parameter("strides", "TENSOR_INT32", "{1}", [1]) +beginMask = Int32Scalar("beginMask", 0) +endMask = Int32Scalar("endMask", 0) +shrinkAxisMask = Int32Scalar("shrinkAxisMask", 0) + +output = Output("output", "TENSOR_QUANT8_ASYMM", "{3}, 1.0, 0") + +model = model.Operation("STRIDED_SLICE", i1, begins, ends, strides, beginMask, endMask, shrinkAxisMask).To(output) + +# Example 1. Input in operand 0, +input0 = {i1: # input 0 + [1, 2, 3, 4]} + +output0 = {output: # output 0 + [1, 2, 3]} + +# Instantiate an example +Example((input0, output0)) diff --git a/runtimes/tests/neural_networks_test/specs/V1_1/strided_slice_quant8_4.mod.py b/runtimes/tests/neural_networks_test/specs/V1_1/strided_slice_quant8_4.mod.py new file mode 100644 index 000000000..f8a54f29d --- /dev/null +++ b/runtimes/tests/neural_networks_test/specs/V1_1/strided_slice_quant8_4.mod.py @@ -0,0 +1,22 @@ +model = Model() +i1 = Input("input", "TENSOR_QUANT8_ASYMM", "{4}, 1.0, 0") +begins = Parameter("begins", "TENSOR_INT32", "{1}", [1]) +ends = Parameter("ends", "TENSOR_INT32", "{1}", [-2]) +strides = Parameter("strides", "TENSOR_INT32", "{1}", [1]) +beginMask = Int32Scalar("beginMask", 0) +endMask = Int32Scalar("endMask", 0) +shrinkAxisMask = Int32Scalar("shrinkAxisMask", 0) + +output = Output("output", "TENSOR_QUANT8_ASYMM", "{1}, 1.0, 0") + +model = model.Operation("STRIDED_SLICE", i1, begins, ends, strides, beginMask, endMask, shrinkAxisMask).To(output) + +# Example 1. Input in operand 0, +input0 = {i1: # input 0 + [1, 2, 3, 4]} + +output0 = {output: # output 0 + [2]} + +# Instantiate an example +Example((input0, output0)) diff --git a/runtimes/tests/neural_networks_test/specs/V1_1/strided_slice_quant8_5.mod.py b/runtimes/tests/neural_networks_test/specs/V1_1/strided_slice_quant8_5.mod.py new file mode 100644 index 000000000..4fa42f5f0 --- /dev/null +++ b/runtimes/tests/neural_networks_test/specs/V1_1/strided_slice_quant8_5.mod.py @@ -0,0 +1,22 @@ +model = Model() +i1 = Input("input", "TENSOR_QUANT8_ASYMM", "{4}, 1.0, 0") +begins = Parameter("begins", "TENSOR_INT32", "{1}", [1]) +ends = Parameter("ends", "TENSOR_INT32", "{1}", [3]) +strides = Parameter("strides", "TENSOR_INT32", "{1}", [1]) +beginMask = Int32Scalar("beginMask", 1) +endMask = Int32Scalar("endMask", 0) +shrinkAxisMask = Int32Scalar("shrinkAxisMask", 0) + +output = Output("output", "TENSOR_QUANT8_ASYMM", "{3}, 1.0, 0") + +model = model.Operation("STRIDED_SLICE", i1, begins, ends, strides, beginMask, endMask, shrinkAxisMask).To(output) + +# Example 1. Input in operand 0, +input0 = {i1: # input 0 + [1, 2, 3, 4]} + +output0 = {output: # output 0 + [1, 2, 3]} + +# Instantiate an example +Example((input0, output0)) diff --git a/runtimes/tests/neural_networks_test/specs/V1_1/strided_slice_quant8_6.mod.py b/runtimes/tests/neural_networks_test/specs/V1_1/strided_slice_quant8_6.mod.py new file mode 100644 index 000000000..bcd8841f0 --- /dev/null +++ b/runtimes/tests/neural_networks_test/specs/V1_1/strided_slice_quant8_6.mod.py @@ -0,0 +1,22 @@ +model = Model() +i1 = Input("input", "TENSOR_QUANT8_ASYMM", "{4}, 1.0, 0") +begins = Parameter("begins", "TENSOR_INT32", "{1}", [1]) +ends = Parameter("ends", "TENSOR_INT32", "{1}", [3]) +strides = Parameter("strides", "TENSOR_INT32", "{1}", [1]) +beginMask = Int32Scalar("beginMask", 0) +endMask = Int32Scalar("endMask", 1) +shrinkAxisMask = Int32Scalar("shrinkAxisMask", 0) + +output = Output("output", "TENSOR_QUANT8_ASYMM", "{3}, 1.0, 0") + +model = model.Operation("STRIDED_SLICE", i1, begins, ends, strides, beginMask, endMask, shrinkAxisMask).To(output) + +# Example 1. Input in operand 0, +input0 = {i1: # input 0 + [1, 2, 3, 4]} + +output0 = {output: # output 0 + [2, 3, 4]} + +# Instantiate an example +Example((input0, output0)) diff --git a/runtimes/tests/neural_networks_test/specs/V1_1/strided_slice_quant8_7.mod.py b/runtimes/tests/neural_networks_test/specs/V1_1/strided_slice_quant8_7.mod.py new file mode 100644 index 000000000..e1ae9db6b --- /dev/null +++ b/runtimes/tests/neural_networks_test/specs/V1_1/strided_slice_quant8_7.mod.py @@ -0,0 +1,22 @@ +model = Model() +i1 = Input("input", "TENSOR_QUANT8_ASYMM", "{3}, 1.0, 0") +begins = Parameter("begins", "TENSOR_INT32", "{1}", [-1]) +ends = Parameter("ends", "TENSOR_INT32", "{1}", [-4]) +strides = Parameter("strides", "TENSOR_INT32", "{1}", [-1]) +beginMask = Int32Scalar("beginMask", 0) +endMask = Int32Scalar("endMask", 0) +shrinkAxisMask = Int32Scalar("shrinkAxisMask", 0) + +output = Output("output", "TENSOR_QUANT8_ASYMM", "{3}, 1.0, 0") + +model = model.Operation("STRIDED_SLICE", i1, begins, ends, strides, beginMask, endMask, shrinkAxisMask).To(output) + +# Example 1. Input in operand 0, +input0 = {i1: # input 0 + [1, 2, 3]} + +output0 = {output: # output 0 + [3, 2, 1]} + +# Instantiate an example +Example((input0, output0)) diff --git a/runtimes/tests/neural_networks_test/specs/V1_1/strided_slice_quant8_8.mod.py b/runtimes/tests/neural_networks_test/specs/V1_1/strided_slice_quant8_8.mod.py new file mode 100644 index 000000000..6531dd3d4 --- /dev/null +++ b/runtimes/tests/neural_networks_test/specs/V1_1/strided_slice_quant8_8.mod.py @@ -0,0 +1,22 @@ +model = Model() +i1 = Input("input", "TENSOR_QUANT8_ASYMM", "{2, 3}, 1.0, 0") +begins = Parameter("begins", "TENSOR_INT32", "{2}", [1, -1]) +ends = Parameter("ends", "TENSOR_INT32", "{2}", [2, -4]) +strides = Parameter("strides", "TENSOR_INT32", "{2}", [2, -1]) +beginMask = Int32Scalar("beginMask", 0) +endMask = Int32Scalar("endMask", 0) +shrinkAxisMask = Int32Scalar("shrinkAxisMask", 0) + +output = Output("output", "TENSOR_QUANT8_ASYMM", "{1, 3}, 1.0, 0") + +model = model.Operation("STRIDED_SLICE", i1, begins, ends, strides, beginMask, endMask, shrinkAxisMask).To(output) + +# Example 1. Input in operand 0, +input0 = {i1: # input 0 + [1, 2, 3, 4, 5, 6]} + +output0 = {output: # output 0 + [6, 5, 4]} + +# Instantiate an example +Example((input0, output0)) diff --git a/runtimes/tests/neural_networks_test/specs/V1_1/strided_slice_quant8_9.mod.py b/runtimes/tests/neural_networks_test/specs/V1_1/strided_slice_quant8_9.mod.py new file mode 100644 index 000000000..7f066011e --- /dev/null +++ b/runtimes/tests/neural_networks_test/specs/V1_1/strided_slice_quant8_9.mod.py @@ -0,0 +1,22 @@ +model = Model() +i1 = Input("input", "TENSOR_QUANT8_ASYMM", "{2, 3}, 1.0, 0") +begins = Parameter("begins", "TENSOR_INT32", "{2}", [1, 0]) +ends = Parameter("ends", "TENSOR_INT32", "{2}", [2, 2]) +strides = Parameter("strides", "TENSOR_INT32", "{2}", [1, 1]) +beginMask = Int32Scalar("beginMask", 1) +endMask = Int32Scalar("endMask", 0) +shrinkAxisMask = Int32Scalar("shrinkAxisMask", 0) + +output = Output("output", "TENSOR_QUANT8_ASYMM", "{2, 2}, 1.0, 0") + +model = model.Operation("STRIDED_SLICE", i1, begins, ends, strides, beginMask, endMask, shrinkAxisMask).To(output) + +# Example 1. Input in operand 0, +input0 = {i1: # input 0 + [1, 2, 3, 4, 5, 6]} + +output0 = {output: # output 0 + [1, 2, 4, 5]} + +# Instantiate an example +Example((input0, output0)) diff --git a/runtimes/tests/neural_networks_test/specs/V1_1/sub.mod.py b/runtimes/tests/neural_networks_test/specs/V1_1/sub.mod.py new file mode 100644 index 000000000..1e4afb205 --- /dev/null +++ b/runtimes/tests/neural_networks_test/specs/V1_1/sub.mod.py @@ -0,0 +1,19 @@ +# model +model = Model() +i1 = Input("op1", "TENSOR_FLOAT32", "{1, 2, 2, 1}") +i2 = Input("op2", "TENSOR_FLOAT32", "{1, 2, 2, 1}") +act = Int32Scalar("act", 0) # an int32_t scalar fuse_activation +i3 = Output("op3", "TENSOR_FLOAT32", "{1, 2, 2, 1}") +model = model.Operation("SUB", i1, i2, act).To(i3) + +# Example 1. Input in operand 0, +input0 = {i1: # input 0 + [2.0, -4.0, 8.0, -16.0], + i2: # input 1 + [2.0, -2.0, -4.0, 4.0]} + +output0 = {i3: # output 0 + [0.0, -2.0, 12.0, -20.0]} + +# Instantiate an example +Example((input0, output0)) diff --git a/runtimes/tests/neural_networks_test/specs/V1_1/sub_broadcast_float.mod.py b/runtimes/tests/neural_networks_test/specs/V1_1/sub_broadcast_float.mod.py new file mode 100644 index 000000000..53bdf9e86 --- /dev/null +++ b/runtimes/tests/neural_networks_test/specs/V1_1/sub_broadcast_float.mod.py @@ -0,0 +1,19 @@ +# model +model = Model() +i1 = Input("op1", "TENSOR_FLOAT32", "{1, 2}") +i2 = Input("op2", "TENSOR_FLOAT32", "{2, 2}") +act = Int32Scalar("act", 0) +i3 = Output("op3", "TENSOR_FLOAT32", "{2, 2}") +model = model.Operation("SUB", i1, i2, act).To(i3) + +# Example 1. Input in operand 0, +input0 = {i1: # input 0 + [1, 2], + i2: # input 1 + [1, 2, 3, 4]} + +output0 = {i3: # output 0 + [0, 0, -2, -2]} + +# Instantiate an example +Example((input0, output0)) diff --git a/runtimes/tests/neural_networks_test/specs/V1_1/transpose.mod.py b/runtimes/tests/neural_networks_test/specs/V1_1/transpose.mod.py new file mode 100644 index 000000000..49f15a7cb --- /dev/null +++ b/runtimes/tests/neural_networks_test/specs/V1_1/transpose.mod.py @@ -0,0 +1,18 @@ +model = Model() +i1 = Input("input", "TENSOR_FLOAT32", "{1, 2, 2, 1}") +perms = Parameter("perms", "TENSOR_INT32", "{4}", [0, 2, 1, 3]) +output = Output("output", "TENSOR_FLOAT32", "{1, 2, 2, 1}") + +model = model.Operation("TRANSPOSE", i1, perms).To(output) + +# Example 1. Input in operand 0, +input0 = {i1: # input 0 + [1.0, 2.0, + 3.0, 4.0]} + +output0 = {output: # output 0 + [1.0, 3.0, + 2.0, 4.0]} + +# Instantiate an example +Example((input0, output0)) diff --git a/runtimes/tests/neural_networks_test/specs/V1_1/transpose_float_1.mod.py b/runtimes/tests/neural_networks_test/specs/V1_1/transpose_float_1.mod.py new file mode 100644 index 000000000..e8f0ea84b --- /dev/null +++ b/runtimes/tests/neural_networks_test/specs/V1_1/transpose_float_1.mod.py @@ -0,0 +1,32 @@ +model = Model() +i1 = Input("input", "TENSOR_FLOAT32", "{2, 3, 4, 5}") +perms = Parameter("perms", "TENSOR_INT32", "{4}", [2, 0, 1, 3]) +output = Output("output", "TENSOR_FLOAT32", "{4, 2, 3, 5}") + +model = model.Operation("TRANSPOSE", i1, perms).To(output) + +# Example 1. Input in operand 0, +input0 = {i1: # input 0 + [0, 1, 2, 3, 4, 5, 6, 7, 8, 9, 10, 11, + 12, 13, 14, 15, 16, 17, 18, 19, 20, 21, 22, 23, + 24, 25, 26, 27, 28, 29, 30, 31, 32, 33, 34, 35, + 36, 37, 38, 39, 40, 41, 42, 43, 44, 45, 46, 47, + 48, 49, 50, 51, 52, 53, 54, 55, 56, 57, 58, 59, + 60, 61, 62, 63, 64, 65, 66, 67, 68, 69, 70, 71, + 72, 73, 74, 75, 76, 77, 78, 79, 80, 81, 82, 83, + 84, 85, 86, 87, 88, 89, 90, 91, 92, 93, 94, 95, + 96, 97, 98, 99, 100, 101, 102, 103, 104, 105, 106, 107, + 108, 109, 110, 111, 112, 113, 114, 115, 116, 117, 118, 119]} + +output0 = {output: # output 0 + [0, 1, 2, 3, 4, 20, 21, 22, 23, 24, 40, 41, 42, 43, 44, + 60, 61, 62, 63, 64, 80, 81, 82, 83, 84, 100, 101, 102, 103, 104, + 5, 6, 7, 8, 9, 25, 26, 27, 28, 29, 45, 46, 47, 48, 49, + 65, 66, 67, 68, 69, 85, 86, 87, 88, 89, 105, 106, 107, 108, 109, + 10, 11, 12, 13, 14, 30, 31, 32, 33, 34, 50, 51, 52, 53, 54, + 70, 71, 72, 73, 74, 90, 91, 92, 93, 94, 110, 111, 112, 113, 114, + 15, 16, 17, 18, 19, 35, 36, 37, 38, 39, 55, 56, 57, 58, 59, + 75, 76, 77, 78, 79, 95, 96, 97, 98, 99, 115, 116, 117, 118, 119]} + +# Instantiate an example +Example((input0, output0)) diff --git a/runtimes/tests/neural_networks_test/specs/V1_1/transpose_quant8_1.mod.py b/runtimes/tests/neural_networks_test/specs/V1_1/transpose_quant8_1.mod.py new file mode 100644 index 000000000..6893a62e6 --- /dev/null +++ b/runtimes/tests/neural_networks_test/specs/V1_1/transpose_quant8_1.mod.py @@ -0,0 +1,32 @@ +model = Model() +i1 = Input("input", "TENSOR_QUANT8_ASYMM", "{2, 3, 4, 5}, 1.0, 0") +perms = Parameter("perms", "TENSOR_INT32", "{4}", [2, 0, 1, 3]) +output = Output("output", "TENSOR_QUANT8_ASYMM", "{4, 2, 3, 5}, 1.0, 0") + +model = model.Operation("TRANSPOSE", i1, perms).To(output) + +# Example 1. Input in operand 0, +input0 = {i1: # input 0 + [0, 1, 2, 3, 4, 5, 6, 7, 8, 9, 10, 11, + 12, 13, 14, 15, 16, 17, 18, 19, 20, 21, 22, 23, + 24, 25, 26, 27, 28, 29, 30, 31, 32, 33, 34, 35, + 36, 37, 38, 39, 40, 41, 42, 43, 44, 45, 46, 47, + 48, 49, 50, 51, 52, 53, 54, 55, 56, 57, 58, 59, + 60, 61, 62, 63, 64, 65, 66, 67, 68, 69, 70, 71, + 72, 73, 74, 75, 76, 77, 78, 79, 80, 81, 82, 83, + 84, 85, 86, 87, 88, 89, 90, 91, 92, 93, 94, 95, + 96, 97, 98, 99, 100, 101, 102, 103, 104, 105, 106, 107, + 108, 109, 110, 111, 112, 113, 114, 115, 116, 117, 118, 119]} + +output0 = {output: # output 0 + [0, 1, 2, 3, 4, 20, 21, 22, 23, 24, 40, 41, 42, 43, 44, + 60, 61, 62, 63, 64, 80, 81, 82, 83, 84, 100, 101, 102, 103, 104, + 5, 6, 7, 8, 9, 25, 26, 27, 28, 29, 45, 46, 47, 48, 49, + 65, 66, 67, 68, 69, 85, 86, 87, 88, 89, 105, 106, 107, 108, 109, + 10, 11, 12, 13, 14, 30, 31, 32, 33, 34, 50, 51, 52, 53, 54, + 70, 71, 72, 73, 74, 90, 91, 92, 93, 94, 110, 111, 112, 113, 114, + 15, 16, 17, 18, 19, 35, 36, 37, 38, 39, 55, 56, 57, 58, 59, + 75, 76, 77, 78, 79, 95, 96, 97, 98, 99, 115, 116, 117, 118, 119]} + +# Instantiate an example +Example((input0, output0)) |