I’m currently using Pytorch 1.13.1 on my Macbook M1 Pro
Long story short, I wanted to reproduce this notebook:
PINN/solve_PDE_NN.ipynb at main · nanditadoloi/PINN · GitHub on my machine. But obviously, I have to change the device to
However, it returns
RuntimeError: derivative for aten::linear_backward is not implemented if I set
device = torch.device("mps")
But it runs fine if I set the device to
"cpu". Does anyone have a similar problem?
Addition: Just found the culprit. In the training step in the given link, it combines two loss functions the
mse_f. I tried to use
mse_uonly and it works fine on MPS, but when I tried
mse_fonly, the error message appear.
But I still have no idea why.
Thank you in advance