Multi-threaded VisDrone and VOC downloads (#7108)
* Multi-threaded VOC download * Update VOC.yaml * Update * Update general.py * Update general.py
This commit is contained in:
1 parent
ecc2c7ba73
commit
c3ae4e4af6
7 files changed
+13
-6
No files matched your search
@@ -34,6 +34,7 @@ names: ['wheat_head'] # class names
|
||||
download: |
|
||||
from utils.general import download, Path
|
||||
|
||||
|
||||
# Download
|
||||
dir = Path(yaml['path']) # dataset root dir
|
||||
urls = ['https://zenodo.org/record/4298502/files/global-wheat-codalab-official.zip',
|
||||
|
||||
@@ -65,6 +65,7 @@ download: |
|
||||
|
||||
from utils.general import Path, download, np, xyxy2xywhn
|
||||
|
||||
|
||||
# Make Directories
|
||||
dir = Path(yaml['path']) # dataset root dir
|
||||
for p in 'images', 'labels':
|
||||
|
||||
@@ -24,6 +24,7 @@ download: |
|
||||
from tqdm import tqdm
|
||||
from utils.general import np, pd, Path, download, xyxy2xywh
|
||||
|
||||
|
||||
# Download
|
||||
dir = Path(yaml['path']) # dataset root dir
|
||||
parent = Path(dir.parent) # download dir
|
||||
|
||||
+1
-1
@@ -62,7 +62,7 @@ download: |
|
||||
urls = [url + 'VOCtrainval_06-Nov-2007.zip', # 446MB, 5012 images
|
||||
url + 'VOCtest_06-Nov-2007.zip', # 438MB, 4953 images
|
||||
url + 'VOCtrainval_11-May-2012.zip'] # 1.95GB, 17126 images
|
||||
download(urls, dir=dir / 'images', delete=False)
|
||||
download(urls, dir=dir / 'images', delete=False, threads=3)
|
||||
|
||||
# Convert
|
||||
path = dir / f'images/VOCdevkit'
|
||||
|
||||
+1
-1
@@ -54,7 +54,7 @@ download: |
|
||||
'https://github.com/ultralytics/yolov5/releases/download/v1.0/VisDrone2019-DET-val.zip',
|
||||
'https://github.com/ultralytics/yolov5/releases/download/v1.0/VisDrone2019-DET-test-dev.zip',
|
||||
'https://github.com/ultralytics/yolov5/releases/download/v1.0/VisDrone2019-DET-test-challenge.zip']
|
||||
download(urls, dir=dir)
|
||||
download(urls, dir=dir, threads=4)
|
||||
|
||||
# Convert
|
||||
for d in 'VisDrone2019-DET-train', 'VisDrone2019-DET-val', 'VisDrone2019-DET-test-dev':
|
||||
|
||||
@@ -30,6 +30,7 @@ names: ['person', 'bicycle', 'car', 'motorcycle', 'airplane', 'bus', 'train', 't
|
||||
download: |
|
||||
from utils.general import download, Path
|
||||
|
||||
|
||||
# Download labels
|
||||
segments = False # segment or box labels
|
||||
dir = Path(yaml['path']) # dataset root dir
|
||||
|
||||
Reference in new issue
Block a user