Every time I reupload predictions to the same data row, the new ones get added on top of the old ones without replacing them. I tried asking support chat bot but it only mentioned deleting runs of a model. What model if I uploaded my own predictions without specifying any model?
Anyone knows how to quickly clear all previous predictions for a specific data row? Using web UI for this is a tedious process.
project = client.get_project("<PROJECT_ID>")
importList = []
for imports in project.bulk_import_requests():
importList.append(imports)
#importList[0]
#importList[0].delete() #This will delete all pre-annotations uploaded via MAL
For Labelbox devs to see:
Naming of a “bulk_import_requests” method looks very counter intuitive: it looks like Im about to upload something instead of fetching old imports. Hence I could not find it as it was in my blind spot.
Word breakdown:
bulk - is often used by SDKs for uploading many objects at once, not downloading
import - is for uploading, not for fetching info
bulk_import_requests - looks like I’m about to call many upload operations at once.
I would suggest renaming this method to something like: list_mal_imports since these imports are created by MALPredictionImport class. It would even be much better if this class didn’t stand alone but migrated all its methods into client.get_project(“…”).import_predictions. Would be much more intuitive and SDK user would not have to do investigation connecting the dots from all over the SDK documentation just to import/delete predictions