![]() |
Sleipnir
A linearity-exploiting reverse mode autodiff library and nonlinear program solver DSL.
|
Sparsity and Linearity-Exploiting Interior-Point solver - Now Internally Readable
Named after Odin's eight-legged horse from Norse mythology, Sleipnir is a reverse mode autodiff library, interior-point method, and NLP solver DSL for C++23 and Python. The DSL automatically chooses the best solver based on the problem structure.
The C++ API also supports arbitrary scalar types, so users can specify higher precision floating-point types at the cost of speed.
Sleipnir's internals are intended to be readable by those who aren't domain experts with links to explanatory material for its algorithms.
The following platforms are supported:
sudo apt install g++-14)xcode-select --install)To use Sleipnir within a CMake project, add the following to CMakeLists.txt:
To use Sleipnir in Python, install sleipnirgroup-jormungandr from PyPI:
If necessary, follow these instructions to build from source.
See the C++ API docs, Python API docs, and usage docs.
See the examples folder, C++ optimization unit tests, and Python optimization unit tests.
See the benchmarks folder.