About this project
SAHI (Slicing Aided Hyper Inference) is a lightweight vision library aimed at large-scale object detection and instance segmentation. Its core idea is sliced inference: splitting large images into overlapping tiles, running detection on each tile, and merging the results, which helps surface small objects that a single full-image pass may miss.
The library is framework agnostic. The README lists support for Ultralytics models (YOLO variants, YOLOE, YOLO11-OBB), MMDetection, HuggingFace transformers models such as RT-DETR, TorchVision, Detectron2, YOLOv5, YOLOX, GroundingDINO and Roboflow/RF-DETR. Installation is via pip, with optional framework-specific extras.
A command-line interface covers the main workflows: predict for sliced or standard image and video inference; predict-fiftyone to inspect results in the FiftyOne app; coco slice to slice COCO images and annotations; coco fiftyone to browse predictions ordered by misdetections; coco evaluate for class-wise COCO AP/AR; coco analyse for error-analysis plots; and coco yolo to convert COCO datasets to Ultralytics format. Python APIs are documented for prediction, slicing and COCO utilities.
Beyond inference, SAHI provides dataset tooling: slicing, subsampling, filtering, merging and splitting of COCO datasets, plus conversion to YOLO format. Error-analysis plots and evaluation reports help diagnose detection failures, and FiftyOne integration supports interactive visualization and inspection of predictions.
The project is published on PyPI and conda-forge, has an ICIP 2022 paper, and its documentation is indexed for AI coding assistants via Context7 MCP and an llms.txt file. The README also links notebooks and demos for each supported framework, a HuggingFace Space demo, and community resources including a list of citing publications and competition winners.
Comments
0 people shared their preference · Deer Point appears after 10 participants
Sign in to join the discussion.