MCPcopy Create free account
hub / github.com/NodeDB-Lab/nodedb / split_internal_children

Function split_internal_children

nodedb-spatial/src/rtree/split.rs:105–114  ·  view source on GitHub ↗
(mut children: Vec<ChildRef>)

Source from the content-addressed store, hash-verified

103}
104
105fn split_internal_children(mut children: Vec<ChildRef>) -> (Vec<ChildRef>, Vec<ChildRef>) {
106 let min_fill = MIN_FILL_INTERNAL;
107 let best_axis = choose_best_axis_internal(&mut children, min_fill);
108
109 sort_children_by_axis(&mut children, best_axis);
110 let best_k = choose_best_split_internal(&children, min_fill);
111
112 let split_off = children.split_off(best_k);
113 (children, split_off)
114}
115
116fn choose_best_axis_leaf(entries: &mut [RTreeEntry], min_fill: usize) -> usize {
117 let mut best_axis = 0;

Callers 1

split_nodeFunction · 0.85

Calls 3

sort_children_by_axisFunction · 0.85

Tested by

no test coverage detected