update fluid Train API param_path to checkpoint_config
Created by: seiriosPlus
First: add self.checkpoint
to Train
.
Second: add checkpoint feature in Train class.
class CheckpointConfig(object):
def __init__(self, checkpoint_dir=None, max_num_checkpoints=3, save_interval_secs=600):
if checkpoint_dir is None:
self.checkpoint_dir = os.getcwd()
self.max_num_checkpoints = max_num_checkpoints
self.save_interval_secs = save_interval_secs
Thrid: add checkpoint_config
in Train init.
Add load_checkpoint
in Train init.
Add save_checkpoint
in Train _train_by_any_executor
.
Add clean_checkpoint
in Train _train_by_any_executor