Recover annotations from MALPredictionImport

I have a project in labelbox. I preannotated the data using python with MALPredictionImport. The import would like this:

import labelbox as lb

#below I instantiate client, create predictions blabla


upload_job_mal = lb.MALPredictionImport.create_from_objects(
    client=client, project_id=project_id, name=name, predictions=predictions
)
upload_job_mal.wait_until_done()

Everything is uploaded correctly. During the annotation project, annotators will delete or modify these pre-annotations. Is there any way to recover these original sent pre-annotations in python or the GUI?

Hey,
We currently do not have a way to recover those annotations once they are deleted. I would recommend saving them as you are importing. You could also get the actual file associated with the annotation import that would show all the data rows like so:

upload_job = lb.MALPredictionImport.create_from_objects(
    client = client,
    project_id = project.uid,
    name="mal_job"+str(uuid4()),
    predictions=labels
)

upload_job.wait_until_done()

print(upload_job.status_file_url)

Thanks,
Gabe

1 Like