This project is focused on generating fashion images using Generative Adversarial Networks (GANs). GANs are a popular class of deep learning models that consist of a generator network and a discriminator network, trained in an adversarial manner. The generator learns to produce realistic images, while the discriminator learns to distinguish between real and generated images.
The Fashion Image Generation project aims to generate new and visually appealing fashion images using GANs. By training the GAN model on a dataset of real fashion images, the generator network can learn to generate new images that resemble the training data.
To train the GAN model, Fashion-MNIST dataset, is used.It is a dataset of Zalando's article images consisting of a training set of 60,000 examples and a test set of 10,000 examples. Each example is a 28x28 grayscale image, associated with a label from 10 classes.
The GAN architecture consists of two main components: the generator and the discriminator.
The goal of the generator is to transform random noise into images that resemble the real fashion images in the dataset. The generator architecture consists of sequential layers, including dense, upsampling, and convolutional layers with LeakyReLU activations.
The discriminator network acts as a binary classifier, distinguishing between real and generated fashion images. The discriminator architecture comprises convolutional layers with LeakyReLU activations and dropout layers for regularization.
The GAN model is trained using a custom training loop implemented with TensorFlow's tf.GradientTape function . The training loop involves alternating steps between updating the generator and discriminator networks.
During each step, real images from the dataset are fed to the discriminator, and generated images are passed through the generator. The gradients are then computed and used to update the model parameters. This process continues for a certain number of epochs until the model converges.
Images generated by the model before it has been trained
Images generated by the model after it has been trained for 10 epochs