MCPcopy Create free account
hub / github.com/Raibows/MLinRust / new

Method new

src/model/knn.rs:99–107  ·  view source on GitHub ↗

k: k nearest neighbours weighting: weighting the neibours, default is these neighbours are equal features: \[batch, feature\] labels: \[batch\] total_dim: total dim of the feature p: the parameter p of [minkowski distance](https://en.wikipedia.org/wiki/Minkowski_distance) default is p = 2

(k: usize, weighting: Option<KNNWeighting>, features: Vec<Vec<f32>>, labels: Vec<T>, total_dim: usize, p: Option<usize>)

Source from the content-addressed store, hash-verified

source not stored for this graph (policy: none)

Callers

nothing calls this directly

Calls 2

into_iterMethod · 0.80
feature_lenMethod · 0.80

Tested by

no test coverage detected