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
11.21k stars 1.86k forks source link

[TTS][Errno 2] No such file or directory: '/home/wanghx/Documents/MFA/newdir/train/mfcc/raw_mfcc.0.scp' #3220

Open haoxue1215 opened 1 year ago

haoxue1215 commented 1 year ago

For support and discussions, please use our Discourse forums. Calculating MFCCs... Traceback (most recent call last): File "aligner/command_line/align.py", line 186, in File "aligner/command_line/align.py", line 142, in validate_args File "aligner/command_line/align.py", line 94, in align_corpus File "aligner/aligner/pretrained.py", line 74, in init File "aligner/aligner/pretrained.py", line 122, in setup File "aligner/aligner/base.py", line 89, in setup File "aligner/corpus.py", line 979, in initialize_corpus File "aligner/corpus.py", line 852, in create_mfccs File "aligner/corpus.py", line 863, in _combine_feats FileNotFoundError: [Errno 2] No such file or directory: '/home/wanghx/Documents/MFA/newdir/train/mfcc/raw_mfcc.0.scp' [98494] Failed to execute script align generate durations.txt extract feature [nltk_data] Error loading averaged_perceptron_tagger: <urlopen error [nltk_data] [Errno 111] Connection refused> [nltk_data] Error loading cmudict: <urlopen error [Errno 111] [nltk_data] Connection refused> /home/wanghx/PaddleSpeech/tts/lib/python3.7/site-packages/librosa/core/constantq.py:1059: DeprecationWarning: np.complex is a deprecated alias for the builtin complex. To silence this warning, use complex by itself. Doing this will not modify any behavior and is safe. If you specifically wanted the numpy scalar type, use np.complex128 here. Deprecated in NumPy 1.20; for more details and guidance: https://numpy.org/devdocs/release/1.20.0-notes.html#deprecations dtype=np.complex, 196 1 100%|█████████████████| 196/196 [00:00<00:00, 16033.77it/s] Done Traceback (most recent call last): File "local/extract_feature.py", line 352, in replace_spkid=args.replace_spkid) File "local/extract_feature.py", line 267, in extract_feature vocab_speaker, dump_dir, "train") File "local/extract_feature.py", line 160, in normalize "energy": np.load, File "/home/wanghx/PaddleSpeech/paddlespeech/t2s/datasets/data_table.py", line 47, in init assert len(data) > 0, "This dataset has no examples" AssertionError: This dataset has no examples

If you've found a bug then please create an issue with the following information:

Describe the bug A clear and concise description of what the bug is.

To Reproduce Steps to reproduce the behavior:

  1. Go to '...'
  2. Click on '....'
  3. Scroll down to '....'
  4. See error

Expected behavior A clear and concise description of what you expected to happen.

Screenshots If applicable, add screenshots to help explain your problem.

Environment (please complete the following information):

Additional context Add any other context about the problem here.

安装官方给的教程微调训练,官方要的文件夹内容都准备好了,但是报这个文件缺失错误,我看了下确实没有这个文件,但是官方给的文件里面并没有这个路径的这个文件,请问是什么时候生成的吗?我应该怎么解决呢?

zh794390558 commented 1 year ago

看着是生成mfcc特征的时候生成的,详细的可以参看MFA的文档。或 https://mp.weixin.qq.com/s?__biz=MzkyMTQyMjY0MA==&mid=2247487768&idx=1&sn=f1f44e8439926e7539621374cb467206&chksm=c1828f47f6f5065108c087379b782c8ea43fa23e6dfe5a5cb2e2c08caf6871d6cb37eab5a304#rd

gotoolkits commented 1 year ago

也有同样问题,按照操作指南文档配置与下载,在使用speech_web点击“一键微调”后报错了一大堆的错误:

