1 write to Centroids
Microsoft.ML.KMeansClustering (1)
KMeansPlusPlusTrainer.cs (1)
1059
Centroids
= new VBuffer<float>[k];
10 references to Centroids
Microsoft.ML.KMeansClustering (10)
KMeansPlusPlusTrainer.cs (10)
1061
Centroids
[j] = VBufferUtils.CreateDense<float>(dimensionality);
1079
VBufferUtils.Clear(ref
Centroids
[i]);
1135
VectorUtils.Add(in features, ref
Centroids
[cluster]);
1165
VectorUtils.Add(in workChunkArr[i].
Centroids
[j], ref reducedState.
Centroids
[j]);
1211
VectorUtils.Add(in CachedSum[i], ref
Centroids
[i]);
1214
VectorUtils.ScaleBy(ref
Centroids
[i], (float)(1.0 / ClusterSizes[i]));
1218
float clusterDelta = MathUtils.Sqrt(VectorUtils.L2DistSquared(in
Centroids
[i], in centroids[i]));
1225
centroidL2s[i] = VectorUtils.NormSquared(
Centroids
[i]);
1229
Utils.Swap(ref centroids[i], ref
Centroids
[i]);