mirror of
https://github.com/FunAudioLLM/CosyVoice.git
synced 2026-02-04 09:29:25 +08:00
update vc code
This commit is contained in:
@@ -25,7 +25,6 @@ class CosyVoice:
|
||||
|
||||
def __init__(self, model_dir, load_jit=True, load_onnx=False):
|
||||
instruct = True if '-Instruct' in model_dir else False
|
||||
vc = True if '-VC' in model_dir else False
|
||||
self.model_dir = model_dir
|
||||
if not os.path.exists(model_dir):
|
||||
model_dir = snapshot_download(model_dir)
|
||||
@@ -37,7 +36,6 @@ class CosyVoice:
|
||||
'{}/speech_tokenizer_v1.onnx'.format(model_dir),
|
||||
'{}/spk2info.pt'.format(model_dir),
|
||||
instruct,
|
||||
vc,
|
||||
configs['allowed_special'])
|
||||
self.model = CosyVoiceModel(configs['llm'], configs['flow'], configs['hift'])
|
||||
self.model.load('{}/llm.pt'.format(model_dir),
|
||||
|
||||
Reference in New Issue
Block a user