Skip to content

Commit c5758a8

Browse files
authored
Stop extracting features when hubert_base.pt does not exist. (#535)
* support detection of pretrained model, support train without pretrained model path in web ui * support detection of pretrained model, support train without pretrained model path in web ui * support detection of pretrained model, support train without pretrained model path in web ui * Stop extracting features when hubert_base.pt is not exist. * Stop extracting features when hubert_base.pt is not exist. * Make error more noticeable
1 parent 28383fb commit c5758a8

File tree

1 file changed

+4
-0
lines changed

1 file changed

+4
-0
lines changed

extract_feature_print.py

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -63,6 +63,10 @@ def readwave(wav_path, normalize=False):
6363

6464
# HuBERT model
6565
printt("load model(s) from {}".format(model_path))
66+
# if hubert model is exist
67+
if (os.access(model_path, os.F_OK) == False):
68+
printt("Error: Extracting is shut down because %s does not exist, you may download it from https://huggingface.co/lj1995/VoiceConversionWebUI/tree/main" % model_path)
69+
exit(0)
6670
models, saved_cfg, task = checkpoint_utils.load_model_ensemble_and_task(
6771
[model_path],
6872
suffix="",

0 commit comments

Comments
 (0)