pub trait Distance<T>: Clone {
// Required method
fn distance(&self, a: &T, b: &T) -> f64;
}
Expand description
Distance metric, a function that calculates distance between two points
pub trait Distance<T>: Clone {
// Required method
fn distance(&self, a: &T, b: &T) -> f64;
}
Distance metric, a function that calculates distance between two points