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

RuntimeError: Sizes of tensors must match except in dimension 2. Got 31 and 30 (The offending index is 0) #34

Open
us-Mike opened this issue Mar 1, 2024 · 0 comments

Comments

@us-Mike
Copy link

us-Mike commented Mar 1, 2024

Traceback (most recent call last):
File "inference_for_demo_video.py", line 238, in
no_move=False,
File "/home/yaohs/miniconda3/envs/dreamtalk/lib/python3.7/site-packages/torch/autograd/grad_mode.py", line 27, in decorate_context
return func(*args, **kwargs)
File "/home/yaohs/Work/dreamtalk/generators/utils.py", line 102, in render_video
output_dict = net_G(cur_src_img, win_exp)
File "/home/yaohs/miniconda3/envs/dreamtalk/lib/python3.7/site-packages/torch/nn/modules/module.py", line 889, in _call_impl
result = self.forward(*input, **kwargs)
File "/home/yaohs/Work/dreamtalk/generators/face_model.py", line 35, in forward
output = self.warpping_net(input_image, descriptor)
File "/home/yaohs/miniconda3/envs/dreamtalk/lib/python3.7/site-packages/torch/nn/modules/module.py", line 889, in _call_impl
result = self.forward(*input, **kwargs)
File "/home/yaohs/Work/dreamtalk/generators/face_model.py", line 94, in forward
output = self.hourglass(input_image, descriptor)
File "/home/yaohs/miniconda3/envs/dreamtalk/lib/python3.7/site-packages/torch/nn/modules/module.py", line 889, in _call_impl
result = self.forward(*input, **kwargs)
File "/home/yaohs/Work/dreamtalk/generators/base_function.py", line 39, in forward
return self.decoder(self.encoder(x, z), z)
File "/home/yaohs/miniconda3/envs/dreamtalk/lib/python3.7/site-packages/torch/nn/modules/module.py", line 889, in _call_impl
result = self.forward(*input, **kwargs)
File "/home/yaohs/Work/dreamtalk/generators/base_function.py", line 89, in forward
out = torch.cat([out, x.pop()], 1) if self.skip_connect else out
RuntimeError: Sizes of tensors must match except in dimension 2. Got 31 and 30 (The offending index is 0)

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