Skip to main content

pbalm

Python implementation of PBALM.

pbalm solves optimization problems of the form:

$$ \begin{aligned} \min_{x} \quad & f_1(x) + f_2(x) \ \text{s.t.} \quad & g(x) \leq 0 \ & h(x) = 0 \end{aligned} $$

where $f_1$ is smooth (possibly nonconvex), $f_2$ is possibly nonsmooth but prox-friendly, and $g$, $h$ define smooth inequality and equality constraints, respectively.

Quick example:

python3 -m pip install pbalm
import jax.numpy as jnp
import pbalm

def f1(x):
    return jnp.sum(x**2)

# L1 regularization (nonsmooth)
lbda = 0.1
f2 = pbalm.L1Norm(lbda)

# inequality constraint g_j(x) <= 0; j=1
def g_1(x):
    return x[0] - 0.8

# equality constraints h_i(x) = 0; i=1,2
def h_1(x):
    return x[0] + x[1] - 1.0

def h_2(x):
    return x[1] * x[2] - 2.0

x0 = jnp.array([1.0, 1.0, 2.0])

# create problem and solve
problem = pbalm.Problem(f1=f1, f2=f2, g=[g_1], h=[h_1, h_2])
result = pbalm.solve(problem, x0=x0, tol=1e-6)

print(f"Solution: {result.x}")

More examples in /examples/ directory.

References

@article{adeoye2025pbalm,
  title={A proximal augmented Lagrangian method for nonconvex optimization with equality and inequality constraints},
  author={Adeoye, Adeyemi D. and Latafat, Puya and Bemporad, Alberto},
  journal={arXiv preprint arXiv:2509.02894},
  year={2025}
}

Acknowledgments

This work was funded by the European Union (ERC Advanced Research Grant COMPACT, No. 101141351). Views and opinions expressed are however those of the authors only and do not necessarily reflect those of the European Union or the European Research Council. Neither the European Union nor the granting authority can be held responsible for them.

ERC logo

Default inner solver: PANOC; also calls prox functions from: alpaqa.

Metadata

Release files for pbalm 0.1.3

For a detailed explanation of source distributions (sdists) and built distributions (wheels), please see the package formats documentation.

Source distribution (sdist)

Source distribution for pbalm 0.1.3
File Size Uploaded
pbalm-0.1.3.tar.gz 98.5 kB Details

Built distribution (wheel)

Table of built distributions (wheels) for pbalm 0.1.3
File Interpreter ABI Platform
pbalm-0.1.3-py3-none-any.whl Python 3 none any Details

Total release size: 191.6 kB

Release files / pbalm-0.1.3.tar.gz

Download URL pbalm-0.1.3.tar.gz
Size 98.5 kB
Tags Source
SHA-256 checksum
How to use checksums
9bc24ee88c8920c2af6db707168f381f82315e08e31020f54c933f1d6317d7b4
BLAKE2b-256 checksum
How to use checksums
6bbadc2345f54a4ce396af8933dcf655d0fa73f2191d77cfdb269d5c31d2ef26
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No
Uploaded via twine/7.0.0 CPython/3.12.13

Release files / pbalm-0.1.3-py3-none-any.whl

Download URL pbalm-0.1.3-py3-none-any.whl
Size 93.1 kB
Tags Python 3
SHA-256 checksum
How to use checksums
5e6c0c9fc17de5d944331f7efbac9a5ebbbe0aab56ba8d19fd4665254b51b676
BLAKE2b-256 checksum
How to use checksums
84f931ff039133c9850893c9a87e75fbab54c685b728470bb703169839ab8359
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No
Uploaded via twine/7.0.0 CPython/3.12.13

Release history Release notifications | RSS feed

0.1.7

2 release files

This release

0.1.3 This release

2 release files

0.1.2

2 release files

Anthropic, PBC Visionary sponsor Bloomberg Visionary sponsor Hudson River Trading Visionary sponsor Meta Visionary sponsor NVIDIA Visionary sponsor Microsoft Sustainability sponsor Depot Continuous Integration AWS Cloud computing and Security Sponsor Datadog Monitoring Fastly CDN Google Download Analytics Sentry Error logging StatusPage Status page