Import Predictions
Overview
To upload predictions in Encord Active, you need to create a prediction branch. This guide explains everything you need to know for importing predictions.
Predictions Workflow
- Import Predictions to Annotate Project: Everything starts in Annotate. Your labels and predictions must exist in your Annotate Project for the labels and predictions to appear in Active.
- Import/Sync Project in Active: After importing your predictions, you can then import the Project into Active. Or you can sync an existing Active Project after importing your predictions.
- Analyse the Predictions in Active: Once the Project import/sync completes, specify the prediction set for Active to analyse.
- Select the Predictions in Active: Once analysis completes, select the prediction set you want to view in Active.
Supported Prediction Formats
- Supports multi-level nested classifications (radio, checklist, or free-form text) under objects or classifications.
- Handles all object types and classification.
-
Only top-level objects and classifications are considered when calculating in model metrics.
-
Metrics are not yet available for keypoints and polylines. If you are interested in these, please contact the Encord team.
Does not supports multiple levels of nested classifications (radio, checklist, or free-form text) under tools or classifications.
Confidence Score
You can include confidence scores when uploading predictions. Encord automatically calculates model metrics based on your prediction set and assigned confidence scores.
Prediction Branches
When importing prediction sets into Encord Active, they are added as branches to individual label rows on your data units (images, videos, audio). Each data unit has the following:
- A MAIN branch for ground truth annotations or pre-labels.
- Optional Consensus branches and Prediction branches for different prediction sets.
STEP 1: Import Predictions
Import your predictions to a Project in Annotate. Encord currently supports importing predictions from the Encord format and from COCO.
TLDR;
Import Encord-Format Predictions
Use branch_name
to create a prediction branch in label_rows_v2
for a data unit.
branch_name
supports alphanumeric characters (a-z, A-Z, 0-9) and is case sensitivebranch_name
supports the following special characters: hyphens (-), underscores (_), and periods (.)
This simple example imports a bounding box model prediction to all data units in the prediction branch.
Import COCO Labels as Predictions
The following code imports COCO labels as predictions for Active.
For more information on importing COCO labels into Encord, refer to our documentation.
Replace the following:
-
<private_key_path>
with the file path to your SSH private key. -
<my-prediction-branch-name>
with the name of your prediction branch. -
<project_hash>
with the Project ID for your Project. -
COCOimportfile.json
with the full path of the COCO file containing the predictions you want to import.
Verify Prediction Import
After importing your predictions, verify that your predictions imported.
The following code returns all labels and predictions on all branches.
End-to-End Prediction Import Example
We provide an end-to-end example using a Jupyter Notebook here.
STEP 2: Import/Sync Project to Active
Import or sync the Annotate Project in Active.
STEP 3: Analyse the Predictions
Active MUST analyse the predictions before you can view the predictions in Active.
STEP 4: Select the Predictions
Once analysis completes, select the prediction set to view in Active.
Next Steps
Model and Prediction Validation
Was this page helpful?