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

API参数没注释 #763

Open
yushanyong opened this issue Sep 24, 2024 · 4 comments
Open

API参数没注释 #763

yushanyong opened this issue Sep 24, 2024 · 4 comments
Labels
documentation Improvements or additions to documentation

Comments

@yushanyong
Copy link

yushanyong commented Sep 24, 2024

ChatTTS.Chat.infer(
    self,
    text,
    stream=False,
    lang=None,
    skip_refine_text=False,
    refine_text_only=False,
    use_decoder=True,
    do_text_normalization=True,
    do_homophone_replacement=True,
    params_refine_text=<ChatTTS.core.Chat.RefineTextParams object at 0x17ae4bee0>,
    params_infer_code=<ChatTTS.core.Chat.InferCodeParams object at 0x17ae4be50>,
)

其中如下几个参数,不理解是什么意思,具体是什么作用

    lang=None,
    skip_refine_text=False,
    refine_text_only=False,
    use_decoder=True,
@fumiama
Copy link
Member

fumiama commented Sep 24, 2024

  • lang: en 或 zh,不指定则自动检测。
  • skip_refine_text: 跳过 refine_text 步骤。
  • refine_text_only: 仅进行 refine_text 步骤。
  • use_decoder: 使用Decoder.pt而非DVAE_full.pt(一般来说效果更差)。

@fumiama fumiama added the documentation Improvements or additions to documentation label Sep 24, 2024
@yushanyong
Copy link
Author

好的,谢谢!

@LingfengPan
Copy link

麻烦请教下这两个参数是什么意思呀,do_text_normalization 和 do_homophone_replacement

@fumiama
Copy link
Member

fumiama commented Oct 1, 2024

麻烦请教下这两个参数是什么意思呀,do_text_normalization 和 do_homophone_replacement

text_normalization 是将文本正规化为模型支持的文字,如12变为十二。homophone_replacement 将生僻字替换为同音的简单字,你可以用关关雎鸠,在河之洲做测试。

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
documentation Improvements or additions to documentation
Projects
None yet
Development

No branches or pull requests

3 participants