Contents

meanAveragePrecisionScore(classifications:groundTruth:)

Computes the mean average precision.

Declaration

static func meanAveragePrecisionScore(classifications: some Sequence<ClassificationDistribution<Label>>, groundTruth: some Sequence<Set<Label>>) -> Float

Parameters

  • classifications:

    A sequence of multi-label classifications.

  • groundTruth:

    A sequence of multi-label correct labels.

Return Value

The mean average precision.

Discussion

An average precision score summarizes the precision-recall curve for a label. The mean average precision is the mean of the average precision scores for all the classification labels.

See Also

Computing the precision