src/bvhtoolbox/convert/csv2bvh.py
def _update_channels(nodes, root_pos_channels, rot_channels):
    """ Add information about channels in root position and joint rotations to nodes.
    
    :param nodes: Dictionary with skeleton hierarchy to update.
    :param root_pos_channels: Which position channels the root has.
    :type root_pos_channels: list
    :param rot_channels: Dictionary with mapping of joint name to list of its rotation channels.
    :type rot_channels: dict
    """
    for node, properties in nodes.items():
        # End sites do not have any channels.
        if not properties['children']:
            continue
        if not properties['parent']:
            properties['channels'] = root_pos_channels + rot_channels[node]
        else:
            properties['channels'] = rot_channels[node]
 Add information about channels in root position and joint rotations to nodes.
    
    :param nodes: Dictionary with skeleton hierarchy to update.
    :param root_pos_channels: Which position channels the root has.
    :type root_pos_channels: list
    :param rot_channels: Dictionary with mapping of joint name to list of its rotation channels.
    :type rot_channels: dict
    
Add information about channels in root position and joint rotations to nodes.
Add information about channels in root position and joint rotations to nodes .
def _update_channels(nodes, root_pos_channels, rot_channels):
    for node, properties in nodes.items():
        if not properties['children']:
            continue
        if not properties['parent']:
            properties['channels'] = root_pos_channels + rot_channels[node]
        else:
            properties['channels'] = rot_channels[node]
def _update_channels ( nodes , root_pos_channels , rot_channels ) : for node , properties in nodes . items ( ) : if not properties [ 'children' ] : continue if not properties [ 'parent' ] : properties [ 'channels' ] = root_pos_channels + rot_channels [ node ] else : properties [ 'channels' ] = rot_channels [ node ]
Add information about channels in root position and joint rotations to nodes.
Add information about channels in root position and joint rotations to nodes .
""" Add information about channels in root position and joint rotations to nodes.
    
    :param nodes: Dictionary with skeleton hierarchy to update.
    :param root_pos_channels: Which position channels the root has.
    :type root_pos_channels: list
    :param rot_channels: Dictionary with mapping of joint name to list of its rotation channels.
    :type rot_channels: dict
    """ # End sites do not have any channels.
nodes
Dictionary with skeleton hierarchy to update.
Dictionary with skeleton hierarchy to update .
root_pos_channels
Which position channels the root has.
Which position channels the root has .
rot_channels
Dictionary with mapping of joint name to list of its rotation channels.
Dictionary with mapping of joint name to list of its rotation channels .