Datasets:
Update README.md
Browse files
README.md
CHANGED
|
@@ -72,15 +72,28 @@ pip install -U fiftyone
|
|
| 72 |
## Usage
|
| 73 |
|
| 74 |
```python
|
|
|
|
| 75 |
import fiftyone as fo
|
| 76 |
-
from
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 77 |
|
| 78 |
-
# Load
|
| 79 |
-
|
| 80 |
-
|
|
|
|
|
|
|
|
|
|
| 81 |
|
| 82 |
-
# Launch the App
|
| 83 |
-
session = fo.launch_app(dataset)
|
| 84 |
```
|
| 85 |
|
| 86 |
|
|
|
|
| 72 |
## Usage
|
| 73 |
|
| 74 |
```python
|
| 75 |
+
|
| 76 |
import fiftyone as fo
|
| 77 |
+
from huggingface_hub import snapshot_download
|
| 78 |
+
|
| 79 |
+
|
| 80 |
+
# Download the dataset snapshot to the current working directory
|
| 81 |
+
|
| 82 |
+
snapshot_download(
|
| 83 |
+
repo_id="Voxel51/toon3d",
|
| 84 |
+
local_dir=".",
|
| 85 |
+
repo_type="dataset"
|
| 86 |
+
)
|
| 87 |
+
|
| 88 |
+
|
| 89 |
|
| 90 |
+
# Load dataset from current directory using FiftyOne's native format
|
| 91 |
+
dataset = fo.Dataset.from_dir(
|
| 92 |
+
dataset_dir=".", # Current directory contains the dataset files
|
| 93 |
+
dataset_type=fo.types.FiftyOneDataset, # Specify FiftyOne dataset format
|
| 94 |
+
name="toon3d" # Assign a name to the dataset for identification
|
| 95 |
+
)
|
| 96 |
|
|
|
|
|
|
|
| 97 |
```
|
| 98 |
|
| 99 |
|