bartz.grove.traverse_tree¶
- bartz.grove.traverse_tree(x, var_tree, split_tree)[source]¶
Find the leaf where a point falls into.
- Parameters:
x (
UInt[Array, 'p']) – The coordinates to evaluate the tree at.var_tree (
UInt[Array, 'half_tree_size']) – The decision axes of the tree.split_tree (
UInt[Array, 'half_tree_size']) – The decision boundaries of the tree.
- Returns:
UInt[Array, '']– The index of the leaf.