Skip to content

Commit

Permalink
Merge pull request #332 from DrewThomasson/Persian-patch-1
Browse files Browse the repository at this point in the history
Added new persian-tts-female-vits model
  • Loading branch information
eginhard authored Mar 10, 2025
2 parents 6d78df9 + 8776132 commit e2defc1
Show file tree
Hide file tree
Showing 2 changed files with 20 additions and 1 deletion.
11 changes: 11 additions & 0 deletions TTS/.models.json
Original file line number Diff line number Diff line change
Expand Up @@ -723,6 +723,17 @@
"description": "persian-tts-female-glow_tts model for text to speech purposes. Single-speaker female voice Trained on persian-tts-dataset-famale. \nThis model has no compatible vocoder thus the output quality is not very good. \nDataset: https://www.kaggle.com/datasets/magnoliasis/persian-tts-dataset-famale.",
"author": "@karim23657",
"license": "CC-BY-4.0"
},
"vits-female": {
"hf_url": [
"https://huggingface.co/Kamtera/persian-tts-female-vits/resolve/main/best_model_30824.pth",
"https://huggingface.co/Kamtera/persian-tts-female-vits/resolve/main/config.json"
],
"default_vocoder": null,
"commit": null,
"description": "persian-tts-female-vits model for text to speech purposes. Single-speaker female voice trained on persian-tts-dataset-female.\nDataset: https://www.kaggle.com/datasets/magnoliasis/persian-tts-dataset-famale.",
"author": "@karim23657",
"license": "openrail"
}
}
},
Expand Down
10 changes: 9 additions & 1 deletion TTS/api.py
Original file line number Diff line number Diff line change
Expand Up @@ -158,7 +158,15 @@ def download_model_by_name(
self, model_name: str, vocoder_name: str | None = None
) -> tuple[Path | None, Path | None, Path | None, Path | None, Path | None]:
model_path, config_path, model_item = self.manager.download_model(model_name)
if "fairseq" in model_name or (model_item is not None and isinstance(model_item["model_url"], list)):
if (
"fairseq" in model_name
or "openvoice" in model_name
or (
model_item is not None
and isinstance(model_item["model_url"], list)
and len(model_item["model_url"]) > 2
)
):
# return model directory if there are multiple files
# we assume that the model knows how to load itself
return None, None, None, None, model_path
Expand Down

0 comments on commit e2defc1

Please sign in to comment.