Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Add Vietnamese support to XTTS configurations and tokenizer #3666

Closed
wants to merge 2 commits into from
Closed
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
1 change: 1 addition & 0 deletions TTS/tts/configs/xtts_config.py
Original file line number Diff line number Diff line change
Expand Up @@ -89,6 +89,7 @@ class XttsConfig(BaseTTSConfig):
"ko",
"ja",
"hi",
"vi",
]
)

Expand Down
3 changes: 3 additions & 0 deletions TTS/tts/layers/xtts/tokenizer.py
Original file line number Diff line number Diff line change
Expand Up @@ -611,6 +611,7 @@ def __init__(self, vocab_file=None):
"ja": 71,
"hu": 224,
"ko": 95,
"vi": 250,
}

@cached_property
Expand Down Expand Up @@ -639,6 +640,8 @@ def preprocess_text(self, txt, lang):
elif lang == "hi":
# @manmay will implement this
txt = basic_cleaners(txt)
elif lang == "vi":
txt = basic_cleaners(txt)
else:
raise NotImplementedError(f"Language '{lang}' is not supported.")
return txt
Expand Down
Loading