Dataset Splits

Dataset Splits

A dataset version can have multiple splits, usually separating training, validation and test data.

Get all splits

splits = client.get_dataset_splits(my_dataset.id, new_dataset_version.id)
ParameterTypeDescription
dataset_idstrThe dataset id
dataset_version_idstrThe dataset version id

Create a split

new_split = DatasetSplit(
    name= "train",
    description= "training data for our model to learn from" 
)

new_split = client.create_dataset_split(my_dataset.id, new_dataset_version.id, new_split)
ParameterTypeDescription
dataset_idstrThe dataset id
dataset_version_idstrThe dataset version id
splitDatasetSplitThe split object

Dataset split properties in more detail:

PropertyTypeDescription
idstrUnique id for the dataset split
created_atstrThe creation date
updated_atstrLast updated date
namestrThe dataset split name
descriptionstrThe dataset split description
user_idstrThe unique id of the dataset split creator
version_idThe unique id of the dataset version the split belongs to

Get a split

my_split = client.get_dataset_split(my_dataset.id, new_dataset_version.id, new_split.id)
ParameterTypeDescription
dataset_idstrThe dataset id
dataset_version_idstrThe dataset version id
split_idstrThe split id

Update a split

my_split.description = "Training data"

client.update_dataset_split(my_dataset.id, new_dataset_version.id, my_split)
ParameterTypeDescription
dataset_idstrThe dataset id
dataset_version_idstrThe dataset version id
splitDatasetSplitThe split object

Delete a split

client.delete_dataset_split(my_dataset.id, new_dataset_version.id, my_split)
ParameterTypeDescription
dataset_idstrThe dataset id
dataset_version_idstrThe dataset version id
splitDatasetSplitThe split object