O
- the type of data objects handled by this algorithm@Reference(authors="T. Hu, S. Y. Sung", title="Detecting pattern-based outliers", booktitle="Pattern Recognition Letters 24(16)", url="https://doi.org/10.1016/S0167-8655(03)00165-X", bibkey="DBLP:journals/prl/HuS03") public class VarianceOfVolume<O extends SpatialComparable> extends AbstractDistanceBasedAlgorithm<O,OutlierResult> implements OutlierAlgorithm
The volume is estimated by the distance to the k-nearest neighbor, then the variance of volume is computed.
Unfortunately, this approach needs an enormous numerical precision, and may not work for high-dimensional, non-normalized data. We therefore divide each volume by the average across the data set. This means values are even less comparable across data sets, but this avoids some of the numerical problems of this method.
Reference:
T. Hu, S. Y. Sung
Detecting pattern-based outliers
Pattern Recognition Letters 24(16)
Modifier and Type | Class and Description |
---|---|
static class |
VarianceOfVolume.Parameterizer<O extends SpatialComparable>
Parameterization class.
|
Modifier and Type | Field and Description |
---|---|
protected int |
k
The number of neighbors to query (including the query point!)
|
private static Logging |
LOG
The logger for this class.
|
ALGORITHM_ID
DISTANCE_FUNCTION_ID
Constructor and Description |
---|
VarianceOfVolume(int k,
DistanceFunction<? super O> distanceFunction)
Constructor.
|
Modifier and Type | Method and Description |
---|---|
private void |
computeVolumes(KNNQuery<O> knnq,
int dim,
DBIDs ids,
WritableDoubleDataStore vols)
Compute volumes
|
private void |
computeVOVs(KNNQuery<O> knnq,
DBIDs ids,
DoubleDataStore vols,
WritableDoubleDataStore vovs,
DoubleMinMax vovminmax)
Compute variance of volumes.
|
TypeInformation[] |
getInputTypeRestriction()
Get the input type restriction used for negotiating the data query.
|
protected Logging |
getLogger()
Get the (STATIC) logger for this class.
|
OutlierResult |
run(Database database,
Relation<O> relation)
Runs the VOV algorithm on the given database.
|
getDistanceFunction
run
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
run
private static final Logging LOG
protected int k
public VarianceOfVolume(int k, DistanceFunction<? super O> distanceFunction)
k
- the number of neighbors to use for comparison (excluding the query
point)distanceFunction
- the neighborhood distance functionpublic OutlierResult run(Database database, Relation<O> relation)
database
- Database to queryrelation
- Data to processprivate void computeVolumes(KNNQuery<O> knnq, int dim, DBIDs ids, WritableDoubleDataStore vols)
knnq
- KNN querydim
- Data dimensionalityids
- IDs to processvols
- Volume storageprivate void computeVOVs(KNNQuery<O> knnq, DBIDs ids, DoubleDataStore vols, WritableDoubleDataStore vovs, DoubleMinMax vovminmax)
knnq
- KNN queryids
- IDs to processvols
- Volumesvovs
- Variance of Volume storagevovminmax
- Score minimum/maximum trackerpublic TypeInformation[] getInputTypeRestriction()
AbstractAlgorithm
getInputTypeRestriction
in interface Algorithm
getInputTypeRestriction
in class AbstractAlgorithm<OutlierResult>
protected Logging getLogger()
AbstractAlgorithm
getLogger
in class AbstractAlgorithm<OutlierResult>
Copyright © 2019 ELKI Development Team. License information.