We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
.tar
1 parent 3fc8999 commit d7bc5d7Copy full SHA for d7bc5d7
utils/general.py
@@ -594,10 +594,12 @@ def download_one(url, dir):
594
else:
595
LOGGER.warning(f'Failed to download {url}...')
596
597
- if unzip and success and f.suffix in ('.zip', '.gz'):
+ if unzip and success and f.suffix in ('.zip', '.tar', '.gz'):
598
LOGGER.info(f'Unzipping {f}...')
599
if f.suffix == '.zip':
600
ZipFile(f).extractall(path=dir) # unzip
601
+ elif f.suffix == '.tar':
602
+ os.system(f'tar xf {f} --directory {f.parent}') # unzip
603
elif f.suffix == '.gz':
604
os.system(f'tar xfz {f} --directory {f.parent}') # unzip
605
if delete:
0 commit comments