1
0
Fork 0
mirror of synced 2024-05-17 03:12:18 +12:00

Add default option for ClippedMSECriterion

This commit is contained in:
nagadomi 2018-10-03 18:34:26 +09:00
parent 1dc32aaa89
commit cf638aea48

View file

@ -2,8 +2,8 @@ local ClippedMSECriterion, parent = torch.class('w2nn.ClippedMSECriterion','nn.C
function ClippedMSECriterion:__init(min, max)
parent.__init(self)
self.min = min
self.max = max
self.min = min or 0
self.max = max or 1
self.diff = torch.Tensor()
self.diff_pow2 = torch.Tensor()
end