zju3dv / Mirrored-Human

[CVPR 2021 Oral] Reconstructing 3D Human Pose by Watching Humans in the Mirror
Other
187 stars 10 forks source link

ImportError: cannot import name 'init_with_spin' #9

Open QiFuChina opened 2 years ago

QiFuChina commented 2 years ago

I got same error below (easymocap) C:\ResourceCode\EasyMocap>python apps/demo/1v1p_mirror.py data/zju-m-demo --out data/zju-m-demo-output --vis_smpl --video Traceback (most recent call last): File "apps/demo/1v1p_mirror.py", line 8, in from easymocap.estimator import SPIN, init_with_spin ImportError: cannot import name 'init_with_spin' I try to traceback filelvlp_mirror.py but I didn't know where is the model init_with_spin

odu-beyond commented 2 years ago

apps/demo/1v1p_mirror.py line 8 from easymocap.estimator import SPIN, init_with_spin ↓ from easymocap.estimator.SPIN import SPIN, init_with_spin

easymocap\estimator\SPIN\spin_api.py line 179 checkpoint = torch.load(checkpoint) ↓ checkpoint = torch.load(checkpoint, torch.device('cpu'))

ownload pretrained SPIN model here and place it to data/models/spin_checkpoints.pt. Fetch the extra data here and place the smpl_mean_params.npz to data/models/smpl_mean_params.npz. data └── models  ├── smpl_mean_params.npz  └── spin_checkpoint.pt