Skip to main content

knn_between

Function knn_between 

Source
pub fn knn_between(
    targets: &[[f32; 3]],
    queries: &[[f32; 3]],
    k: usize,
    options: KnnOptions,
    backend: SpatialBackend,
    periodic: Option<&PeriodicBox>,
    context: &ExecutionContext,
) -> Result<KnnResult, SpatialError>
Expand description

Finds the k nearest targets of every point of queries.

Rows follow queries; neighbour indices refer to targets. Semantics otherwise match knn_within.

ยงErrors

Returns an error when the combined point count exceeds a 32-bit index, or for any reason knn_within does.