facebookresearch/theseus
A Facebook Research library enabling backpropagation through nonlinear optimization solvers like Gauss-Newton and Levenberg-Marquardt, built on PyTorch.

Theseus provides differentiable nonlinear optimization primitives that can be incorporated into neural network computation graphs. It implements classic optimization algorithms including Gauss-Newton, Levenberg-Marquardt, and nonlinear least-squares solvers, enabling gradient-based learning through optimization layers. The library is used for applications in computer vision, robotics, and embodied AI where optimization problems need to be end-to-end differentiable.
Frequently asked
- What is facebookresearch/theseus?
- A Facebook Research library enabling backpropagation through nonlinear optimization solvers like Gauss-Newton and Levenberg-Marquardt, built on PyTorch.
- Is theseus open source?
- Yes — facebookresearch/theseus is open source, released under the MIT license.
- What language is theseus written in?
- facebookresearch/theseus is primarily written in Python.
- How popular is theseus?
- facebookresearch/theseus has 2k stars on GitHub.
- Where can I find theseus?
- facebookresearch/theseus is on GitHub at https://github.com/facebookresearch/theseus.