Uses of Class
org.tribuo.anomaly.Event
Package
Description
Provides classes and infrastructure for anomaly detection problems.
Evaluation classes for anomaly detection.
Provides anomaly data generators used for demos and testing implementations.
Provides an interface to LibLinear-java for anomaly detection problems.
Provides an interface to LibSVM for anomaly detection problems.
-
Uses of Event in org.tribuo.anomaly
Modifier and TypeFieldDescriptionstatic final Event
AnomalyFactory.ANOMALOUS_EVENT
The anomalous event.static final Event
AnomalyFactory.EXPECTED_EVENT
The expected event.static final Event
AnomalyFactory.UNKNOWN_EVENT
The unknown event.Modifier and TypeMethodDescriptionEvent.copy()
<V> Event
AnomalyFactory.generateOutput
(V label) ImmutableAnomalyInfo.getOutput
(int id) AnomalyFactory.getUnknownOutput()
Modifier and TypeMethodDescriptionAnomalyFactory.constructInfoForExternalModel
(Map<Event, Integer> mapping) AnomalyInfo.generateImmutableOutputInfo()
AnomalyFactory.generateInfo()
AnomalyInfo.generateMutableOutputInfo()
AnomalyInfo.getDomain()
Returns the set of possibleEvent
s.AnomalyFactory.getEvaluator()
ImmutableAnomalyInfo.iterator()
Modifier and TypeMethodDescriptionAnomalyFactory.constructInfoForExternalModel
(Map<Event, Integer> mapping) boolean
ImmutableAnomalyInfo.domainAndIDEquals
(ImmutableOutputInfo<Event> other) -
Uses of Event in org.tribuo.anomaly.evaluation
Modifier and TypeMethodDescriptionprotected org.tribuo.anomaly.evaluation.AnomalyMetric.Context
AnomalyEvaluator.createContext
(Model<Event> model, List<Prediction<Event>> predictions) protected org.tribuo.anomaly.evaluation.AnomalyMetric.Context
AnomalyEvaluator.createContext
(Model<Event> model, List<Prediction<Event>> predictions) org.tribuo.anomaly.evaluation.AnomalyMetric.Context
AnomalyMetric.createContext
(Model<Event> model, List<Prediction<Event>> predictions) org.tribuo.anomaly.evaluation.AnomalyMetric.Context
AnomalyMetric.createContext
(Model<Event> model, List<Prediction<Event>> predictions) protected AnomalyEvaluation
AnomalyEvaluator.createEvaluation
(org.tribuo.anomaly.evaluation.AnomalyMetric.Context context, Map<MetricID<Event>, Double> results, EvaluationProvenance provenance) protected Set<AnomalyMetric>
AnomalyEvaluator.createMetrics
(Model<Event> model) ModifierConstructorDescriptionAnomalyMetric
(MetricTarget<Event> target, String name, ToDoubleBiFunction<MetricTarget<Event>, org.tribuo.anomaly.evaluation.AnomalyMetric.Context> impl) Creates an anomaly detection metric, with a specific name, using the supplied evaluation function.AnomalyMetric
(MetricTarget<Event> target, String name, ToDoubleBiFunction<MetricTarget<Event>, org.tribuo.anomaly.evaluation.AnomalyMetric.Context> impl) Creates an anomaly detection metric, with a specific name, using the supplied evaluation function. -
Uses of Event in org.tribuo.anomaly.example
Modifier and TypeMethodDescriptionAnomalyDataGenerator.denseTrainTest()
Makes a simple dataset for training and testing.AnomalyDataGenerator.denseTrainTest()
Makes a simple dataset for training and testing.AnomalyDataGenerator.denseTrainTest
(double negate) Generates a train/test dataset pair which is dense in the features, each example has 4 features,{A,B,C,D}, and there are 4 clusters, {0,1,2,3}.AnomalyDataGenerator.denseTrainTest
(double negate) Generates a train/test dataset pair which is dense in the features, each example has 4 features,{A,B,C,D}, and there are 4 clusters, {0,1,2,3}.AnomalyDataGenerator.emptyExample()
Generates an example with no features.AnomalyDataGenerator.gaussianAnomaly()
Generates two datasets, one without anomalies drawn from a single gaussian and the second drawn from a mixture of two gaussians, with the second tagged anomalous.AnomalyDataGenerator.gaussianAnomaly()
Generates two datasets, one without anomalies drawn from a single gaussian and the second drawn from a mixture of two gaussians, with the second tagged anomalous.AnomalyDataGenerator.gaussianAnomaly
(long size, double fractionAnomalous) Generates two datasets, one without anomalies drawn from a single gaussian and the second drawn from a mixture of two gaussians, with the second tagged anomalous.AnomalyDataGenerator.gaussianAnomaly
(long size, double fractionAnomalous) Generates two datasets, one without anomalies drawn from a single gaussian and the second drawn from a mixture of two gaussians, with the second tagged anomalous.static MutableDataset<Event>
GaussianAnomalyDataSource.generateDataset
(int numSamples, double[] expectedMeans, double[] expectedVariances, double[] anomalousMeans, double[] anomalousVariances, float fractionAnomalous, long seed) Generates an anomaly detection dataset sampling each feature uniformly from a univariate Gaussian.GaussianAnomalyDataSource.getOutputFactory()
AnomalyDataGenerator.invalidSparseExample()
Generates an example with the feature ids 1,5,8, which does not intersect with the ids used elsewhere in this class.GaussianAnomalyDataSource.iterator()
AnomalyDataGenerator.sparseTrainTest()
Makes a simple dataset for training and testing.AnomalyDataGenerator.sparseTrainTest()
Makes a simple dataset for training and testing.AnomalyDataGenerator.sparseTrainTest
(double negate) Generates a pair of datasets, where the features are sparse, and unknown features appear in the test data.AnomalyDataGenerator.sparseTrainTest
(double negate) Generates a pair of datasets, where the features are sparse, and unknown features appear in the test data. -
Uses of Event in org.tribuo.anomaly.liblinear
Modifier and TypeMethodDescriptionprotected LibLinearModel<Event>
LibLinearAnomalyTrainer.createModel
(ModelProvenance provenance, ImmutableFeatureMap featureIDMap, ImmutableOutputInfo<Event> outputIDInfo, List<de.bwaldvogel.liblinear.Model> models) LibLinearAnomalyModel.innerGetExcuse
(Example<Event> e, double[][] allFeatureWeights) The call to model.getFeatureWeights in the public methods copies the weights array so this inner method exists to save the copy in getExcuses.Modifier and TypeMethodDescriptionprotected LibLinearModel<Event>
LibLinearAnomalyTrainer.createModel
(ModelProvenance provenance, ImmutableFeatureMap featureIDMap, ImmutableOutputInfo<Event> outputIDInfo, List<de.bwaldvogel.liblinear.Model> models) protected com.oracle.labs.mlrg.olcut.util.Pair<de.bwaldvogel.liblinear.FeatureNode[][],
double[][]> LibLinearAnomalyTrainer.extractData
(Dataset<Event> data, ImmutableOutputInfo<Event> outputInfo, ImmutableFeatureMap featureMap) protected com.oracle.labs.mlrg.olcut.util.Pair<de.bwaldvogel.liblinear.FeatureNode[][],
double[][]> LibLinearAnomalyTrainer.extractData
(Dataset<Event> data, ImmutableOutputInfo<Event> outputInfo, ImmutableFeatureMap featureMap) LibLinearAnomalyModel.innerGetExcuse
(Example<Event> e, double[][] allFeatureWeights) The call to model.getFeatureWeights in the public methods copies the weights array so this inner method exists to save the copy in getExcuses.protected de.bwaldvogel.liblinear.Parameter
LibLinearAnomalyTrainer.setupParameters
(ImmutableOutputInfo<Event> labelIDMap) -
Uses of Event in org.tribuo.anomaly.libsvm
Modifier and TypeMethodDescriptionprotected LibSVMModel<Event>
LibSVMAnomalyTrainer.createModel
(ModelProvenance provenance, ImmutableFeatureMap featureIDMap, ImmutableOutputInfo<Event> outputIDInfo, List<libsvm.svm_model> models) LibSVMAnomalyTrainer.train
(Dataset<Event> dataset, Map<String, com.oracle.labs.mlrg.olcut.provenance.Provenance> instanceProvenance) Modifier and TypeMethodDescriptionprotected double
LibSVMAnomalyTrainer.extractOutput
(Event output) Converts an output into a double for use in training.Modifier and TypeMethodDescriptionprotected LibSVMModel<Event>
LibSVMAnomalyTrainer.createModel
(ModelProvenance provenance, ImmutableFeatureMap featureIDMap, ImmutableOutputInfo<Event> outputIDInfo, List<libsvm.svm_model> models) protected com.oracle.labs.mlrg.olcut.util.Pair<libsvm.svm_node[][],
double[][]> LibSVMAnomalyTrainer.extractData
(Dataset<Event> data, ImmutableOutputInfo<Event> outputInfo, ImmutableFeatureMap featureMap) protected com.oracle.labs.mlrg.olcut.util.Pair<libsvm.svm_node[][],
double[][]> LibSVMAnomalyTrainer.extractData
(Dataset<Event> data, ImmutableOutputInfo<Event> outputInfo, ImmutableFeatureMap featureMap) LibSVMAnomalyTrainer.train
(Dataset<Event> dataset, Map<String, com.oracle.labs.mlrg.olcut.provenance.Provenance> instanceProvenance) ModifierConstructorDescriptionLibSVMAnomalyTrainer
(SVMParameters<Event> parameters) Creates a one-class LibSVM trainer using the supplied parameters andTrainer.DEFAULT_SEED
.LibSVMAnomalyTrainer
(SVMParameters<Event> parameters, long seed) Creates a one-class LibSVM trainer using the supplied parameters and RNG seed.