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.
1 parent db88be7 commit e5fdbd9Copy full SHA for e5fdbd9
1 file changed
examples/singa_peft/examples/data/download_mnist.py
@@ -23,17 +23,17 @@
23
24
25
def check_exist_or_download(url, download_dir):
26
+ download_dir = os.path.abspath(download_dir)
27
os.makedirs(download_dir, exist_ok=True)
28
29
name = url.rsplit('/', 1)[-1]
30
filename = os.path.join(download_dir, name)
31
32
if not os.path.isfile(filename):
- print("Downloading %s to %s" % (url, filename))
33
+ print("Downloading %s -> %s" % (url, filename))
34
urllib.request.urlretrieve(url, filename)
35
else:
- print("Already Downloaded: %s" % filename)
36
-
+ print("Already Downloaded: %s -> %s" % (url, filename))
37
38
if __name__ == '__main__':
39
parser = argparse.ArgumentParser(
0 commit comments