|
a |
|
b/code/download.py |
|
|
1 |
""" |
|
|
2 |
a simple automatic script for download LUNA16 dataset from google drive |
|
|
3 |
|
|
|
4 |
Usage: python download.py |
|
|
5 |
""" |
|
|
6 |
|
|
|
7 |
from __future__ import print_function |
|
|
8 |
import sys |
|
|
9 |
import os |
|
|
10 |
from datetime import datetime |
|
|
11 |
|
|
|
12 |
file_id = [ |
|
|
13 |
'https://drive.google.com/open?id=0Bz-jINrxV740dVhQRHl6OWNRanc', |
|
|
14 |
'https://drive.google.com/open?id=0Bz-jINrxV740QTZNenZadmw4NEE', |
|
|
15 |
'https://drive.google.com/open?id=0Bz-jINrxV740OFRGZ0lvZ1pZU28', |
|
|
16 |
'https://drive.google.com/open?id=0Bz-jINrxV740Z0NoSW9JRE9RRVk', |
|
|
17 |
'https://drive.google.com/open?id=0Bz-jINrxV740SDB3R0hYalJGa2M', |
|
|
18 |
'https://drive.google.com/open?id=0Bz-jINrxV740Nm1fQWhTZUVia2s', |
|
|
19 |
'https://drive.google.com/open?id=0Bz-jINrxV740YXBpYV9MQkVxSk0', |
|
|
20 |
'https://drive.google.com/open?id=0Bz-jINrxV740YTM0X2dQcGZ1eFU', |
|
|
21 |
'https://drive.google.com/open?id=0Bz-jINrxV740WEpXakYyRWxaSm8', |
|
|
22 |
'https://drive.google.com/open?id=0Bz-jINrxV740YVZFMEdpQmZrOTQ' |
|
|
23 |
] |
|
|
24 |
|
|
|
25 |
file_id = [fid[fid.find('=')+1:] for fid in file_id] |
|
|
26 |
|
|
|
27 |
file_name = ['subset'+str(i)+'.zip' for i in range(1, 10)] |
|
|
28 |
|
|
|
29 |
for fid, fname in zip(file_id, file_name): |
|
|
30 |
print fname |
|
|
31 |
print datetime.now() |
|
|
32 |
command = 'python google_drive.py '+fid+ ' '+fname |
|
|
33 |
os.sys(command) |