Plachtaa / VITS-fast-fine-tuning

This repo is a pipeline of VITS finetuning for fast speaker adaptation TTS, and many-to-many voice conversion
Apache License 2.0
4.69k stars 705 forks source link

训练好后的模型,运行 python VC_inference.py --model_dir ./OUTPUT_MODEL/G_latest.pth --share True 报错 #454

Closed ThornbirdZhang closed 12 months ago

ThornbirdZhang commented 12 months ago

采用19分钟的短音频训练CJ模型结束。运行python VC_inference.py --model_dir ./OUTPUT_MODEL/G_latest.pth --share True报错: Traceback (most recent call last): File "VCinference.py", line 104, in = utils.load_checkpoint(args.model_dir, net_g, None) File "/data/VITS-fast-fine-tuning/utils.py", line 178, in load_checkpoint model.load_state_dict(new_state_dict) File "/opt/conda/envs/vitsFT/lib/python3.8/site-packages/torch/nn/modules/module.py", line 1671, in load_state_dict raise RuntimeError('Error(s) in loading state_dict for {}:\n\t{}'.format( RuntimeError: Error(s) in loading state_dict for SynthesizerTrn: size mismatch for enc_p.emb.weight: copying a param with shape torch.Size([52, 192]) from checkpoint, the shape in current model is torch.Size([68, 192]). 各位大神,这个是什么原因呢

ThornbirdZhang commented 12 months ago

找到原因了,json文件走了默认值