(.venv) ubuntu@VM-ubuntu:~/software/paddleSpeech/PaddleSpeech/demos/speech_web/speech_server$ python vc.py --port 8010 INFO: Started server process [330120] INFO: Waiting for application startup. INFO: Application startup complete. INFO: Uvicorn running on http://0.0.0.0:8010 (Press CTRL+C to quit)

        # check oov
        python3 /home/ubuntu/software/paddleSpeech/PaddleSpeech/examples/other/tts_finetune/tts3/local/check_oov.py                 --input_dir=/home/ubuntu/software/paddleSpeech/PaddleSpeech/demos/speech_web/speech_server/source/wav/finetune/default                 --pretrained_model_dir=/home/ubuntu/software/paddleSpeech/PaddleSpeech/demos/speech_web/speech_server/source/model/fastspeech2_aishell3_ckpt_1.1.0                 --newdir_name=newdir                 --lang=zh

        # get mfa result
        python3 /home/ubuntu/software/paddleSpeech/PaddleSpeech/examples/other/tts_finetune/tts3/local/get_mfa_result.py                 --input_dir=/home/ubuntu/software/paddleSpeech/PaddleSpeech/demos/speech_web/speech_server/source/wav/finetune/default/newdir                 --mfa_dir=/home/ubuntu/software/paddleSpeech/PaddleSpeech/demos/speech_web/speech_server/tmp_dir/finetune/default/mfa_result                 --lang=zh

        # generate durations.txt
        python3 /home/ubuntu/software/paddleSpeech/PaddleSpeech/examples/other/tts_finetune/tts3/local/generate_duration.py                 --mfa_dir=/home/ubuntu/software/paddleSpeech/PaddleSpeech/demos/speech_web/speech_server/tmp_dir/finetune/default/mfa_result 

        # extract feature
        python3 /home/ubuntu/software/paddleSpeech/PaddleSpeech/examples/other/tts_finetune/tts3/local/extract_feature.py                 --duration_file="./durations.txt"                 --input_dir=/home/ubuntu/software/paddleSpeech/PaddleSpeech/demos/speech_web/speech_server/source/wav/finetune/default/newdir                 --dump_dir=/home/ubuntu/software/paddleSpeech/PaddleSpeech/demos/speech_web/speech_server/tmp_dir/finetune/default/dump                 --pretrained_model_dir=/home/ubuntu/software/paddleSpeech/PaddleSpeech/demos/speech_web/speech_server/source/model/fastspeech2_aishell3_ckpt_1.1.0

        # create finetune env
        python3 /home/ubuntu/software/paddleSpeech/PaddleSpeech/examples/other/tts_finetune/tts3/local/prepare_env.py                 --pretrained_model_dir=/home/ubuntu/software/paddleSpeech/PaddleSpeech/demos/speech_web/speech_server/source/model/fastspeech2_aishell3_ckpt_1.1.0                 --output_dir=/home/ubuntu/software/paddleSpeech/PaddleSpeech/demos/speech_web/speech_server/tmp_dir/finetune/default/exp

        # finetune
        python3 /home/ubuntu/software/paddleSpeech/PaddleSpeech/examples/other/tts_finetune/tts3/local/finetune.py                 --pretrained_model_dir=/home/ubuntu/software/paddleSpeech/PaddleSpeech/demos/speech_web/speech_server/source/model/fastspeech2_aishell3_ckpt_1.1.0                 --dump_dir=/home/ubuntu/software/paddleSpeech/PaddleSpeech/demos/speech_web/speech_server/tmp_dir/finetune/default/dump                 --output_dir=/home/ubuntu/software/paddleSpeech/PaddleSpeech/demos/speech_web/speech_server/tmp_dir/finetune/default/exp                 --ngpu=0                 --epoch=100                 --finetune_config=conf/tts3_finetune.yaml

