RCAN icon indicating copy to clipboard operation
RCAN copied to clipboard

training loss not decrease

Open wl082013 opened this issue 6 years ago • 5 comments

Hi I tried to run the code, it somehow worked after I changed the torch version and some codes. For instance, I commented 'plt.plot(axis, self.log[:, i].numpy(), label=label)' since it is told that [ x and y dimension does not match). During the training, however, the loss is not descreasing, but increasing (see the attached figure). I dont know what is the problem, maybe there is something with the code ? Really appreiciate your help.

1565701586(1)

wl082013 avatar Aug 13 '19 13:08 wl082013

I experience a similar issue, and add that the training loss is extremely high. Does model directly predict the uint8 RGB values? If so, why was this found necessary instead of output being within range of [0,1].

From what I can tell they:

  1. apply meanshift by subtraction
  2. apply their model
  3. add the residual
  4. super resolve
  5. apply meanshift by addition

input and output are both on RGB scale [0,255].

yhu9 avatar Oct 08 '19 21:10 yhu9

I had the same problem, and at a certain point in the training, loss became very large.Have you solved the problem yet?

LcenArthas avatar Jun 03 '20 13:06 LcenArthas

In my case, the initializer was the problem. I used LeCunNormal initializer and the loss became extremely large, but KaimingUniform initializer, the loss converged properly.

S-Nakamur-a avatar Jun 03 '20 13:06 S-Nakamur-a

Thank you very much. Could you please tell me where I should make the change?I actually use the pre-trained model to initialize it, but the effect is very bad.

LcenArthas avatar Jun 03 '20 14:06 LcenArthas

In my case, the initializer was the problem. I used LeCunNormal initializer and the loss became extremely large, but KaimingUniform initializer, the loss converged properly.

Could you tell me which part of the code is the initialization of the model,please?

BEAUTIFULSB avatar Dec 31 '21 02:12 BEAUTIFULSB