Generative Adversarial Networks Explained: Unlocking AI’s Creative Potential

 Generative Adversarial Networks (GANs) have been a topic of great interest in the AI community for several years.

Many blogs have been written on the topic already and they are great but what they lack is an intuitive guide to understand what GANs are!

My commitment to converting complex AI ideas to simple everyday analogies has led me to write this blog on GANs. I have written articles  on RAG and transformer as well so check them out if you want to learn more about them.

GAN Architecture Block Diagram

Let’s dive into the world of GANs imagine you are an art gallery curator and you have a huge collection of paintings. 

You need a new art piece so you call an artist (generator) to create art that looks like a real art piece but there is a catch, a critic (discriminator) is also in the building.

The artist aka generator has little skill but by creating more and more it can get better whereas the critic's (discriminator) role is to find flaws in the creation and if flaws are found then the piece is rejected.

GANs are called adversarial networks because the generator and discriminator are in a tug-of-war the more fakes the discriminator catches the more real-looking painting the generator(artist) would make.

At first, the generator creates an image that is far from real, so the discriminator catches it and the image is rejected.

The artist returns with a new piece, slightly better this time. The critic scrutinizes it, finding some flaws but also acknowledging improvements. The artist refines their technique based on this critique.

This back-and-forth continues, with the artist improving at creating convincing pieces, and the critic becoming increasingly skilled at spotting the fakes. Over time, the artist’s work becomes so refined that even the most discerning critic struggles to tell the difference between AI-generated art and real masterpieces.

In this setup generator and discriminator are a neural network which finds the underlying distribution of the data in which the discriminator minimizes its loss function meaning it has a better capability of finding “fakes” and the generator (artist)’ 's loss function is maximized which might seem counterintuitive but generators’ job is to fool discriminator by creating images which look strikingly “real”.

If you want to learn the math behind the Generative Adversarial network check out the blog by Jake Tae here.

Author’s Note: If this exploration into the world of GANs and AI art curation sparked your interest, be sure to share, and follow for more insights into the fascinating intersections of technology and creativity!

Comments