未验证 提交 77f4597f 编写于 作者: X xiaoting 提交者: GitHub

fix out of range for area interp, test=develop (#36466)

上级 a7830a29
...@@ -296,7 +296,8 @@ def interpolate(x, ...@@ -296,7 +296,8 @@ def interpolate(x,
) )
if resample == 'AREA': if resample == 'AREA':
if isinstance(size, list) or isinstance(size, tuple): if isinstance(size, list) or isinstance(size, tuple) or isinstance(
size, Variable):
if len(size) == 0: if len(size) == 0:
raise ValueError("output size can not be empty") raise ValueError("output size can not be empty")
if len(x.shape) == 3: if len(x.shape) == 3:
......
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册