未验证 提交 b70501ab 编写于 作者: littletomatodonkey's avatar littletomatodonkey 提交者: GitHub

fix msdef (#385)

fix multi-scale def
上级 366eb59c
...@@ -20,11 +20,18 @@ def multiscale_def(image_shape, num_scale, use_flip=True): ...@@ -20,11 +20,18 @@ def multiscale_def(image_shape, num_scale, use_flip=True):
if use_flip: if use_flip:
num_scale //= 2 num_scale //= 2
base_name_list.append('image_flip') base_name_list.append('image_flip')
multiscale_def['image_flip'] = {
'shape': [None] + image_shape,
'dtype': 'float32',
'lod_level': 0
}
multiscale_def['im_info_image_flip'] = { multiscale_def['im_info_image_flip'] = {
'shape': [None, 3], 'shape': [None, 3],
'dtype': 'float32', 'dtype': 'float32',
'lod_level': 0 'lod_level': 0
} }
ms_def_names.append('image_flip')
ms_def_names.append('im_info_image_flip')
for base_name in base_name_list: for base_name in base_name_list:
for i in range(0, num_scale - 1): for i in range(0, num_scale - 1):
name = base_name + '_scale_' + str(i) name = base_name + '_scale_' + str(i)
......
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册