-
Couldn't load subscription status.
- Fork 537
-
Hello,
Is it really necessary to have .double in this line ?
(backend.py line 1944)
def norm(self, a, axis=None, keepdims=False):
return torch.linalg.norm(a.double(), dim=axis, keepdims=keepdims)
It has the effect of coverting to float64 which is not supported by mps (gpu for mac silicon) , which raises this error
TypeError: Cannot convert a MPS Tensor to float64 dtype as the MPS framework doesn't support float64. Please use float32 instead.
Is this conversion to float64 intended ?
Beta Was this translation helpful? Give feedback.
All reactions
We rmoved this conversion in this PR that is now merged.
#572
Replies: 1 comment 2 replies
-
I donnt think it is necessary and i don't remember why we have this. This is a recent change
@kachayev you did this change in the backend, do you knwo why? We should try to keep the precision and not change it there.
Beta Was this translation helpful? Give feedback.
All reactions
-
We rmoved this conversion in this PR that is now merged.
#572
Beta Was this translation helpful? Give feedback.
All reactions
-
Thank you for the quick fix.
Beta Was this translation helpful? Give feedback.