Fix bug when searching for vocoder

This commit is contained in:
babysor00 2022-03-07 20:08:29 +08:00
parent fc26c38152
commit 3c97d22938
2 changed files with 3 additions and 2 deletions

View File

@ -453,6 +453,7 @@ class Toolbox:
model_config_fpaths = list(model_fpath.parent.rglob("*.json"))
if self.vc_mode and self.ui.current_extractor_fpath is None:
return
if len(model_config_fpaths) > 0:
model_config_fpath = model_config_fpaths[0]
else:
vocoder = rnn_vocoder

View File

@ -19,7 +19,7 @@ def load_checkpoint(filepath, device):
return checkpoint_dict
def load_model(weights_fpath, config_fpath="./vocoder/saved_models/24k/config.json", verbose=True):
def load_model(weights_fpath, config_fpath="./vocoder/hifigan/config_16k.json", verbose=True):
global generator, _device, output_sample_rate
if verbose: