3D detection pipeline filtering
Open
@maciejmajek is already working on this.
Since Sep 2, 2025.
enhancement
- Dominant language
- Python
- Stars
- 589
- Forks
- 76
- Avg merge
- 1d 13h
- Merged PRs (30d)
- 3
Description
Is your feature request related to a problem? Please describe.
3D detection pipeline need filtering
Describe the solution you'd like
Filtering algo, example below
def _filter_outliers_statistical(points_array: np.ndarray, k: int = 20, std_ratio: float = 2.0) -> np.ndarray:
if points_array.shape[0] == 0:
return points_array
k_eff = min(max(2, k), points_array.shape[0])
nn = NearestNeighbors(n_neighbors=k_eff, algorithm="auto")
nn.fit(points_array)
distances, _ = nn.kneighbors(points_array)
# exclude the zero-distance to self by dropping the first column when possible
if distances.shape[1] > 1:
mean_neighbor_distance = distances[:, 1:].mean(axis=1)
else:
mean_neighbor_distance = distances.mean(axis=1)
threshold = mean_neighbor_distance.mean() + std_ratio * mean_neighbor_distance.std()
inlier_mask = mean_neighbor_distance <= threshold
return points_array[inlier_mask]
Describe alternatives you've considered
None
Contributor guide
First steps
- Read the whole issue, then the project's contributing guide.
- Comment on the issue to say you are picking it up — it saves two people doing the same work.
- Fork the repository and make your change on a branch.
- Open a pull request that references the issue number.
Assessment
This issue has not been assessed yet.