Skip to content

Commit

Permalink
Update transpose_optimizer.py
Browse files Browse the repository at this point in the history
  • Loading branch information
sdpython committed Aug 4, 2020
1 parent 4949509 commit 7047b47
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion tf2onnx/optimizer/transpose_optimizer.py
Original file line number Diff line number Diff line change
Expand Up @@ -283,7 +283,7 @@ def _handle_nhwc_tranpose(self, trans):
# move transpose into branches to let Transposes can be "handled" in each branch
for n in out_nodes:
branch_trans = n.graph.make_node("Transpose", [trans.input[0]], attr=trans.attr_onnx)
n.graph.replace_input(n, trans.output[0], branch_trans.output[0], 0)
n.graph.replace_input(n, trans.output[0], branch_trans.output[0])

self._g.remove_node(trans.name)
return False
Expand Down

0 comments on commit 7047b47

Please sign in to comment.