
Security News
Browserslist-rs Gets Major Refactor, Cutting Binary Size by Over 1MB
Browserslist-rs now uses static data to reduce binary size by over 1MB, improving memory use and performance for Rust-based frontend tools.
Grid-Restrained Nelder-Mead Algorithm
Python implementation of grid-restrained variant of the Nelder-Mead algorithm, a derivative-free, unconstrained optimization algorithm that provably converges to a stationary point. See [1] for details.
This implementation has minimal dependencies and integrates well with the SciPy library. The code is fully typed, passes mypy, and comes with basic unit tests.
The MATLAB implementation [2] by the authors of [1] and the PyOPUS implementation [3] were used for reference. Variable names and default parameter were mostly taken from [1]. The adaptive parameters are as suggest in [4].
[2] https://fides.fe.uni-lj.si/~arpadb/software-grnm.html
[3] http://spiceopus.si/pyopus/doc/optimizer.grnm.html?highlight=grnm#module-pyopus.optimizer.grnm
GridNM is available on PyPI and can be installed, for example, using pip:
pip install gridnm
Here is an example of how to use gridnm to minimize the 2D rosenbrock function:
from gridnm import GridNM
from scipy.optimize import rosen
# initial point
x0 = [-1.2, 1]
# create solver instance
gridnm = GridNM(rosen, x0)
# run solver
sol = gridnm.solve()
# print solution
print(f"x_opt = {sol.x}")
See the comments in src/gridnm/gridnm.py
for options and parameters.
FAQs
Grid-restrained Nelder-Mead algorithm
We found that gridnm demonstrated a healthy version release cadence and project activity because the last version was released less than a year ago. It has 1 open source maintainer collaborating on the project.
Did you know?
Socket for GitHub automatically highlights issues in each pull request and monitors the health of all your open source dependencies. Discover the contents of your packages and block harmful activity before you install or update your dependencies.
Security News
Browserslist-rs now uses static data to reduce binary size by over 1MB, improving memory use and performance for Rust-based frontend tools.
Research
Security News
Eight new malicious Firefox extensions impersonate games, steal OAuth tokens, hijack sessions, and exploit browser permissions to spy on users.
Security News
The official Go SDK for the Model Context Protocol is in development, with a stable, production-ready release expected by August 2025.