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

train error about h36m #37

Closed
SaterZhan opened this issue Jan 5, 2022 · 2 comments
Closed

train error about h36m #37

SaterZhan opened this issue Jan 5, 2022 · 2 comments

Comments

@SaterZhan
Copy link

hello,i meet a question like this,i failed to resolve it ,need your help,thanks
INFO:datasets.base_dataset:len of h36m-p2-mosh: 26859
0%| | 0/200 [00:23<?, ?it/s]
Traceback (most recent call last):_Jan05-08-53-12-BCm Epoch 0: 0%| | 1/4877 [00:12<16:54:58, 12.49s/it]
File "train.py", line 69, in
main(None, ngpus_per_node, options)
File "train.py", line 38, in main
trainer.fit()
File "/home/data1/zxt/PyMAF-master/core/trainer.py", line 502, in fit
self.train(epoch)
File "/home/data1/zxt/PyMAF-master/core/trainer.py", line 278, in train
out = self.train_step(batch)
File "/home/data1/zxt/PyMAF-master/core/trainer.py", line 324, in train_step
gt_out = self.smpl(betas=gt_betas, body_pose=gt_pose[:,3:], global_orient=gt_pose[:,:3])
File "/home/data2/anaconda1/envs/pymaf/lib/python3.6/site-packages/torch/nn/modules/module.py", line 493, in call
result = self.forward(*input, **kwargs)
File "/home/data1/zxt/PyMAF-master/models/smpl.py", line 34, in forward
smpl_output = super().forward(*args, **kwargs)
File "/home/data2/anaconda1/envs/pymaf/lib/python3.6/site-packages/smplx/body_models.py", line 376, in forward
self.lbs_weights, pose2rot=pose2rot, dtype=self.dtype)
File "/home/data2/anaconda1/envs/pymaf/lib/python3.6/site-packages/smplx/lbs.py", line 179, in lbs
v_shaped = v_template + blend_shapes(betas, shapedirs)
File "/home/data2/anaconda1/envs/pymaf/lib/python3.6/site-packages/smplx/lbs.py", line 265, in blend_shapes
blend_shape = torch.einsum('bl,mkl->bmk', [betas, shape_disps])
File "/home/data2/anaconda1/envs/pymaf/lib/python3.6/site-packages/torch/functional.py", line 211, in einsum
return torch._C._VariableFunctions.einsum(equation, operands)
RuntimeError: size of dimension does not match previous size, operand 1, dim 2
pymaf_res50_as_lp3_mlp256-128-64-5_Jan05-08-53-12-BCm Epoch 0: 0%|

@HongwenZhang
Copy link
Owner

Hi, this issue may be raised by the incompatible number of the shape components in SMPL (I am not so sure). We use 10 shape components with version 0.1.13 of smplx. Please also refer to issue #4.

@SaterZhan
Copy link
Author

thanks so much, you are right! i'm wrong as used another version of SMPL!

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