From ad7aa91f55eb282993c92f5041beb72dfac372b7 Mon Sep 17 00:00:00 2001 From: Philip Meier Date: Tue, 12 Apr 2022 13:37:08 +0200 Subject: [PATCH] do not re-download from GDrive if file is already present --- torchvision/datasets/utils.py | 1 + 1 file changed, 1 insertion(+) diff --git a/torchvision/datasets/utils.py b/torchvision/datasets/utils.py index 06ceb7327c4..7fe80b8ab56 100644 --- a/torchvision/datasets/utils.py +++ b/torchvision/datasets/utils.py @@ -234,6 +234,7 @@ def download_file_from_google_drive(file_id: str, root: str, filename: Optional[ if check_integrity(fpath, md5): print(f"Using downloaded {'and verified ' if md5 else ''}file: {fpath}") + return url = "https://drive.google.com/uc" params = dict(id=file_id, export="download")