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
// ISSUE HERE: use the line below with metal to see zero gradients...letmut pred_loss = Tensor::zeros(&[1],(Kind::Float, device));// With the line below, the issue goes away// let mut pred_loss;
When the variable is inited with a Tensor, the grads becomes zeros after about 5 iteration. But when I leave it uninitialized at the first place, the issue goes away.
When you run the code, it'll print about 40 times and you can see how the grads change.
The text was updated successfully, but these errors were encountered:
code: https://github.com/michael8090/test-candle-metal/tree/tch-rs-grads
At line 123:
When the variable is inited with a Tensor, the grads becomes zeros after about 5 iteration. But when I leave it uninitialized at the first place, the issue goes away.
When you run the code, it'll print about 40 times and you can see how the grads change.
The text was updated successfully, but these errors were encountered: