未验证 提交 d6763ca2 编写于 作者: K kinghuin 提交者: GitHub

fix load_checkpoint bug (#600)

上级 dbca09ae
......@@ -833,8 +833,9 @@ class BaseTask(object):
self.exe,
main_program=self.main_program)
# Revise max_train_steps when incremental training
self.max_train_steps = self.env.current_step + self.max_train_steps / self.config.num_epoch * (
self.config.num_epoch - self.env.current_epoch + 1)
if is_load_successful:
self.max_train_steps = self.env.current_step + self.max_train_steps / self.config.num_epoch * (
self.config.num_epoch - self.env.current_epoch + 1)
return is_load_successful
def load_parameters(self, dirname):
......
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册