Defining Hyperparameters for GAN

Below are some of the hyperparameters defined that we will be using throughout the code and are totally configurable. 

# Smoothing value
smooth_real = 0.9

# Number of epochs
epochs = 5

# Batchsize
batch_size = 128

# Optimizer for the generator
optimizer_g = Adam(lr=0.0002, beta_1=0.5)

# Optimizer for the discriminator
optimizer_d = Adam(lr=0.0004, beta_1=0.5)

# Shape of the input image
input_shape = (28,28,1)
Experiment with different learning rates, optimizers, batch size as well as smoothing value to see how these factors affect the quality of your model and if you get better results, show it to the deep learning community.
..................Content has been hidden....................

You can't read the all page of ebook, please click here login for view all page.
Reset