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
[TTS][Paddle-Lite]add a TTS demo for ARM Linux #2991
Merged
Merged
Conversation
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Thanks for your contribution! |
大神,加微信聊下?PaddleSpeech 用户群搜索 “子龙” |
yt605155624
changed the title
add a TTS demo for ARM Linux
[TTS]add a TTS demo for ARM Linux
Mar 6, 2023
SmileGoat
reviewed
Mar 6, 2023
SmileGoat
reviewed
Mar 6, 2023
SmileGoat
reviewed
Mar 6, 2023
> Paddle-Lite/lite/api/light_api.cc:462 CheckInputValid] Error input tensor precision type. Input index (0) Tensor name (text) Require precision type (int64_t) Input precision type (float).
SwimmingTiger
force-pushed
the
upstream-pr1
branch
from
March 6, 2023 05:56
748f164
to
c76874a
Compare
SwimmingTiger
force-pushed
the
upstream-pr1
branch
from
March 6, 2023 05:57
c76874a
to
93819cd
Compare
TODO: 引入 paddlespeech_tts_cpp |
yt605155624
reviewed
Mar 6, 2023
The prebuilt libraries has been placed to a BCE BOS server.
Demo does not use OpenCV functions. Even if the Paddle-Lite library enables OpenCV, it does not need to be installed when building the demo.
add steps for building paddle-lite library.
In CentOS 7, its aarch64-redhat-linux-g++. It might be a good idea not to give a compiler name and let cmake find it by itself.
yt605155624
changed the title
[TTS]add a TTS demo for ARM Linux
[TTS][Paddle-Lite]add a TTS demo for ARM Linux
Mar 6, 2023
yt605155624
approved these changes
Mar 7, 2023
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
LGTM
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
PR types
Others
PR changes
Others
Describe
Add a TTS demo for ARM Linux.
PaddleSpeech TTS 文本到语音 ARM Linux Demo
修改自demos/TTSAndroid,模型也来自该安卓Demo。
使用与安卓Demo版本相同的Paddle-Lite推理库(Paddle-Lite:68b66fd35),
该库兼容 Ubuntu 16.04 到 20.04,如果你的发行版与其不兼容,可以自行从源代码编译。
注意 Paddle-Lite 2.12 与TTS不兼容,无法导出或运行TTS模型,需要使用更新的版本(比如
develop
分支中的代码)。配置
打开 config.sh 按需修改配置。
默认编译64位版本,如果要编译32位版本,把
ARM_ABI=armv8
改成ARM_ABI=armv7hf
。下载Paddle Lite库文件和模型文件
安装依赖
以 Ubuntu 18.04 为例:
编译
运行
将把src/main.cpp里定义在
sentencesToChoose
数组中的十句话转换为wav
文件,保存在output
文件夹中。测试环境
我在 RK3588 上用 docker 测的
docker run --name ubuntu-18.04-armhf --privileged -v ~/work:/parent/work --network=host -it armv7/armhf-ubuntu:18.04
docker run --name ubuntu-18.04 --privileged -v ~/work:/parent/work --network=host -it ubuntu:18.04 # host是arm64
macOS里的docker应该也能这样测吧