No need for ¢roid, &distance
This commit is contained in:
parent
77ea216075
commit
a9ccb379c6
|
@ -103,7 +103,7 @@ fn main() {
|
|||
"green",
|
||||
];
|
||||
|
||||
let (kmeans, nb_iterations) = kmeans(elements, initial, &distance, ¢roid, 1000).unwrap();
|
||||
let (kmeans, nb_iterations) = kmeans(elements, initial, distance, centroid, 1000).unwrap();
|
||||
let kmeans = kmeans.into_iter();
|
||||
|
||||
println!("Converged in {} iterations.", nb_iterations);
|
||||
|
|
Loading…
Reference in New Issue