locuslab / mpc.pytorch

A fast and differentiable model predictive control (MPC) solver for PyTorch.
https://locuslab.github.io/mpc.pytorch/
MIT License
872 stars 146 forks source link

Fix compatibility issues #32

Closed fedebotu closed 2 years ago

fedebotu commented 3 years ago

Here is a changelog of the fixes:

bamos commented 3 years ago

Thanks for the updates! Are the gradient tests passing with this? I think replacing the Function with the Module will make it so the right backward pass doesn't get called (here) and will make the derivatives silently wrong

bamos commented 2 years ago

Fixed in https://github.com/locuslab/mpc.pytorch/commit/bf19cd4405d8242e93f4c0a5464739f98798a833