ultralytics/JSON2YOLO
Legacy JSON-to-YOLO dataset converter for COCO, LabelMe, Labelbox, VoTT, INFOLKS, and ATH annotations. Superseded by convert_coco() in the Ultralytics package.
What it solves
JSON2YOLO simplifies the process of converting dataset annotations from JSON formats—specifically COCO and LabelMe—into the YOLO format. This is necessary for training object detection, segmentation, and pose estimation models using frameworks like Ultralytics YOLO, which require a specific label layout for efficient real-time inference.
How it works
The toolkit provides scripts and a Python method (convert_coco) to process annotation files. It reads JSON files containing image, category, and annotation data and transforms them into the YOLO dataset structure, which consists of a labels directory and an images directory, accompanied by a YAML configuration file for class names.
Who it’s for
It is designed for machine learning practitioners who need to prepare their datasets for training YOLO-based object detection models across Linux, macOS, and Windows platforms.
Highlights
- Multi-format support: Converts COCO detection, segmentation, and keypoint annotations, as well as LabelMe polygon, rectangle, circle, linestrip, and mask annotations.
- Cross-platform: Runs on Linux, macOS, and Windows.
- Handoff to main package: Now integrated into the main
ultralyticsPython package for updated functionality. - Flexible input: Handles COCO JSONs with standard keys and LabelMe's one-JSON-per-image approach.
Related
- Project
- Project
- Project
- Project
- Project