babysor / MockingBird

🚀AI拟声: 5秒内克隆您的声音并生成任意语音内容 Clone a voice in 5 seconds to generate arbitrary speech in real-time
Other
35.36k stars 5.21k forks source link

batch_size报错, #253

Open zzh666123321 opened 2 years ago

zzh666123321 commented 2 years ago

File "E:\python_learning\AI算法\MockingBird-main\synthesizer\models\tacotron.py", line 547, in load self.load_state_dict(checkpoint["model_state"], strict=False) File "E:\Anaconda\envs\python_learning\lib\site-packages\torch\nn\modules\module.py", line 1044, in load_state_dict raise RuntimeError('Error(s) in loading state_dict for {}:\n\t{}'.format( RuntimeError: Error(s) in loading state_dict for Tacotron: size mismatch for encoder_proj.weight: copying a param with shape torch.Size([12 8, 512]) from checkpoint, the shape in current model is torch.Size([128, 1024]). size mismatch for decoder.attn_rnn.weight_ih: copying a param with shape torch.Size([384, 768]) from checkpoint, the shape in current model is torch.Size([384, 1280]). size mismatch for decoder.rnn_input.weight: copying a param with shape torch.Size([1024, 640]) from checkpoint, the shape in current model is torch.Size([1024, 1152]). size mismatch for decoder.stop_proj.weight: copying a param with shape torch.Size([1, 1536]) from checkpoint, the shape in current model is torch.Size([1, 2048]).

michael20102013 commented 2 years ago

同样的错误

Howie-hxu commented 2 years ago

你需要切换到tag v0.0.1的版本,然后加入#issue 37的修改。 切换tag的命令:git checkout -b local_tag_0.0.1 v0.0.1