提交 6fc1defd 编写于 作者: W wuzewu 提交者: hong

Fix compatibility issue of fluid.io.save_vars on windows platform (#19181)

上级 c8cdef37
...@@ -222,13 +222,13 @@ def save_vars(executor, ...@@ -222,13 +222,13 @@ def save_vars(executor,
continue continue
new_var = _clone_var_in_block_(save_block, each_var) new_var = _clone_var_in_block_(save_block, each_var)
if filename is None: if filename is None:
save_file_path = os.path.join(save_dirname, new_var.name)
save_file_path = os.path.normpath(save_file_path)
save_block.append_op( save_block.append_op(
type='save', type='save',
inputs={'X': [new_var]}, inputs={'X': [new_var]},
outputs={}, outputs={},
attrs={ attrs={'file_path': save_file_path})
'file_path': os.path.join(save_dirname, new_var.name)
})
else: else:
save_var_map[new_var.name] = new_var save_var_map[new_var.name] = new_var
......
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册