if I do hq=hq.double() or hq=torch.tensor(hq,dtype=torch.float64) before moving hq to the device I get the error:
RuntimeError: Expected object of scalar type Float but got scalar type Half for argument #2 'mat2' in call to _th_mm

If I first move to device then do  hq=torch.tensor(hq,dtype=torch.float64)  I get:
Expected object of device type cuda but got device type cpu for argument #1 'self' in call to _th_mm