Skip to main content
POST
Add Images
Click for Python SDK
A Dataset can be populated with labeled and unlabeled data. Using Nucleus, you can filter down the data inside your dataset using custom metadata about your images. For instance, your local dataset may contain Sunny, Foggy, and Rainy folders of images. All of these images can be uploaded into a single Nucleus Dataset, with added metadata like {"weather": "Sunny"}. To update an item’s metadata, you can re-ingest the same items with the update argument set to true. Existing metadata will be overwritten for DatasetItems in the payload that share a reference_id with a previously uploaded DatasetItem. To retrieve your existing reference_ids, see Get Dataset Items. The asynchronous endpoint returns an AsyncJob object that can sleep until complete, return current status, or return errors. There are two stages: first the metadata for the images is pulled into a reupload queue. Then the images are processed in batches of 3000. During this phase, the status will be updated every 3000 images.

Authorizations

Authorization
string
header
required

Basic authentication header of the form Basic <encoded-value>, where <encoded-value> is the base64-encoded string username:password.

Path Parameters

dataset_id
string
required

The Scale-generated ID of the Dataset.

Body

application/json
items
object[]
required

The list of image DatasetItems to upload.

update
boolean
default:false

Whether to overwrite existing DatasetItems with conflicting reference_ids. The default behavior (False) is to ignore conflicting uploads. This is the main way we recommend to update or add to metadata: simply rerun your ingestion with update=True.

Response

200

dataset_id
string
Example:

"ds_c6ka7tfaypgg05rf2ts0"

new_items
integer
default:0
Example:

1

updated_items
integer
default:0
Example:

0

ignored_items
integer
default:0
Example:

0

rows
object[]