Label set
A label set is a collection of labels. Create a new label set if you want to upload model predictions and use features such as model-assisted labeling.
Create a new label set with client.add_labelset(). You need to specify the name and (optionally) the description of the new label set.
For best performance, create a new dataset and choose a suitable data category.
or Use client.upload_asset() to upload a local file to Segments.ai's asset storage service.
Add a sample with client.add_sample(). For each sample, specify a name and the required sample attributes. If you do not have URLs for your assets, upload the assets to Segments.ai first.
dataset = "segments-demo/bdd100k"
name = "sequence_1"
image_urls = [
"https://segmentsai-prod.s3.eu-west-2.amazonaws.com/assets/jane/a13358ef-a1ae-443c-8ea1-5f61dd9cdc26.jpg",
"https://segmentsai-prod.s3.eu-west-2.amazonaws.com/assets/jane/4f47973f-5568-47f1-8a7d-44bfeb6f0f76.jpg",
]
frames = [
{
"name": "frame_00001.jpg",
"image": {
"url": image_urls[0],
},
},
{
"name": "frame_00002.jpg",
"image": {
"url": image_urls[1],
},
},
]
attributes = {"frames": frames}
sample = client.add_sample(dataset, name, attributes)Are you sure you want to delete this label set? All labels in the label set will be deleted as well.
Are you sure you want to delete 0 samples? The corresponding labels will be deleted as well.