Berny is an optimizer of molecular geometries with respect to the total energy, using nuclear gradient information.
In each step, it takes energy and Cartesian gradients as an input, and returns a new equilibrium structure estimate.
The package implements a single optimization algorithm, which is an amalgam of several techniques, comprising the quasi-Newton method, redundant internal coordinates, an iterative Hessian approximation, a trust region scheme, and linear search. The algorithm is described in more detailed in the documentation.
Several desirable features are missing at the moment but planned, some of them being actively worked on (help is always welcome): crystal geometries, coordinate constraints, coordinate weighting, transition state search.
Install and update using Pip:
pip install -U pyberny
from berny import Berny, geomlib optimizer = Berny(geomlib.readfile('geom.xyz')) for geom in optimizer: # get energy and gradients for geom optimizer.send((energy, gradients))
- Documentation: https://azag0.github.io/pyberny