Class MultiLabelEvaluationImpl

java.lang.Object
org.tribuo.multilabel.evaluation.MultiLabelEvaluationImpl
All Implemented Interfaces:
com.oracle.labs.mlrg.olcut.provenance.Provenancable<EvaluationProvenance>, ClassifierEvaluation<MultiLabel>, Evaluation<MultiLabel>, MultiLabelEvaluation

public final class MultiLabelEvaluationImpl extends Object implements MultiLabelEvaluation
The implementation of a MultiLabelEvaluation using the default metrics.

The classification metrics consider labels independently.

  • Method Summary

    Modifier and Type
    Method
    Description
    Get a map of all the metrics stored in this evaluation.
    double
    Returns the balanced error rate, i.e., the mean of the per label recalls.
    double
    confusion(MultiLabel predicted, MultiLabel truth)
    Returns the number of times label truth was predicted as label predicted.
    double
    f1(MultiLabel label)
    Returns the F_1 score, i.e., the harmonic mean of the precision and recall.
    double
    fn()
    Returns the micro averaged number of false negatives.
    double
    fn(MultiLabel label)
    Returns the number of false negatives, i.e., the number of times the true label was incorrectly predicted as another label.
    double
    fp()
    Returns the micro average of the number of false positives across all the labels, i.e., the total number of false positives.
    double
    fp(MultiLabel label)
    Returns the number of false positives, i.e., the number of times this label was predicted but it was not the true label..
    double
    Gets the value associated with the specific metric.
    Returns the underlying confusion matrix.
    Gets the predictions stored in this evaluation.
     
    double
    The average across the predictions of the intersection of the true and predicted labels divided by the union of the true and predicted labels.
    double
    Returns the macro averaged F_1 across all the labels.
    double
    Returns the macro averaged precision.
    double
    Returns the macro averaged recall.
    double
    Returns the macro averaged number of false negatives.
    double
    Returns the macro averaged number of false positives, averaged across the labels.
    double
    Returns the macro averaged number of true negatives.
    double
    Returns the macro averaged number of true positives, averaged across the labels.
    double
    Returns the micro averaged F_1 across all labels.
    double
    Returns the micro averaged precision.
    double
    Returns the micro averaged recall.
    double
    Returns the precision of this label, i.e., the number of true positives divided by the number of true positives plus false positives.
    double
    Returns the recall of this label, i.e., the number of true positives divided by the number of true positives plus false negatives.
    double
    tn()
    Returns the total number of true negatives.
    double
    tn(MultiLabel label)
    Returns the number of true negatives for that label, i.e., the number of times it wasn't predicted, and was not the true label.
     
    double
    tp()
    Returns the micro average of the number of true positives across all the labels, i.e., the total number of true positives.
    double
    tp(MultiLabel label)
    Returns the number of true positives, i.e., the number of times the label was correctly predicted.

    Methods inherited from class java.lang.Object

    clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait