Package elki.outlier.trivial
Class TrivialGeneratedOutlier
- java.lang.Object
-
- elki.outlier.trivial.TrivialGeneratedOutlier
-
- All Implemented Interfaces:
Algorithm
,OutlierAlgorithm
public class TrivialGeneratedOutlier extends java.lang.Object implements OutlierAlgorithm
Extract outlier score from the model the objects were generated by.This algorithm can only be applied to data that was freshly generated, to the generator model information is still available.
- Since:
- 0.5.0
- Author:
- Erich Schubert
-
-
Nested Class Summary
Nested Classes Modifier and Type Class Description static class
TrivialGeneratedOutlier.Par
Parameterization class.-
Nested classes/interfaces inherited from interface elki.Algorithm
Algorithm.Utils
-
-
Constructor Summary
Constructors Constructor Description TrivialGeneratedOutlier()
Constructor.TrivialGeneratedOutlier(double expect)
Constructor.
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description OutlierResult
autorun(Database database)
Try to auto-run the algorithm on a database by calling a method calledrun
, with an optionalDatabase
first, and with data relations as specified byAlgorithm.getInputTypeRestriction()
.TypeInformation[]
getInputTypeRestriction()
Get the input type restriction used for negotiating the data query.OutlierResult
run(Relation<Model> models, Relation<NumberVector> vecs, Relation<?> labels)
Run the algorithm
-
-
-
Field Detail
-
LOG
private static final Logging LOG
Class logger
-
expect
double expect
Expected share of outliers.
-
-
Method Detail
-
getInputTypeRestriction
public TypeInformation[] getInputTypeRestriction()
Description copied from interface:Algorithm
Get the input type restriction used for negotiating the data query.- Specified by:
getInputTypeRestriction
in interfaceAlgorithm
- Returns:
- Type restriction
-
autorun
public OutlierResult autorun(Database database)
Description copied from interface:Algorithm
Try to auto-run the algorithm on a database by calling a method calledrun
, with an optionalDatabase
first, and with data relations as specified byAlgorithm.getInputTypeRestriction()
.- Specified by:
autorun
in interfaceAlgorithm
- Specified by:
autorun
in interfaceOutlierAlgorithm
- Parameters:
database
- the database to run the algorithm on- Returns:
- the Result computed by this algorithm
-
run
public OutlierResult run(Relation<Model> models, Relation<NumberVector> vecs, Relation<?> labels)
Run the algorithm- Parameters:
models
- Model relationvecs
- Vector relationlabels
- Label relation- Returns:
- Outlier result
-
-