@Reference(authors="Erich Schubert, Arthur Zimek, Hans-Peter Kriegel", title="Fast and Scalable Outlier Detection with Approximate Nearest Neighbor Ensembles", booktitle="Proc. 20th Int. Conf. Database Systems for Advanced Applications (DASFAA 2015)", url="https://doi.org/10.1007/978-3-319-18123-3_2", bibkey="DBLP:conf/dasfaa/SchubertZK15") public class NaiveProjectedKNNPreprocessor<O extends NumberVector> extends java.lang.Object implements KNNIndex<O>
This serves as a comparison method in:
Erich Schubert, Arthur Zimek, Hans-Peter Kriegel
Fast and Scalable Outlier Detection with Approximate Nearest Neighbor
Ensembles
Proc. 20th Int. Conf. Database Systems for Advanced Applications
(DASFAA 2015)
| Modifier and Type | Class and Description |
|---|---|
static class |
NaiveProjectedKNNPreprocessor.Factory<V extends NumberVector>
Index factory class
|
protected class |
NaiveProjectedKNNPreprocessor.NaiveProjectedKNNQuery
KNN Query processor for naive projections.
|
| Modifier and Type | Field and Description |
|---|---|
private static Logging |
LOG
Class logger.
|
(package private) Mean |
mean
Mean number of distance computations.
|
(package private) WritableDataStore<int[]> |
positions
Curve position storage
|
(package private) RandomProjectionFamily |
proj
Random projection family to use.
|
(package private) java.util.List<ModifiableDoubleDBIDList> |
projected
Projected data.
|
(package private) int |
projections
Number of projections to use.
|
(package private) java.util.Random |
random
Random number generator.
|
protected Relation<O> |
relation
The representation we are bound to.
|
(package private) double |
window
Curve window size.
|
| Constructor and Description |
|---|
NaiveProjectedKNNPreprocessor(Relation<O> relation,
double window,
int projections,
RandomProjectionFamily proj,
java.util.Random random)
Constructor.
|
| Modifier and Type | Method and Description |
|---|---|
KNNQuery<O> |
getKNNQuery(DistanceQuery<O> distanceQuery,
java.lang.Object... hints)
Get a KNN query object for the given distance query and k.
|
java.lang.String |
getLongName()
A "pretty" name for the result, for use in titles, captions and menus.
|
java.lang.String |
getShortName()
A short name for the result, useful for file names.
|
void |
initialize()
Initialize the index.
|
void |
logStatistics()
Send statistics to the logger, if enabled.
|
protected void |
preprocess() |
static int[] |
randomPermutation(int[] out,
java.util.Random random)
Perform a random permutation of the array, in-place.
|
static int[] |
range(int start,
int end)
Initialize an integer value range.
|
protected final Relation<O extends NumberVector> relation
private static final Logging LOG
final double window
final int projections
WritableDataStore<int[]> positions
Mean mean
RandomProjectionFamily proj
java.util.Random random
java.util.List<ModifiableDoubleDBIDList> projected
public NaiveProjectedKNNPreprocessor(Relation<O> relation, double window, int projections, RandomProjectionFamily proj, java.util.Random random)
relation - Relation to index.window - Window multiplicator.projections - Number of projections to use.proj - Projection family to use.random - Random number generator.public void initialize()
Indexinitialize in interface Indexprotected void preprocess()
public static int[] range(int start,
int end)
start - Starting valueend - End value (exclusive)public static int[] randomPermutation(int[] out,
java.util.Random random)
out - Prefilled array to be modified.random - Random generator.public java.lang.String getLongName()
ResultgetLongName in interface Resultpublic java.lang.String getShortName()
ResultgetShortName in interface Resultpublic void logStatistics()
IndexlogStatistics in interface Indexpublic KNNQuery<O> getKNNQuery(DistanceQuery<O> distanceQuery, java.lang.Object... hints)
KNNIndexgetKNNQuery in interface KNNIndex<O extends NumberVector>distanceQuery - Distance queryhints - Hints for the optimizernullCopyright © 2019 ELKI Development Team. License information.