Class SphericalAFKMC2
- java.lang.Object
-
- elki.clustering.kmeans.initialization.AbstractKMeansInitialization
-
- elki.clustering.kmeans.initialization.KMC2
-
- elki.clustering.kmeans.initialization.AFKMC2
-
- elki.clustering.kmeans.initialization.SphericalAFKMC2
-
- All Implemented Interfaces:
KMeansInitialization
@Title("Spherical AFK-MC\u00b2") @Reference(authors="R. Pratap, A. A. Deshmukh, P. Nair, T. Dutt", title="A Faster Sampling Algorithm for Spherical k-means", booktitle="Proc. 10th Asian Conference on Machine Learning, ACML", url="http://proceedings.mlr.press/v95/pratap18a.html", bibkey="DBLP:conf/acml/PratapDND18") public class SphericalAFKMC2 extends AFKMC2
Spherical K-Means++ initialization with markov chains.FIXME: currently assumes the vectors to be L2 normalized beforehand, but does not ensure that this is true.
Reference:
R. Pratap, A. A. Deshmukh, P. Nair, T. Dutt
A Faster Sampling Algorithm for Spherical k-means
Proc. 10th Asian Conference on Machine Learning, ACML- Since:
- 0.8.0
- Author:
- Erich Schubert
-
-
Nested Class Summary
Nested Classes Modifier and Type Class Description protected static class
SphericalAFKMC2.Instance
Abstract instance implementing the weight handling.static class
SphericalAFKMC2.Par
Parameterization class.
-
Field Summary
Fields Modifier and Type Field Description protected double
alpha
Parameter to balance distance vs. uniform sampling.private static Logging
LOG
Class logger.-
Fields inherited from class elki.clustering.kmeans.initialization.AbstractKMeansInitialization
rnd
-
-
Constructor Summary
Constructors Constructor Description SphericalAFKMC2(int m, double alpha, RandomFactory rnd)
Constructor.
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description double[][]
chooseInitialMeans(Relation<? extends NumberVector> relation, int k, NumberVectorDistance<?> distance)
Choose initial means-
Methods inherited from class elki.clustering.kmeans.initialization.AbstractKMeansInitialization
unboxVectors
-
-
-
-
Field Detail
-
LOG
private static final Logging LOG
Class logger.
-
alpha
protected double alpha
Parameter to balance distance vs. uniform sampling.
-
-
Constructor Detail
-
SphericalAFKMC2
public SphericalAFKMC2(int m, double alpha, RandomFactory rnd)
Constructor.- Parameters:
m
- M parameteralpha
- alpha-SKM parameter, usually 1.5rnd
- Random generator.
-
-
Method Detail
-
chooseInitialMeans
public double[][] chooseInitialMeans(Relation<? extends NumberVector> relation, int k, NumberVectorDistance<?> distance)
Description copied from interface:KMeansInitialization
Choose initial means- Specified by:
chooseInitialMeans
in interfaceKMeansInitialization
- Overrides:
chooseInitialMeans
in classAFKMC2
- Parameters:
relation
- Relationk
- Parameter kdistance
- Distance function- Returns:
- List of chosen means for k-means
-
-