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

show number of speakers

Browse files
Files changed (1) hide show
  1. model.py +15 -13
model.py CHANGED
@@ -230,6 +230,8 @@ def _get_vits_zh_aishell3(repo_id: str, speed: float) -> sherpa_onnx.OfflineTts:
230
 
231
  @lru_cache(maxsize=10)
232
  def _get_vits_hf(repo_id: str, speed: float) -> sherpa_onnx.OfflineTts:
 
 
233
  if "fanchen" in repo_id or "vits-cantonese-hf-xiaomaiiwn" in repo_id:
234
  model = repo_id.split("/")[-1]
235
  else:
@@ -416,20 +418,20 @@ cantonese_models = {
416
  }
417
 
418
  chinese_models = {
419
- "csukuangfj/vits-zh-hf-theresa": _get_vits_hf,
420
- "csukuangfj/vits-zh-hf-eula": _get_vits_hf,
421
- "csukuangfj/vits-zh-hf-echo": _get_vits_hf,
422
- "csukuangfj/vits-zh-hf-bronya": _get_vits_hf,
 
 
 
 
 
 
 
 
 
423
  "csukuangfj/vits-zh-aishell3": _get_vits_zh_aishell3,
424
- "csukuangfj/vits-zh-hf-fanchen-wnj": _get_vits_hf,
425
- "csukuangfj/vits-zh-hf-fanchen-C": _get_vits_hf,
426
- "csukuangfj/vits-zh-hf-fanchen-ZhiHuiLaoZhe": _get_vits_hf,
427
- "csukuangfj/vits-zh-hf-fanchen-ZhiHuiLaoZhe_new": _get_vits_hf,
428
- "csukuangfj/vits-zh-hf-fanchen-unity": _get_vits_hf,
429
- "csukuangfj/vits-zh-hf-doom": _get_vits_hf,
430
- "csukuangfj/vits-zh-hf-zenyatta": _get_vits_hf, # 804
431
- "csukuangfj/vits-zh-hf-abyssinvoker": _get_vits_hf,
432
- "csukuangfj/vits-zh-hf-keqing": _get_vits_hf,
433
  "csukuangfj/vits-piper-zh_CN-huayan-medium": _get_vits_piper,
434
  # "csukuangfj/vits-piper-zh_CN-huayan-x_low": _get_vits_piper,
435
  }
 
230
 
231
  @lru_cache(maxsize=10)
232
  def _get_vits_hf(repo_id: str, speed: float) -> sherpa_onnx.OfflineTts:
233
+ repo_id = repo_id.split("|")[0]
234
+
235
  if "fanchen" in repo_id or "vits-cantonese-hf-xiaomaiiwn" in repo_id:
236
  model = repo_id.split("/")[-1]
237
  else:
 
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
424
+ "csukuangfj/vits-zh-hf-echo|804": _get_vits_hf, # 804
425
+ "csukuangfj/vits-zh-hf-bronya|804": _get_vits_hf, # 804
426
+ "csukuangfj/vits-zh-hf-doom|804": _get_vits_hf, # 804
427
+ "csukuangfj/vits-zh-hf-zenyatta|804": _get_vits_hf, # 804
428
+ "csukuangfj/vits-zh-hf-abyssinvoker|804": _get_vits_hf, # 804
429
+ "csukuangfj/vits-zh-hf-fanchen-wnj|1": _get_vits_hf, # 1
430
+ "csukuangfj/vits-zh-hf-fanchen-C|187": _get_vits_hf, # 187
431
+ "csukuangfj/vits-zh-hf-fanchen-ZhiHuiLaoZhe|1": _get_vits_hf, # 1
432
+ "csukuangfj/vits-zh-hf-fanchen-ZhiHuiLaoZhe_new|1": _get_vits_hf, # 1
433
+ "csukuangfj/vits-zh-hf-fanchen-unity|1": _get_vits_hf, # 1
434
  "csukuangfj/vits-zh-aishell3": _get_vits_zh_aishell3,
 
 
 
 
 
 
 
 
 
435
  "csukuangfj/vits-piper-zh_CN-huayan-medium": _get_vits_piper,
436
  # "csukuangfj/vits-piper-zh_CN-huayan-x_low": _get_vits_piper,
437
  }