March 2018
Intermediate to advanced
272 pages
7h 53m
English
Loading the dataset is almost exactly the same, as Keras also provides a loader for CIFAR-10, using the following code:
from keras.datasets import cifar10def load_data(): (X_train, y_train), (X_test, y_test) = cifar10.load_data() X_train = (X_train.astype(np.float32) - 127.5) / 127.5 return X_train