Repository Analysis

roboflow/supervision

We write your reusable computer vision tools. 💜

29.5 Moderate AI signal View on GitHub

Analysis Overview

This report presents the forensic synthetic code analysis of roboflow/supervision, a Python project with 48,000 GitHub stars. SynthScan v2.0 examined 98,237 lines of code across 327 source files, recording 1748 pattern matches distributed across 18 syntactic categories. The overall adjusted score of 29.5 places this repository in the Moderate AI signal band.

The scanner applied 160+ deterministic lexical heuristics, multi-line block detectors, abstract syntax tree depth profilers, and a cross-file Jaccard similarity matrix to construct a statistically normalised synthetic code estimate. All matches are individually weighted by severity coefficient and contextual multiplier before summation, and the resulting headline score is temporally discounted to account for the repository's development history relative to the commercial emergence of large language model coding tooling (November 2022 onward).

29.5
Adjusted Score
29.5
Raw Score
100%
Time Factor
2026-07-13
Last Push
48.0K
Stars
Python
Language
98.2K
Lines of Code
327
Files
1.7K
Pattern Hits
2026-07-14
Scan Date
0.76
HC Hit Rate

What These Metrics Mean

Adjusted Score
Primary synthetic code indicator. Raw score normalised per 1,000 lines of code and multiplied by the temporal discount factor. This is the definitive comparative metric — use it to rank repositories by AI authorship density.
Raw Score
The unmodified sum of all severity-weighted, context-multiplied pattern match scores before temporal discounting. Reflects the absolute signal strength independent of when the repository was last active.
Time Factor
The temporal discount multiplier (0–100%) applied to the raw score. Repositories last updated before ChatGPT's launch (Nov 2022) receive a 5% factor. Full signal is only assigned to repositories active in the post-adoption era (Jan 2024+).
Pattern Hits
Total count of individual pattern matches across all files and categories. A high hit count with a low score may indicate a very large codebase with isolated AI snippets; a low count with a high score indicates dense, concentrated AI signatures.
HC Hit Rate
High+Critical pattern hits per file, averaged across the repository. This orthogonal signal catches repositories where a few files are densely packed with high-severity AI tells — a strong indicator even when the normalised score appears moderate due to codebase size.
Lines of Code / Files
Total lines and files analysed. The scanner examines 94 file extensions. These denominators are used to normalise the score, enabling fair comparison between repositories of vastly different sizes.

Score History

This chart maps the temporal evolution of the adjusted synthetic code score across successive scan runs. An upward trajectory indicates ongoing incorporation of AI-generated code or expanding LLM-assisted scaffolding; a stable or declining trajectory may reflect active human refactoring, code removal, or the adoption of stricter authorship policies. The dashed secondary line (right axis) independently tracks total raw pattern hit count, which can diverge from the normalised score when codebase size changes significantly between scans.

Severity Breakdown

Classifies detected patterns by their diagnostic confidence and structural impact. CRITICAL patterns (coefficient 10) represent definitive synthetic signatures — hallucinated imports, explicit LLM attribution metadata — virtually never produced by human authors. HIGH (5) indicates strong structural tells such as cross-file repetition or cross-linguistic idioms. MEDIUM (2) covers recognisable conversational padding and AI-specific vocabulary. LOW (1) captures subtle indicators like tautological comments and generic boilerplate that require density to carry independent signal.

CRITICAL 0HIGH 247MEDIUM 127LOW 1374

Directory Score Breakdown

This horizontal bar chart decomposes the repository's raw synthetic code score by top-level directory, allowing you to pinpoint precisely which modules or components carry the highest AI authorship density. Directories with disproportionately high scores relative to their size warrant targeted manual review: concentrated AI signatures often trace back to mass-generated configuration layers, auto-ported test suites, LLM-scaffolded boilerplate classes, or entire subsystems authored under heavy copilot assistance. Use this view to prioritise your human code-review effort.

Pattern Findings

The scanner identified 1748 distinct pattern matches across 18 syntactic categories. Each entry below represents a discrete location in the source code where the engine recorded a statistically significant AI authorship indicator. Expand any category row to inspect the individual file paths, line numbers, code snippets, and the lexical context (CODE, COMMENT, or STRING) in which each match was detected.

Reading the findings table: The Severity column indicates the diagnostic confidence level (CRITICAL / HIGH / MEDIUM / LOW). The Context column identifies whether the match occurred inside executable code, an inline comment, or a string literal — comment-context matches receive a ×1.5 weight because LLMs systematically over-annotate. The ⚡ bolt icon marks clustered matches: three or more patterns within a 10-line window, each receiving an additional ×1.5 density multiplier as dense clusters constitute far stronger evidence of synthetic authorship than isolated hits.

