Skip to content

Commit

Permalink
fix ci
Browse files Browse the repository at this point in the history
  • Loading branch information
comaniac committed Jun 9, 2020
1 parent 6c4bb92 commit 58103c9
Showing 1 changed file with 4 additions and 3 deletions.
7 changes: 4 additions & 3 deletions python/tvm/relay/op/transform.py
Original file line number Diff line number Diff line change
Expand Up @@ -217,10 +217,11 @@ def reshape(data, newshape):
for shape in newshape:
if isinstance(shape, IntImm):
tempshape.append(shape.value)
elif isinstance(shape, int):
tempshape.append(shape)
else:
raise RuntimeError('Unrecognized shape type: %s' % type(shape))
try:
tempshape.append(int(shape))
except ValueError as err:
raise RuntimeError('Unrecognized shape type: %s' % err)
newshape = const(tempshape)
return _make.reshape(data, newshape)

Expand Down

0 comments on commit 58103c9

Please sign in to comment.