diff options
author | Patrik Gustavsson <patrik.gustavsson@arm.com> | 2020-12-01 16:02:29 +0100 |
---|---|---|
committer | Patrik Gustavsson <patrik.gustavsson@arm.com> | 2020-12-18 16:33:32 +0100 |
commit | 2349d429d926e258e9a61d34c7fd97660ab9fb98 (patch) | |
tree | b5151d0f12428e47d64b1fb2ce4f2f8c19304a0d /ethosu/vela/test/testutil.py | |
parent | 528a56df829b65f7a2c61953650b123c461095f7 (diff) | |
download | ethos-u-vela-2349d429d926e258e9a61d34c7fd97660ab9fb98.tar.gz |
MLBEDSW-3654 Add/use op ifm/ofm shapes
Add ifm/ofm shapes to op
Changed to rely on these shapes
Signed-off-by: Patrik Gustavsson <patrik.gustavsson@arm.com>
Change-Id: I571535a1dcadc2bdb04a3c727a8e1c49703b174d
Diffstat (limited to 'ethosu/vela/test/testutil.py')
-rw-r--r-- | ethosu/vela/test/testutil.py | 5 |
1 files changed, 5 insertions, 0 deletions
diff --git a/ethosu/vela/test/testutil.py b/ethosu/vela/test/testutil.py index 9ba39bc5..63f841b4 100644 --- a/ethosu/vela/test/testutil.py +++ b/ethosu/vela/test/testutil.py @@ -69,6 +69,8 @@ def create_elemwise_op( ofm = Tensor(ofm_shape, datatype, name + "_ofm") ofm.quantization = ofm_quant op.set_output_tensor(ofm) + op.set_ifm_ofm_shapes() + return op @@ -104,6 +106,8 @@ def create_op_with_quant_tensors( qp.zero_point = np.zeros(bias_shape) bias = create_const_tensor("bias", bias_shape, DataType.int32, np.zeros(bias_shape), np.int32, quantization=qp) op.add_input_tensor(bias) + + op.set_ifm_ofm_shapes() return op @@ -113,6 +117,7 @@ def create_op(op_type, inputs, output, attrs=None): op.outputs = [output] if attrs is not None: op.attrs = attrs + op.set_ifm_ofm_shapes() return op |