Hyper-Verbose Identifiers1084 hits · 974 pts
SeverityFileLineSnippetContext
LOWtests/test_public_api.py12def test_all_symbols_are_importable(symbol_name: str) -> None:CODE
LOWtests/test_public_api.py31def test_shipped_imports_are_listed_in_all(symbol_name: str) -> None:CODE
LOWtests/test_validate_deprecations.py99def test_validate_public_shims_warn(call: Callable[[], object], version: str) -> None:CODE
LOWtests/test_validate_deprecations.py104def test_private_validation_paths_do_not_warn() -> None:CODE
LOWtests/test_validate_deprecations.py124def test_import_supervision_stays_silent_about_bytetrack() -> None:CODE
LOWtests/helpers.py597def create_predictions_with_class_iou_tests(CODE
LOWtests/classification/test_core.py95def test_from_clip_empty_output_dtypes() -> None:CODE
LOWtests/classification/test_core.py104def test_from_timm_empty_output_dtypes() -> None:CODE
LOWtests/classification/test_core.py113def test_from_timm_softmaxes_logits() -> None:CODE
LOWtests/classification/test_core.py126def test_classifications_compare_numpy_fields_by_value() -> None:CODE
LOWtests/metrics/test_size_bucket_regressions.py47def test_size_bucket_match_is_not_stolen(CODE
LOWtests/metrics/test_size_bucket_regressions.py76def test_small_bucket_mar_returns_zero_without_bucket_targets() -> None:CODE
LOWtests/metrics/test_size_bucket_regressions.py101def test_medium_bucket_mar_counts_global_rank_budget() -> None:CODE
LOWtests/metrics/test_size_bucket_regressions.py145def test_mask_target_requires_masks(metric_cls, missing_side) -> None:CODE
LOWtests/metrics/test_mean_average_recall.py148def complex_scenario_predictions():CODE
LOWtests/metrics/test_mean_average_recall.py287def two_class_two_image_detections():CODE
LOWtests/metrics/test_mean_average_recall.py327def three_class_single_image_detections():CODE
LOWtests/metrics/test_mean_average_recall.py367def test_compute_value_error_for_missing_required_fields_after_update(CODE
LOWtests/metrics/test_mean_average_recall.py403def test_mask_content_preserves_compact_mask() -> None:CODE
LOWtests/metrics/test_mean_average_recall.py419def test_compute_with_compact_mask_matches_dense() -> None:CODE
LOWtests/metrics/test_mean_average_recall.py440def test_single_perfect_detection() -> None:CODE
LOWtests/metrics/test_mean_average_recall.py456def test_recall_per_class_keeps_each_max_detection_cutoff() -> None:CODE
LOWtests/metrics/test_mean_average_recall.py483def test_empty_inputs_keep_max_detection_axis() -> None:CODE
LOWtests/metrics/test_mean_average_recall.py505def test_medium_bucket_scores_target_matched_small_prediction() -> None:CODE
LOWtests/metrics/test_mean_average_recall.py536def test_compute_value_error_for_missing_required_fields(missing_attribute) -> None:CODE
LOWtests/metrics/test_mean_average_recall.py570def test_complex_integration_scenario(CODE
LOWtests/metrics/test_mean_average_recall.py598def test_mar_at_k_limits_per_image_not_per_class(CODE
LOWtests/metrics/test_mean_average_recall.py655def test_three_class_single_image_scenario(three_class_single_image_detections) -> None:CODE
LOWtests/metrics/test_mean_average_recall.py702def test_dataset_split_integration(yolo_dataset_two_classes) -> None:CODE
LOWtests/metrics/test_mean_average_recall.py784def test_greedy_matching_two_valid_pairs():CODE
LOWtests/metrics/test_f1_score.py13 def predictions_multiple_classes(self):CODE
LOWtests/metrics/test_f1_score.py40 def test_initialization_default(self):CODE
LOWtests/metrics/test_f1_score.py48 def test_initialization_custom(self):CODE
LOWtests/metrics/test_f1_score.py57 def test_mask_content_preserves_compact_mask(self) -> None:CODE
LOWtests/metrics/test_f1_score.py72 def test_compute_with_compact_mask_matches_dense(self) -> None:CODE
LOWtests/metrics/test_f1_score.py163 def test_medium_bucket_scores_target_matched_small_prediction(self) -> None:CODE
LOWtests/metrics/test_f1_score.py180 def test_false_positives_on_background_image_counted(self):CODE
LOWtests/metrics/test_f1_score.py223 def test_false_positives_of_absent_class_counted(self, method, expected):CODE
LOWtests/metrics/test_f1_score.py246 def test_false_positives_on_background_image_weighted_returns_zero(self):CODE
LOWtests/metrics/test_f1_score.py260 def test_single_class_mixed_results(CODE
LOWtests/metrics/test_f1_score.py275 def test_precision_recall_imbalance(CODE
LOWtests/metrics/test_f1_score.py308 def test_different_iou_thresholds(self, predictions_iou_064, targets_iou_064):CODE
LOWtests/metrics/test_f1_score.py344 def test_mismatched_list_lengths(self, detections_50_50, targets_50_50):CODE
LOWtests/metrics/test_f1_score.py356 def test_compute_value_error_for_missing_required_fields(CODE
LOWtests/metrics/test_f1_score.py443 def test_greedy_matching_two_valid_pairs(self):CODE
LOWtests/metrics/test_lazy_imports.py50def test_metrics_package_import_keeps_pyplot_lazy() -> None:CODE
LOWtests/metrics/test_lazy_imports.py60def test_precision_plot_imports_pyplot_on_demand(monkeypatch) -> None:CODE
LOWtests/metrics/conftest.py65def predictions_multiple_classes():CODE
LOWtests/metrics/conftest.py112def predictions_confidence_ranking():CODE
LOWtests/metrics/test_mean_average_precision.py38 def test_single_perfect_detection(self, detections_50_50, targets_50_50):CODE
LOWtests/metrics/test_mean_average_precision.py47 def test_multiple_perfect_detections(self):CODE
LOWtests/metrics/test_mean_average_precision.py66 def test_perfect_non_square_oriented_boxes_get_full_map(self):CODE
LOWtests/metrics/test_mean_average_precision.py92 def test_batch_updates_perfect_detections(self, detections_50_50, targets_50_50):CODE
LOWtests/metrics/test_mean_average_precision.py312 def test_mixed_classes_with_missing_detections(CODE
LOWtests/metrics/test_mean_average_precision.py342 def test_empty_predictions_and_targets(self):CODE
LOWtests/metrics/test_mean_average_precision.py393 def test_mask_pixel_count_drives_size_buckets(self) -> None:CODE
LOWtests/metrics/test_mean_average_precision.py416 def test_boxes_target_ignores_masks(self) -> None:CODE
LOWtests/metrics/test_mean_average_precision.py462 def test_missing_oriented_boxes_raise(self) -> None:CODE
LOWtests/metrics/test_mean_average_precision.py478 def test_cross_matched_obb_orients_iou_correctly(self) -> None:CODE
LOWtests/metrics/test_mean_average_precision.py510 def test_crowd_gt_ignores_contained_detection(self) -> None:CODE
1024 more matches not shown…
Docstring Block Structure191 hits · 955 pts
SeverityFileLineSnippetContext
HIGHtests/helpers.py46 Create a Detections object from list-based inputs. This is a helper function primarily used for testing purposSTRING
HIGHtests/helpers.py106 Create a KeyPoints object from list-based inputs. This is a helper function primarily used for testing purposeSTRING
HIGHtests/helpers.py170 Generate random bounding boxes within given image dimensions and size constraints. Creates `count` bounding boSTRING
HIGHtests/helpers.py387 Create a synthetic YOLO-format dataset on disk. Generates dummy images with YOLO-format annotations, `data.yamSTRING
HIGHtests/geometry/test_utils.py9 Generate a semicircle with a given number of points. Parameters: n (int): amount of points in polygSTRING
HIGHsrc/supervision/metrics/detection.py68 Convert Supervision Detections to a numpy tensor for metric computation. Args: detections: Detections/STRING
HIGHsrc/supervision/metrics/detection.py443Render detections onto a copy of ``scene`` with a title overlay. Args: scene: Source image panel (not mutatSTRING
HIGHsrc/supervision/metrics/detection.py689 Calculate confusion matrix based on predicted and ground-truth detections. Args: targets: STRING
HIGHsrc/supervision/metrics/detection.py773 Calculate confusion matrix based on predicted and ground-truth detections. Args: predictioSTRING
HIGHsrc/supervision/metrics/detection.py1283 Calculate mean average precision based on predicted and ground-truth detections. Args: tarSTRING
HIGHsrc/supervision/metrics/detection.py1383 Calculate Mean Average Precision based on predicted and ground-truth detections at different threshSTRING
HIGHsrc/supervision/key_points/core.py386 Create a `sv.KeyPoints` object from the [Roboflow](https://roboflow.com/) API inference result or the [STRING
HIGHsrc/supervision/key_points/core.py470 Creates a `sv.KeyPoints` instance from a [MediaPipe](https://github.com/google-ai-edge/mediapipe) STRING
HIGHsrc/supervision/key_points/core.py600 Creates a `sv.KeyPoints` instance from a [YOLOv8](https://github.com/ultralytics/ultralytics) pose infeSTRING
HIGHsrc/supervision/key_points/core.py637 Create a `sv.KeyPoints` instance from a [YOLO-NAS](https://github.com/Deci-AI/super-gradients/blob/master/YOLONSTRING
HIGHsrc/supervision/key_points/core.py695 Create a `sv.KeyPoints` object from the [Detectron2](https://github.com/facebookresearch/detectron2) inSTRING
HIGHsrc/supervision/key_points/core.py746 Create a `sv.KeyPoints` object from the [Transformers](https://github.com/huggingface/transformers) infSTRING
HIGHsrc/supervision/key_points/core.py830Filter keypoints using a 2D boolean mask of shape `(n, m)`. This method selects the **same set of keypoints froSTRING
HIGHsrc/supervision/key_points/core.py1063 Get a subset of the KeyPoints object or access an item from its data field. Supports detection-level (STRING
HIGHsrc/supervision/key_points/core.py1179 Merge a list of KeyPoints objects into a single KeyPoints object. This method takes a list of KeyPointSTRING
HIGHsrc/supervision/key_points/core.py1300 Performs non-max suppression on the keypoint detections. Bounding boxes are derived from valid keypointSTRING
HIGHsrc/supervision/key_points/core.py1385 Convert a KeyPoints object to a Detections object. This approximates the bounding box of the detected oSTRING
HIGHsrc/supervision/key_points/annotators.py62 Annotates the given scene with skeleton vertices based on the provided key points. It draws circles at STRING
HIGHsrc/supervision/key_points/annotators.py154 Annotates the given scene by drawing lines between specified key points to form edges. Edges where eithSTRING
HIGHsrc/supervision/key_points/annotators.py420 Draws filled semi-transparent covariance ellipses around each keypoint. Args: scene: The iSTRING
HIGHsrc/supervision/key_points/annotators.py520 Draws stroke-only covariance ellipse outlines around each keypoint. Args: scene: The imageSTRING
HIGHsrc/supervision/key_points/annotators.py624 Draws radially-fading covariance ellipses around each keypoint. Args: scene: The image to STRING
HIGHsrc/supervision/key_points/annotators.py766 Draws labels at skeleton vertex positions on the image. Vertices marked not visible via ``key_points.viSTRING
HIGHsrc/supervision/dataset/core.py211 Splits the dataset into two parts (training and testing) using the provided split_ratio. The input STRING
HIGHsrc/supervision/dataset/core.py279 Merge a list of `DetectionDataset` objects into a single `DetectionDataset` object. This mSTRING
HIGHsrc/supervision/dataset/core.py459 Creates a Dataset instance from PASCAL VOC formatted data. Args: images_directory_path: PaSTRING
HIGHsrc/supervision/dataset/core.py519 Creates a Dataset instance from YOLO formatted data. Args: images_directory_path: The pathSTRING
HIGHsrc/supervision/dataset/core.py681 Creates a Dataset instance from LabelMe formatted data. LabelMe stores one JSON file per image, each cSTRING
HIGHsrc/supervision/dataset/core.py784 Creates a Dataset instance from CreateML formatted data. CreateML stores object-detection annotations STRING
HIGHsrc/supervision/dataset/core.py838 Exports the dataset to CreateML format. This method saves the images and their corresponding annotationSTRING
HIGHsrc/supervision/dataset/core.py885 Creates a Dataset instance from COCO formatted data. Args: images_directory_path: The pathSTRING
HIGHsrc/supervision/dataset/core.py1142 Splits the dataset into two parts (training and testing) using the provided split_ratio. ASTRING
HIGHsrc/supervision/dataset/core.py1245 Load data from a multiclass folder structure into a ClassificationDataset. Args: root_direSTRING
HIGHsrc/supervision/dataset/utils.py148Raise if two image paths would be written to the same output file. Dataset image paths may share a basename when thSTRING
HIGHsrc/supervision/dataset/utils.py238 Splits the data into two parts using the provided train_ratio. Args: data: The data to split. STRING
HIGHsrc/supervision/dataset/formats/coco.py53Convert a list of class names to COCO ``categories`` entries. Category ids are emitted 1-indexed to comply with theSTRING
HIGHsrc/supervision/dataset/formats/coco.py245Convert `Detections` to COCO ``annotations`` entries. The internal 0-indexed ``Detections.class_id`` is serialized STRING
HIGHsrc/supervision/dataset/formats/coco.py387 Generates a mapping from sequential class indices to original COCO class ids. This function is essential when STRING
HIGHsrc/supervision/dataset/formats/coco.py461 Load COCO annotations and convert them to `Detections`. If `force_masks` is `False`, masks are still loaded foSTRING
HIGHsrc/supervision/dataset/formats/coco.py590Save a DetectionDataset to a COCO-format ``annotations.json`` file. Args: dataset: The DetectionDataset to STRING
HIGHsrc/supervision/dataset/formats/labelme.py67Convert a single image's LabelMe shapes into ``Detections``. Only ``rectangle`` and ``polygon`` shapes are importedSTRING
HIGHsrc/supervision/dataset/formats/labelme.py172Load LabelMe annotations and convert them to ``Detections``. LabelMe stores one JSON file per image, each containinSTRING
HIGHsrc/supervision/dataset/formats/labelme.py304Convert ``Detections`` into a list of LabelMe shape dicts. Masked detections are exported as ``polygon`` shapes (onSTRING
HIGHsrc/supervision/dataset/formats/labelme.py360Export a ``DetectionDataset`` to per-image LabelMe ``.json`` files. Args: dataset: The ``DetectionDataset``STRING
HIGHsrc/supervision/dataset/formats/yolo.py78Return class names from a YOLO data.yaml file ordered by class index. Supports list and dict forms of the ``names``STRING
HIGHsrc/supervision/dataset/formats/yolo.py316Convert detections to YOLO annotation lines. Args: detections: The detections to serialize. Each detection STRING
HIGHsrc/supervision/dataset/formats/pascal_voc.py30Build a Pascal VOC ``<object>`` XML element for one detection. Coordinates are converted to 1-indexed Pascal VOC coSTRING
HIGHsrc/supervision/dataset/formats/pascal_voc.py390Write Pascal VOC XML annotation files for every image in *dataset*. Args: dataset: Dataset whose annotationSTRING
HIGHsrc/supervision/dataset/formats/createml.py60Convert a single image's CreateML annotations into ``Detections``. CreateML stores each box as a pixel-space centreSTRING
HIGHsrc/supervision/dataset/formats/createml.py135Load CreateML object-detection annotations and convert them to ``Detections``. CreateML uses a single JSON file conSTRING
HIGHsrc/supervision/dataset/formats/createml.py225Convert ``Detections`` into a list of CreateML annotation dicts. Each bounding box is stored as a pixel-space centrSTRING
HIGHsrc/supervision/dataset/formats/createml.py286Export a ``DetectionDataset`` to a CreateML object-detection JSON file. Only the filename component of each image pSTRING
HIGHsrc/supervision/annotators/core.py228 Annotates the given scene with bounding boxes based on the provided detections. Args: scenSTRING
HIGHsrc/supervision/annotators/core.py531 Annotates the given scene with masks based on the provided detections. Args: scene: The imSTRING
HIGHsrc/supervision/annotators/core.py640 Annotates the given scene with polygons based on the provided detections. Args: scene: TheSTRING
131 more matches not shown…
Decorative Section Separators118 hits · 429 pts
SeverityFileLineSnippetContext
MEDIUMtests/dataset/test_core.py709# ---------------------------------------------------------------------------COMMENT
MEDIUMtests/dataset/test_core.py711# ---------------------------------------------------------------------------COMMENT
MEDIUMtests/dataset/test_core.py634# ---------------------------------------------------------------------------COMMENT
MEDIUMtests/dataset/test_core.py636# ---------------------------------------------------------------------------COMMENT
MEDIUMtests/dataset/test_progress.py169# ---------------------------------------------------------------------------COMMENT
MEDIUMtests/dataset/test_progress.py171# ---------------------------------------------------------------------------COMMENT
MEDIUMtests/dataset/test_progress.py110# ---------------------------------------------------------------------------COMMENT
MEDIUMtests/dataset/test_progress.py112# ---------------------------------------------------------------------------COMMENT
MEDIUMtests/dataset/test_progress.py133# ---------------------------------------------------------------------------COMMENT
MEDIUMtests/dataset/test_progress.py135# ---------------------------------------------------------------------------COMMENT
MEDIUMtests/draw/test_utils.py148# ---------------------------------------------------------------------------COMMENT
MEDIUMtests/draw/test_utils.py150# ---------------------------------------------------------------------------COMMENT
MEDIUMtests/draw/test_utils.py181# ---------------------------------------------------------------------------COMMENT
MEDIUMtests/draw/test_utils.py183# ---------------------------------------------------------------------------COMMENT
MEDIUMtests/draw/test_utils.py213# ---------------------------------------------------------------------------COMMENT
MEDIUMtests/draw/test_utils.py215# ---------------------------------------------------------------------------COMMENT
MEDIUMtests/draw/test_utils.py245# ---------------------------------------------------------------------------COMMENT
MEDIUMtests/draw/test_utils.py247# ---------------------------------------------------------------------------COMMENT
MEDIUMtests/draw/test_utils.py275# ---------------------------------------------------------------------------COMMENT
MEDIUMtests/draw/test_utils.py277# ---------------------------------------------------------------------------COMMENT
MEDIUMtests/detection/test_from_adapters.py201# ---------------------------------------------------------------------------COMMENT
MEDIUMtests/detection/test_from_adapters.py203# ---------------------------------------------------------------------------COMMENT
MEDIUMtests/detection/test_from_adapters.py313# ---------------------------------------------------------------------------COMMENT
MEDIUMtests/detection/test_from_adapters.py315# ---------------------------------------------------------------------------COMMENT
MEDIUMtests/detection/test_from_adapters.py373# ---------------------------------------------------------------------------COMMENT
MEDIUMtests/detection/test_from_adapters.py375# ---------------------------------------------------------------------------COMMENT
MEDIUMtests/detection/test_from_adapters.py434# ---------------------------------------------------------------------------COMMENT
MEDIUMtests/detection/test_from_adapters.py436# ---------------------------------------------------------------------------COMMENT
MEDIUMtests/detection/test_from_adapters.py480# ---------------------------------------------------------------------------COMMENT
MEDIUMtests/detection/test_from_adapters.py482# ---------------------------------------------------------------------------COMMENT
MEDIUMtests/detection/test_from_adapters.py537# ---------------------------------------------------------------------------COMMENT
MEDIUMtests/detection/test_from_adapters.py539# ---------------------------------------------------------------------------COMMENT
MEDIUMtests/detection/test_from_adapters.py602# ---------------------------------------------------------------------------COMMENT
MEDIUMtests/detection/test_from_adapters.py604# ---------------------------------------------------------------------------COMMENT
MEDIUMtests/detection/test_from_adapters.py709# ---------------------------------------------------------------------------COMMENT
MEDIUMtests/detection/test_from_adapters.py711# ---------------------------------------------------------------------------COMMENT
MEDIUMtests/detection/test_from_adapters.py755# ---------------------------------------------------------------------------COMMENT
MEDIUMtests/detection/test_from_adapters.py757# ---------------------------------------------------------------------------COMMENT
MEDIUMtests/detection/test_compact_mask_iou.py23# ---------------------------------------------------------------------------COMMENT
MEDIUMtests/detection/test_compact_mask_iou.py25# ---------------------------------------------------------------------------COMMENT
MEDIUMtests/detection/test_compact_mask_iou.py383# ---------------------------------------------------------------------------COMMENT
MEDIUMtests/detection/test_compact_mask_iou.py385# ---------------------------------------------------------------------------COMMENT
MEDIUMtests/detection/test_compact_mask.py1092# ---------------------------------------------------------------------------COMMENT
MEDIUMtests/detection/test_compact_mask.py1094# ---------------------------------------------------------------------------COMMENT
MEDIUMtests/detection/tools/test_transformers.py21# ---------------------------------------------------------------------------COMMENT
MEDIUMtests/detection/tools/test_transformers.py23# ---------------------------------------------------------------------------COMMENT
MEDIUMtests/detection/tools/test_transformers.py26# ---------------------------------------------------------------------------COMMENT
MEDIUMtests/detection/tools/test_transformers.py28# ---------------------------------------------------------------------------COMMENT
MEDIUMtests/detection/tools/test_transformers.py148# ---------------------------------------------------------------------------COMMENT
MEDIUMtests/detection/tools/test_transformers.py150# ---------------------------------------------------------------------------COMMENT
MEDIUMtests/detection/tools/test_transformers.py202# ---------------------------------------------------------------------------COMMENT
MEDIUMtests/detection/tools/test_transformers.py204# ---------------------------------------------------------------------------COMMENT
MEDIUMtests/detection/tools/test_transformers.py310# ---------------------------------------------------------------------------COMMENT
MEDIUMtests/detection/tools/test_transformers.py312# ---------------------------------------------------------------------------COMMENT
MEDIUMtests/detection/tools/test_transformers.py356# ---------------------------------------------------------------------------COMMENT
MEDIUMtests/detection/tools/test_transformers.py358# ---------------------------------------------------------------------------COMMENT
MEDIUMtests/detection/tools/test_transformers.py65# ---------------------------------------------------------------------------COMMENT
MEDIUMtests/detection/tools/test_transformers.py67# ---------------------------------------------------------------------------COMMENT
MEDIUMtests/detection/tools/test_transformers.py109# ---------------------------------------------------------------------------COMMENT
MEDIUMtests/detection/tools/test_transformers.py111# ---------------------------------------------------------------------------COMMENT
58 more matches not shown…
Cross-File Repetition48 hits · 240 pts
SeverityFileLineSnippetContext
HIGHtests/metrics/test_mean_average_recall.py0test compute raises valueerror when required fields are missing.STRING
HIGHtests/metrics/test_f1_score.py0test compute raises valueerror when required fields are missing.STRING
HIGHtests/metrics/test_precision.py0test compute raises valueerror when required fields are missing.STRING
HIGHtests/metrics/test_recall.py0test compute raises valueerror when required fields are missing.STRING
HIGHtests/metrics/test_f1_score.py0test that mismatched prediction/target list lengths raise errorSTRING
HIGHtests/metrics/test_precision.py0test that mismatched prediction/target list lengths raise errorSTRING
HIGHtests/metrics/test_recall.py0test that mismatched prediction/target list lengths raise errorSTRING
HIGHtests/metrics/test_f1_score.py0greedy matching finds both tps; np.unique style missed the second pair. iou matrix: [[1.0, 0.667], [0.333, 0.538]]. at iSTRING
HIGHtests/metrics/test_precision.py0greedy matching finds both tps; np.unique style missed the second pair. iou matrix: [[1.0, 0.667], [0.333, 0.538]]. at iSTRING
HIGHtests/metrics/test_recall.py0greedy matching finds both tps; np.unique style missed the second pair. iou matrix: [[1.0, 0.667], [0.333, 0.538]]. at iSTRING
HIGHexamples/time_in_zone/rfdetr_file_example.py0calculating detections dwell time in zones, using rtsp stream. args: rtsp_url: complete rtsp url for the video stream zoSTRING
HIGHexamples/time_in_zone/rfdetr_stream_example.py0calculating detections dwell time in zones, using rtsp stream. args: rtsp_url: complete rtsp url for the video stream zoSTRING
HIGHexamples/time_in_zone/rfdetr_naive_stream_example.py0calculating detections dwell time in zones, using rtsp stream. args: rtsp_url: complete rtsp url for the video stream zoSTRING
HIGHexamples/time_in_zone/utils/general.py0load polygon zone configurations from a json file. this function reads a json file which contains polygon coordinates, aSTRING
HIGHexamples/count_people_in_zone/ultralytics_example.py0load polygon zone configurations from a json file. this function reads a json file which contains polygon coordinates, aSTRING
HIGHexamples/count_people_in_zone/inference_example.py0load polygon zone configurations from a json file. this function reads a json file which contains polygon coordinates, aSTRING
HIGHsrc/supervision/metrics/recall.py0reset the metric to its initial state, clearing all stored data.STRING
HIGHsrc/supervision/metrics/mean_average_recall.py0reset the metric to its initial state, clearing all stored data.STRING
HIGHsrc/supervision/metrics/f1_score.py0reset the metric to its initial state, clearing all stored data.STRING
HIGHsrc/supervision/metrics/precision.py0reset the metric to its initial state, clearing all stored data.STRING
HIGHsrc/supervision/metrics/mean_average_precision.py0reset the metric to its initial state, clearing all stored data.STRING
HIGHsrc/supervision/metrics/recall.py0add new predictions and targets to the metric, but do not compute the result. args: predictions: the predicted detectionSTRING
HIGHsrc/supervision/metrics/mean_average_recall.py0add new predictions and targets to the metric, but do not compute the result. args: predictions: the predicted detectionSTRING
HIGHsrc/supervision/metrics/f1_score.py0add new predictions and targets to the metric, but do not compute the result. args: predictions: the predicted detectionSTRING
HIGHsrc/supervision/metrics/precision.py0add new predictions and targets to the metric, but do not compute the result. args: predictions: the predicted detectionSTRING
HIGHsrc/supervision/metrics/mean_average_precision.py0add new predictions and targets to the metric, but do not compute the result. args: predictions: the predicted detectionSTRING
HIGHsrc/supervision/metrics/recall.py0compute the confusion matrix for each class and iou threshold. assumes the matches and prediction_class_ids are sorted bSTRING
HIGHsrc/supervision/metrics/f1_score.py0compute the confusion matrix for each class and iou threshold. assumes the matches and prediction_class_ids are sorted bSTRING
HIGHsrc/supervision/metrics/precision.py0compute the confusion matrix for each class and iou threshold. assumes the matches and prediction_class_ids are sorted bSTRING
HIGHsrc/supervision/metrics/recall.py0broadcastable function, computing the precision from the confusion matrix. args: confusion_matrix: shape (n, ..., 3), whSTRING
HIGHsrc/supervision/metrics/mean_average_recall.py0broadcastable function, computing the precision from the confusion matrix. args: confusion_matrix: shape (n, ..., 3), whSTRING
HIGHsrc/supervision/metrics/f1_score.py0broadcastable function, computing the precision from the confusion matrix. args: confusion_matrix: shape (n, ..., 3), whSTRING
HIGHsrc/supervision/metrics/precision.py0broadcastable function, computing the precision from the confusion matrix. args: confusion_matrix: shape (n, ..., 3), whSTRING
HIGHsrc/supervision/metrics/recall.py0return boxes, masks or oriented bounding boxes from detections. for the mask target this may return a :class:`~supervisiSTRING
HIGHsrc/supervision/metrics/mean_average_recall.py0return boxes, masks or oriented bounding boxes from detections. for the mask target this may return a :class:`~supervisiSTRING
HIGHsrc/supervision/metrics/f1_score.py0return boxes, masks or oriented bounding boxes from detections. for the mask target this may return a :class:`~supervisiSTRING
HIGHsrc/supervision/metrics/recall.py0return a copy of detections with contents filtered by object size.STRING
HIGHsrc/supervision/metrics/mean_average_recall.py0return a copy of detections with contents filtered by object size.STRING
HIGHsrc/supervision/metrics/f1_score.py0return a copy of detections with contents filtered by object size.STRING
HIGHsrc/supervision/metrics/precision.py0return a copy of detections with contents filtered by object size.STRING
HIGHsrc/supervision/metrics/recall.py0filter predictions and targets by object size category.STRING
HIGHsrc/supervision/metrics/f1_score.py0filter predictions and targets by object size category.STRING
HIGHsrc/supervision/metrics/precision.py0filter predictions and targets by object size category.STRING
HIGHsrc/supervision/metrics/recall.py0convert the result to a pandas dataframe. returns: the result as a dataframe.STRING
HIGHsrc/supervision/metrics/mean_average_recall.py0convert the result to a pandas dataframe. returns: the result as a dataframe.STRING
HIGHsrc/supervision/metrics/f1_score.py0convert the result to a pandas dataframe. returns: the result as a dataframe.STRING
HIGHsrc/supervision/metrics/precision.py0convert the result to a pandas dataframe. returns: the result as a dataframe.STRING
HIGHsrc/supervision/metrics/mean_average_precision.py0convert the result to a pandas dataframe. returns: the result as a dataframe.STRING
Unused Imports202 hits · 143 pts
SeverityFileLineSnippetContext
LOWtests/helpers.py9CODE
LOWtests/classification/test_core.py1CODE
LOWtests/metrics/test_lazy_imports.py3CODE
LOWtests/metrics/test_core.py3CODE
LOWtests/metrics/utils/test_utils.py3CODE
LOWtests/metrics/utils/test_object_size.py3CODE
LOWtests/metrics/utils/test_matching.py3CODE
LOWtests/detection/tools/test_transformers.py3CODE
LOWtests/detection/utils/test_iou_and_nms.py1CODE
LOWexamples/time_in_zone/rfdetr_file_example.py1CODE
LOWexamples/time_in_zone/rfdetr_stream_example.py1CODE
LOWexamples/time_in_zone/rfdetr_naive_stream_example.py1CODE
LOWexamples/compact_mask/bench_inference_api.py10CODE
LOWsrc/supervision/__init__.py10CODE
LOWsrc/supervision/__init__.py10CODE
LOWsrc/supervision/__init__.py10CODE
LOWsrc/supervision/__init__.py10CODE
LOWsrc/supervision/__init__.py10CODE
LOWsrc/supervision/__init__.py10CODE
LOWsrc/supervision/__init__.py10CODE
LOWsrc/supervision/__init__.py10CODE
LOWsrc/supervision/__init__.py10CODE
LOWsrc/supervision/__init__.py10CODE
LOWsrc/supervision/__init__.py10CODE
LOWsrc/supervision/__init__.py10CODE
LOWsrc/supervision/__init__.py10CODE
LOWsrc/supervision/__init__.py10CODE
LOWsrc/supervision/__init__.py10CODE
LOWsrc/supervision/__init__.py10CODE
LOWsrc/supervision/__init__.py10CODE
LOWsrc/supervision/__init__.py10CODE
LOWsrc/supervision/__init__.py10CODE
LOWsrc/supervision/__init__.py10CODE
LOWsrc/supervision/__init__.py10CODE
LOWsrc/supervision/__init__.py10CODE
LOWsrc/supervision/__init__.py10CODE
LOWsrc/supervision/__init__.py35CODE
LOWsrc/supervision/__init__.py35CODE
LOWsrc/supervision/__init__.py35CODE
LOWsrc/supervision/__init__.py35CODE
LOWsrc/supervision/__init__.py41CODE
LOWsrc/supervision/__init__.py42CODE
LOWsrc/supervision/__init__.py42CODE
LOWsrc/supervision/__init__.py42CODE
LOWsrc/supervision/__init__.py47CODE
LOWsrc/supervision/__init__.py48CODE
LOWsrc/supervision/__init__.py49CODE
LOWsrc/supervision/__init__.py50CODE
LOWsrc/supervision/__init__.py50CODE
LOWsrc/supervision/__init__.py50CODE
LOWsrc/supervision/__init__.py55CODE
LOWsrc/supervision/__init__.py56CODE
LOWsrc/supervision/__init__.py56CODE
LOWsrc/supervision/__init__.py60CODE
LOWsrc/supervision/__init__.py61CODE
LOWsrc/supervision/__init__.py61CODE
LOWsrc/supervision/__init__.py62CODE
LOWsrc/supervision/__init__.py63CODE
LOWsrc/supervision/__init__.py63CODE
LOWsrc/supervision/__init__.py63CODE
142 more matches not shown…
Deep Nesting55 hits · 50 pts
SeverityFileLineSnippetContext
LOWtests/annotators/test_docs.py38CODE
LOWexamples/time_in_zone/scripts/draw_zones.py128CODE
LOWexamples/speed_estimation/ultralytics_example.py39CODE
LOWexamples/speed_estimation/yolo_nas_example.py40CODE
LOWexamples/speed_estimation/inference_example.py40CODE
LOWsrc/supervision/metrics/detection.py1041CODE
LOWsrc/supervision/metrics/detection.py1148CODE
LOWsrc/supervision/metrics/recall.py150CODE
LOWsrc/supervision/metrics/recall.py316CODE
LOWsrc/supervision/metrics/mean_average_recall.py386CODE
LOWsrc/supervision/metrics/f1_score.py147CODE
LOWsrc/supervision/metrics/f1_score.py353CODE
LOWsrc/supervision/metrics/precision.py149CODE
LOWsrc/supervision/metrics/precision.py349CODE
LOWsrc/supervision/metrics/mean_average_precision.py506CODE
LOWsrc/supervision/metrics/mean_average_precision.py822CODE
LOWsrc/supervision/metrics/mean_average_precision.py947CODE
LOWsrc/supervision/metrics/mean_average_precision.py1500CODE
LOWsrc/supervision/metrics/mean_average_precision.py1579CODE
LOWsrc/supervision/key_points/core.py467CODE
LOWsrc/supervision/key_points/core.py945CODE
LOWsrc/supervision/key_points/annotators.py153CODE
LOWsrc/supervision/key_points/annotators.py343CODE
LOWsrc/supervision/key_points/annotators.py760CODE
LOWsrc/supervision/dataset/formats/coco.py158CODE
LOWsrc/supervision/dataset/formats/coco.py237CODE
LOWsrc/supervision/dataset/formats/yolo.py145CODE
LOWsrc/supervision/annotators/core.py2188CODE
LOWsrc/supervision/annotators/core.py2939CODE
LOWsrc/supervision/annotators/core.py3136CODE
LOWsrc/supervision/annotators/utils.py38CODE
LOWsrc/supervision/annotators/utils.py78CODE
LOWsrc/supervision/utils/file.py20CODE
LOWsrc/supervision/utils/video.py248CODE
LOWsrc/supervision/utils/video.py306CODE
LOWsrc/supervision/validators/__init__.py191CODE
LOWsrc/supervision/detection/line_zone.py807CODE
LOWsrc/supervision/detection/compact_mask.py59CODE
LOWsrc/supervision/detection/compact_mask.py254CODE
LOWsrc/supervision/detection/core.py856CODE
LOWsrc/supervision/detection/core.py2493CODE
LOWsrc/supervision/detection/vlm.py692CODE
LOWsrc/supervision/detection/tools/inference_slicer.py309CODE
LOWsrc/supervision/detection/tools/inference_slicer.py474CODE
LOWsrc/supervision/detection/tools/inference_slicer.py554CODE
LOWsrc/supervision/detection/utils/internal.py166CODE
LOWsrc/supervision/detection/utils/internal.py285CODE
LOWsrc/supervision/detection/utils/internal.py532CODE
LOWsrc/supervision/detection/utils/internal.py593CODE
LOWsrc/supervision/detection/utils/internal.py647CODE
LOWsrc/supervision/detection/utils/iou_and_nms.py449CODE
LOWsrc/supervision/detection/utils/iou_and_nms.py1390CODE
LOWsrc/supervision/detection/utils/iou_and_nms.py1514CODE
LOWsrc/supervision/detection/utils/masks.py330CODE
LOWsrc/supervision/detection/utils/converters.py290CODE
Cross-Language Confusion4 hits · 30 pts
SeverityFileLineSnippetContext
HIGHtests/detection/test_compact_mask_iou.py193 # Ensure no all-false mask (diagonal would be undefined).COMMENT
HIGHsrc/supervision/metrics/recall.py353 # undefined, so report 0 as the empty case did before.COMMENT
HIGHsrc/supervision/metrics/f1_score.py403 # undefined, so report 0 as the empty case did before.COMMENT
HIGHsrc/supervision/metrics/precision.py399 # undefined, so report 0 as the empty case did before.COMMENT
Magic Placeholder Names4 hits · 20 pts
SeverityFileLineSnippetContext
HIGHdocs/how_to/benchmark_a_model.md53rf = Roboflow(api_key="<YOUR_API_KEY>")CODE
HIGHdocs/how_to/benchmark_a_model.md53rf = Roboflow(api_key="<YOUR_API_KEY>")CODE
HIGHdocs/how_to/benchmark_a_model.md67rf = Roboflow(api_key="<YOUR_API_KEY>")CODE
HIGHdocs/how_to/benchmark_a_model.md67rf = Roboflow(api_key="<YOUR_API_KEY>")CODE
Self-Referential Comments4 hits · 12 pts
SeverityFileLineSnippetContext
MEDIUMsrc/supervision/metrics/mean_average_precision.py516 # Create an empty EvaluationDataset object for the predictionsCOMMENT
MEDIUMsrc/supervision/metrics/mean_average_precision.py1657 # Create a coco object with the targetsCOMMENT
MEDIUMsrc/supervision/metrics/mean_average_precision.py1661 # Create a coco evaluator with the predictionsCOMMENT
MEDIUMsrc/supervision/metrics/mean_average_precision.py1707 # Create the final MeanAveragePrecisionResult objectCOMMENT
AI Structural Patterns12 hits · 10 pts
SeverityFileLineSnippetContext
LOWexamples/heatmap_and_track/script.py13CODE
LOWsrc/supervision/dataset/core.py576CODE
LOWsrc/supervision/dataset/core.py933CODE
LOWsrc/supervision/annotators/core.py108CODE
LOWsrc/supervision/annotators/core.py1318CODE
LOWsrc/supervision/annotators/core.py1669CODE
LOWsrc/supervision/annotators/core.py3285CODE
LOWsrc/supervision/utils/image.py633CODE
LOWsrc/supervision/detection/line_zone.py356CODE
LOWsrc/supervision/detection/line_zone.py752CODE
LOWsrc/supervision/detection/tools/inference_slicer.py262CODE
LOWsrc/supervision/detection/tools/polygon_zone.py143CODE
Modern Structural Boilerplate9 hits · 9 pts
SeverityFileLineSnippetContext
LOWsrc/supervision/__init__.py165__all__ = [CODE
LOWsrc/supervision/metrics/__init__.py23__all__ = [CODE
LOWsrc/supervision/key_points/core.py29logger = logging.getLogger(__name__)CODE
LOWsrc/supervision/dataset/utils.py3__all__ = ["check_no_basename_collisions", "train_test_split"]CODE
LOWsrc/supervision/dataset/formats/labelme.py31__all__ = [CODE
LOWsrc/supervision/tracker/__init__.py5__all__ = ["ByteTrack"]CODE
LOWsrc/supervision/assets/__init__.py4__all__ = ["ImageAssets", "VideoAssets", "download_assets"]CODE
LOWsrc/supervision/detection/line_zone.py325 def _update_class_id_to_name(self, detections: Detections) -> None:CODE
LOWsrc/supervision/detection/utils/internal.py15logger = logging.getLogger(__name__)CODE
Modern AI Meta-Vocabulary3 hits · 8 pts
SeverityFileLineSnippetContext
MEDIUMdocs/llms.txt112- Zero-shot object detection with YOLO-World: https://supervision.roboflow.com/latest/cookbooks/#zero-shot-object-detectCODE
MEDIUMdocs/llms.full.txt121- Zero-shot object detection with YOLO-World: https://supervision.roboflow.com/latest/cookbooks/#zero-shot-object-detectCODE
MEDIUMexamples/compact_mask/benchmark.py622# Scenario runner — orchestrates stagesCOMMENT
Redundant / Tautological Comments5 hits · 7 pts
SeverityFileLineSnippetContext
LOWexamples/traffic_analysis/setup.sh6# Check if 'data' directory does not exist and then create itCOMMENT
LOWexamples/count_people_in_zone/setup.sh6# Check if 'data' directory does not exist and then create itCOMMENT
LOWsrc/supervision/metrics/mean_average_precision.py536 # Check if the predictions contain any unsupported keysCOMMENT
LOWsrc/supervision/metrics/mean_average_precision.py1085 # Set recall to either the final recall value or 0 (when thereCOMMENT
LOWsrc/supervision/detection/compact_mask.py162 # Check if last run has same parity (True/False) as current chunk.COMMENT
Excessive Try-Catch Wrapping5 hits · 5 pts
SeverityFileLineSnippetContext
LOWsrc/supervision/utils/video.py215 except Exception as exc:CODE
LOWsrc/supervision/utils/video.py440 except Exception as exc:CODE
LOWsrc/supervision/assets/downloader.py58 except Exception:CODE
LOWsrc/supervision/detection/vlm.py302 except Exception:CODE
LOWsrc/supervision/detection/vlm.py797 except Exception:CODE
AI Slop Vocabulary1 hit · 3 pts
SeverityFileLineSnippetContext
MEDIUMpyproject.toml145# Enable linting rules for code style, imports, and best practices.COMMENT
Dead Code1 hit · 2 pts
SeverityFileLineSnippetContext
MEDIUMsrc/supervision/metrics/recall.py513CODE
Over-Commented Block1 hit · 1 pts
SeverityFileLineSnippetContext
LOWsrc/supervision/config.py1CLASS_NAME_DATA_FIELD: str = "class_name"COMMENT
Overly Generic Function Names1 hit · 0 pts
SeverityFileLineSnippetContext
LOWsrc/supervision/utils/internal.py142 def my_method(cls):STRING