From 4eab76d2113f5a4b4005b8d6917f870d4523b5c9 Mon Sep 17 00:00:00 2001 From: caozhou Date: Wed, 28 Oct 2020 14:33:48 +0800 Subject: [PATCH] fix comment problem --- mindspore/train/callback/_checkpoint.py | 3 ++- mindspore/train/serialization.py | 4 ++-- 2 files changed, 4 insertions(+), 3 deletions(-) diff --git a/mindspore/train/callback/_checkpoint.py b/mindspore/train/callback/_checkpoint.py index 34b1bd0624..5cbfaa0358 100644 --- a/mindspore/train/callback/_checkpoint.py +++ b/mindspore/train/callback/_checkpoint.py @@ -90,7 +90,8 @@ class CheckpointConfig: Default: True. Integrated save function is only supported in automatic parallel scene, not supported in manual parallel. async_save (bool): Whether asynchronous execution saves the checkpoint to a file. Default: False. - saved_network (Cell): Network to be saved in checkpoint file. Default: None. + saved_network (Cell): Network to be saved in checkpoint file. If the saved_network has no relation + with the network in training, the initial value of saved_network will be saved. Default: None. Raises: ValueError: If the input_param is None or 0. diff --git a/mindspore/train/serialization.py b/mindspore/train/serialization.py index 6940b92ad4..15ba4ab07c 100644 --- a/mindspore/train/serialization.py +++ b/mindspore/train/serialization.py @@ -232,8 +232,8 @@ def load_checkpoint(ckpt_file_name, net=None, strict_load=False, filter_prefix=N net (Cell): Cell network. Default: None strict_load (bool): Whether to strict load the parameter into net. If False, it will load parameter in the param_dict into net with the same suffix. Default: False - filter_prefix (Union[str, list[str], tuple[str]]): Parameter with the filter prefix will not be loaded. - Default: None. + filter_prefix (Union[str, list[str], tuple[str]]): Parameters starting with the filter_prefix + will not be loaded. Default: None. Returns: Dict, key is parameter name, value is a Parameter.