Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

加载自己的GPT-SoVITS模型失败 #108

Open
levin-go opened this issue Oct 7, 2024 · 1 comment
Open

加载自己的GPT-SoVITS模型失败 #108

levin-go opened this issue Oct 7, 2024 · 1 comment

Comments

@levin-go
Copy link

levin-go commented Oct 7, 2024

使用的是GPT-SoVITS V2,加载模型报错如下,求指导,谢谢!

模型加载中... /root/Linly-Talker/GPT_SoVITS/pretrained_models/zhiqiang2-e15.ckpt /root/Linly-Talker/GPT_SoVITS/pretrained_models/zhiqiang2_e8_s72.pth
Number of parameter: 77.61M
Traceback (most recent call last):
  File "/root/miniconda3/lib/python3.8/site-packages/gradio/queueing.py", line 495, in call_prediction
    output = await route_utils.call_process_api(
  File "/root/miniconda3/lib/python3.8/site-packages/gradio/route_utils.py", line 232, in call_process_api
    output = await app.get_blocks().process_api(
  File "/root/miniconda3/lib/python3.8/site-packages/gradio/blocks.py", line 1561, in process_api
    result = await self.call_function(
  File "/root/miniconda3/lib/python3.8/site-packages/gradio/blocks.py", line 1179, in call_function
    prediction = await anyio.to_thread.run_sync(
  File "/root/miniconda3/lib/python3.8/site-packages/anyio/to_thread.py", line 31, in run_sync
    return await get_asynclib().run_sync_in_worker_thread(
  File "/root/miniconda3/lib/python3.8/site-packages/anyio/_backends/_asyncio.py", line 937, in run_sync_in_worker_thread
    return await future
  File "/root/miniconda3/lib/python3.8/site-packages/anyio/_backends/_asyncio.py", line 867, in run
    result = context.run(func, *args)
  File "/root/miniconda3/lib/python3.8/site-packages/gradio/utils.py", line 695, in wrapper
    response = f(*args, **kwargs)
  File "/root/miniconda3/lib/python3.8/site-packages/gradio/utils.py", line 695, in wrapper
    response = f(*args, **kwargs)
  File "webui.py", line 375, in load_vits_model
    vits.load_model(all_gpt_path, all_sovits_path)
  File "/root/Linly-Talker/VITS/GPT_SoVITS.py", line 358, in load_model
    print(self.vq_model.load_state_dict(dict_s2["weight"], strict=False))
  File "/root/miniconda3/lib/python3.8/site-packages/torch/nn/modules/module.py", line 2041, 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.text_embedding.weight: copying a param with shape torch.Size([732, 192]) from checkpoint, the shape in current model is torch.Size([322, 192]).
        size mismatch for ref_enc.spectral.0.fc.weight: copying a param with shape torch.Size([128, 704]) from checkpoint, the shape in current model is torch.Size([128, 1025]).
@Kedreamix
Copy link
Owner

非常感谢你的关注,可能是我最近还未更新v2的方法,所以我会快速看看v2的能力以及对其进行更新和适配

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants