Course Study Note
Day 4 — GANs and Pix2Pix
I separated the generator and discriminator objectives, then followed how a conditional GAN becomes an image-to-image translator.
- Date
- 2025-07-10
- Course
- 2025 Generative Models Intensive — From VAE to Stable Diffusion
Study checkpoint for this day
Study checkpoint for this day
Topics from the day
- GAN Training Structure
I traced gradients and labels while alternating the two optimizers.
- Pix2Pix and Conditional Generation
I linked adversarial loss to realism and L1 loss to input preservation.
Alternating two optimizers
I split the minimax objective from Generative Adversarial Nets into discriminator and generator updates. Generated samples are detached for the D update; the G update keeps the gradient path through D without updating D’s parameters.
Reading the loss curves
A small discriminator loss does not mean that generation is good. I need the two curves, generated samples, and diversity together to spot an overpowering discriminator or mode collapse.
Pix2Pix
Pix2Pix conditions both networks on the input image. Its adversarial term rewards realistic local structure, while L1 helps preserve the paired target and U-Net skip connections carry spatial detail.
I did not retain a paired-image output from the course run, so a direct L1-only comparison remains a future rerun.