Skip to main content

mbGDML

Create, use, and analyze machine learning potentials within the many-body expansion framework.

Documentation

Build Status Codecov DOI License Repo size Black style Black style

MotivationApproachFeaturesInstallationLicense

Motivation

Machine learning potentials (i.e., force fields) often rely on local descriptors for size transferability. These descriptors partition total properties into atomic contributions; however, they inherently neglect complicated long-range interactions by enforcing atomic radial cutoffs. Global descriptors encode the entire structure with no cutoffs and can capture interactions at all scales. However, they are restricted to systems with the same number of atoms.

Gradient-domain machine learning (GDML) is one example of a ML potential with a global descriptor. GDML is unique because it trains directly on forces and recovers total energy through analytical integration. This provides substantially more information about the potential energy surface (PES) and allows for better interpolation between training data. As a result, GDML typically only needs 1000 structures to accurately learn energies and forces.

To date, GDML has been limited to the exact system it was trained on. This makes simulations on arbitrarily size systems, like solvents, futile.

Approach

Many-body expansions (MBEs) rigorously decomposes total (i.e., supersystem) energies into fundamental n-body interactions. This expansion is formally exact when all N-body interactions are accounted for. In practice, however, it is typically truncated to the third order. One can then model any system by summing up 1-, 2-, and 3-body contributions.

MBEs driven by GDML potentials trained on n-body interactions is a promising approach for size-transferable potentials. Furthermore, GDML model's remarkable data efficiency enables training on highly accurate quantum chemical methods.

Features

Train

  • Train GDML models using grid searches, Bayesian optimization, or both on CPUs.
  • Custom loss functions.
  • Iterative training procedure for automated curation of optimal training sets.

Predict

  • Many-body predictions with GDML, SchNet and GAP potentials.
  • Parallel GDML predictions with ray from a laptop to multiple nodes.
  • Periodic structures with the minimum-image convention.
  • Alchemical predictions by tuning out 2- or 3-body contributions of specific entities.

Analysis

  • Prediction sets that store decomposed predictions for further analysis.
  • Radial distribution functions.
  • Cluster and identify problematic (i.e., high error) structures using sklearn.

Interfaces

Installation

You can install mbGDML from PyPI by using pip install mbGDML. Or, the latest development version can be installed directly from the GitHub repository or from TestPyPI.

git clone https://github.com/keithgroup/mbGDML
cd mbGDML
pip install .

Citing this work

If you find this code helpful in your research or project, please consider citing the following paper:

Maldonado, A. M.; Poltavsky, I.; Vassilev-Galindo, V.; Tkatchenko, A.; Keith, J. A. Modeling molecular ensembles with gradient-domain machine learning force fields. Digital Discovery 2023, 2 (3), 871-880. DOI: 10.1039/D3DD00011G.

@article{maldonado2023modeling,
  title={Modeling molecular ensembles with gradient-domain machine learning force fields},
  author={Maldonado, Alex M and Poltavsky, Igor and Vassilev-Galindo, Valentin and Tkatchenko, Alexandre and Keith, John A},
  journal={Digital Discovery},
  volume={2},
  number={3},
  pages={871--880},
  year={2023},
  publisher={Royal Society of Chemistry},
  doi={10.1039/D3DD00011G}
}

Citing the paper helps acknowledge the effort put into developing and maintaining this codebase, and it provides a way to support further research and development. Thank you for your support!

License

Distributed under the MIT License. See LICENSE for more information.

Release files for mbGDML 0.1.1

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

Source distribution (sdist)

Source distribution for mbGDML 0.1.1
File Size Uploaded
mbGDML-0.1.1.tar.gz 143.4 kB Details

Built distribution (wheel)

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

Total release size: 300.7 kB

Release files / mbGDML-0.1.1.tar.gz

Download URL mbGDML-0.1.1.tar.gz
Size 143.4 kB
Tags Source
SHA-256 checksum
How to use checksums
d496d938c47582297c30481ff3409b0e08ea9ff4bdb6a38171575d82519b0645
BLAKE2b-256 checksum
How to use checksums
3ca7c78c3725e01bb5b05c46dd2494e6dbdb6aed59d01dca3fcc995ea7b31bd1
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No
Uploaded via twine/4.0.1 CPython/3.9.17

Release files / mbGDML-0.1.1-py3-none-any.whl

Download URL mbGDML-0.1.1-py3-none-any.whl
Size 157.3 kB
Tags Python 3
SHA-256 checksum
How to use checksums
5f17e673ad49d40315a0a43fd3fcac1e259dbef6624fd4d29b2b2e8f44444092
BLAKE2b-256 checksum
How to use checksums
15a2d774c4cf2ef0f7a8ec7f07013fedb3bdd254c489b69b60037f1c0fc58899
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No
Uploaded via twine/4.0.1 CPython/3.9.17

Release history Release notifications | RSS feed

This release

0.1.1 This release

2 release files

0.1.0

2 release files

0.0.4

2 release files

0.0.3

2 release files

0.0.2

1 release file

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