Skip to content

Commit

Permalink
Fix slice size
Browse files Browse the repository at this point in the history
  • Loading branch information
kevinthesun committed Jun 12, 2020
1 parent 7f20b9d commit e64a00f
Showing 1 changed file with 3 additions and 0 deletions.
3 changes: 3 additions & 0 deletions python/tvm/relay/frontend/tensorflow.py
Original file line number Diff line number Diff line change
Expand Up @@ -1155,6 +1155,9 @@ def _impl(inputs, attr, params, mod):
if not isinstance(begin, (_expr.Call, _expr.Var)):
for _ in range(len(begin), data_dim):
begin.append(0)
elif not isinstance(size, (_expr.Call, _expr.Var)):
for _ in range(len(size), data_dim):
size.append(-1)
return _op.strided_slice(inputs[0], begin=begin, end=size,
strides=strides, slice_mode="size")
return _impl
Expand Down

0 comments on commit e64a00f

Please sign in to comment.