Dataset Downloader
Preview
Dataset_downloader allow you to download large dataset from multiple list of url, from image-net for example. You can split the download into 2 folders, one for the training and one for the testing. File are save into their class name, perfect for model training. It looks something like that:
root:.
|
├───test
│ ├───accerola
│ ├───apple
│ └───lemon
├───train
│ ├───accerola
│ ├───apple
│ └───lemon
Installation
Simply install from pip:
pip install dataset_downloader
Config
Create a dataset.json file with the following content:
{
"outputTrain": "...",
"outputTest": "...",
"ratio": ...,
"classes": {
"class1": [
"http://url1",
"http://url2"
],
"class2": [
"http://url1",
"http://url2"
],
"class3": "list_images.txt"
}
}
outputTrain: Output folder of the training imagesoutputTest: Output folder of the testing imagesratio: The ratio of training/testing images. 0.8 correspond of 80% of training images.classes: List of classes with their urls. Urls can be a list of url, a file containing a list of urls or an url containing a list of urls
An exemple of file on a windows computer:
"outputTrain": "D:/dataset/train",
"outputTest": "D:/dataset/test",
"ratio": 0.8,
"classes": {
"accerola": [
"http://tiachea.files.wordpress.com/2008/10/acerolas.jpg",
"http://www.jardimdeflores.com.br/floresefolhas/JPEGS/A56acerola5.JPG",
"http://farm2.staticflickr.com/1353/4602150961_177e096984_z.jpg",
],
"apple": [
"http://www.naturalhealth365.com/images/apple.jpg",
"http://urbanext.illinois.edu/fruit/images/apple1.jpg",
"https://www.aroma-zone.com/cms//sites/default/files/plante-acerola.jpg"
],
"lemon": "list_images.txt",
"watermelon": "https://gist.githubusercontent.com/johnrazeur/645787bc08a5aedd82da9573fbfa169a/raw/49cea1ee1438cecef8ac213b20f24e5ae02d4d78/watermelon.txt"
}
Run
Simple call the dataset_downloader command:
cd yourdirectory
# You must create the dataset.json file before
dataset_downloader
Metadata
Release files for dataset-downloader 1.0.0
For a detailed explanation of source distributions (sdists) and built distributions (wheels), please see the package formats documentation.
Source distribution (sdist)
| File | Size | Uploaded | |
|---|---|---|---|
| dataset_downloader-1.0.0.tar.gz | 3.9 kB | Details |
Built distribution (wheel)
| File | Interpreter | ABI | Platform | Reset |
|---|---|---|---|---|
| dataset_downloader-1.0.0-py3-none-any.whl | Python 3 | none | any | Details |
Total release size: 9.6 kB
Release files / dataset_downloader-1.0.0.tar.gz
| Download URL | dataset_downloader-1.0.0.tar.gz |
|---|---|
| Size | 3.9 kB |
| Tags | Source |
|
SHA-256 checksum How to use checksums |
f45ad3dafb0e1bfa5cd1346b6972941137d51dff166d2246edf9926341027157
|
|
BLAKE2b-256 checksum How to use checksums |
e6039379a450c9978b94231640715b4845a8c59c5afa2c27156949c4d55bf853
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
No |
| Uploaded via |
twine/1.12.1 pkginfo/1.4.2 requests/2.20.0 setuptools/40.4.3 requests-toolbelt/0.8.0 tqdm/4.28.1 CPython/3.6.7
|
Release files / dataset_downloader-1.0.0-py3-none-any.whl
| Download URL | dataset_downloader-1.0.0-py3-none-any.whl |
|---|---|
| Size | 5.7 kB |
| Tags | Python 3 |
|
SHA-256 checksum How to use checksums |
86f624443d9ac7deb0d908176549adf68ee7f1e757042e76ff7f124859f587da
|
|
BLAKE2b-256 checksum How to use checksums |
1747d923bf433df1831f928c58062215d00f3d8857f2ebbaa1dd0055aa137d94
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
No |
| Uploaded via |
twine/1.12.1 pkginfo/1.4.2 requests/2.20.0 setuptools/40.4.3 requests-toolbelt/0.8.0 tqdm/4.28.1 CPython/3.6.7
|