forked from 626_privacy/tensorflow_privacy
parent
f58891f3e3
commit
a1e9ca2a18
1 changed files with 2 additions and 2 deletions
|
@ -250,7 +250,7 @@ def extract_mnist_data(filename, num_images, image_size, pixel_depth):
|
||||||
np.save(filename, data)
|
np.save(filename, data)
|
||||||
return data
|
return data
|
||||||
else:
|
else:
|
||||||
with tf.gfile.Open(filename+'.npy', mode='r') as file_obj:
|
with tf.gfile.Open(filename+'.npy', mode='rb') as file_obj:
|
||||||
return np.load(file_obj)
|
return np.load(file_obj)
|
||||||
|
|
||||||
|
|
||||||
|
@ -266,7 +266,7 @@ def extract_mnist_labels(filename, num_images):
|
||||||
np.save(filename, labels)
|
np.save(filename, labels)
|
||||||
return labels
|
return labels
|
||||||
else:
|
else:
|
||||||
with tf.gfile.Open(filename+'.npy', mode='r') as file_obj:
|
with tf.gfile.Open(filename+'.npy', mode='rb') as file_obj:
|
||||||
return np.load(file_obj)
|
return np.load(file_obj)
|
||||||
|
|
||||||
|
|
||||||
|
|
Loading…
Reference in a new issue