July 2018
Intermediate to advanced
474 pages
13h 37m
English
This section will walk through the steps to visualize the MNIST handwritten images in a Jupyter notebook:
import numpy as npimport matplotlib.pyplot as plt%matplotlib inline
for i in range(2): image = data.train.images[i] image = np.array(image, dtype='float') label = data.train.labels[i] pixels = image.reshape((28, 28)) plt.imshow(pixels, cmap='gray') print('-----------------') print(label) plt.show()
Read now
Unlock full access