Skip to content

Commit

Permalink
Fixed extra reshape parameter bug. (apache#4524)
Browse files Browse the repository at this point in the history
  • Loading branch information
jwfromm authored and zhiics committed Jan 11, 2020
1 parent 4f3bc94 commit 3f3a3a6
Showing 1 changed file with 2 additions and 1 deletion.
3 changes: 2 additions & 1 deletion python/tvm/relay/frontend/onnx.py
Expand Up @@ -463,7 +463,8 @@ def _impl_v1(cls, inputs, attr, params):
@classmethod
def _impl_v5(cls, inputs, attr, params):
if get_name(inputs[1]) in params:
shape = tuple(params[inputs[1].name_hint].asnumpy())
# pop shape out of parameters since it wont be needed later.
shape = tuple(params.pop(inputs[1].name_hint).asnumpy())
out = _op.reshape(inputs[0], shape)
else:
data, shape = inputs
Expand Down

0 comments on commit 3f3a3a6

Please sign in to comment.