Update train_ms.py
This commit is contained in:
@@ -1,5 +1,4 @@
|
|||||||
# flake8: noqa: E402
|
# flake8: noqa: E402
|
||||||
|
|
||||||
import platform
|
import platform
|
||||||
import os
|
import os
|
||||||
import torch
|
import torch
|
||||||
@@ -582,7 +581,7 @@ def train_and_evaluate(
|
|||||||
epoch,
|
epoch,
|
||||||
os.path.join(hps.model_dir, "DUR_{}.pth".format(global_step)),
|
os.path.join(hps.model_dir, "DUR_{}.pth".format(global_step)),
|
||||||
)
|
)
|
||||||
keep_ckpts = getattr(hps.train, "keep_ckpts", 10)
|
keep_ckpts = config.train_ms_config.keep_ckpts
|
||||||
if keep_ckpts > 0:
|
if keep_ckpts > 0:
|
||||||
utils.clean_checkpoints(
|
utils.clean_checkpoints(
|
||||||
path_to_models=hps.model_dir,
|
path_to_models=hps.model_dir,
|
||||||
|
|||||||
Reference in New Issue
Block a user