Creating a Dataset Version
Create a new version for a dataset.
dataset.create_version(name=None, version_format=None, label_task_type=None, label_task_id=None, **kwargs)
Sample Code
from modelarts.session import Session from modelarts.dataset import Dataset session = Session() dataset = Dataset(session, dataset_id) create_version_resp = dataset.create_version(name="V001", version_format="Default", label_task_type=0, description="version 001")
Example 2: Create a dataset based on a labeling task.
from modelarts.session import Session from modelarts.dataset import Dataset session = Session() dataset = Dataset(session, dataset_id) create_version_resp = dataset.create_version(label_task_id="IbAhFai5KXWC3gthUfz", description="dataset version from label task")
Parameters
| Parameter | Mandatory | Type | Description |
|---|---|---|---|
| name | No | String | Version name that consists of 1 to 32 characters. |
| version_format | No | String | Format of a dataset version. The options are as follows:
|
| label_task_type | No | Integer | Labeling type of a dataset version. The options are as follows:
|
| label_task_id | No | String | ID of a labeling task based on which a dataset version is created. |
| description | No | String | Version description consisting of 0 to 256 characters without special characters (!<>=&"'). The parameter is left blank by default. |
Feedback
Was this page helpful?
Provide feedbackThank you very much for your feedback. We will continue working to improve the documentation.