From a39c92016ffffe0c8825a33b0925de5e2ad59817 Mon Sep 17 00:00:00 2001 From: Onuralp SEZER Date: Thu, 21 Sep 2023 15:45:04 +0300 Subject: [PATCH] =?UTF-8?q?docs(example):=20=F0=9F=93=9D=20example=20Label?= =?UTF-8?q?Annotator=20doc=20fix?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Signed-off-by: Onuralp SEZER --- supervision/annotators/core.py | 8 +------- 1 file changed, 1 insertion(+), 7 deletions(-) diff --git a/supervision/annotators/core.py b/supervision/annotators/core.py index 3e4fa0ed..7af1d671 100644 --- a/supervision/annotators/core.py +++ b/supervision/annotators/core.py @@ -285,13 +285,7 @@ class LabelAnnotator(BaseAnnotator): >>> classes = ['person', ...] >>> image = ... >>> detections = sv.Detections(...) - - >>> label_annotator = sv.LabelAnnotator() - >>> labels = [ - ... f"{classes[class_id]} {confidence:0.2f}" - ... for _, _, confidence, class_id, _ - ... in detections - ... ] + >>> label_annotator = sv.LabelAnnotator(classes=classes) >>> annotated_frame = label_annotator.annotate( ... scene=image.copy(), ... detections=detections,