Created
October 31, 2017 15:29
-
-
Save cafielo/49844eabf1b8c1a7bd0b885e61197167 to your computer and use it in GitHub Desktop.
1. Mnist load
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
from __future__ import print_function | |
import keras | |
from keras.datasets import mnist | |
from keras.models import Sequential | |
from keras.layers import Dense, Dropout, Flatten, Activation | |
from keras.layers import Conv2D, MaxPooling2D | |
from keras import backend as K | |
from keras.layers.normalization import BatchNormalization | |
batch_size = 128 | |
num_classes = 10 | |
epochs = 10 | |
# input image dimensions | |
img_rows, img_cols = 28, 28 | |
# the data, shuffled and split between train and test sets | |
(x_train, y_train), (x_test, y_test) = mnist.load_data() |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment