16.03.2021 Views

Advanced Deep Learning with Keras

Create successful ePaper yourself

Turn your PDF publications into a flip-book with our unique Google optimized e-Paper software.

Chapter 6

# call discriminator builder with 4 outputs: source, label,

# and 2 codes

discriminator = gan.discriminator(inputs, num_labels=num_labels, with_

codes=True)

The generator is created by:

# call generator with inputs, labels and codes as total inputs

# to generator

generator = gan.generator(inputs, image_size, labels=labels,

codes=[code1, code2])

Figure 6.1.4: The InfoGAN Keras model

[ 171 ]

Hooray! Your file is uploaded and ready to be published.

Saved successfully!

Ooh no, something went wrong!