For the complete documentation index, see llms.txt. This page is also available as Markdown.

LabelStudio

Overview

This converter allows to import images with .json annotations in LabelStudio format. Supported LabelStuidio format geometry types: polygonlabels (polygon), rectanglelabels (rectangle), brushlabels (RLE masks), and choices (tags)

Result of the import

Format description

Supported image formats: .jpg, .jpeg, .mpo, .bmp, .png, .webp, .tiff, .tif, .jfif, .avif, .heic, and .heif With annotations: yes Supported annotation file extension: .json. Grouped by: Any structure (will be uploaded as a single dataset)\

Input files structure

⚠️ Note: image names should correspond to the names in the annotation files (data > image field in the JSON file).

Example directory structure:

Single-Image Annotation JSON

An annotation file should contain the following fields:

  • annotations or predictions - a list of dictionaries, each containing annotation for single image

    • result - list of dictionaries, each containing information about the objects

      • original_width - the width of the original image

      • original_height - the height of the original image

      • value - a dictionary containing information about the object

        • polygonlabels/rectanglelabels/brushlabels/choices - field with the object class name

        • points - a list of points of the object (for polygonlabels and rectanglelabels shape types)

        • rle and format - a base64 encoded mask of the object (for mask shape type)

      • type - the type of the object (one of the following: polygonlabels, rectanglelabels, brushlabels, choices, relation)

  • data - a dictionary containing information about the image

    • image - the path to the image

Example of the annotation file:

📄 annotation_1.json

Last updated