|
|
|||||||||||||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||||||||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Objectde.lmu.ifi.dbs.elki.logging.AbstractLoggable
de.lmu.ifi.dbs.elki.utilities.optionhandling.AbstractParameterizable
de.lmu.ifi.dbs.elki.algorithm.AbstractAlgorithm<O,R>
de.lmu.ifi.dbs.elki.algorithm.DistanceBasedAlgorithm<V,DoubleDistance,MultiResult>
de.lmu.ifi.dbs.elki.algorithm.outlier.ABOD<V>
V
- Vector typepublic class ABOD<V extends RealVector<V,?>>
Angle-Based Outlier Detection Outlier detection using variance analysis on angles, especially for high dimensional data sets. H.-P. Kriegel, M. Schubert, and A. Zimek: Angle-Based Outlier Detection in High-dimensional Data. In: Proc. 14th ACM SIGKDD Int. Conf. on Knowledge Discovery and Data Mining (KDD '08), Las Vegas, NV, 2008.
Field Summary | |
---|---|
static AssociationID<Double> |
ABOD_NORM
Association ID for ABOD Normalization value. |
static AssociationID<Double> |
ABOD_SCORE
Association ID for ABOD. |
(package private) boolean |
fast
Variable to store fast mode flag. |
private Flag |
FAST_FLAG
Flag for fast mode. |
static OptionID |
FAST_ID
OptionID for FAST_FLAG |
static OptionID |
FAST_SAMPLE_ID
OptionID for FAST_SAMPLE_PARAM |
private IntParameter |
FAST_SAMPLE_PARAM
Parameter for sample size to be used in fast mode. |
private int |
k
k parameter |
static OptionID |
K_ID
OptionID for K_PARAM |
private IntParameter |
K_PARAM
Parameter for k, the number of neighbors used in kNN queries. |
static OptionID |
KERNEL_FUNCTION_ID
OptionID for KERNEL_FUNCTION_PARAM |
private ClassParameter<KernelFunction<V,DoubleDistance>> |
KERNEL_FUNCTION_PARAM
Parameter for Kernel function. |
(package private) KernelFunction<V,DoubleDistance> |
kernelFunction
Store the configured Kernel version |
(package private) MultiResult |
result
Result storage. |
(package private) int |
sampleSize
Variable to store fast mode flag. |
Fields inherited from class de.lmu.ifi.dbs.elki.algorithm.DistanceBasedAlgorithm |
---|
DISTANCE_FUNCTION_ID, DISTANCE_FUNCTION_PARAM |
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, logger |
Constructor Summary | |
---|---|
ABOD()
Constructor |
Method Summary | |
---|---|
private double |
calcCos(KernelMatrix<V> kernelMatrix,
Integer aKey,
Integer bKey)
Compute the cosinus value between vectors aKey and bKey. |
private double |
calcDenominator(KernelMatrix<V> kernelMatrix,
Integer aKey,
Integer bKey,
Integer cKey)
|
private PriorityQueue<FCPair<Double,Integer>> |
calcDistsandNN(Database<V> data,
KernelMatrix<V> kernelMatrix,
int sampleSize,
Integer aKey,
HashMap<Integer,Double> dists)
|
private PriorityQueue<FCPair<Double,Integer>> |
calcDistsandRNDSample(Database<V> data,
KernelMatrix<V> kernelMatrix,
int sampleSize,
Integer aKey,
HashMap<Integer,Double> dists)
|
private double[] |
calcFastNormalization(Integer x,
HashMap<Integer,Double> dists)
|
private double[] |
calcNormalization(Integer xKey,
HashMap<Integer,Double> dists)
|
private double |
calcNumerator(KernelMatrix<V> kernelMatrix,
Integer aKey,
Integer bKey,
Integer cKey)
|
private void |
generateExplanation(Database<V> data,
Integer key,
LinkedList<Integer> expList)
|
private double |
getAbofFilter(KernelMatrix<V> kernelMatrix,
Integer aKey,
HashMap<Integer,Double> dists,
double fulCounter,
double counter,
List<Integer> neighbors)
|
Description |
getDescription()
Return a description of the algorithm. |
void |
getExplanations(Database<V> data)
|
MultiResult |
getFastRanking(Database<V> database,
int k,
int sampleSize)
Main part of the algorithm. |
MultiResult |
getRanking(Database<V> database,
int k)
Main part of the algorithm. |
MultiResult |
getResult()
Return the results of the last run. |
protected MultiResult |
runInTime(Database<V> database)
The run method encapsulated in measure of runtime. |
List<String> |
setParameters(List<String> args)
Calls the super method and sets parameters FAST_FLAG ,
FAST_SAMPLE_PARAM and KERNEL_FUNCTION_PARAM . |
Methods inherited from class de.lmu.ifi.dbs.elki.algorithm.DistanceBasedAlgorithm |
---|
getDistanceFunction |
Methods inherited from class de.lmu.ifi.dbs.elki.algorithm.AbstractAlgorithm |
---|
isTime, isVerbose, run, setTime, setVerbose |
Methods inherited from class de.lmu.ifi.dbs.elki.utilities.optionhandling.AbstractParameterizable |
---|
addOption, addParameterizable, addParameterizable, checkGlobalParameterConstraints, collectOptions, getAttributeSettings, getParameters, rememberParametersExcept, removeOption, removeParameterizable, shortDescription |
Methods inherited from class de.lmu.ifi.dbs.elki.logging.AbstractLoggable |
---|
debugFine, debugFiner, debugFinest, exception, progress, 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.utilities.optionhandling.Parameterizable |
---|
checkGlobalParameterConstraints, collectOptions, getParameters, shortDescription |
Field Detail |
---|
public static final OptionID K_ID
K_PARAM
private final IntParameter K_PARAM
Key: -abod.k
Default value: 30
private int k
public static final OptionID FAST_ID
FAST_FLAG
private final Flag FAST_FLAG
Key: -abod.fast
boolean fast
public static final OptionID FAST_SAMPLE_ID
FAST_SAMPLE_PARAM
private final IntParameter FAST_SAMPLE_PARAM
Key: -abod.samplesize
int sampleSize
public static final OptionID KERNEL_FUNCTION_ID
KERNEL_FUNCTION_PARAM
private final ClassParameter<KernelFunction<V extends RealVector<V,?>,DoubleDistance>> KERNEL_FUNCTION_PARAM
Key: -abod.kernelfunction
Default: PolynomialKernelFunction
public static final AssociationID<Double> ABOD_SCORE
public static final AssociationID<Double> ABOD_NORM
KernelFunction<V extends RealVector<V,?>,DoubleDistance> kernelFunction
MultiResult result
Constructor Detail |
---|
public ABOD()
Method Detail |
---|
public MultiResult getRanking(Database<V> database, int k)
database
- Database to usek
- k for kNN queries
public MultiResult getFastRanking(Database<V> database, int k, int sampleSize)
database
- Database to usek
- k for kNN queriessampleSize
- Sample size
private double[] calcNormalization(Integer xKey, HashMap<Integer,Double> dists)
private double[] calcFastNormalization(Integer x, HashMap<Integer,Double> dists)
private double getAbofFilter(KernelMatrix<V> kernelMatrix, Integer aKey, HashMap<Integer,Double> dists, double fulCounter, double counter, List<Integer> neighbors)
private double calcCos(KernelMatrix<V> kernelMatrix, Integer aKey, Integer bKey)
kernelMatrix
- aKey
- bKey
-
private double calcDenominator(KernelMatrix<V> kernelMatrix, Integer aKey, Integer bKey, Integer cKey)
private double calcNumerator(KernelMatrix<V> kernelMatrix, Integer aKey, Integer bKey, Integer cKey)
private PriorityQueue<FCPair<Double,Integer>> calcDistsandNN(Database<V> data, KernelMatrix<V> kernelMatrix, int sampleSize, Integer aKey, HashMap<Integer,Double> dists)
private PriorityQueue<FCPair<Double,Integer>> calcDistsandRNDSample(Database<V> data, KernelMatrix<V> kernelMatrix, int sampleSize, Integer aKey, HashMap<Integer,Double> dists)
public void getExplanations(Database<V> data)
data
- private void generateExplanation(Database<V> data, Integer key, LinkedList<Integer> expList)
protected MultiResult runInTime(Database<V> database) throws IllegalStateException
AbstractAlgorithm
runInTime
in class AbstractAlgorithm<V extends RealVector<V,?>,MultiResult>
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 Description getDescription()
public MultiResult getResult()
public List<String> setParameters(List<String> args) throws ParameterException
FAST_FLAG
,
FAST_SAMPLE_PARAM
and KERNEL_FUNCTION_PARAM
. The
remaining parameters are then passed to the kernelFunction
.
setParameters
in interface Parameterizable
setParameters
in class DistanceBasedAlgorithm<V extends RealVector<V,?>,DoubleDistance,MultiResult>
args
- parameters to set the attributes accordingly to
ParameterException
- in case of wrong parameter-setting
|
|
|||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |