A package for solving complementarity problems in Julia with scalable gradients compatible with ChainRules.
import Pkg
Pkg.add("https://github.com:avik-pal/ComplementaritySolve.jl.git")| Solver | Native Batching | CPU | CUDA1 | Details |
|---|---|---|---|---|
| NonlinearReformulation | ✔️ | ✔️ | ✔️ | |
| RPGS | ❌ | ✔️ | ❌ | |
| PGS | ❌ | ✔️ | ❌ | |
| PSOR | ❌ | ✔️ | ❌ | |
| BokhovenIterativeAlgorithm | ✔️ | ✔️ | ✔️ | Assumes PSD M |
| InteriorPointMethod | ✔️ | ✔️ | ✔️ | Assumes PSD M |
Solvers that don't natively support batching, use threads to solve multiple problems in parallel.
| Solver | CPU | CUDA1 | Details |
|---|---|---|---|
| NonlinearReformulation | ✔️ | ✔️ | |
| PATHSolver | ✔️ | ❌ |
|
All LCPs, MLCPs, and NCPs can be converted to MCPs, and these solvers can be used directly.
| Method | Problem Type | Native Batching | CPU | CUDA1 | Details |
|---|---|---|---|---|---|
| LinearComplementarityAdjoint | LCP | ✔️ | ✔️ | ✔️ | |
| MixedComplementarityAdjoint | MCP | ✔️ | ✔️ |
More details are WIP. Examples can be found in test directory.
- Supports batched problems for LCPs.
- Can use any arbitrary forward solver. If Siconos is faster, we can use that solver, and we will still be able to give gradients to the end user.
- Most solvers should work on GPUs OOTB.
- Scalable Adjoint computation using Linear Solve trick rather than computing explicit Jacobians like ParametricMCPs.jl.
- If solver thinks problem is small enough, we still construct the Jacobian.