Skip to content

Commit

Permalink
downloading MNIST dataset from alternate URL (apache#20014)
Browse files Browse the repository at this point in the history
Co-authored-by: Rohit Kumar Srivastava <[email protected]>
  • Loading branch information
access2rohit and Rohit Kumar Srivastava committed Mar 12, 2021
1 parent fa030f3 commit 4d79273
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion example/image-classification/train_mnist.py
Original file line number Diff line number Diff line change
Expand Up @@ -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)
Expand Down

0 comments on commit 4d79273

Please sign in to comment.