pub trait NeighborhoodProvider {
// Required methods
fn query_k(
&self,
index: usize,
k: usize,
) -> Result<Vec<usize>, SpatialError>;
fn query_radius(
&self,
index: usize,
radius: f32,
) -> Result<Vec<usize>, SpatialError>;
}Expand description
Neighborhood query abstraction for feature estimation.
Required Methods§
Sourcefn query_k(&self, index: usize, k: usize) -> Result<Vec<usize>, SpatialError>
fn query_k(&self, index: usize, k: usize) -> Result<Vec<usize>, SpatialError>
Returns up to k neighbor indices excluding the query point itself.
Sourcefn query_radius(
&self,
index: usize,
radius: f32,
) -> Result<Vec<usize>, SpatialError>
fn query_radius( &self, index: usize, radius: f32, ) -> Result<Vec<usize>, SpatialError>
Returns all neighbor indices within radius, excluding the query point.