Skip to content

webknossos.skeleton.node

#   class Node:
#   Node( position: webknossos.geometry.vec3_int.Vec3Int, skeleton: webknossos.skeleton.skeleton.Skeleton, comment: Union[str, NoneType] = None, radius: Union[float, NoneType] = None, rotation: Union[Tuple[float, float, float], NoneType] = None, inVp: Union[int, NoneType] = None, inMag: Union[int, NoneType] = None, bitDepth: Union[int, NoneType] = None, interpolation: Union[bool, NoneType] = None, time: Union[int, NoneType] = None, is_branchpoint: bool = False, branchpoint_time: Union[int, NoneType] = None, enforced_id: Union[int, NoneType] = None )

To create a node, it is recommended to use Tree.add_node. That way, the newly created group is automatically attached as a child to the tree.

A small usage example:

tree = skeleton.add_tree("a tree")
node_1 = tree.add_node(position=(0, 0, 0), comment="node 1")
node_2 = tree.add_node(position=(100, 100, 100), comment="node 2")

tree.add_edge(node_1, node_2)
#   comment: Union[str, NoneType]
#   radius: Union[float, NoneType]
#   rotation: Union[Tuple[float, float, float], NoneType]
#   inVp: Union[int, NoneType]
#   inMag: Union[int, NoneType]
#   bitDepth: Union[int, NoneType]
#   interpolation: Union[bool, NoneType]
#   time: Union[int, NoneType]
#   is_branchpoint: bool
#   branchpoint_time: Union[int, NoneType]
#   id: int
Back to top