[babysor/MockingBird]报错RuntimeError: Numpy is not available

2024-07-16 424 views
3

使用最新版本无修改 使用的模型 出现报错 Traceback (most recent call last): File "G:\MockingBirdzip\MockingBird-main\toolbox__init.py", line 111, in func = lambda: self.load_from_browser(self.ui.browse_file()) File "G:\MockingBirdzip\MockingBird-main\toolbox__init__.py", line 191, in load_from_browser self.add_real_utterance(wav, name, speaker_name) File "G:\MockingBirdzip\MockingBird-main\toolbox\init__.py", line 215, in add_real_utterance embed, partialembeds, = encoder.embed_utterance(encoder_wav, return_partials=True) File "G:\MockingBirdzip\MockingBird-main\encoder\inference.py", line 164, in embed_utterance partial_embeds = embed_frames_batch(frames_batch) File "G:\MockingBirdzip\MockingBird-main\encoder\inference.py", line 62, in embed_frames_batch frames = torch.from_numpy(frames_batch).to(_device) RuntimeError: Numpy is not available

image 控制台全文C:\Users\admin\AppData\Local\Programs\Python\Python310\python.exe G:/MockingBirdzip/MockingBird-main/demo_toolbox.py C:\Users\admin\AppData\Local\Programs\Python\Python310\lib\site-packages\torch_masked__init__.py:223: UserWarning: Failed to initialize NumPy: module compiled against API version 0xf but this version of numpy is 0xe (Triggered internally at ..\torch\csrc\utils\tensor_numpy.cpp:68.) example_input = torch.tensor([[-3, -2, -1], [0, 1, 2]]) G:\MockingBirdzip\MockingBird-main\encoder\audio.py:13: UserWarning: Unable to import 'webrtcvad'. This package enables noise removal and is recommended. warn("Unable to import 'webrtcvad'. This package enables noise removal and is recommended.") Arguments: datasets_root: None vc_mode: False enc_models_dir: encoder\saved_models syn_models_dir: synthesizer\saved_models voc_models_dir: vocoder\saved_models extractor_models_dir: ppg_extractor\saved_models convertor_models_dir: ppg2mel\saved_models cpu: False seed: None no_mp3_support: False

Warning: you did not pass a root directory for datasets as argument. The recognized datasets are: LibriSpeech/dev-clean LibriSpeech/dev-other LibriSpeech/test-clean LibriSpeech/test-other LibriSpeech/train-clean-100 LibriSpeech/train-clean-360 LibriSpeech/train-other-500 LibriTTS/dev-clean LibriTTS/dev-other LibriTTS/test-clean LibriTTS/test-other LibriTTS/train-clean-100 LibriTTS/train-clean-360 LibriTTS/train-other-500 LJSpeech-1.1 VoxCeleb1/wav VoxCeleb1/test_wav VoxCeleb2/dev/aac VoxCeleb2/test/aac VCTK-Corpus/wav48 aidatatang_200zh/corpus/dev aidatatang_200zh/corpus/test aishell3/test/wav magicdata/train Feel free to add your own. You can still use the toolbox by recording samples yourself. Loaded encoder "pretrained.pt" trained to step 1594501 Traceback (most recent call last): File "G:\MockingBirdzip\MockingBird-main\toolbox__init.py", line 111, in func = lambda: self.load_from_browser(self.ui.browse_file()) File "G:\MockingBirdzip\MockingBird-main\toolbox__init__.py", line 191, in load_from_browser self.add_real_utterance(wav, name, speaker_name) File "G:\MockingBirdzip\MockingBird-main\toolbox\init__.py", line 215, in add_real_utterance embed, partialembeds, = encoder.embed_utterance(encoder_wav, return_partials=True) File "G:\MockingBirdzip\MockingBird-main\encoder\inference.py", line 164, in embed_utterance partial_embeds = embed_frames_batch(frames_batch) File "G:\MockingBirdzip\MockingBird-main\encoder\inference.py", line 62, in embed_frames_batch frames = torch.from_numpy(frames_batch).to(_device) RuntimeError: Numpy is not available

回答

1

是刚导入样本语音时报错的

3

可能是我用的代码不是最新的代码训练的?猜测,我的代码是大约2个月前的代码,或许新代码和旧代码的模型不通用,我等会把我的代码上传一份给你试试

6

将requirements.txt中numpy的版本调整一下,我这边调整到1.20.0,就不报错了。