Skip to content

Commit a052dec

Browse files
fix typo
1 parent 95aecf4 commit a052dec

File tree

1 file changed

+2
-2
lines changed

1 file changed

+2
-2
lines changed

tf2onnx/shape_inference.py

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -297,7 +297,7 @@ def infer_shape_for_op_supplementary(op):
297297
return set_shape_from_inputs_broadcast(op.inputs, op.outputs[0])
298298

299299
if op.type == "RandomUniform":
300-
shape_op = op.inputs[0]
300+
shape_op = op.inputs[0].op
301301
if not shape_op or shape_op.type != "Shape":
302302
return False
303303
return set_shape_from_input(shape_op.inputs[0], op.outputs[0])
@@ -349,7 +349,7 @@ def infer_shape_for_op_supplementary(op):
349349
if op.type == "ExpandDims":
350350
# https://www.tensorflow.org/api_docs/python/tf/expand_dims
351351
input_shape = utils.get_shape_from_tf_output(op.inputs[0])
352-
dim_op = op.inputs[1]
352+
dim_op = op.inputs[1].op
353353
if input_shape is None or not utils.is_const_op(dim_op):
354354
return False
355355

0 commit comments

Comments
 (0)