retarget_bvh issue

Issue #872 resolved
Noname created an issue

Hello,

I have issue with retarget_bvh but unfortunately that project don’t have enabled issues o git.

So I use blender 3.0.1 and:

  1. import BVH
  2. select imported armature and use function “Load and Retarget”
  3. becaue those bvh construct same armatue I would expect that mapping will happen 1:1, but apparently that’s not he case and error happens:
Python: Traceback (most recent call last):
  File "C:\Users\user\AppData\Roaming\Blender Foundation\Blender\3.0\scripts\addons\Diffeomorphic-retarget_bvh-942ae13d47df\utils.py", line 334, in execute
    self.run(context)
  File "C:\Users\user\AppData\Roaming\Blender Foundation\Blender\3.0\scripts\addons\Diffeomorphic-retarget_bvh-942ae13d47df\retarget.py", line 633, in run
    info = self.retarget(context, filepath)
  File "C:\Users\user\AppData\Roaming\Blender Foundation\Blender\3.0\scripts\addons\Diffeomorphic-retarget_bvh-942ae13d47df\retarget.py", line 657, in retarget
    self.renameAndRescaleBvh(context, srcRig, trgRig)
  File "C:\Users\user\AppData\Roaming\Blender Foundation\Blender\3.0\scripts\addons\Diffeomorphic-retarget_bvh-942ae13d47df\load.py", line 613, in renameAndRescaleBvh
    self.rescaleRig(trgRig, srcRig)
  File "C:\Users\user\AppData\Roaming\Blender Foundation\Blender\3.0\scripts\addons\Diffeomorphic-retarget_bvh-942ae13d47df\load.py", line 575, in rescaleRig
    trgScale = upleg1.length
AttributeError: 'NoneType' object has no attribute 'length'

location: <unknown location>:-1

In armature there is no bone named upleg1.

It would be nice if importer could offer 1:1 mapping option.

Thanks in advance and best regards

Comments (4)

  1. Noname reporter

    I managed to solve issue by creating new rig definition (json file) so I guess this can be ignored, but still I’m wondering if 1:1 translation could be possible ? It seams like check for upleg1 existence could resolve issue (plus any others).

  2. Thomas Larsson repo owner

    I shut down the bug tracker for the retargeter because I didn’t want to monitor yet another webpage. The addon info points to this webpage.

    The retargeter uses the length of the thigh bone to scale translations. The idea is that the thigh length matters for walk cycles, and almost every character has a thigh. However, for that to work the plugin must identify the thigh bone correctly. If there is no matching json file, it tries to identify the rig automatically using the bone hierarchy, but that can go wrong. E.g., automatic identification of a genesis rig fails because it mistakes the pectorals for the collar bones.

    Anyway, the plugin now fails more gracefully if it doesn’t find a thigh bone.

  3. Log in to comment