in tseval/utils/resources_utils.py [0:0]
def download_and_extract(url):
compressed_filename = url.split('/')[-1]
compressed_filepath = os.path.join(DOWNLOAD_DIR, compressed_filename)
# Special case for github repo zips which all have the same name, redownload everytime
if 'github.com' in url and os.path.exists(compressed_filepath):
os.remove(compressed_filepath)
if not os.path.exists(compressed_filepath):
download(url, compressed_filepath)
print('Extracting...')
return extract(compressed_filepath, DOWNLOAD_DIR)