diff --git a/paddlespeech/s2t/utils/checkpoint.py b/paddlespeech/s2t/utils/checkpoint.py index 4c493715..1d24c880 100644 --- a/paddlespeech/s2t/utils/checkpoint.py +++ b/paddlespeech/s2t/utils/checkpoint.py @@ -94,10 +94,7 @@ class Checkpoint(): """ configs = {} - if len(checkpoint_path) == 0 or checkpoint_path == "None": - checkpoint_path = None - - if checkpoint_path is not None: + if checkpoint_path: pass elif checkpoint_dir is not None and record_file is not None: # load checkpint from record file