Repository navigation
Conversation
Signed-off-by: Emre K <110906681+kocaemre@users.noreply.github.com>
|
Thanks a lot for this, @kocaemre! Comparing the kd-tree nearest neighbor against a brute-force search is exactly the kind of output check #103 asks for, the inputs are small and deterministic, and including a point exactly on the radius boundary (r=1.0) is a nice touch — it pins down that the search is inclusive. A few requests before merging:
Minor: a one-line comment on why Thanks again! |
|
Hi @kocaemre, just checking in: are you still working on this? These tests matter even more now: #204 found that the kd-tree search visits every node instead of skipping subtrees, and your brute-force comparison would be the safety net for fixing it. If there's no update by November 28, I'll close this PR for now. It isn't a rejection: you're welcome to reopen it anytime. |
Summary
Verification
python - <<'PY' ...guard failed before the patch withmissing output regression tests: test_nearest_neighbor_matches_brute_force, test_radius_search_returns_only_points_within_radius.venv/bin/python -m pytest test/test_search_nearest_neighbor_kd_tree.py -q→ 3 passed.venv/bin/python -m pytest test/test_search_nearest_neighbor_kd_tree.py test/test_search_neighbor_points_kd_tree.py -q→ 4 passed.venv/bin/python -m py_compile test/test_search_nearest_neighbor_kd_tree.py src/components/search/kd_tree/kd_tree.py src/components/sensors/lidar/scan_point.pygit diff --checkNo user-visible change: this adds regression coverage only.
Closes #103 for the kd-tree component slice.