Skip to main content

A Newtonian message passing network for deep learning of interatomic potentials and forces

Project description

NewtonNet

A Newtonian message passing network for deep learning of interatomic potentials and forces

architecture

Installation and Dependencies

We recommend using conda environment to install dependencies of this library. Please install (or load) conda and then proceed with the following commands:

conda create --name newtonnet python=3.12
conda activate newtonnet

Now, you can install NewtonNet in the conda environment by cloning this repository:

git clone https://github.com/THGLab/NewtonNet.git

cd NewtonNet

pip install torch
pip install -e .

Once you finished installations succesfully, you will be able to run NewtonNet modules anywhere on your computer as long as the newtonnet environment is activated. If you have trouble installing torch_geometric, torch_scatter, or torch_cluster, please refer to the PyG documentation page. Optionally, if you want to use Weights & Biases for logging, you can initialize it with

wandb login

Training and Inference

You can find several run files inside the scripts directory that rely on the implemented modules in the NewtonNet library. The run scripts need to be accompanied with a yaml configuration file. You can run an example training script with the following command:

python newtonnet_train.py --config config.yml

or resume a checkpoint of an interupted training with the following command:

python newtonnet_train.py --resume md17_model/training_1

Optionally for large datasets, you might want to process the data on a CPU node with larger memory using:

python preprocess.py --root md17_data/aspirin/ccsd_train

All models are assumed in ASE units, such as eV and Ang. You can call an ASE calculator from newtonnet.utils.ase_interface. An example MD script can be found in simulate.py.

The documentation of the modules are available at most cases. Please look up local classes or functions and consult with the docstrings in the code.

Project details


Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Source Distribution

newtonnet-2.0.1.tar.gz (19.8 kB view details)

Uploaded Source

Built Distribution

If you're not sure about the file name format, learn more about wheel file names.

newtonnet-2.0.1-py3-none-any.whl (25.0 kB view details)

Uploaded Python 3

File details

Details for the file newtonnet-2.0.1.tar.gz.

File metadata

  • Download URL: newtonnet-2.0.1.tar.gz
  • Upload date:
  • Size: 19.8 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/6.1.0 CPython/3.10.14

File hashes

Hashes for newtonnet-2.0.1.tar.gz
Algorithm Hash digest
SHA256 76098c992198eababff8bce2b02566514d302ebce0725b4cc27d574586f1f415
MD5 b67a8b99b9055bde12b2def79387af1e
BLAKE2b-256 28b04256feeebec62547b2a876f3f0bf672f5f40cb53b74aaaa373525a96102d

See more details on using hashes here.

File details

Details for the file newtonnet-2.0.1-py3-none-any.whl.

File metadata

  • Download URL: newtonnet-2.0.1-py3-none-any.whl
  • Upload date:
  • Size: 25.0 kB
  • Tags: Python 3
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/6.1.0 CPython/3.10.14

File hashes

Hashes for newtonnet-2.0.1-py3-none-any.whl
Algorithm Hash digest
SHA256 d03c25e5c9f3a7797aee02b3426532e77396f0ac4b650e23e662e5ac97a810cb
MD5 227903e679278332fa43e9f22e54ea62
BLAKE2b-256 673fabb75a6dec7b6a761aed0016d3eefa86e69b2f3334b28222d4889d0d1012

See more details on using hashes here.

Supported by

AWS Cloud computing and Security Sponsor Datadog Monitoring Depot Continuous Integration Fastly CDN Google Download Analytics Pingdom Monitoring Sentry Error logging StatusPage Status page