PaddlePaddle / PaddleSpeech

Easy-to-use Speech Toolkit including Self-Supervised Learning model, SOTA/Streaming ASR with punctuation, Streaming TTS with text frontend, Speaker Verification System, End-to-End Speech Translation and Keyword Spotting. Won NAACL2022 Best Demo Award.
https://paddlespeech.readthedocs.io
Apache License 2.0
10.99k stars 1.83k forks source link

ernie-sat 运行报错 #2286

Closed sixyang closed 2 years ago

sixyang commented 2 years ago

运行 run_gen_en_new.sh 出现如下问题:

root@container-c6d2118d3c-6824b4ba:~/xx/PaddleSpeech-r1.1.0/examples/ernie_sat# ./run_gen_en_new.sh 

new_str is  We are trying to establish a date.I enjoy my life, do you?
Traceback (most recent call last):
  File "local/inference_new.py", line 613, in <module>
    data_dict = evaluate(
  File "local/inference_new.py", line 599, in evaluate
    results_dict = get_wav(
  File "local/inference_new.py", line 51, in get_wav
    wav_org, output_feat, old_span_bdy, new_span_bdy, fs, hop_length = get_mlm_output(
  File "local/inference_new.py", line 548, in get_mlm_output
    mlm_model, train_conf = load_model(model_name)
  File "local/inference_new.py", line 81, in load_model
    odim = conf.n_mels
  File "/root/miniconda3/lib/python3.8/site-packages/yacs/config.py", line 141, in __getattr__
    raise AttributeError(name)
AttributeError: n_mels

运行 run_gen_en.sh 显示缺失这个文件:

root@container-c6d2118d3c-6824b4ba:~/xx/PaddleSpeech-r1.1.0/examples/ernie_sat# ./run_gen_en.sh

new_str is  We are trying to establish a date.I enjoy my life, do you?
W0822 18:15:55.987232 38375 device_context.cc:447] Please NOTE: device: 0, GPU Compute Capability: 8.6, Driver API Version: 11.6, Runtime API Version: 11.2
W0822 18:15:55.989818 38375 device_context.cc:465] device: 0, cuDNN Version: 8.1.
sh: 1: tools/htk/HTKTools/HCopy: not found
sh: 1: tools/htk/HTKTools/HVite: not found
Traceback (most recent call last):
  File "local/inference.py", line 600, in <module>
    data_dict = evaluate(
  File "local/inference.py", line 586, in evaluate
    results_dict = get_wav(
  File "local/inference.py", line 49, in get_wav
    wav_org, output_feat, old_span_bdy, new_span_bdy, fs, hop_length = get_mlm_output(
  File "local/inference.py", line 549, in get_mlm_output
    return decode_with_model(
  File "local/inference.py", line 491, in decode_with_model
    batch, old_span_bdy, new_span_bdy = prep_feats(
  File "local/inference.py", line 450, in prep_feats
    wav, phns, mfa_start, mfa_end, old_span_bdy, new_span_bdy = prep_feats_with_dur(
  File "local/inference.py", line 340, in prep_feats_with_dur
    mfa_start, mfa_end, old_phns, new_phns, span_to_repl, span_to_add = get_phns_and_spans(
  File "local/inference.py", line 168, in get_phns_and_spans
    intervals, word2phns = alignment(wav_path, old_str)
  File "/root/autodl-tmp/PaddleSpeech-r1.1.0/examples/ernie_sat/local/align.py", line 348, in alignment
    with open(tmpbase + '.aligned', 'r') as fid:
FileNotFoundError: [Errno 2] No such file or directory: '/tmp/root_38375.aligned'

请问如何解决,谢谢!

sixyang commented 2 years ago

同时追问一下~ 那个 aishell3 的 ernie-sat 的 README 什么都没有,请问会更新吗?

yt605155624 commented 2 years ago
  1. 不要跑 *_new.sh , 跑不带 new 的,带 new 的要 link aishell3(vctk)(aishell3_vctk)/ernie_sat/conf/default.yaml 过来
  2. 请按照 readme, 编译 htk 到指定位置
  3. ernie-sat 目前还在开发中,相关 README 后续会补齐
sixyang commented 2 years ago
  1. 不要跑 *_new.sh , 跑不带 new 的,带 new 的要 link aishell3(vctk)(aishell3_vctk)/ernie_sat/conf/default.yaml 过来
  2. 请按照 readme, 编译 htk 到指定位置
  3. ernie-sat 目前还在开发中,相关 README 后续会补齐

好的,感谢!

yt605155624 commented 2 years ago

ERNIE-SAT 示例已完成,欢迎试用:

纯中文:https://github.com/PaddlePaddle/PaddleSpeech/tree/develop/examples/aishell3/ernie_sat 纯英文:https://github.com/PaddlePaddle/PaddleSpeech/tree/develop/examples/vctk/ernie_sat 中英文混合:https://github.com/PaddlePaddle/PaddleSpeech/tree/develop/examples/aishell3_vctk/ernie_sat