1 Star 2 Fork 3

峯挚 / HanTTS

加入 Gitee
与超过 1200万 开发者一起发现、参与优秀开源项目,私有仓库也完全免费 :)
免费加入
克隆/下载
README.md 2.60 KB
一键复制 编辑 原始数据 按行查看 历史
Junze Wu 提交于 2020-05-23 23:12 . Update README

HanTTS Build Status

Chinese Text-to-Speech(TTS)

汉字 => ["han4", "zi4"] => .wav audio

Read this page in 简体中文

Libraries Used

For turning Chinese characters into pinyin

For processing .wav files

Web backend

A list of all Chinese characters is obtained from 倉頡平台2012, a Chinese input software.

Build and Run

git clone https://github.com/junzew/HanTTS.git
cd HanTTS
pip install --user -r requires.txt

Download syllables.zip from SourceForge, and decompress under the directory HanTTS.

  • Either run locally: python main.py
  • Or through web interface: cd into the server folder
     npm install
     node app.js
    Navigate to localhost:3000 in a browser

Use your own voice

  • Record five tones of each pinyin listed in mapping.json
  • Group them by the first letter (a,b,c,d, etc.), and save under folder ./recording as {letter}.wav
  • Then run python process.py {letter}for each letter to split recordings into individual pinyin
  • Move valid .wav files from ./pre to the folder ./syllables

Deploy to Heroku

heroku create
heroku git:remote -a <app-name>
heroku buildpacks:set https://github.com/heroku/heroku-buildpack-nodejs#v170 -a <app-name>
heroku buildpacks:add --index 1 heroku-community/apt
heroku buildpacks:add --index 3 heroku/python

$heroku buildpacks
=== hantts Buildpack URLs
1. heroku-community/apt
2. https://github.com/heroku/heroku-buildpack-nodejs#v170
3. heroku/python

heroku apps:rename <newname>
heroku ps:scale web=1
git push heroku master

Issues Encountered during Deployment:

Based on the text-to-speech-sample project by @alexram1313

马建仓 AI 助手
尝试更多
代码解读
代码找茬
代码优化
1
https://gitee.com/dhfhub/HanTTS.git
git@gitee.com:dhfhub/HanTTS.git
dhfhub
HanTTS
HanTTS
master

搜索帮助

344bd9b3 5694891 D2dac590 5694891