Skip to content
体验新版
项目
组织
正在加载...
登录
切换导航
打开侧边栏
PaddlePaddle
DeepSpeech
提交
e0892686
D
DeepSpeech
项目概览
PaddlePaddle
/
DeepSpeech
大约 2 年 前同步成功
通知
210
Star
8425
Fork
1598
代码
文件
提交
分支
Tags
贡献者
分支图
Diff
Issue
245
列表
看板
标记
里程碑
合并请求
3
Wiki
0
Wiki
分析
仓库
DevOps
项目成员
Pages
D
DeepSpeech
项目概览
项目概览
详情
发布
仓库
仓库
文件
提交
分支
标签
贡献者
分支图
比较
Issue
245
Issue
245
列表
看板
标记
里程碑
合并请求
3
合并请求
3
Pages
分析
分析
仓库分析
DevOps
Wiki
0
Wiki
成员
成员
收起侧边栏
关闭侧边栏
动态
分支图
创建新Issue
提交
Issue看板
未验证
提交
e0892686
编写于
4月 20, 2022
作者:
小湉湉
提交者:
GitHub
4月 20, 2022
浏览文件
操作
浏览文件
下载
差异文件
Merge pull request #1727 from yt605155624/refactor_syn_util
[TTS]add paddle device set for ort and inference
上级
523d5bd6
4646f7cc
变更
5
隐藏空白更改
内联
并排
Showing
5 changed file
with
18 addition
and
0 deletion
+18
-0
paddlespeech/t2s/exps/inference.py
paddlespeech/t2s/exps/inference.py
+4
-0
paddlespeech/t2s/exps/inference_streaming.py
paddlespeech/t2s/exps/inference_streaming.py
+4
-0
paddlespeech/t2s/exps/ort_predict.py
paddlespeech/t2s/exps/ort_predict.py
+4
-0
paddlespeech/t2s/exps/ort_predict_e2e.py
paddlespeech/t2s/exps/ort_predict_e2e.py
+3
-0
paddlespeech/t2s/exps/ort_predict_streaming.py
paddlespeech/t2s/exps/ort_predict_streaming.py
+3
-0
未找到文件。
paddlespeech/t2s/exps/inference.py
浏览文件 @
e0892686
...
@@ -14,6 +14,7 @@
...
@@ -14,6 +14,7 @@
import
argparse
import
argparse
from
pathlib
import
Path
from
pathlib
import
Path
import
paddle
import
soundfile
as
sf
import
soundfile
as
sf
from
timer
import
timer
from
timer
import
timer
...
@@ -101,6 +102,9 @@ def parse_args():
...
@@ -101,6 +102,9 @@ def parse_args():
# only inference for models trained with csmsc now
# only inference for models trained with csmsc now
def
main
():
def
main
():
args
=
parse_args
()
args
=
parse_args
()
paddle
.
set_device
(
args
.
device
)
# frontend
# frontend
frontend
=
get_frontend
(
frontend
=
get_frontend
(
lang
=
args
.
lang
,
lang
=
args
.
lang
,
...
...
paddlespeech/t2s/exps/inference_streaming.py
浏览文件 @
e0892686
...
@@ -15,6 +15,7 @@ import argparse
...
@@ -15,6 +15,7 @@ import argparse
from
pathlib
import
Path
from
pathlib
import
Path
import
numpy
as
np
import
numpy
as
np
import
paddle
import
soundfile
as
sf
import
soundfile
as
sf
from
timer
import
timer
from
timer
import
timer
...
@@ -100,6 +101,9 @@ def parse_args():
...
@@ -100,6 +101,9 @@ def parse_args():
# only inference for models trained with csmsc now
# only inference for models trained with csmsc now
def
main
():
def
main
():
args
=
parse_args
()
args
=
parse_args
()
paddle
.
set_device
(
args
.
device
)
# frontend
# frontend
frontend
=
get_frontend
(
frontend
=
get_frontend
(
lang
=
args
.
lang
,
lang
=
args
.
lang
,
...
...
paddlespeech/t2s/exps/ort_predict.py
浏览文件 @
e0892686
...
@@ -16,6 +16,7 @@ from pathlib import Path
...
@@ -16,6 +16,7 @@ from pathlib import Path
import
jsonlines
import
jsonlines
import
numpy
as
np
import
numpy
as
np
import
paddle
import
soundfile
as
sf
import
soundfile
as
sf
from
timer
import
timer
from
timer
import
timer
...
@@ -25,6 +26,7 @@ from paddlespeech.t2s.utils import str2bool
...
@@ -25,6 +26,7 @@ from paddlespeech.t2s.utils import str2bool
def
ort_predict
(
args
):
def
ort_predict
(
args
):
# construct dataset for evaluation
# construct dataset for evaluation
with
jsonlines
.
open
(
args
.
test_metadata
,
'r'
)
as
reader
:
with
jsonlines
.
open
(
args
.
test_metadata
,
'r'
)
as
reader
:
test_metadata
=
list
(
reader
)
test_metadata
=
list
(
reader
)
...
@@ -143,6 +145,8 @@ def parse_args():
...
@@ -143,6 +145,8 @@ def parse_args():
def
main
():
def
main
():
args
=
parse_args
()
args
=
parse_args
()
paddle
.
set_device
(
args
.
device
)
ort_predict
(
args
)
ort_predict
(
args
)
...
...
paddlespeech/t2s/exps/ort_predict_e2e.py
浏览文件 @
e0892686
...
@@ -15,6 +15,7 @@ import argparse
...
@@ -15,6 +15,7 @@ import argparse
from
pathlib
import
Path
from
pathlib
import
Path
import
numpy
as
np
import
numpy
as
np
import
paddle
import
soundfile
as
sf
import
soundfile
as
sf
from
timer
import
timer
from
timer
import
timer
...
@@ -178,6 +179,8 @@ def parse_args():
...
@@ -178,6 +179,8 @@ def parse_args():
def
main
():
def
main
():
args
=
parse_args
()
args
=
parse_args
()
paddle
.
set_device
(
args
.
device
)
ort_predict
(
args
)
ort_predict
(
args
)
...
...
paddlespeech/t2s/exps/ort_predict_streaming.py
浏览文件 @
e0892686
...
@@ -15,6 +15,7 @@ import argparse
...
@@ -15,6 +15,7 @@ import argparse
from
pathlib
import
Path
from
pathlib
import
Path
import
numpy
as
np
import
numpy
as
np
import
paddle
import
soundfile
as
sf
import
soundfile
as
sf
from
timer
import
timer
from
timer
import
timer
...
@@ -246,6 +247,8 @@ def parse_args():
...
@@ -246,6 +247,8 @@ def parse_args():
def
main
():
def
main
():
args
=
parse_args
()
args
=
parse_args
()
paddle
.
set_device
(
args
.
device
)
ort_predict
(
args
)
ort_predict
(
args
)
...
...
编辑
预览
Markdown
is supported
0%
请重试
或
添加新附件
.
添加附件
取消
You are about to add
0
people
to the discussion. Proceed with caution.
先完成此消息的编辑!
取消
想要评论请
注册
或
登录