csukuangfj commited on
Commit
fffaea0
1 Parent(s): 7fd4d7a

add a new chinese tts model

Browse files
Files changed (1) hide show
  1. model.py +4 -0
model.py CHANGED
@@ -237,6 +237,9 @@ def _get_vits_hf(repo_id: str, speed: float) -> sherpa_onnx.OfflineTts:
237
  else:
238
  model = repo_id.split("-")[-1]
239
 
 
 
 
240
  if not Path("/tmp/dict").is_dir():
241
  os.system(
242
  "cd /tmp; curl -SL -O https://github.com/csukuangfj/cppjieba/releases/download/sherpa-onnx-2024-04-19/dict.tar.bz2; tar xvf dict.tar.bz2"
@@ -418,6 +421,7 @@ cantonese_models = {
418
  }
419
 
420
  chinese_models = {
 
421
  "csukuangfj/vits-zh-hf-keqing|804": _get_vits_hf, # 804
422
  "csukuangfj/vits-zh-hf-theresa|804": _get_vits_hf, # 804
423
  "csukuangfj/vits-zh-hf-eula|804": _get_vits_hf, # 804
 
237
  else:
238
  model = repo_id.split("-")[-1]
239
 
240
+ if "sherpa-onnx-vits-zh-ll" in repo_id:
241
+ model = "model.onnx"
242
+
243
  if not Path("/tmp/dict").is_dir():
244
  os.system(
245
  "cd /tmp; curl -SL -O https://github.com/csukuangfj/cppjieba/releases/download/sherpa-onnx-2024-04-19/dict.tar.bz2; tar xvf dict.tar.bz2"
 
421
  }
422
 
423
  chinese_models = {
424
+ "csukuangfj/sherpa-onnx-vits-zh-ll|5|效果很棒": _get_vits_hf, # 804
425
  "csukuangfj/vits-zh-hf-keqing|804": _get_vits_hf, # 804
426
  "csukuangfj/vits-zh-hf-theresa|804": _get_vits_hf, # 804
427
  "csukuangfj/vits-zh-hf-eula|804": _get_vits_hf, # 804