Datasets:
Update README.md
Browse files
README.md
CHANGED
@@ -88,6 +88,8 @@ tags:
|
|
88 |
pretty_name: Unsplash Lite w/ Palettes
|
89 |
size_categories:
|
90 |
- 10K<n<100K
|
|
|
|
|
91 |
---
|
92 |
|
93 |
# The Unsplash Lite Dataset (v1.2.1) with color palettes
|
@@ -109,16 +111,14 @@ from datasets import load_dataset, DownloadManager, Image
|
|
109 |
|
110 |
ds = load_dataset("1aurent/unsplash-lite-palette")
|
111 |
|
112 |
-
def download_image(url: str | list[str]
|
|
|
113 |
filename = dl_manager.download(url)
|
114 |
return {"image": filename}
|
115 |
|
116 |
ds = ds.map(
|
117 |
function=download_image,
|
118 |
input_columns=["url"],
|
119 |
-
fn_kwargs={
|
120 |
-
"dl_manager": DownloadManager(),
|
121 |
-
},
|
122 |
batched=True,
|
123 |
num_proc=6,
|
124 |
)
|
|
|
88 |
pretty_name: Unsplash Lite w/ Palettes
|
89 |
size_categories:
|
90 |
- 10K<n<100K
|
91 |
+
source_datasets:
|
92 |
+
- 1aurent/unsplash-lite
|
93 |
---
|
94 |
|
95 |
# The Unsplash Lite Dataset (v1.2.1) with color palettes
|
|
|
111 |
|
112 |
ds = load_dataset("1aurent/unsplash-lite-palette")
|
113 |
|
114 |
+
def download_image(url: str | list[str]) -> str | list[str]:
|
115 |
+
dl_manager = DownloadManager()
|
116 |
filename = dl_manager.download(url)
|
117 |
return {"image": filename}
|
118 |
|
119 |
ds = ds.map(
|
120 |
function=download_image,
|
121 |
input_columns=["url"],
|
|
|
|
|
|
|
122 |
batched=True,
|
123 |
num_proc=6,
|
124 |
)
|