Export Data
Export data for use in model training.
You can export a dataset from the Roboflow platform using the web interface and the Python SDK.
Python SDK
REST API
CLI
To create a ZIP file of a dataset for export from the Python SDK, use the
project.export()
method. To download the ZIP file, use the project.download()
method.version.download(model_format="yolov5", location="./downloads")
/:workspace/:project/:version/:format
is the route you should use to get the download link for an exported dataset in a specific format. You can use this in the Jupyter notebooks from our model library or your own custom training scripts.The following endpoint returns an
export
value that contains a link
key with a URL from which you can download a dataset:curl "https://api.roboflow.com/roboflow/chess-sample-4ckfl/1/yolov5pytorch?api_key=$ROBOFLOW_API_KEY"
Here is an example payload returned by the endpoint:
{
"workspace": {
"name": "Roboflow",
"url": "roboflow",
"members": 7
},
"project": {
"id": "roboflow/chess-sample-4ckfl",
"type": "object-detection",
"name": "Chess Sample",
"created": 1630335544.592,
"updated": 1630335741.988,
"images": 12,
"unannotated": 3,
"annotation": "pieces",
"public": false,
"splits": {
"test": 1,
"train": 9,
"valid": 2
},
"classes": {
"white-bishop": 11,
"black-king": 8,
"black-knight": 11,
"white-queen": 7,
"black-bishop": 8,
"white-rook": 10,
"black-rook": 10,
"white-king": 8,
"black-queen": 4,
"black-pawn": 37,
"white-pawn": 34,
"white-knight": 10
}
},
"version": {
"id": "roboflow/chess-sample-4ckfl/1",
"name": "augmented",
"created": 1630335698.746,
"images": 30,
"splits": {
"train": 27,
"test": 1,
"valid": 2
},
"model": {
"id": "chess-sample-4ckfl/1",
"endpoint": "https://detect.staging.roboflow.com/chess-sample-4ckfl/1",
"start": 1630335799.682,
"end": 1630337523.889,
"fromScratch": false,
"tfjs": true,
"oak": true,
"map": "62.87",
"recall": "85.29",
"precision": "23.44"
},
"preprocessing": {
"grayscale": {
"enabled": true
},
"resize": {
"width": 416,
"height": 416,
"enabled": true,
"format": "Stretch to"
},
"auto-orient": {
"enabled": true
}
},
"augmentation": {
"rotate": {
"enabled": true,
"degrees": "5"
},
"exposure": {
"enabled": true,
"percent": "25"
},
"noise": {
"enabled": true,
"percent": "2"
},
"image": {
"versions": "3",
"enabled": true
},
"flip": {
"horizontal": true,
"enabled": true,
"vertical": false
},
"brightness": {
"enabled": true,
"brighten": true,
"percent": "25",
"darken": true
},
"crop": {
"percent": 30,
"enabled": true,
"min": 0
}
},
"exports": [
"yolov5pytorch"
]
},
"export": {
"format": "yolov5pytorch",
"link": "https://app.staging.roboflow.com/ds/o06EL6FAt7?key=KYtxHKCvaN"
}
}
You can export data through the Roboflow CLI using the following command:
roboflow download <datasetUrl>
Here are the settings options available for dataset export:
Object Detection | Single-Label Classification | Multi-Label Classification | Instance Segmentation | Semantic Segmentation |
---|---|---|---|---|
clip | folder | multiclass | coco-segmentation | coco-segmentation |
coco | clip | folder | clip | png-mask-semantic |
createml | | clip | coco | |
darknet | | | createml | |
multiclass | |