I have a model u(x,t) with layers 2X50, then 50X50, and 50X1.
I train the model with input x,t of size [100,2]. In the final layer I get u and now I want to differentiate it w.r.t to x and t and double differentiate w.r.t to x. How do I do this in PyTorch?