KDTree.build

KDTree.build(objects, axis=0)[source]

Populate a kd-tree with given objects.

Parameters:
objectssequence[tuple[[float, float, float] | compas.geometry.Point, int or str]]

The tree objects as a sequence of point-label tuples.

axisint, optional

The axis along which to build.

Returns:
Node or None

The root node, or None if the sequence of objects is empty.