Class AFKMC2.Instance
- java.lang.Object
-
- elki.clustering.kmeans.initialization.KMC2.Instance
-
- elki.clustering.kmeans.initialization.AFKMC2.Instance
-
- Direct Known Subclasses:
SphericalAFKMC2.Instance
- Enclosing class:
- AFKMC2
protected static class AFKMC2.Instance extends KMC2.Instance
Abstract instance implementing the weight handling.- Author:
- Erich Schubert
-
-
Constructor Summary
Constructors Constructor Description Instance(Relation<? extends NumberVector> relation, NumberVectorDistance<?> distance, int m, RandomFactory rnd)
Constructor.
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description protected Logging
getLogger()
Class logger.protected DBIDRef
sample(double weightsum)
Weighted sampling.-
Methods inherited from class elki.clustering.kmeans.initialization.KMC2.Instance
chooseRemaining, distance, distance, initialWeights, run
-
-
-
-
Constructor Detail
-
Instance
public Instance(Relation<? extends NumberVector> relation, NumberVectorDistance<?> distance, int m, RandomFactory rnd)
Constructor.- Parameters:
relation
- Data relation to processdistance
- Distance functionm
- M parameterrnd
- Random generator
-
-
Method Detail
-
sample
protected DBIDRef sample(double weightsum)
Description copied from class:KMC2.Instance
Weighted sampling.- Overrides:
sample
in classKMC2.Instance
- Parameters:
weightsum
- Total weight sum.- Returns:
- Sampled object
-
getLogger
protected Logging getLogger()
Description copied from class:KMC2.Instance
Class logger.- Overrides:
getLogger
in classKMC2.Instance
- Returns:
- Logger
-
-