Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- import pandas as pd
- import matplotlib.pyplot as plt
- from tensorflow.keras.datasets import mnist
- (x_train,y_train), (x_test,y_test) = mnist.load_data()
- x_train.shape
- image_0 = x_train[0]
- plt.imshow(image_0)
- from tensorflow.keras.utils import to_categorical
- y_cat_train = to_categorical(y_train)
- y_cat_test = to_categorical(y_test)
- x_train = x_train / 255
- x_test = x_test / 255
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement