From c4ede20a2d0628f2b34e73aac9f0176efc696a61 Mon Sep 17 00:00:00 2001 From: SkalskiP Date: Tue, 15 Jul 2025 21:13:46 +0200 Subject: [PATCH] add deprecation message to old mAP --- supervision/metrics/detection.py | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) diff --git a/supervision/metrics/detection.py b/supervision/metrics/detection.py index 52bf96e0..946ccd21 100644 --- a/supervision/metrics/detection.py +++ b/supervision/metrics/detection.py @@ -496,7 +496,8 @@ class ConfusionMatrix: @deprecated( "`MeanAveragePrecision` is deprecated and will be removed in " "`supervision-0.31.0`. Use " - "`supervision.metrics.mean_average_precision.MeanAveragePrecision` instead." + "`supervision.metrics.mean_average_precision.MeanAveragePrecision` instead. The " + "deprecated implementation provides results that are inconsistent with pycocotools." ) @dataclass(frozen=True) class MeanAveragePrecision: @@ -505,7 +506,7 @@ class MeanAveragePrecision: `MeanAveragePrecision` is **deprecated** and will be removed in `supervision-0.31.0`. - The current implementation provides results that are inconsistent with + The deprecated implementation provides results that are inconsistent with `pycocotools`. Please use `supervision.metrics.mean_average_precision.MeanAveragePrecision` instead, which matches the results of `pycocotools` and is now the recommended approach.