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
torch.Tensor.to allows the user to provide a reference tensor in lieu of explicitly passing device and dtype; however, this logic seems to be missing from LinearOperator.to.
To reproduce
A = DiagLinearOperator(torch.rand(3, dtype=torch.float64))
B = A.to(torch.rand(3, dtype=torch.float32))
B.dtype
> torch.float64
Expected Behavior
The code should either follow the same convention as torch.Tensor.to or raise an exception.
The text was updated successfully, but these errors were encountered:
🐛 Bug
torch.Tensor.to
allows the user to provide a reference tensor in lieu of explicitly passingdevice
anddtype
; however, this logic seems to be missing fromLinearOperator.to
.To reproduce
Expected Behavior
The code should either follow the same convention as
torch.Tensor.to
or raise an exception.The text was updated successfully, but these errors were encountered: