The hermi package implements integrals over atom-centred Gaussian basis functions for use in quantum chemistry.
It implements a generalised McMurchie--Davidson algorithm which targets matrix operations in order to effectively vectorise the workload via NumPy calls.
This permits efficient integral generation without any custom compiled code.
Installation
The package can be installed from the PyPI repository:
pip install hermi
Alternatively, clone the repository and install via the source code:
git clone https://github.com/obackhouse/hermi.git
cd hermi && pip install .
Usage
Helper classes for molecules and basis sets are implemented:
from hermi import Molecule, Basis
molecule = Molecule.from_list(["Li", "H"], [[0.0, 0.0, 0.0], [0.0, 0.0, 1.64]])
basis = Basis.from_molecule(molecule, "6-31g")
The automatic basis construction uses the basis-set-exchange library.
Operators can then be constructed and evaluated over the basis set:
from hermi import Overlap
overlap = Overlap()
matrix = overlap.collect(basis)
Operators are also composable; along with lazy evaluation and caching, this can afford optimisations when computing molecular integrals summed over a number of operators:
from hermi import Kinetic, Nuclear
core_hamiltonian = Kinetic() + Nuclear(molecule)
matrix = core_hamiltonian.collect(basis)
Development
We recommend uv for development, install development dependencies and run the test suite with:
uv sync --extra dev
uv run pytest
The operator integration tests compare Cartesian and spherical integrals against PySCF.
References
This work is based on several papers: first, the original paper of McMurchie and Davidson, and more specifically, the modern implementations detailed in papers by Neese and by Asadchev and Valeev.
Metadata
Release files for hermi 0.1.0
For a detailed explanation of source distributions (sdists) and built distributions (wheels), please see the package formats documentation.
Source distribution (sdist)
| File | Size | Uploaded | |
|---|---|---|---|
| hermi-0.1.0.tar.gz | 241.4 kB | Details |
Built distribution (wheel)
| File | Interpreter | ABI | Platform | Reset |
|---|---|---|---|---|
| hermi-0.1.0-py3-none-any.whl | Python 3 | none | any | Details |
Total release size: 487.4 kB
Release files / hermi-0.1.0.tar.gz
| Download URL | hermi-0.1.0.tar.gz |
|---|---|
| Size | 241.4 kB |
| Tags | Source |
|
SHA-256 checksum How to use checksums |
13b8018b717ea59061f258585863a6f6590f90672572615e086dab9eb5ce8c0b
|
|
BLAKE2b-256 checksum How to use checksums |
1544320f1d8ca49b20abbbea708041477c7401ee80f6ae9a8b9cba14485bc685
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
Yes |
| Uploaded via |
uv/0.13.0 {"installer":{"name":"uv","version":"0.13.0","subcommand":["publish"]},"python":null,"implementation":{"name":null,"version":null},"distro":{"name":"Ubuntu","version":"24.04","id":"noble","libc":null},"system":{"name":null,"release":null},"cpu":null,"openssl_version":null,"setuptools_version":null,"rustc_version":null,"ci":true}
|
Release files / hermi-0.1.0-py3-none-any.whl
| Download URL | hermi-0.1.0-py3-none-any.whl |
|---|---|
| Size | 246.0 kB |
| Tags | Python 3 |
|
SHA-256 checksum How to use checksums |
11e2cbbaa1d52201e30b13d14669b50a643d6dfb4781d354387ed93ac1f72503
|
|
BLAKE2b-256 checksum How to use checksums |
d778fb67af46dec32f02e8eb3dbfc6e8e264f5c7112abc26047546be6fb2db05
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
Yes |
| Uploaded via |
uv/0.13.0 {"installer":{"name":"uv","version":"0.13.0","subcommand":["publish"]},"python":null,"implementation":{"name":null,"version":null},"distro":{"name":"Ubuntu","version":"24.04","id":"noble","libc":null},"system":{"name":null,"release":null},"cpu":null,"openssl_version":null,"setuptools_version":null,"rustc_version":null,"ci":true}
|