eherr / motion_preprocessing_tool

Preprocessing for the construction of statistical motion models. Provides a skeleton animation viewer and an interface to a motion database with retargeting and animation editing functions.
MIT License
17 stars 5 forks source link

KeyError: 'right_hip' #8

Open Cicistrawberry opened 1 year ago

Cicistrawberry commented 1 year ago

Hello, when I performed the retargeting operation, I encountered the following problem. Could you help me fix it, please? Thanks very much!

I ①import a bvh file ->②add new model ->③assign joints -> ④then click Guess All Coordinate Systems, but the following error will come up (no matter which skeleton I select)?

Traceback (most recent call last): File "D:\python\motion_processing_tool-main\tool\core\dialogs\skeleton_editor_dialog.py", line 635, in slot_guess_cos_map cos_map = create_local_cos_map_from_skeleton_axes_with_map(temp_skeleton) File "D:\software\Anaconda\envs\pytorch37\lib\site-packages\anim_utils\retargeting\analytical.py", line 140, in create_local_cos_map_from_skeleton_axes_with_map
body_x_axis = get_body_x_axis(skeleton)*flip File "D:\software\Anaconda\envs\pytorch37\lib\site-packages\anim_utils\retargeting\analytical.py", line 72, in get_body_x_axis rh = skeleton.skeleton_model["joints"]["right_hip"] KeyError: 'right_hip'

90a18d77-cd7e-446f-8ce5-b8fa1ca6dea3

eherr commented 1 year ago

Hi,

this means the label "right_hip" was not assigned to a joint of the skeleton. The tool uses the left and right hip joints together with the neck of the default pose to define the local x and y axis of the root. Sorry I plan to improve the documentation and the usability.