carlosedubarreto / b3d_mocap_import

addon for blender to import mocap data from tools like easymocap, frankmocap and Vibe
106 stars 14 forks source link

Use of Easymocap to obtain a output with file replacement #30

Open italosalgado14 opened 2 years ago

italosalgado14 commented 2 years ago

Hi!. Thanks for the code. And trying to get the Easymocap output to import it into Blender, but I have had problems with the output even though I have replaced the 2 files indicated in the Git: (env) laila@laila:~/Nexar/EasyMocapP$ python apps/demo/mv1p.py 0_input/sample --out 1_output/sample/smplx --vis_det --vis_repro --undis --sub_vis 1 7 13 19 --body bodyhandface --model smplx --gender male --vis_smpl --write_smpl_full

Demo code for multiple views and one person:

- Input : 0_input/sample => 1, 2, 3, 4, 5, 6, 7, 8, 9, 10, 11, 12, 13, 14, 15, 16, 17, 18, 19, 20, 21, 22, 23
- Output: 1_output/sample/smplx
- Body  : smplx=>male, bodyhandface

triangulation: 100%|██████████████████████████| 800/800 [05:54<00:00, 2.26it/s] dump: 100%|█████████████████████████████████| 800/800 [00:00<00:00, 2730.57it/s] loading: 100%|███████████████████████████████| 800/800 [00:05<00:00, 145.35it/s] Traceback (most recent call last): File "/home/laila/Nexar/EasyMocapP/apps/demo/mv1p.py", line 113, in mv1pmf_smpl(dataset, args) File "/home/laila/Nexar/EasyMocapP/apps/demo/mv1p.py", line 70, in mv1pmf_smpl params = smpl_from_keypoints3d2d(body_model, kp3ds, keypoints2d, bboxes, File "/home/laila/Nexar/EasyMocapP/easymocap/pipeline/basic.py", line 58, in smpl_from_keypoints3d2d params_init = body_model.init_params(nFrames=1) File "/home/laila/Nexar/EasyMocapP/env/lib/python3.9/site-packages/torch/nn/modules/module.py", line 947, in getattr raise AttributeError("'{}' object has no attribute '{}'".format( AttributeError: 'SMPLlayer' object has no attribute 'init_params' (env) laila@laila:~/Nexar/EasyMocapP$

What error could be associated with this? I am using the June 18 version of Easymocap, when I got this error: https://github.com/carlosedubarreto/b3d_mocap_import/issues/14

Thanks!

italosalgado14 commented 2 years ago

AutoEdit: I copy the function init_params from the original Easymocap File and put them in your edited file (this is not necesary, use original EasyMocap Proyect), and use the model SMPL-X from the "add-on of SMPL-X for Blender" (see https://www.youtube.com/watch?v=-vvSjAyiK_g video explain this). And its works! =)

carlosedubarreto commented 2 years ago

Thats amazing. And I'm happy that it worked, because looking at the error, I have no idea what could be wrong 😅

But I have some news. I guess you are doing the process using the python version, that you have to deal with everything in the command line.

Last week I release a easier version, that you can do everything inside blender. so it gets much easier in the end.

you can get it for free at https://carlosedubarreto.gumroad.com/l/ceb_easymocap_blender

And I'm editing a video showing the full workflow I did to get from the raw video, to sync them manually and have the result 3d motion in blender.

Thats probably going to be released in a few hours, at: https://www.youtube.com/c/CEBStudios