Datasets:
Commit
•
e095840
1
Parent(s):
296b500
Update how to use headers (#6)
Browse files- Update how to use headers (0707527e0c6d4d551818cfd79015100e2e8b2e14)
Co-authored-by: Mishig Davaadorj <mishig@users.noreply.huggingface.co>
README.md
CHANGED
@@ -375,7 +375,7 @@ The results for models trained on the Common Voice datasets are available via th
|
|
375 |
Abkhaz, Arabic, Armenian, Assamese, Asturian, Azerbaijani, Basaa, Bashkir, Basque, Belarusian, Bengali, Breton, Bulgarian, Cantonese, Catalan, Central Kurdish, Chinese (China), Chinese (Hong Kong), Chinese (Taiwan), Chuvash, Czech, Danish, Dhivehi, Dutch, English, Erzya, Esperanto, Estonian, Finnish, French, Frisian, Galician, Georgian, German, Greek, Guarani, Hakha Chin, Hausa, Hill Mari, Hindi, Hungarian, Igbo, Indonesian, Interlingua, Irish, Italian, Japanese, Kabyle, Kazakh, Kinyarwanda, Kurmanji Kurdish, Kyrgyz, Latvian, Lithuanian, Luganda, Macedonian, Malayalam, Maltese, Marathi, Meadow Mari, Moksha, Mongolian, Nepali, Norwegian Nynorsk, Odia, Persian, Polish, Portuguese, Punjabi, Romanian, Romansh Sursilvan, Romansh Vallader, Russian, Sakha, Santali (Ol Chiki), Saraiki, Sardinian, Serbian, Slovak, Slovenian, Sorbian, Upper, Spanish, Swahili, Swedish, Taiwanese (Minnan), Tamil, Tatar, Thai, Tigre, Tigrinya, Toki Pona, Turkish, Twi, Ukrainian, Urdu, Uyghur, Uzbek, Vietnamese, Votic, Welsh
|
376 |
```
|
377 |
|
378 |
-
|
379 |
|
380 |
The `datasets` library allows you to load and pre-process your dataset in pure Python, at scale. The dataset can be downloaded and prepared in one call to your local drive by using the `load_dataset` function.
|
381 |
|
@@ -397,7 +397,7 @@ print(next(iter(cv_11)))
|
|
397 |
|
398 |
*Bonus*: create a [PyTorch dataloader](https://huggingface.co/docs/datasets/use_with_pytorch) directly with your own datasets (local/streamed).
|
399 |
|
400 |
-
Local
|
401 |
|
402 |
```python
|
403 |
from datasets import load_dataset
|
@@ -408,7 +408,7 @@ batch_sampler = BatchSampler(RandomSampler(cv_11), batch_size=32, drop_last=Fals
|
|
408 |
dataloader = DataLoader(cv_11, batch_sampler=batch_sampler)
|
409 |
```
|
410 |
|
411 |
-
Streaming
|
412 |
|
413 |
```python
|
414 |
from datasets import load_dataset
|
|
|
375 |
Abkhaz, Arabic, Armenian, Assamese, Asturian, Azerbaijani, Basaa, Bashkir, Basque, Belarusian, Bengali, Breton, Bulgarian, Cantonese, Catalan, Central Kurdish, Chinese (China), Chinese (Hong Kong), Chinese (Taiwan), Chuvash, Czech, Danish, Dhivehi, Dutch, English, Erzya, Esperanto, Estonian, Finnish, French, Frisian, Galician, Georgian, German, Greek, Guarani, Hakha Chin, Hausa, Hill Mari, Hindi, Hungarian, Igbo, Indonesian, Interlingua, Irish, Italian, Japanese, Kabyle, Kazakh, Kinyarwanda, Kurmanji Kurdish, Kyrgyz, Latvian, Lithuanian, Luganda, Macedonian, Malayalam, Maltese, Marathi, Meadow Mari, Moksha, Mongolian, Nepali, Norwegian Nynorsk, Odia, Persian, Polish, Portuguese, Punjabi, Romanian, Romansh Sursilvan, Romansh Vallader, Russian, Sakha, Santali (Ol Chiki), Saraiki, Sardinian, Serbian, Slovak, Slovenian, Sorbian, Upper, Spanish, Swahili, Swedish, Taiwanese (Minnan), Tamil, Tatar, Thai, Tigre, Tigrinya, Toki Pona, Turkish, Twi, Ukrainian, Urdu, Uyghur, Uzbek, Vietnamese, Votic, Welsh
|
376 |
```
|
377 |
|
378 |
+
## How to use
|
379 |
|
380 |
The `datasets` library allows you to load and pre-process your dataset in pure Python, at scale. The dataset can be downloaded and prepared in one call to your local drive by using the `load_dataset` function.
|
381 |
|
|
|
397 |
|
398 |
*Bonus*: create a [PyTorch dataloader](https://huggingface.co/docs/datasets/use_with_pytorch) directly with your own datasets (local/streamed).
|
399 |
|
400 |
+
### Local
|
401 |
|
402 |
```python
|
403 |
from datasets import load_dataset
|
|
|
408 |
dataloader = DataLoader(cv_11, batch_sampler=batch_sampler)
|
409 |
```
|
410 |
|
411 |
+
### Streaming
|
412 |
|
413 |
```python
|
414 |
from datasets import load_dataset
|