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

Function make_tree

nodedb-spatial/src/hybrid.rs:139–149  ·  view source on GitHub ↗
()

Source from the content-addressed store, hash-verified

137 use crate::rtree::RTreeEntry;
138
139 fn make_tree() -> RTree {
140 let mut tree = RTree::new();
141 // 10 points in a grid from (0,0) to (9,9).
142 for i in 0..10 {
143 tree.insert(RTreeEntry {
144 id: i,
145 bbox: BoundingBox::from_point(i as f64, i as f64),
146 });
147 }
148 tree
149 }
150
151 #[test]
152 fn prefilter_with_distance() {

Callers 2

prefilter_with_distanceFunction · 0.85

Calls 1

insertMethod · 0.45

Tested by 2

prefilter_with_distanceFunction · 0.68