Conditional GANs and Applications

From Unconditional to Conditional

A vanilla GAN takes only random noise as input — the generator decides what to produce. A conditional GAN (cGAN) also takes some additional information — a class label, a text description, another image — and conditions its output on that. This is what unlocks the really interesting applications.

Conditional GAN
Conditional GAN

For a day-to-night conditional GAN, the discriminator gets to see real and generated nighttime photos along with the corresponding daytime photo. The generator gets noise plus the daytime photo. The conditioning anchors the output to the input scene while letting the generator hallucinate the lighting, sky, and shadows.

Day-to-night conditional GAN
Day to Night with a Conditional GAN. [Source]

Real-world applications

  • Synthetic training data. One of the biggest unsung uses of GANs in industry is creating synthetic training data. Need a dataset of faces for a face-recognition project but can't collect that many real ones (or have privacy concerns)? Generate them. Need to train a self-driving car's perception system on nighttime conditions but you mostly drove during the day? Use a day-to-night conditional GAN to augment your dataset.
  • Photo and video tools. The dramatic age-progression filter, the "fix this old photo" button, AI-driven upscaling in modern TVs and game consoles — much of this lineage runs through GAN research from 2016–2018. Even when modern apps have moved to diffusion models, they often still use GAN-based components for super-resolution.
  • Creative tools. NVIDIA's GauGAN (turn a doodle into a landscape photo) is a conditional GAN. Many "anime style" face filters started life as GANs.
Side-by-side comparison, GAN face generation from 2014 to 2019
The progress on GAN face generation from 2014 to 2019 is one of the most striking visual examples of progress in any subfield of machine learning. [Source]
Conditional GAN Application Explorer

Image-to-Image Translation

Conditioning input

Input image (e.g. daytime scene, semantic map, sketch)

Generator produces

Noise z + conditioning image → transformed output image

Discriminator sees

Real output image + conditioning image vs. generated output + conditioning image

Real-world context

Day→night, summer→winter, satellite→map, sketch→photo, label→scene. The discriminator sees both the conditioning image and the output — it can't be fooled by a realistic output that doesn't match the input.

Explore the major conditional GAN application types: select a task to see how the conditioning input changes, what the discriminator sees, and which real products use that GAN variant.

💭Reflection

A medical imaging company wants to train a tumor detection model but only has 300 labeled MRI scans — far too few for a robust classifier. How might a conditional GAN help? What risks would you need to consider?