align.py:60: YAMLLoadWarning: calling yaml.load() without Loader=... is deprecated, as the default Loader is unsafe. Please read https://msg.pyyaml.org/load for full details. Setting up corpus information... Number of speakers in corpus: 1, average number of utterances per speaker: 12.0 /home/ubuntu/software/paddleSpeech/PaddleSpeech/demos/speech_web/speech_server/tools/montreal-forced-aligner/lib/aligner/models.py:87: YAMLLoadWarning: calling yaml.load() without Loader=... is deprecated, as the default Loader is unsafe. Please read https://msg.pyyaml.org/load for full details. Creating dictionary information... Setting up training data... Calculating MFCCs... Traceback (most recent call last): File "aligner/command_line/align.py", line 186, in File "aligner/command_line/align.py", line 142, in validate_args File "aligner/command_line/align.py", line 94, in align_corpus File "aligner/aligner/pretrained.py", line 74, in init File "aligner/aligner/pretrained.py", line 122, in setup File "aligner/aligner/base.py", line 89, in setup File "aligner/corpus.py", line 979, in initialize_corpus File "aligner/corpus.py", line 852, in create_mfccs File "aligner/corpus.py", line 863, in _combine_feats FileNotFoundError: [Errno 2] No such file or directory: '/home/ubuntu/Documents/MFA/newdir/train/mfcc/raw_mfcc.0.scp' [330266] Failed to execute script align Traceback (most recent call last): File "/home/ubuntu/software/paddleSpeech/PaddleSpeech/examples/other/tts_finetune/tts3/local/generate_duration.py", line 17, in from utils.gen_duration_from_textgrid import gen_duration_from_textgrid ModuleNotFoundError: No module named 'utils.gen_duration_from_textgrid' /home/ubuntu/software/paddleSpeech/PaddleSpeech/.venv/lib/python3.8/site-packages/librosa/core/constantq.py:1059: DeprecationWarning: np.complex is a deprecated alias for the builtin complex. To silence this warning, use complex by itself. Doing this will not modify any behavior and is safe. If you specifically wanted the numpy scalar type, use np.complex128 here. Deprecated in NumPy 1.20; for more details and guidance: https://numpy.org/devdocs/release/1.20.0-notes.html#deprecations dtype=np.complex, Traceback (most recent call last): File "/home/ubuntu/software/paddleSpeech/PaddleSpeech/examples/other/tts_finetune/tts3/local/extract_feature.py", line 30, in from paddlespeech.t2s.datasets.get_feats import Energy File "/home/ubuntu/software/paddleSpeech/PaddleSpeech/.venv/lib/python3.8/site-packages/paddlespeech/t2s/datasets/get_feats.py", line 17, in import pyworld File "/home/ubuntu/software/paddleSpeech/PaddleSpeech/.venv/lib/python3.8/site-packages/pyworld/init.py", line 7, in from .pyworld import * File "pyworld/pyworld.pyx", line 1, in init pyworld.pyworld ValueError: numpy.ndarray size changed, may indicate binary incompatibility. Expected 96 from C header, got 88 from PyObject /home/ubuntu/software/paddleSpeech/PaddleSpeech/.venv/lib/python3.8/site-packages/librosa/core/constantq.py:1059: DeprecationWarning: np.complex is a deprecated alias for the builtin complex. To silence this warning, use complex by itself. Doing this will not modify any behavior and is safe. If you specifically wanted the numpy scalar type, use np.complex128 here. Deprecated in NumPy 1.20; for more details and guidance: https://numpy.org/devdocs/release/1.20.0-notes.html#deprecations dtype=np.complex, rank: 0, pid: 330331, parent_pid: 330236 multiple speaker fastspeech2! Traceback (most recent call last): File "/home/ubuntu/software/paddleSpeech/PaddleSpeech/examples/other/tts_finetune/tts3/local/finetune.py", line 269, in train_sp(train_args, config) File "/home/ubuntu/software/paddleSpeech/PaddleSpeech/examples/other/tts_finetune/tts3/local/finetune.py", line 102, in train_sp with open(args.speaker_dict, 'rt') as f: FileNotFoundError: [Errno 2] No such file or directory: '/home/ubuntu/software/paddleSpeech/PaddleSpeech/demos/speech_web/speech_server/tmp_dir/finetune/default/dump/speaker_id_map.txt'

        # check oov
        python3 /home/ubuntu/software/paddleSpeech/PaddleSpeech/examples/other/tts_finetune/tts3/local/check_oov.py                 --input_dir=/home/ubuntu/software/paddleSpeech/PaddleSpeech/demos/speech_web/speech_server/source/wav/finetune/default                 --pretrained_model_dir=/home/ubuntu/software/paddleSpeech/PaddleSpeech/demos/speech_web/speech_server/source/model/fastspeech2_aishell3_ckpt_1.1.0                 --newdir_name=newdir                 --lang=zh

        # get mfa result
        python3 /home/ubuntu/software/paddleSpeech/PaddleSpeech/examples/other/tts_finetune/tts3/local/get_mfa_result.py                 --input_dir=/home/ubuntu/software/paddleSpeech/PaddleSpeech/demos/speech_web/speech_server/source/wav/finetune/default/newdir                 --mfa_dir=/home/ubuntu/software/paddleSpeech/PaddleSpeech/demos/speech_web/speech_server/tmp_dir/finetune/default/mfa_result                 --lang=zh

        # generate durations.txt
        python3 /home/ubuntu/software/paddleSpeech/PaddleSpeech/examples/other/tts_finetune/tts3/local/generate_duration.py                 --mfa_dir=/home/ubuntu/software/paddleSpeech/PaddleSpeech/demos/speech_web/speech_server/tmp_dir/finetune/default/mfa_result 

        # extract feature
        python3 /home/ubuntu/software/paddleSpeech/PaddleSpeech/examples/other/tts_finetune/tts3/local/extract_feature.py                 --duration_file="./durations.txt"                 --input_dir=/home/ubuntu/software/paddleSpeech/PaddleSpeech/demos/speech_web/speech_server/source/wav/finetune/default/newdir                 --dump_dir=/home/ubuntu/software/paddleSpeech/PaddleSpeech/demos/speech_web/speech_server/tmp_dir/finetune/default/dump                 --pretrained_model_dir=/home/ubuntu/software/paddleSpeech/PaddleSpeech/demos/speech_web/speech_server/source/model/fastspeech2_aishell3_ckpt_1.1.0

        # create finetune env
        python3 /home/ubuntu/software/paddleSpeech/PaddleSpeech/examples/other/tts_finetune/tts3/local/prepare_env.py                 --pretrained_model_dir=/home/ubuntu/software/paddleSpeech/PaddleSpeech/demos/speech_web/speech_server/source/model/fastspeech2_aishell3_ckpt_1.1.0                 --output_dir=/home/ubuntu/software/paddleSpeech/PaddleSpeech/demos/speech_web/speech_server/tmp_dir/finetune/default/exp

        # finetune
        python3 /home/ubuntu/software/paddleSpeech/PaddleSpeech/examples/other/tts_finetune/tts3/local/finetune.py                 --pretrained_model_dir=/home/ubuntu/software/paddleSpeech/PaddleSpeech/demos/speech_web/speech_server/source/model/fastspeech2_aishell3_ckpt_1.1.0                 --dump_dir=/home/ubuntu/software/paddleSpeech/PaddleSpeech/demos/speech_web/speech_server/tmp_dir/finetune/default/dump                 --output_dir=/home/ubuntu/software/paddleSpeech/PaddleSpeech/demos/speech_web/speech_server/tmp_dir/finetune/default/exp                 --ngpu=0                 --epoch=100                 --finetune_config=conf/tts3_finetune.yaml

运行结果: 1

starccy commented 1 year ago

应该是要删一个 so 文件,参考:https://github.com/PaddlePaddle/PaddleSpeech/issues/2319#issuecomment-1229405871