提交 e130bf37 编写于 作者: T tangwei12

optimize python checkpint dir config

上级 b6ee59ae
......@@ -543,6 +543,11 @@ class DistributeTranspiler:
serial_number = self._get_lastest_checkpoint_dir(self.checkpoint_dir)
startup_prog.global_block().create_var(
name=SERIAL_VAR_NAME,
persistable=True,
type=core.VarDesc.VarType.RAW)
startup_prog.global_block().append_op(
type="checkpoint_load",
inputs={"X": load_vars},
......@@ -612,6 +617,11 @@ class DistributeTranspiler:
serial_number = self._get_lastest_checkpoint_dir(self.checkpoint_dir)
s_prog.global_block().create_var(
name=SERIAL_VAR_NAME,
persistable=True,
type=core.VarDesc.VarType.RAW)
s_prog.global_block().append_op(
type="checkpoint_load",
inputs={"X": load_vars},
......
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册