Skip to content
体验新版
项目
组织
正在加载...
登录
切换导航
打开侧边栏
PaddlePaddle
DeepSpeech
提交
efc269b7
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看板
提交
efc269b7
编写于
4月 16, 2022
作者:
X
xiongxinlei
浏览文件
操作
浏览文件
下载
电子邮件补丁
差异文件
remove unuseful code, test=doc
上级
89b102a7
变更
12
隐藏空白更改
内联
并排
Showing
12 changed file
with
14 addition
and
31 deletion
+14
-31
demos/speech_recognition/run.sh
demos/speech_recognition/run.sh
+0
-11
examples/aishell/asr1/conf/preprocess.yaml
examples/aishell/asr1/conf/preprocess.yaml
+1
-1
examples/aishell/asr1/conf/tuning/decode.yaml
examples/aishell/asr1/conf/tuning/decode.yaml
+2
-2
examples/aishell/asr1/run.sh
examples/aishell/asr1/run.sh
+5
-5
paddlespeech/__init__.py
paddlespeech/__init__.py
+0
-3
paddlespeech/s2t/exps/u2/bin/test_wav.py
paddlespeech/s2t/exps/u2/bin/test_wav.py
+1
-3
paddlespeech/server/conf/ws_application.yaml
paddlespeech/server/conf/ws_application.yaml
+1
-1
paddlespeech/server/tests/asr/online/websocket_client.py
paddlespeech/server/tests/asr/online/websocket_client.py
+1
-1
paddlespeech/server/ws/asr_socket.py
paddlespeech/server/ws/asr_socket.py
+0
-1
paddlespeech/vector/cluster/diarization.py
paddlespeech/vector/cluster/diarization.py
+1
-1
setup.py
setup.py
+1
-1
utils/DER.py
utils/DER.py
+1
-1
未找到文件。
demos/speech_recognition/run.sh
已删除
100755 → 0
浏览文件 @
89b102a7
#!/bin/bash
# wget -c https://paddlespeech.bj.bcebos.com/PaddleAudio/zh.wav https://paddlespeech.bj.bcebos.com/PaddleAudio/en.wav
# asr
export
CUDA_VISIBLE_DEVICES
=
0
paddlespeech asr
--input
audio/119994.wav
-v
# asr + punc
# paddlespeech asr --input ./zh.wav | paddlespeech text --task punc
\ No newline at end of file
examples/aishell/asr1/conf/preprocess.yaml
浏览文件 @
efc269b7
...
...
@@ -5,7 +5,7 @@ process:
n_mels
:
80
n_shift
:
160
win_length
:
400
dither
:
0.
0
dither
:
0.
1
-
type
:
cmvn_json
cmvn_path
:
data/mean_std.json
# these three processes are a.k.a. SpecAugument
...
...
examples/aishell/asr1/conf/tuning/decode.yaml
浏览文件 @
efc269b7
...
...
@@ -3,9 +3,9 @@ decode_batch_size: 128
error_rate_type
:
cer
decoding_method
:
attention
# 'attention', 'ctc_greedy_search', 'ctc_prefix_beam_search', 'attention_rescoring'
ctc_weight
:
0.5
# ctc weight for attention rescoring decode mode.
decoding_chunk_size
:
1
# decoding chunk size. Defaults to -1.
decoding_chunk_size
:
-
1
# decoding chunk size. Defaults to -1.
# <0: for decoding, use full chunk.
# >0: for decoding, use fixed chunk size as set.
# 0: used for training, it's prohibited here.
num_decoding_left_chunks
:
-1
# number of left chunks for decoding. Defaults to -1.
simulate_streaming
:
Tru
e
# simulate streaming inference. Defaults to False.
simulate_streaming
:
Fals
e
# simulate streaming inference. Defaults to False.
examples/aishell/asr1/run.sh
浏览文件 @
efc269b7
...
...
@@ -3,12 +3,12 @@ source path.sh
set
-e
gpus
=
0,1,2,3
stage
=
5
stop_stage
=
5
conf_path
=
conf/c
hunk_c
onformer.yaml
stage
=
0
stop_stage
=
5
0
conf_path
=
conf/conformer.yaml
decode_conf_path
=
conf/tuning/decode.yaml
avg_num
=
20
audio_file
=
audio/zh
.wav
audio_file
=
data/demo_01_03
.wav
source
${
MAIN_ROOT
}
/utils/parse_options.sh
||
exit
1
;
...
...
@@ -44,7 +44,7 @@ fi
# Optionally, you can add LM and test it with runtime.
if
[
${
stage
}
-le
5
]
&&
[
${
stop_stage
}
-ge
5
]
;
then
# test a single .wav file
CUDA_VISIBLE_DEVICES
=
0 ./local/test_wav.sh
${
conf_path
}
${
decode_conf_path
}
exp/
chunk_conformer/checkpoints/multi_cn
${
audio_file
}
||
exit
-1
CUDA_VISIBLE_DEVICES
=
0 ./local/test_wav.sh
${
conf_path
}
${
decode_conf_path
}
exp/
${
ckpt
}
/checkpoints/
${
avg_ckpt
}
${
audio_file
}
||
exit
-1
fi
# Not supported at now!!!
...
...
paddlespeech/__init__.py
浏览文件 @
efc269b7
...
...
@@ -14,6 +14,3 @@
import
_locale
_locale
.
_getdefaultlocale
=
(
lambda
*
args
:
[
'en_US'
,
'utf8'
])
paddlespeech/s2t/exps/u2/bin/test_wav.py
浏览文件 @
efc269b7
...
...
@@ -128,12 +128,10 @@ if __name__ == "__main__":
args
=
parser
.
parse_args
()
config
=
CfgNode
(
new_allowed
=
True
)
if
args
.
config
:
print
(
f
"load config:
{
args
.
config
}
"
)
config
.
merge_from_file
(
args
.
config
)
if
args
.
decode_cfg
:
print
(
f
"load decode cfg:
{
args
.
decode_cfg
}
"
)
decode_confs
=
CfgNode
(
new_allowed
=
True
)
decode_confs
.
merge_from_file
(
args
.
decode_cfg
)
config
.
decode
=
decode_confs
...
...
paddlespeech/server/conf/ws_application.yaml
浏览文件 @
efc269b7
...
...
@@ -4,7 +4,7 @@
# SERVER SETTING #
#################################################################################
host
:
0.0.0.0
port
:
809
6
port
:
809
0
# The task format in the engin_list is: <speech task>_<engine type>
# task choices = ['asr_online', 'tts_online']
...
...
paddlespeech/server/tests/asr/online/websocket_client.py
浏览文件 @
efc269b7
...
...
@@ -105,7 +105,7 @@ class ASRAudioHandler:
def
main
(
args
):
logging
.
basicConfig
(
level
=
logging
.
INFO
)
logging
.
info
(
"asr websocket client start"
)
handler
=
ASRAudioHandler
(
"127.0.0.1"
,
809
6
)
handler
=
ASRAudioHandler
(
"127.0.0.1"
,
809
0
)
loop
=
asyncio
.
get_event_loop
()
# support to process single audio file
...
...
paddlespeech/server/ws/asr_socket.py
浏览文件 @
efc269b7
...
...
@@ -93,7 +93,6 @@ async def websocket_endpoint(websocket: WebSocket):
sample_rate
=
asr_engine
.
config
.
sample_rate
x_chunk
,
x_chunk_lens
=
asr_engine
.
preprocess
(
samples
,
sample_rate
)
print
(
x_chunk_lens
)
asr_engine
.
run
(
x_chunk
,
x_chunk_lens
)
asr_results
=
asr_engine
.
postprocess
()
asr_results
=
asr_engine
.
postprocess
()
...
...
paddlespeech/vector/cluster/diarization.py
浏览文件 @
efc269b7
...
...
@@ -18,11 +18,11 @@ A few sklearn functions are modified in this script as per requirement.
"""
import
argparse
import
warnings
from
distutils.util
import
strtobool
import
numpy
as
np
import
scipy
import
sklearn
from
distutils.util
import
strtobool
from
scipy
import
sparse
from
scipy.sparse.csgraph
import
connected_components
from
scipy.sparse.csgraph
import
laplacian
as
csgraph_laplacian
...
...
setup.py
浏览文件 @
efc269b7
...
...
@@ -168,7 +168,7 @@ class DevelopCommand(develop):
def
run
(
self
):
develop
.
run
(
self
)
# must after develop.run, or pkg install by shell will not see
#
self.execute(_post_install, (self.install_lib, ), msg="Post Install...")
self
.
execute
(
_post_install
,
(
self
.
install_lib
,
),
msg
=
"Post Install..."
)
class
InstallCommand
(
install
):
...
...
utils/DER.py
浏览文件 @
efc269b7
...
...
@@ -26,9 +26,9 @@ import argparse
import
os
import
re
import
subprocess
from
distutils.util
import
strtobool
import
numpy
as
np
from
distutils.util
import
strtobool
FILE_IDS
=
re
.
compile
(
r
"(?<=Speaker Diarization for).+(?=\*\*\*)"
)
SCORED_SPEAKER_TIME
=
re
.
compile
(
r
"(?<=SCORED SPEAKER TIME =)[\d.]+"
)
...
...
编辑
预览
Markdown
is supported
0%
请重试
或
添加新附件
.
添加附件
取消
You are about to add
0
people
to the discussion. Proceed with caution.
先完成此消息的编辑!
取消
想要评论请
注册
或
登录