public class FLAME extends ClustererBase implements Parameterized
Constructor and Description |
---|
FLAME(DistanceMetric dm,
int k,
int maxIterations)
Creates a new FLAME clustering object
|
FLAME(FLAME toCopy)
Copy constructor
|
Modifier and Type | Method and Description |
---|---|
FLAME |
clone() |
int[] |
cluster(DataSet dataSet,
ExecutorService threadpool,
int[] designations)
Performs clustering on the given data set.
|
int[] |
cluster(DataSet dataSet,
int[] designations)
Performs clustering on the given data set.
|
DistanceMetric |
getDistanceMetric()
Returns the distance metric to use for the nearest neighbor search
|
double |
getEps()
Returns the minimum difference in scores to consider FLAME converged
|
int |
getK()
Returns the number of neighbors used
|
int |
getMaxIterations()
Returns the maximum number of iterations to perform
|
Parameter |
getParameter(String paramName)
Returns the parameter with the given name.
|
List<Parameter> |
getParameters()
Returns the list of parameters that can be altered for this learner.
|
double |
getStndDevs()
Returns the number of standard deviations away from the mean
density an outlier must be
|
void |
setDistanceMetric(DistanceMetric dm)
Sets the distance metric to use for the nearest neighbor search
|
void |
setEps(double eps)
Sets the convergence goal for the minimum difference in score between
rounds.
|
void |
setK(int k)
Sets the number of neighbors that will be considered in determining
Cluster Supporting Points and assignment contributions.
|
void |
setMaxIterations(int maxIterations)
Sets the maximum number of iterations to perform.
|
void |
setStndDevs(double stndDevs)
Sets the number of standard deviations away from the mean density a
candidate outlier must be to be confirmed as an outlier.
|
void |
setVectorCollectionFactory(VectorCollectionFactory<VecPaired<Vec,Integer>> vectorCollectionFactory)
Sets the vector collection factory used to accelerate the nearest
neighbor search.
|
cluster, cluster, createClusterListFromAssignmentArray, getDatapointsFromCluster, supportsWeightedData
public FLAME(DistanceMetric dm, int k, int maxIterations)
dm
- the distance metric to usek
- the number of neighbors to considermaxIterations
- the maximum number of iterations to performpublic FLAME(FLAME toCopy)
toCopy
- the object to copypublic void setMaxIterations(int maxIterations)
maxIterations
- the maximum number of iterations to performpublic int getMaxIterations()
public void setK(int k)
k
- the number of neighbors to considerpublic int getK()
public void setEps(double eps)
eps
- the minimum difference in scores for convergencepublic double getEps()
public void setStndDevs(double stndDevs)
stndDevs
- the number of standard deviations away from the mean
density an outlier must bepublic double getStndDevs()
public void setDistanceMetric(DistanceMetric dm)
dm
- the distance metric to usepublic DistanceMetric getDistanceMetric()
public void setVectorCollectionFactory(VectorCollectionFactory<VecPaired<Vec,Integer>> vectorCollectionFactory)
vectorCollectionFactory
- public int[] cluster(DataSet dataSet, int[] designations)
Clusterer
cluster
in interface Clusterer
dataSet
- the data set to perform clustering ondesignations
- the array which will contain the designated values. The array will be altered and returned by
the function. If null is given, a new array will be created and returned.public int[] cluster(DataSet dataSet, ExecutorService threadpool, int[] designations)
Clusterer
cluster
in interface Clusterer
dataSet
- the data set to perform clustering onthreadpool
- a source of threads to run tasksdesignations
- the array which will contain the designated values. The array will be altered and returned by
the function. If null is given, a new array will be created and returned.public FLAME clone()
clone
in interface Clusterer
clone
in class ClustererBase
public List<Parameter> getParameters()
Parameterized
getParameters
in interface Parameterized
public Parameter getParameter(String paramName)
Parameterized
getParameter
in interface Parameterized
paramName
- the name of the parameter to obtainCopyright © 2017. All rights reserved.