Skip to main content

A text-to-speech framework for fast and high-quality speech synthesis.

Project description

RapidTTS

RapidTTS 是一个轻量级文本转语音工具,面向本地快速推理。当前默认后端是导出为 ONNX 的 MeloTTS。

安装

pip install rapidtts

从源码安装:

git clone https://github.com/RapidAI/RapidTTS.git
cd RapidTTS
pip install -e .

快速使用

命令行合成:

rapidtts text "你好,RapidTTS" outputs/1.wav

Python 调用:

from rapidtts import RapidTTS, SynthesisRequest, TTSModel

tts = RapidTTS(model=TTSModel.MELO_ONNX)
resp = tts.synthesize(SynthesisRequest(text="你好,RapidTTS"))
resp.save("outputs/1.wav")

常用命令

rapidtts download melo_onnx
rapidtts check
rapidtts text "你好,RapidTTS" outputs/1.wav

模型文件

默认模型文件会在未指定模型目录时下载到库安装目录下,并使用 models.yaml 中声明的 SHA256 进行校验。

自定义下载目录:

rapidtts download melo_onnx --save-dir /path/to/melotts_zh_mix_en_onnx

自定义推理模型目录:

rapidtts text "你好,RapidTTS" outputs/1.wav --model-dir /path/to/melotts_zh_mix_en_onnx

License

RapidTTS 使用 Apache-2.0 License。

Project details


Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Source Distributions

No source distribution files available for this release.See tutorial on generating distribution archives.

Built Distribution

If you're not sure about the file name format, learn more about wheel file names.

rapidtts-1.0.0-py3-none-any.whl (41.8 kB view details)

Uploaded Python 3

File details

Details for the file rapidtts-1.0.0-py3-none-any.whl.

File metadata

  • Download URL: rapidtts-1.0.0-py3-none-any.whl
  • Upload date:
  • Size: 41.8 kB
  • Tags: Python 3
  • Uploaded using Trusted Publishing? Yes
  • Uploaded via: twine/6.1.0 CPython/3.13.12

File hashes

Hashes for rapidtts-1.0.0-py3-none-any.whl
Algorithm Hash digest
SHA256 9b308e65c0babbd4c758601da50aaefabecc83cd648a5e83ae975d235d088510
MD5 e93ee9549bfa803e6c4921b39a21a567
BLAKE2b-256 cb3414b795aa3dd09f541ac8cfb8904f32e9d9043583e85c0f0c3e0701ca0c9e

See more details on using hashes here.

Provenance

The following attestation bundles were made for rapidtts-1.0.0-py3-none-any.whl:

Publisher: publish_whl.yml on RapidAI/RapidTTS

Attestations: Values shown here reflect the state when the release was signed and may no longer be current.

Supported by

AWS Cloud computing and Security Sponsor Datadog Monitoring Depot Continuous Integration Fastly CDN Google Download Analytics Pingdom Monitoring Sentry Error logging StatusPage Status page