Skip to content
This repository was archived by the owner on Jul 29, 2024. It is now read-only.
This repository was archived by the owner on Jul 29, 2024. It is now read-only.

KeyError: 'mask' - client.export_to_table #16

Open
@AschHarwood

Description

@AschHarwood

I'm trying to export a dataset to a dataframe. I'm using the boilerplate code from the example notebook labelpandas-export.ipynb.

The code I"m running is:

df = client.export_to_table( project=project_id, include_performance=True, include_agreement=True, include_metadata=True, mask_method="png", verbose=True )

Here's the error:

Exporting labels from Labelbox for project with ID clr7vo5oc0be6072qacc5cwp0
Export complete: 5 labels exported
Flattening labels...

KeyError Traceback (most recent call last)
in <cell line: 1>()
----> 1 df = client.export_to_table(
2 project=project_id,
3 include_performance=True,
4 include_agreement=True,
5 include_metadata=True,

2 frames
/usr/local/lib/python3.10/dist-packages/labelbase/annotate.py in flatten_label(client, label_dict, ontology_index, datarow_id, mask_method, divider)
390 annotation_value = [array, [255,255,255]]
391 else:
--> 392 png = mask_to_bytes(client=client, input=obj['mask']["url"], datarow_id=datarow_id, method="url", color=[255,255,255], output="png")
393 annotation_value = [png, "null"]
394 if "classifications" in obj.keys():

KeyError: 'mask'

Thanks!

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions