未验证 提交 d5c51e62 编写于 作者: J Jiawei Wang 提交者: GitHub

fix range op (#37486)

上级 e76b601b
......@@ -1433,7 +1433,9 @@ def range(start, end, step, dtype, name=None):
step = cast(step, dtype)
if in_dygraph_mode():
return _C_ops.range(start, end, step)
out = _C_ops.range(start, end, step)
out.stop_gradient = True
return out
out_shape = None
if not isinstance(start, Variable) and not isinstance(
......
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册