code: def __init__(self):
      self.img_rows = 28
      self.img_cols = 28
      self.channels = 1
      self.img_shape = (self.channels, self.img_rows, self.img_cols)
      self.latent_dim = 100
  
      optimizer = Adam(learning_rate=0.0002, b1=0.5)
      loss_function = CrossEntropy
  
      # Build the discriminator
      self.discriminator = self.build_discriminator(
          optimizer, loss_function
      )
  
      # Build the generator
      self.generator = self.build_generator(optimizer, loss_function)
  
      # Build the combined model
      self.combined = NeuralNetwork(
          optimizer=optimizer, loss=loss_function
      )
      self.combined.layers.extend(self.generator.layers)
      self.combined.layers.extend(self.discriminator.layers)
  
      print()
      self.generator.summary(name="Generator")
      self.discriminator.summary(name="Discriminator")
  
file_path: ML-From-Scratch/mlfromscratch/unsupervised_learning/dcgan.py
imports: from __future__ import print_function, division
  import matplotlib.pyplot
  import numpy
  import progressbar
  from sklearn.datasets import fetch_mldata
  from mlfromscratch.deep_learning.optimizers import Adam
  from mlfromscratch.deep_learning.loss_functions import CrossEntropy
  from mlfromscratch.deep_learning.layers import Dense, Dropout, Flatten, Activation, Reshape, BatchNormalization, ZeroPadding2D, Conv2D, UpSampling2D
  from mlfromscratch.deep_learning import NeuralNetwork
label_desc: Use image node_id 1 to create a new DCGAN object  with example: obj = DCGAN()