@@ -8,20 +8,21 @@ $ roboflow --help
88```
99
1010```
11- usage: roboflow [-h] {login,download,upload,import,infer,project,workspace} ...
11+ usage: roboflow [-h] {login,download,upload,import,infer,search-export, project,workspace} ...
1212
1313Welcome to the roboflow CLI: computer vision at your fingertips 🪄
1414
1515options:
1616 -h, --help show this help message and exit
1717
1818subcommands:
19- {login,download,upload,import,infer,project,workspace}
19+ {login,download,upload,import,infer,search-export, project,workspace}
2020 login Log in to Roboflow
2121 download Download a dataset version from your workspace or Roboflow Universe.
2222 upload Upload a single image to a dataset
2323 import Import a dataset from a local folder
2424 infer perform inference on an image
25+ search-export Export search results as a dataset
2526 project project related commands. type 'roboflow project' to see detailed command help
2627 workspace workspace related commands. type 'roboflow workspace' to see detailed command help
2728```
@@ -245,3 +246,45 @@ roboflow infer -w roboflow-58fyf -m rock-paper-scissors-sxsw/11 ~/scissors.png
245246 "prediction_type": "ObjectDetectionModel"
246247}
247248```
249+
250+ ## Example: search and export a dataset
251+
252+ Use Roboflow's search to query images across your workspace and export matching results as a dataset. This is useful when you want to create a dataset from specific search criteria (e.g. images with a certain class, tag, or other metadata).
253+
254+ ``` bash
255+ $ roboflow search-export --help
256+ ```
257+ ```
258+ usage: roboflow search-export [-h] [-f FORMAT] [-w WORKSPACE] [-l LOCATION] [-d DATASET] [-g ANNOTATION_GROUP] [-n NAME] [--no-extract] query
259+
260+ positional arguments:
261+ query Search query (e.g. 'tag:annotate' or '*')
262+
263+ options:
264+ -h, --help show this help message and exit
265+ -f FORMAT Annotation format (default: coco)
266+ -w WORKSPACE Workspace url or id (uses default workspace if not specified)
267+ -l LOCATION Local directory to save the export
268+ -d DATASET Limit export to a specific dataset (project slug)
269+ -g ANNOTATION_GROUP Limit export to a specific annotation group
270+ -n NAME Optional name for the export
271+ --no-extract Skip extraction, keep the zip file
272+ ```
273+
274+ Export all images tagged "annotate" in COCO format:
275+
276+ ``` bash
277+ $ roboflow search-export " tag:annotate"
278+ ```
279+
280+ Export images containing a specific class, limited to one dataset, in COCO format:
281+
282+ ``` bash
283+ $ roboflow search-export " class:person" -f coco -d my-dataset -l ~ /exports/people
284+ ```
285+
286+ ```
287+ Export started (id=abc123). Polling for completion...
288+ Downloading search export to /Users/tony/exports/people: 100%|██████████| 5420/5420 [00:02<00:00, 2710.00it/s]
289+ Search export extracted to /Users/tony/exports/people
290+ ```
0 commit comments