TCMR_RELEASE icon indicating copy to clipboard operation
TCMR_RELEASE copied to clipboard

TCMR missmatch??

Open codeHorasan opened this issue 2 years ago • 6 comments

RuntimeError: Error(s) in loading state_dict for TCMR: size mismatch for regressor.smpl.shapedirs: copying a param with shape torch.Size([6890, 3, 10]) from checkpoint, the shape in current model is torch.Size([6890, 3, 300]).

Anyone know about this?

codeHorasan avatar Jul 07 '22 20:07 codeHorasan

I am not sure what your running (demo or test?), but just change the current model to [6890, 3, 10].

hongsukchoi avatar Jul 07 '22 21:07 hongsukchoi

I am running demo, python demo.py --vid_file demo.mp4 with CPU.

I am getting this error after loading pre-trained model from "tcmr_demo_model.pth.tar", at model.load_state_dict

ckpt = ckpt['gen_state_dict'] model.load_state_dict(ckpt, strict=False)

codeHorasan avatar Jul 07 '22 21:07 codeHorasan

Version mismatch! https://github.com/hongsukchoi/TCMR_RELEASE/issues/16

You don't have to re-install or downgrade. Just change regressor.smpl.shapedirs to [6890,3,10] dimension

hongsukchoi avatar Jul 07 '22 21:07 hongsukchoi

Thank you for your help but I couldn't find on the code where I should change. It gives the error on TCMR, before even creating the SMPL model but in the error message, it mentions regressor.smpl.shapedirs. I tried to add "shapedirs = [6890,3,10]" to SMPL constructor but as I get the error before that line is compiled.

codeHorasan avatar Jul 08 '22 00:07 codeHorasan

Then, the easiest way is to match the version. smplx==0.1.13

Or as I said, change the SMPL's shapedirs to 10 here https://github.com/hongsukchoi/TCMR_RELEASE/blob/ade5ab5e2bd8b1a26338406c0b272d2a16f85070/lib/models/smpl.py#L61

hongsukchoi avatar Jul 08 '22 01:07 hongsukchoi

Thank you for your help but I couldn't find on the code where I should change. It gives the error on TCMR, before even creating the SMPL model but in the error message, it mentions regressor.smpl.shapedirs. I tried to add "shapedirs = [6890,3,10]" to SMPL constructor but as I get the error before that line is compiled.

Hello, have you solved this problem? I have the same problem, do you know how to change the code? Thanks.

ydl832 avatar Feb 26 '24 21:02 ydl832