Customized a little bit Rayleigh

This commit is contained in:
i.ortega 2020-05-10 01:18:38 +02:00
parent c1b2fba6ee
commit 7f50c7ab83
1 changed files with 2 additions and 2 deletions

View File

@ -114,8 +114,8 @@ def rayleighDistribution(sigma2):
def criterion(x, y):
f = nn.CrossEntropyLoss(ignore_index=PAD_IDX)
ray = rayleighDistribution(0.15)
return ray(bp(x.shape[0], y.shape[0]))/1.566055429325195 * f(x, y)
ray = rayleighDistribution(0.2)
return ray(0.05+bp(x.shape[0], y.shape[0]))/1.356244 * f(x, y)
def train(