application_vnd.jupyter.stderr_output_1.png
import keras as K

import numpy as np

import tensorflow as tf

np.random.seed(1)
tf.set_random_seed(1)

tf.logging.set_verbosity(tf.logging.ERROR)
discriminator = K.Sequential()
depth = 64
dropout = 0.4
input_shape = (28, 28, 1)
discriminator.add(K.layers.Conv2D(depth * 1, 5, strides=2, input_shape=input_shape, padding='same'))
discriminator.add(K.layers.LeakyReLU(alpha=0.2))
discriminator.add(K.layers.Dropout(dropout))
discriminator.add(K.layers.Conv2D(depth * 2, 5, strides=2, padding='same'))
discriminator.add(K.layers.LeakyReLU(alpha=0.2))
discriminator.add(K.layers.Dropout(dropout))
discriminator.add(K.layers.Conv2D(depth * 4, 5, strides=2, padding='same'))
discriminator.add(K.layers.LeakyReLU(alpha=0.2))
discriminator.add(K.layers.Dropout(dropout))
discriminator.add(K.layers.Conv2D(depth * 8, 5, strides=1, padding='same'))
discriminator.add(K.layers.LeakyReLU(alpha=0.2))
discriminator.add(K.layers.Dropout(dropout))
discriminator.add(K.layers.Flatten())
discriminator.add(K.layers.Dense(1, activation='sigmoid'))
discriminator.summary()