Hello all, I am looking for the way to use L1 loss in DCGAN. Currently, DCGAN in the pytorch example uses BCELoss.
criterion = nn.BCELoss()
errD_real = criterion(output, label)
As mentioned in the DCGAN paper :“L1 loss does very well at low frequencies (I think this means general tonal-distribution/contrast, color-blotches, etc) but fails at high frequencies (crispness/edge/detail) (thus you get blurry images).”. Thus, I would like to apply L1 loss instead of BCELoss. Have any one success to use L1 loss in DCGAN? How do you use it? Thanks
This is my current solution but I am not sure if it works?
criterion = nn.L1Loss()
errD_real = criterion(output, label)