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

SadTalker generates error #955

Open
buchenhui opened this issue Aug 28, 2024 · 0 comments
Open

SadTalker generates error #955

buchenhui opened this issue Aug 28, 2024 · 0 comments

Comments

@buchenhui
Copy link

Traceback (most recent call last):
File "D:\sd-webui-aki-v4.8\python\lib\site-packages\gradio\routes.py", line 488, in run_predict
output = await app.get_blocks().process_api(
File "D:\sd-webui-aki-v4.8\python\lib\site-packages\gradio\blocks.py", line 1431, in process_api
result = await self.call_function(
File "D:\sd-webui-aki-v4.8\python\lib\site-packages\gradio\blocks.py", line 1103, in call_function
prediction = await anyio.to_thread.run_sync(
File "D:\sd-webui-aki-v4.8\python\lib\site-packages\anyio\to_thread.py", line 31, in run_sync
return await get_asynclib().run_sync_in_worker_thread(
File "D:\sd-webui-aki-v4.8\python\lib\site-packages\anyio_backends_asyncio.py", line 937, in run_sync_in_worker_thread
return await future
File "D:\sd-webui-aki-v4.8\python\lib\site-packages\anyio_backends_asyncio.py", line 867, in run
result = context.run(func, *args)
File "D:\sd-webui-aki-v4.8\python\lib\site-packages\gradio\utils.py", line 707, in wrapper
response = f(*args, **kwargs)
File "D:\sd-webui-aki-v4.8\modules\call_queue.py", line 13, in f
res = func(*args, **kwargs)
File "D:\sd-webui-aki-v4.8/extensions/SadTalker\src\gradio_demo.py", line 51, in test
self.animate_from_coeff = AnimateFromCoeff(self.sadtalker_paths, self.device)
File "D:\sd-webui-aki-v4.8/extensions/SadTalker\src\facerender\animate.py", line 70, in init
self.load_cpk_mapping(sadtalker_path['mappingnet_checkpoint'], mapping=mapping)
File "D:\sd-webui-aki-v4.8/extensions/SadTalker\src\facerender\animate.py", line 147, in load_cpk_mapping
mapping.load_state_dict(checkpoint['mapping'])
File "D:\sd-webui-aki-v4.8\python\lib\site-packages\torch\nn\modules\module.py", line 2153, in load_state_dict
raise RuntimeError('Error(s) in loading state_dict for {}:\n\t{}'.format(
RuntimeError: Error(s) in loading state_dict for MappingNet:
size mismatch for first.0.weight: copying a param with shape torch.Size([1024, 73, 7]) from checkpoint, the shape in current model is torch.Size([1024, 70, 7]).
using safetensor as default
{'checkpoint': 'D:\sd-webui-aki-v4.8\extensions\SadTalker\checkpoints\SadTalker_V0.0.2_256.safetensors', 'dir_of_BFM_fitting': 'D:\sd-webui-aki-v4.8/extensions/SadTalker/src/config', 'audio2pose_yaml_path': 'D:\sd-webui-aki-v4.8/extensions/SadTalker/src/config\auido2pose.yaml', 'audio2exp_yaml_path': 'D:\sd-webui-aki-v4.8/extensions/SadTalker/src/config\auido2exp.yaml', 'use_safetensor': True, 'mappingnet_checkpoint': 'D:\sd-webui-aki-v4.8\extensions\SadTalker\checkpoints\mapping_00229-model.pth.tar', 'facerender_yaml': 'D:\sd-webui-aki-v4.8/extensions/SadTalker/src/config\facerender.yaml'}
Traceback (most recent call last):
File "D:\sd-webui-aki-v4.8\python\lib\site-packages\gradio\routes.py", line 488, in run_predict
output = await app.get_blocks().process_api(
File "D:\sd-webui-aki-v4.8\python\lib\site-packages\gradio\blocks.py", line 1431, in process_api
result = await self.call_function(
File "D:\sd-webui-aki-v4.8\python\lib\site-packages\gradio\blocks.py", line 1103, in call_function
prediction = await anyio.to_thread.run_sync(
File "D:\sd-webui-aki-v4.8\python\lib\site-packages\anyio\to_thread.py", line 31, in run_sync
return await get_asynclib().run_sync_in_worker_thread(
File "D:\sd-webui-aki-v4.8\python\lib\site-packages\anyio_backends_asyncio.py", line 937, in run_sync_in_worker_thread
return await future
File "D:\sd-webui-aki-v4.8\python\lib\site-packages\anyio_backends_asyncio.py", line 867, in run
result = context.run(func, *args)
File "D:\sd-webui-aki-v4.8\python\lib\site-packages\gradio\utils.py", line 707, in wrapper
response = f(*args, **kwargs)
File "D:\sd-webui-aki-v4.8\modules\call_queue.py", line 13, in f
res = func(*args, **kwargs)
File "D:\sd-webui-aki-v4.8/extensions/SadTalker\src\gradio_demo.py", line 51, in test
self.animate_from_coeff = AnimateFromCoeff(self.sadtalker_paths, self.device)
File "D:\sd-webui-aki-v4.8/extensions/SadTalker\src\facerender\animate.py", line 70, in init
self.load_cpk_mapping(sadtalker_path['mappingnet_checkpoint'], mapping=mapping)
File "D:\sd-webui-aki-v4.8/extensions/SadTalker\src\facerender\animate.py", line 147, in load_cpk_mapping
mapping.load_state_dict(checkpoint['mapping'])
File "D:\sd-webui-aki-v4.8\python\lib\site-packages\torch\nn\modules\module.py", line 2153, in load_state_dict
raise RuntimeError('Error(s) in loading state_dict for {}:\n\t{}'.format(
RuntimeError: Error(s) in loading state_dict for MappingNet:
size mismatch for first.0.weight: copying a param with shape torch.Size([1024, 73, 7]) from checkpoint, the shape in current model is torch.Size([1024, 70, 7])

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

1 participant