Skip to main content
This guide will walk you through the process of importing your existing ground truth annotations from other internal or third-party tools into Labelbox.

What is ground truth?

In machine learning, “ground truth” refers to the data that we consider to be the “true” or accurate labels for a given dataset. This data is often created by human annotators and is used to train and evaluate machine learning models. By importing your ground truth annotations into Labelbox, you can consolidate all of your labeled data in one place, creating a single source of truth for your machine learning projects. This is particularly useful when you are migrating from another labeling platform to Labelbox.

How to import your ground truth annotations?

You can generate Python SDK code snippets directly from your project’s “Import labels” tab to help you with the import process. These snippets will serve as a great starting point for the steps below.
  1. Import your data rows: Before you can import your annotations, you need to have the corresponding data rows (the raw data you want to label, such as images, videos, or text) in Labelbox. If you haven’t already, you’ll need to create a dataset and import your data rows into the Catalog.
  2. Create or select an ontology: An ontology (also known as a taxonomy) defines the set of classes and attributes that can be used to label your data. For example, an ontology for an image classification project might include classes like “cat,” “dog,” and “car.” You’ll need to either create a new ontology or select an existing one that matches the annotations you want to import.
  3. Create a labeing project: Your annotations need to be associated with a labeling project in Labelbox. If you don’t already have a project set up with the correct ontology, you will need to create a project.
  4. Send a batch of data rows to your project: Now that your project and ontology are configured, you need to send a batch of data rows to the project’s labeling queue. This will be the specific set of data rows that you will be attaching your imported annotations to.
  5. Create the annotations payload: This is where you’ll prepare the annotations themselves for import. Each annotation in your payload needs to reference a specific annotation class from your ontology and a specific data row ID. Labelbox supports two formats for the annotation payload: Python Annotation Types and NDJSON. Go to the Import labels tab and select Import ground truth. There you will find a sample code snippet you can use to import your ground truth annotations.
  6. Import your annotation payload: Once you have created your annotation payload, the final step is to submit the import job. After the job is complete, your ground truth annotations will appear in your project, and the corresponding data rows will be marked as “Done.” Under Import labelsImport ground truth, copy the code snippet for Import annotations payload.
Check out these end-to-end developer guides to learn how to import ground truth annotations based on your data type.

Import image annotations

Import video annotations

Import text annotations

Import geospatial annotations

Import document annotations

Import conversational text annotations

Import audio annotations

Import HTML annotations

Best practices

  • Before starting a new import job, ensure that there are no existing model-assisted labeling (MAL) annotations on the data rows. Duplicate import jobs can overwrite existing labels or cause unexpected behavior.
  • The activity page in Labelbox will not show any changes until the entire import job is complete.