|
|
|||||||||||||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||||||||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Object de.lmu.ifi.dbs.elki.logging.AbstractLoggable de.lmu.ifi.dbs.elki.utilities.optionhandling.AbstractParameterizable de.lmu.ifi.dbs.elki.algorithm.AbstractAlgorithm<V> de.lmu.ifi.dbs.elki.algorithm.clustering.subspace.CLIQUE<V>
V
- the type of RealVector handled by this Algorithmpublic class CLIQUE<V extends RealVector<V,?>>
Implementation of the CLIQUE algorithm, a grid-based algorithm to identify dense clusters in subspaces of maximum dimensionality.
The implementation consists of two steps:br> 1. Identification of subspaces that contain clusters
The third step of the original algorithm (Generation of minimal description for the clusters) is not (yet) implemented.
Field Summary | |
---|---|
private boolean |
prune
Flag indicating that subspaces with low coverage are pruned. |
private Flag |
PRUNE_FLAG
Flag to indicate that that only subspaces with large coverage (i.e. the fraction of the database that is covered by the dense units) are selected, the rest will be pruned. |
private Clusters<V> |
result
The result of the algorithm; |
private double |
tau
Threshold for the selectivity of a unit. |
private DoubleParameter |
TAU_PARAM
Parameter to specify the density threshold for the selectivity of a unit, where the selectivity is the fraction of total feature vectors contained in this unit, must be a double greater than 0 and less than 1. |
private int |
xsi
Number of units in each dimension. |
private IntParameter |
XSI_PARAM
Parameter to specify the number of intervals (units) in each dimension, must be an integer greater than 0. |
Fields inherited from class de.lmu.ifi.dbs.elki.utilities.optionhandling.AbstractParameterizable |
---|
optionHandler |
Fields inherited from class de.lmu.ifi.dbs.elki.logging.AbstractLoggable |
---|
debug |
Constructor Summary | |
---|---|
CLIQUE()
|
Method Summary | |
---|---|
private double[][] |
computeDiffs(SortedSet<CLIQUESubspace<V>> denseSubspaces,
int[] mi,
int[] mp)
The specified sorted set of dense subspaces is divided into the selected set I and the pruned set P. |
private int[][] |
computeMeans(SortedSet<CLIQUESubspace<V>> denseSubspaces)
The specified sorted set of dense subspaces is divided into the selected set I and the pruned set P. |
private Map<CLIQUEModel<V>,Set<Integer>> |
determineClusters(Database<V> database,
SortedSet<CLIQUESubspace<V>> denseSubspaces)
Determines the clusters in the specified dense subspaces. |
private SortedSet<CLIQUESubspace<V>> |
findDenseSubspaceCandidates(Database<V> database,
Set<CLIQUESubspace<V>> denseSubspaces)
Determines the k-dimensional dense subspace candidates. |
private SortedSet<CLIQUESubspace<V>> |
findDenseSubspaces(Database<V> database,
SortedSet<CLIQUESubspace<V>> denseSubspaces)
Determines the k>1 dimensional dense subspaces and performs a pruning if this option is chosen. |
private SortedSet<CLIQUESubspace<V>> |
findOneDimensionalDenseSubspaceCandidates(Database<V> database)
Determines the one-dimensional dense subspace candidates by making a pass over the database. |
private SortedSet<CLIQUESubspace<V>> |
findOneDimensionalDenseSubspaces(Database<V> database)
Determines the one dimensional dense subspaces and performs a pruning if this option is chosen. |
Description |
getDescription()
Returns a description of the algorithm. |
ClusteringResult<V> |
getResult()
Returns the result of the algorithm. |
private Collection<CLIQUEUnit<V>> |
initOneDimensionalUnits(Database<V> database)
Initializes and returns the one dimensional units. |
private SortedSet<CLIQUESubspace<V>> |
pruneDenseSubspaces(SortedSet<CLIQUESubspace<V>> denseSubspaces)
Performs a MDL-based pruning of the specified dense sunspaces as described in the CLIQUE algorithm. |
protected void |
runInTime(Database<V> database)
Performs the CLIQUE algorithm on the given database. |
String[] |
setParameters(String[] args)
Sets the parameters xsi, tau and prune additionally to the parameters set by the super-class' method. |
private void |
updateMinMax(V featureVector,
double[] minima,
double[] maxima)
Updates the minima and maxima array according to the specified feature vector. |
Methods inherited from class de.lmu.ifi.dbs.elki.algorithm.AbstractAlgorithm |
---|
description, isTime, isVerbose, run, setTime, setVerbose |
Methods inherited from class de.lmu.ifi.dbs.elki.utilities.optionhandling.AbstractParameterizable |
---|
addOption, checkGlobalParameterConstraints, deleteOption, description, description, getAttributeSettings, getParameters, getParameterValue, getPossibleOptions, inlineDescription, isSet, setParameters |
Methods inherited from class de.lmu.ifi.dbs.elki.logging.AbstractLoggable |
---|
debugFine, debugFiner, debugFinest, exception, message, progress, progress, progress, verbose, verbose, warning |
Methods inherited from class java.lang.Object |
---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Methods inherited from interface de.lmu.ifi.dbs.elki.algorithm.Algorithm |
---|
run, setTime, setVerbose |
Methods inherited from interface de.lmu.ifi.dbs.elki.utilities.optionhandling.Parameterizable |
---|
checkGlobalParameterConstraints, description, getAttributeSettings, getParameters, getPossibleOptions, inlineDescription |
Field Detail |
---|
private final IntParameter XSI_PARAM
Key: -clique.xsi
private final DoubleParameter TAU_PARAM
Key: -clique.tau
private final Flag PRUNE_FLAG
Key: -clique.prune
private int xsi
private double tau
private boolean prune
private Clusters<V extends RealVector<V,?>> result
Constructor Detail |
---|
public CLIQUE()
Method Detail |
---|
public ClusteringResult<V> getResult()
getResult
in interface Algorithm<V extends RealVector<V,?>>
getResult
in interface Clustering<V extends RealVector<V,?>>
Algorithm.getResult()
public Description getDescription()
getDescription
in interface Algorithm<V extends RealVector<V,?>>
protected void runInTime(Database<V> database) throws IllegalStateException
runInTime
in class AbstractAlgorithm<V extends RealVector<V,?>>
database
- the database to run the algorithm on
IllegalStateException
- if the algorithm has not been initialized
properly (e.g. the setParameters(String[]) method has been failed
to be called).public String[] setParameters(String[] args) throws ParameterException
setParameters
in interface Parameterizable
setParameters
in class AbstractAlgorithm<V extends RealVector<V,?>>
args
- parameters to set the attributes accordingly to
ParameterException
- in case of wrong parameter-settingParameterizable.setParameters(String[])
private Map<CLIQUEModel<V>,Set<Integer>> determineClusters(Database<V> database, SortedSet<CLIQUESubspace<V>> denseSubspaces)
database
- the database to run the algorithm ondenseSubspaces
- the dense subspaces
private SortedSet<CLIQUESubspace<V>> findOneDimensionalDenseSubspaces(Database<V> database)
database
- the database to run the algorithm on
private SortedSet<CLIQUESubspace<V>> findDenseSubspaces(Database<V> database, SortedSet<CLIQUESubspace<V>> denseSubspaces)
database
- the database to run the algorithm ondenseSubspaces
- the (k-1)-dimensional dense subspaces
private Collection<CLIQUEUnit<V>> initOneDimensionalUnits(Database<V> database)
database
- the database to run the algorithm on
private void updateMinMax(V featureVector, double[] minima, double[] maxima)
featureVector
- the feature vectorminima
- the array of minimamaxima
- the array of maximaprivate SortedSet<CLIQUESubspace<V>> findOneDimensionalDenseSubspaceCandidates(Database<V> database)
database
- the database to run the algorithm on
private SortedSet<CLIQUESubspace<V>> findDenseSubspaceCandidates(Database<V> database, Set<CLIQUESubspace<V>> denseSubspaces)
database
- the database to run the algorithm ondenseSubspaces
- the (k-1)-dimensional dense subspace
private SortedSet<CLIQUESubspace<V>> pruneDenseSubspaces(SortedSet<CLIQUESubspace<V>> denseSubspaces)
denseSubspaces
- the subspaces to be pruned
private int[][] computeMeans(SortedSet<CLIQUESubspace<V>> denseSubspaces)
denseSubspaces
- the dense subspaces
private double[][] computeDiffs(SortedSet<CLIQUESubspace<V>> denseSubspaces, int[] mi, int[] mp)
denseSubspaces
- the dense subspacesmi
- the mean of the selected sets Imp
- the mean of the pruned sets P
|
|
||||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |