Closed weepiess closed 3 years ago
Hi,
for l in range(L): I = torch.t(torch.reshape(X[l], (3, -1))) II = torch.pow(I, 2) if self.intensity_scale: Iy = torch.unsqueeze(torch.sqrt(II[:, 0] + II[:, 1] + II[:, 2]), dim=1) else: Iy = 1
I found a bug here:
torch.sqrt(II[:, 0] + II[:, 1] + II[:, 2]), dim=1)
sqrt is not derivable at point 0 Therefore, it is better to change to this:
torch.sqrt(II[:, 0] + II[:, 1] + II[:, 2]+ EPS), dim=1)
Thanks for catching this. Fixed.
Hi,
I found a bug here:
sqrt is not derivable at point 0 Therefore, it is better to change to this: