public class KernelBasedKMeansEngine extends Object implements ClusteringAlgorithm
| Constructor and Description |
|---|
KernelBasedKMeansEngine() |
KernelBasedKMeansEngine(Kernel kernel,
int k,
int maxIterations) |
| Modifier and Type | Method and Description |
|---|---|
float |
calculateDistance(Example example,
Cluster cluster)
Estimate the distance of an example from the centroid
|
void |
checkConsistency(int K,
int inputSize) |
ClusterList |
cluster(Dataset dataset)
It starts the clustering process exploiting the provided
dataset |
ClusterList |
cluster(Dataset dataset,
ExampleSelector seedSelector)
It starts the clustering process exploiting the provided
dataset |
float |
evaluateKernel(Example e1,
Example e2) |
int |
getK() |
Kernel |
getKernel() |
int |
getMaxIterations() |
void |
setK(int k) |
void |
setKernel(Kernel kernel) |
void |
setMaxIterations(int maxIterations) |
public KernelBasedKMeansEngine()
public KernelBasedKMeansEngine(Kernel kernel, int k, int maxIterations)
kernel - The kernel functionk - The number of expected clustersmaxIterations - The maximum number of iterationspublic float calculateDistance(Example example, Cluster cluster)
example - An examplecluster - A clusterpublic void checkConsistency(int K,
int inputSize)
throws Exception
Exceptionpublic ClusterList cluster(Dataset dataset)
ClusteringAlgorithmdatasetcluster in interface ClusteringAlgorithmpublic ClusterList cluster(Dataset dataset, ExampleSelector seedSelector)
ClusteringAlgorithmdatasetcluster in interface ClusteringAlgorithmseedSelector - the seed selectorpublic int getK()
public Kernel getKernel()
public int getMaxIterations()
public void setK(int k)
public void setKernel(Kernel kernel)
public void setMaxIterations(int maxIterations)
Copyright © 2018 Semantic Analytics Group @ Uniroma2. All rights reserved.