freakazoid,
@freakazoid@retro.social avatar

Pix2pix works by training a "discriminator" network to distinguish the output of a "generator" network, while simultaneously training the generator to fool the discriminator. Unlike with "unconditional" GANs, the discriminator gets to use the input image as well as the output of the discriminator, otherwise the generator could produce something that looked like any of the training outputs for any training input.

You may wonder how you start training a setup like this, since the generator will initially just output noise. The answer is that the generator also gets trained to minimize the L1 norm, i.e. the mean absolute difference between its output and the training image. By itself the L1 norm produces blurry results, which is the whole reason for the discriminator network.

As for how to update the weights, PyTorch or any machine learning framework will automatically produce gradients for you, since that's pretty much the point of those frameworks. So we know how to adjust the generator's output to get a better score from the discriminator, and from that we can compute an adjustment to the generator's weights. And we know how to adjust the discriminator's weights to better discriminate between the "real" and "fake" output images. It's not a game, so both sides get to "cheat".

https://arxiv.org/abs/1611.07004

  • All
  • Subscribed
  • Moderated
  • Favorites
  • random
  • DreamBathrooms
  • InstantRegret
  • osvaldo12
  • magazineikmin
  • tacticalgear
  • rosin
  • everett
  • Youngstown
  • khanakhh
  • slotface
  • ngwrru68w68
  • kavyap
  • cisconetworking
  • thenastyranch
  • JUstTest
  • mdbf
  • GTA5RPClips
  • cubers
  • modclub
  • Durango
  • normalnudes
  • anitta
  • ethstaker
  • tester
  • provamag3
  • megavids
  • Leos
  • lostlight
  • All magazines