You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@mxnet.apache.org by zh...@apache.org on 2021/03/12 08:17:23 UTC
[incubator-mxnet] branch v1.x updated: downloading MNIST dataset
from alternate URL (#20014)
This is an automated email from the ASF dual-hosted git repository.
zha0q1 pushed a commit to branch v1.x
in repository https://gitbox.apache.org/repos/asf/incubator-mxnet.git
The following commit(s) were added to refs/heads/v1.x by this push:
new 18e4bc4 downloading MNIST dataset from alternate URL (#20014)
18e4bc4 is described below
commit 18e4bc472b3fe8b8c8e9ea48b03fa2e24c29b184
Author: Rohit Kumar Srivastava <sr...@osu.edu>
AuthorDate: Fri Mar 12 00:15:48 2021 -0800
downloading MNIST dataset from alternate URL (#20014)
Co-authored-by: Rohit Kumar Srivastava <sr...@buckeyemail.osu.edu>
---
example/image-classification/train_mnist.py | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/example/image-classification/train_mnist.py b/example/image-classification/train_mnist.py
index d47521f..2b256e2 100755
--- a/example/image-classification/train_mnist.py
+++ b/example/image-classification/train_mnist.py
@@ -32,7 +32,7 @@ def read_data(label, image):
"""
download and read data into numpy
"""
- base_url = 'http://yann.lecun.com/exdb/mnist/'
+ base_url = 'https://web.archive.org/web/20160828233817/http://yann.lecun.com/exdb/mnist/'
with gzip.open(download_file(base_url+label, os.path.join('data',label))) as flbl:
magic, num = struct.unpack(">II", flbl.read(8))
label = np.fromstring(flbl.read(), dtype=np.int8)