未验证 提交 4528ed2a 编写于 作者: H HongyuJia 提交者: GitHub

polish default param of XXX_interp_test, the same default value with … (#45258)

* polish default param of XXX_interp_test, the same default value with XXX_interp_np

* set default value data_layout=NCHW, cause C++ end treat NCDHW the same way as NCHW
上级 9f1f1b0a
......@@ -29,14 +29,14 @@ def bicubic_interp_test(x,
OutSize=None,
SizeTensor=None,
Scale=None,
data_layout='NCHW',
data_layout='kNCHW',
out_d=-1,
out_h=-1,
out_w=-1,
scale=[],
interp_method='linear',
align_corners=False,
align_mode=1):
interp_method='bicubic',
align_corners=True,
align_mode=0):
if isinstance(scale, float) or isinstance(scale, int):
scale_list = []
for _ in range(len(x.shape) - 2):
......
......@@ -32,9 +32,9 @@ def bilinear_interp_test(x,
out_h=-1,
out_w=-1,
scale=[],
interp_method='linear',
align_corners=False,
align_mode=1):
interp_method='bilinear',
align_corners=True,
align_mode=0):
if isinstance(scale, float) or isinstance(scale, int):
scale_list = []
for _ in range(len(x.shape) - 2):
......
......@@ -34,8 +34,8 @@ def linear_interp_test(x,
out_w=-1,
scale=[],
interp_method='linear',
align_corners=False,
align_mode=1):
align_corners=True,
align_mode=0):
if isinstance(scale, float) or isinstance(scale, int):
scale_list = []
for _ in range(len(x.shape) - 2):
......
......@@ -35,9 +35,9 @@ def nearest_interp_test(x,
out_h=-1,
out_w=-1,
scale=[],
interp_method='linear',
align_corners=False,
align_mode=1):
interp_method='nearest',
align_corners=True,
align_mode=0):
if isinstance(scale, float) or isinstance(scale, int):
scale_list = []
for _ in range(len(x.shape) - 2):
......
......@@ -35,9 +35,9 @@ def trilinear_interp_test(x,
out_h=-1,
out_w=-1,
scale=[],
interp_method='linear',
align_corners=False,
align_mode=1):
interp_method='trilinear',
align_corners=True,
align_mode=0):
if isinstance(scale, float) or isinstance(scale, int):
scale_list = []
for _ in range(len(x.shape) - 2):
......
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册