From a78bf58c6dbb46f02e11f7c425444f86004e0eae Mon Sep 17 00:00:00 2001 From: Omkar Kabde Date: Tue, 10 Mar 2026 15:01:18 +0530 Subject: [PATCH] refactor docstrings in `src/supervision/annotators` (#2163) --- src/supervision/annotators/core.py | 2 +- src/supervision/annotators/utils.py | 4 ++-- 2 files changed, 3 insertions(+), 3 deletions(-) diff --git a/src/supervision/annotators/core.py b/src/supervision/annotators/core.py index fbb6f853..a2f729b3 100644 --- a/src/supervision/annotators/core.py +++ b/src/supervision/annotators/core.py @@ -3107,7 +3107,7 @@ class ComparisonAnnotator: computed positions. Args: - scene (npt.NDArray[np.uint8]): The image where the labels will be drawn. + scene: The image where the labels will be drawn. """ margin = int(50 * self.label_scale) gap = int(40 * self.label_scale) diff --git a/src/supervision/annotators/utils.py b/src/supervision/annotators/utils.py index 652f176d..2efc053a 100644 --- a/src/supervision/annotators/utils.py +++ b/src/supervision/annotators/utils.py @@ -376,10 +376,10 @@ def hex_to_rgba(hex_color: str) -> tuple[int, int, int, int]: Converts a hex color string (e.g. "#FF00FF" or "#FF00FF80") to an RGBA tuple. Args: - hex_color (str): A hex color string. + hex_color: A hex color string. Returns: - tuple[int, int, int, int]: RGBA values in range 0-255. + RGBA values in range 0-255. Raises: ValueError: If the format is invalid.