You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
I tried porting the code to PyTorch, specifically the Tensorflow version. The latter works perfectly.
But with PyTorch when I use optim.LBFGS, I run into exploding gradients/no updates on the target.
The error is in the update: 151 152 #update scale of initial Hessian approximation --> 153 H_diag = ys / y.dot(y) # (y*y) 154 155 # compute the approximate (L-BFGS) inverse Hessian
ZeroDivisionError: float division by zero
I am running this on CPU only for the time being - macOS 10.13.1 64 bit.
Any insights on why this may be happening?
The text was updated successfully, but these errors were encountered:
I tried porting the code to PyTorch, specifically the Tensorflow version. The latter works perfectly.
But with PyTorch when I use optim.LBFGS, I run into exploding gradients/no updates on the target.
The error is in the update:
151
152 #update scale of initial Hessian approximation
--> 153 H_diag = ys / y.dot(y) # (y*y)
154
155 # compute the approximate (L-BFGS) inverse Hessian
ZeroDivisionError: float division by zero
I am running this on CPU only for the time being - macOS 10.13.1 64 bit.
Any insights on why this may be happening?
The text was updated successfully, but these errors were encountered: