Package org.tribuo
Class Excuse<T extends Output<T>>
java.lang.Object
org.tribuo.Excuse<T>
- Direct Known Subclasses:
EnsembleExcuse
Holds an
Example
, a Prediction
and a Map from String to List of Pairs
that contains the per output explanation.-
Constructor Summary
-
Method Summary
Modifier and TypeMethodDescriptionReturns the features involved in this excuse.The example being excused.Returns the prediction being excused.Returns the scores for all outputs and the relevant feature values.
-
Constructor Details
-
Excuse
public Excuse(Example<T> example, Prediction<T> prediction, Map<String, List<com.oracle.labs.mlrg.olcut.util.Pair<String, Double>>> weights) Constructs an excuse for the prediction of the supplied example, using the feature weights.- Parameters:
example
- The example to excuse.prediction
- The prediction to excuse.weights
- The feature weights involved.
-
-
Method Details
-
excuse
Returns the features involved in this excuse.- Parameters:
label
- The features for the requested output.- Returns:
- The features invovled.
-
getPrediction
Returns the prediction being excused.- Returns:
- The prediction.
-
getScores
Returns the scores for all outputs and the relevant feature values.- Returns:
- The output scores and feature values.
-
getExample
The example being excused.- Returns:
- The example.
-