Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

DOCS-2631: Add dataset export option CLI #3253

Merged
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
9 changes: 6 additions & 3 deletions docs/cli.md
Original file line number Diff line number Diff line change
@@ -296,6 +296,7 @@ viam data export --destination=<output path> --data-type=<output data type> [...
viam data delete [...named args]
viam data dataset add --dataset-id=<dataset-id> --file-ids=<file-id-or-ids> --location-id=<location-id> --org-id=<org-id> [...named args]
viam data dataset remove --dataset-id=<dataset-id> --file-ids=<file-id-or-ids> --location-id=<location-id> --org-id=<org-id> [...named args]
viam data dataset export --destination=<output-directory> --dataset-id=<dataset-id>
viam data database configure --org-id=<org-id> --password=<db-user-password>
viam data database hostname --org-id=<org-id>
```
@@ -340,6 +341,7 @@ done
| `database hostname` | Get the MongoDB Atlas Data Federation instance hostname and connection URI. See [Configure data query](/use-cases/sensor-data-query-with-third-party-tools/#configure-data-query) | - |
| `dataset add` | Add a new image to an existing dataset by its file id, or add a group of images by specifying a filter | `filter` |
| `dataset remove` | Remove an existing image from a dataset by its file id, or remove a group of images by specifying a filter | `filter` |
| `dataset export` | Download all the data from a dataset | - |
| `delete binary` | Delete binary data | - |
| `delete tabular` | Delete tabular data | - |
| `--help` | Return help | - |
@@ -358,23 +360,24 @@ done
<!-- prettier-ignore -->
| Argument | Description | Applicable commands | Required? |
| -------- | ----------- | ------------------- | --------- |
| `--destination` | Output directory for downloaded data |`export`| **Required** |
| `--destination` | Output directory for downloaded data |`export`, `dataset export` | **Required** |
| `--data-type` | Data type to be downloaded: either binary or tabular |`export`| **Required** |
| `--component-name` | Filter by specified component name |`export`, `delete`| Optional |
| `--component-type` | Filter by specified component type |`export`, `delete`| Optional |
| `--component-model` | Filter by specified component model |`export`, `delete`| Optional |
| `--dataset-id` | Dataset to add or remove images from |`dataset`| **Required** |
| `--dataset-id` | Dataset to add or remove images from or download. To retrieve these IDs, navigate to your dataset’s page in the [Viam app](https://app.viam.com), click **…** in the left-hand menu, and click **Copy dataset ID**. | `dataset`, `dataset export` | **Required** |
Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Nice

| `--delete-older-than-days` | Number of days, 0 means all data will be deleted | `delete` | Optional |
| `--start` | ISO-8601 timestamp indicating the start of the interval |`export`, `delete`, `dataset`| Optional |
| `--end` | ISO-8601 timestamp indicating the end of the interval |`export`, `delete`, `dataset`| Optional |
| `--file-ids` | File-ids to add or remove from a dataset |`dataset`| **Required** |
| `--include-jsonl` | Set to `true` to include JSON Lines files for local testing |`dataset export`| Optional |
| `--location-id` | Location ID for the file ids being added or removed from the specified dataset (only accepts one location id) |`dataset`| **Required** |
| `--location-ids` | Filter by specified location ID (accepts comma-separated list) |`export`, `delete`| Optional |
| `--method` | Filter by specified method |`export`, `delete`| Optional |
| `--mime-types` | Filter by specified MIME type (accepts comma-separated list) |`export`, `delete`|false |
| `--org-id` | Org ID for the database user being configured (with `database`), or for the file ids being added or removed from the specified dataset (with `dataset`) | `database configure`, `database hostname`, `dataset` | **Required** |
| `--org-ids` | Filter by specified organizations ID (accepts comma-separated list) |`export`, `delete`| Optional |
| `--parallel` | Number of download requests to make in parallel, with a default value of 10 |`export`, `delete`|false |
| `--parallel` | Number of download requests to make in parallel, with a default value of 10 for `export` and `delete` and 100 for `dataset export` |`export`, `delete`, `dataset export` | Optional |
| `--part-id` | Filter by specified part ID |`export`, `delete`| Optional |
| `--part-name` | Filter by specified part name |`export`, `delete`| Optional |
| `--robot-id` | Filter by specified robot ID |`export`, `delete`| Optional |