Import local annotations
Import annotation JSON with local media or onto existing Unitlab project files. Prepare COCO and Unitlab exports, match file paths, and resolve import errors.
Bring existing labels into a Unitlab project through Upload data > Local. You can select media and annotation JSON together, upload a folder containing both, or add annotation JSON to media already in the project.
For a scripted workflow, use Python SDK annotation imports. Media files and folders can be uploaded separately through the CLI, then labeled through this browser flow or the Python SDK. The CLI media-upload command does not import annotation JSON.
Unitlab uploads new media first, matches the references in the annotation file, and imports supported labels. If the media are still processing, the labels can be scheduled to import when the media become ready.
Before you start
Open the project that should receive the annotations. Local annotation import requires Manage data and Create labels permissions.
Use a supported annotation format from the table below. Save valid UTF-8 JSON and keep each file below your deployment's upload request limit.
Keep media references unique and consistent with the files you select or the existing project items. A filename appearing in two folders needs an unambiguous path or Unitlab file ID.
Annotation import runs in a project, not directly in the Asset library. For general media preparation and file support, see Data upload.
Use an ordinary item in an Annotate or Review stage. Grouped tasks and items currently in Model, Consensus, or Archive cannot receive this import. Creating missing classes also requires Manage classes permission and a project-local ontology; imports cannot add classes to a shared ontology.
Prepare media and labels together
The walkthrough below imports one Car box onto a 1280 × 720 image named road.jpg. Arrange your media and the COCO JSON as follows:
road-scenes/
├── images/
│ └── road.jpg
└── annotations.jsonSave the COCO example below as annotations.json. Its images[0].file_name is images/road.jpg, exactly matching the path beneath road-scenes/. Select the whole road-scenes folder with Upload folder. Unitlab can account for the extra root-folder name added by the browser while preserving the referenced subfolder.
Expected result: one project image with one editable Car bounding box. Use your own media and update the filename, dimensions and coordinates together when adapting the example.
If the media are already in the project, select annotations.json alone. Ensure its references identify those existing items. Renaming files or dropping meaningful subfolder names can prevent matching or create ambiguity.
Select Upload
Unitlab transfers new media, validates the annotation format, matches media and classes, and imports valid labels. The action reads Importing labels… while label import is running.
Complete any video frame or CSV configuration requested for the media. Files that still need processing can have their label import scheduled automatically.
Supported annotation formats
COCO
An object containing images, categories, and annotations arrays
Supported image annotations, or frame annotations with an explicit video frame map.
Unitlab image JSON
schema_version is unitlab-image/1
Native image objects and whole-image select classifications.
Unitlab video JSON
schema_version is unitlab-video/1
Native Unitlab video annotations and supported track information.
UUEF item JSON
version is 1.0, with a media object and a labels array
Supported labels from an individual Unitlab Unified Export Format item.
Audio JSON
Contains audio_files and categories arrays
Supported labels from a Unitlab audio export.
GeoJSON
A FeatureCollection with a features array
Supported annotations from a Unitlab GeoJSON export.
Use exports that retain the media identifiers, class definitions, and annotation fields required by their format. Recognition of a format does not mean every shape or custom extension is supported. Validation reports incompatible classes, unsupported annotations, and missing media.
UUEF import covers image, video, medical, audio, time series, PDF document, text, HTML, geospatial, and pathology labels. Tabular and LiDAR/point-cloud annotation import are not supported by this importer. UUEF group metadata does not recreate Data Groups. Top-level data tags, translations, and transcription are not restored by this label-import flow.
YOLO TXT, JSONL, arbitrary model-response JSON, and generic GeoJSON without Unitlab class/media metadata are not accepted label inputs.
Two companion formats have separate roles:
Frame mapping uses
schema_version: "unitlab-frame-map/1". Upload it with exactly one COCO annotation JSON when frame images need to map to an existing video.Package metadata uses
schema_version: "unitlab-import-manifest/1". This is not a standalone annotation file or a generic data-upload manifest. Include the actual annotation JSON and media from the package.
A ZIP of annotations and images is not the Local annotation-import input. Extract the package and select its folder or supported files.
Import predictions from your own model
You can use supported model predictions as initial labels, then correct and review them in Unitlab:
Bounding boxes
COCO JSON or native unitlab-image/1, using [x, y, width, height] in original image pixels.
Polygons
COCO polygon segmentation or native unitlab-image/1 polygon coordinates.
Segmentation masks
COCO RLE in segmentation, or a native unitlab-image/1 mask annotation. Compressed counts strings and uncompressed integer runs are supported.
A category for the whole image
Native unitlab-image/1 with an image-scope single_select or multi_select class and classifications.
COCO categories define object classes in this importer; they do not import image-wide classifications. Native image classifications appear under Item properties in the editor and can share a file with box or polygon annotations. See the complete image-level classification example.
For COCO masks, use RLE with size: [height, width] matching the original image and counts covering the complete image in COCO column-major order. Polygon segmentation stays as polygons, while RLE segmentation becomes mask labels. A standalone mask PNG is not a label-import JSON file. See the supported model-output structures.
YOLO TXT labels are not supported directly. Convert YOLO detections or polygons to COCO or native image JSON, including the matching media references, class definitions and original pixel coordinates. See model-output conversion guidance. Changing the filename extension does not convert a label file.
Download example annotation files
These are small label-only examples. Supply matching media or adapt the references, dimensions, classes, and geometry to your own files before importing.
COCO video frames with track IDs
The same drive.mp4; labeled source frames 0 and 5
The COCO video pair uses attributes.track_id. Select both files together in the frontend. For programmatic import, use the corresponding track profile shown in the SDK annotation guide.
Model-output examples
These label-only examples use road.jpg at 1280 × 720, or mask-demo.png at 4 × 3 for the small mask fixtures. Replace the references and coordinates with your own media before importing. The two mask files describe the same foreground pixels using different COCO encodings.
COCO boxes and polygons
COCO mask, uncompressed RLE
COCO mask, compressed RLE
Whole-image classification
Native boxes, polygons, and image classification
Example: COCO image bounding boxes
For the folder above, this compact COCO file describes one Car bounding box in images/road.jpg:
Replace the filename, dimensions, class, and coordinates with your own data. COCO bounding boxes use [x, y, width, height] in image pixels, with x and y at the top-left corner. Each annotation's image_id and category_id must reference entries in the same file. For another image, add an images entry with a unique ID and annotations that reference that ID.
Use coordinates from the original media, not a resized preview or normalized 0-to-1 coordinates. Annotation IDs must be unique within each media item. Image dimensions and other supplied media identity information must agree with the project file.
Import COCO annotations onto video frames
For this separate example, prepare drive.mp4 plus the downloadable COCO video labels and frame map from the table above:
A COCO file containing frame images does not, by itself, identify the video or establish the frame indices. Use the unitlab-frame-map/1 companion to map COCO image entries explicitly to the correct project video and frames.
For example, if a COCO annotation file contains image entries with IDs 100 and 105, this companion maps them to original video frames 0 and 5:
Frame-map indices start at 0. Map every COCO image entry exactly once. The matching video must exist in the project, and its uploaded frame sampling must retain the referenced frames. For annotations on every original frame, select Use native frame rate when uploading the video, subject to the 60 fps limit.
Upload one COCO annotation JSON and its one frame mapping JSON at a time. Do not select several COCO files with a shared map or several possible maps in the same import. A frame mapping file without its COCO annotation file cannot import labels.
COCO attributes.track_id can supply track identities when supported by the mapped import. Independent frame annotations without a track identity should not be treated as continuous object tracks.
Native unitlab-video/1 tracks also use explicit frame annotations. Their supported contract uses presence_mode: "explicit_frames" and interpolation: "none"; importing two labeled frames does not generate labels for the intervening frames.
How matching and repeated imports work
Unitlab matches incoming annotation references to the media in the current upload or to existing project data. For new media, the uploader uses the exact returned file IDs and relative paths so that another project file with the same basename does not silently receive the labels.
Use the full referenced subfolder path when needed. A media URL stored in JSON is a matching reference; the importer does not fetch that URL to upload a new file.
Classes are created or reused when compatible. A class mismatch blocks the affected import and explains the conflict. Correct the source format or class definition before retrying.
The browser flow preserves human edits and deletions. It does not automatically recreate a label you deleted or overwrite an edited label when incoming annotations conflict with it. It does not expose a bulk overwrite switch. Successfully imported files are marked complete so a retry does not apply them again within the same upload session. Removing a queued annotation file does not delete labels already saved to the project.
Correct and review imported labels
Imported labels are editable starting annotations. Importing does not mark a task complete or approve its labels, even if the source JSON contains an approved flag.
Approve the work or return it for correction
The assigned reviewer inspects the annotations and makes permitted corrections. The forward action approves the review and follows the configured route; its label may be Mark as Complete or Send to [stage name]. Select Reject to follow the configured rework route. Review assignment and self-review rules still apply.
The browser import keeps conflicting human edits and deletions instead of overwriting them. For a deliberate change to protected work, use SDK annotation imports to inspect conflicts and select an eligible Review destination. Grouped tasks and Model, Consensus and Archive remain unsupported import targets.
See Review, rework and escalation for the full workflow.
Understand the result
The completion message reports Labels: N added · N updated · N kept · N skipped. If imported boxes were clipped to the image boundaries, it also reports Boxes clipped to image bounds.
For media that are still processing, you may see Labels from [file] will be added when its media finish processing. The page reports the scheduled import's success or failure when it settles. Return to the affected items and verify their annotations before using the data downstream.
For large annotation files, the application's parser ceiling and the deployment's request limit are different. The parser accepts up to 80 MiB, but a local transfer can be rejected below that size by the deployment. Split a rejected file into smaller valid annotation files, preserving media references and object identities, or import it from connected cloud storage. Prefer splitting by media item and keep each tracked object in one file. If one item's labels are too large for a local request, use connected cloud storage.
This file is not valid JSON
Correct the JSON syntax, then remove and reselect the corrected file.
Unsupported annotation JSON
Export a supported annotation format. A generic array of URLs, file paths, or task definitions is not accepted.
No matching media found
Include the referenced media in the upload or correct its path/identifier to match the project item.
Several project files match
Use a unique file path or Unitlab file ID.
More than one uploaded file matches
Make the reference unique while retaining its subfolder information.
A class or annotation is incompatible
Read the validation error and correct the source class or unsupported shape.
Add the COCO annotation JSON that belongs to this frame mapping
Select the map and its single COCO companion together.
A file is rejected for size
Keep it below the deployment's request limit and parser ceiling. Split it into smaller valid files with complete references and class definitions, or use connected cloud storage.
Transfer or import stops
Check the error and pending queue. Correct the problem, then select Upload to retry.
Continue with the data
Use Data upload for supported source media and processing steps.
Use Data Groups and layouts for the separate workflow that groups source files in the Asset library.
See Export formats and source inclusion when preparing annotations for reuse or downstream training.
For scripted validation, explicit mappings, and controlled commits, use SDK annotation imports.
Continue with Unitlab: data annotation platform
Complete the workflow
See Pre-labels, review, and export for the full S3, import, human review, and delivery workflow.