omniMD: Omnipotent Molecular Dynamics is a versatile simulation engine designed to bridge the dimensional gap in unbiased molecular interactions by leveraging machine learning-based interatomic potentials.
omniMD provides a solid foundation for developing new simulation algorithms and methods. It allows users to fully customize the behavior of algorithms during a simulation. Whether you are adding a new force field, customizing Monte Carlo moves, or implementing new molecular dynamics integrators, the process is straightforward and well-documented.
Our primary goals for omniMD are flexibility, reliability, and extensibility. Specifically, this means the software is:
- Flexible: Capable of simulating a wide variety of systems—from proteins to crystals—using diverse methods such as molecular dynamics and Monte Carlo algorithms.
- Reliable: Rigorously tested at both the function level and the simulation level to ensure the accuracy of the systems' thermodynamic properties.
- Extensible: Designed with a modular, object-oriented, and open-source architecture that is highly readable and easy to build upon.
omniMD is under active development and should currently be considered alpha software. If you are interested in the project, have questions, or would like to contribute, please feel free to open a GitHub issue.
- Pair, molecular and electrostatic interactions (with Ewald or Wolf methods);
- Energy minimization;
- Molecular dynamics simulations in the NVE, NVT and NPT ensembles;
- Monte Carlo simulations in the NVT ensemble;
- and many others! Have a look at the documentation for more information
omniMD provides both a command line tool for running simulations; and a Rust library for writing your own simulations algorithms using the pre-existing building blocks.
Documentation is hosted on Github Pages, and separated in multiple parts:
- The user manual contains information about the general concepts of systems and simulations used in omniMD. Additionally, it has tutorials on how to use and extend omniMD. Use this documentation if you want to know basic concepts and how they are used in omniMD.
- The input reference contains information about - well, the input file system of omniMD. Use this document if you want to use omniMD as a command line tool without writing code.
- To use omniMD as a library inside your own code, we have a developer documentation, which contains documentation for all the library public functions, and examples for most of them.
omniMD requires the following dependencies:
- Rust: Latest stable version recommended.
- LibTorch: The C++ frontend for PyTorch (required for ML potentials).
omniMD uses tch-rs bindings. You must have LibTorch available.
To utilize your GPU (e.g., RTX 5080) with CUDA 12.9 support, we recommend using the following build.
-
Install PyTorch (Python) with CUDA 12.9: Run the following command as recommended:
pip install torch torchvision --index-url https://download.pytorch.org/whl/cu129
-
Download matching LibTorch C++ Library: You must download the LibTorch C++ library that corresponds to the installed PyTorch version.
- Go to pytorch.org.
- Ensure the version matches the PyTorch version installed above (check
python -c "import torch; print(torch.__version__)"). - Please download the cxx11 ABI version if you are on Linux and rely on gcc > 5.
- Important: Since we are using cutting-edge features/versions,
omnimd-corepoints to the latesttch-rsgit repository to ensure compatibility.
-
Extract the downloaded
libtorcharchive. -
Set the
LIBTORCHenvironment variable to the extracted path. -
Add the
libsubdirectory to your systemPATH(Windows) orLD_LIBRARY_PATH(Linux/macOS).
You can install omniMD directly from the source code:
# 1. Clone the repository
git clone https://github.com/TANG-LAB-WHU/omniMD.git
cd omniMD
# 2. Set Environment Variables (Example for PowerShell)
# Assume LibTorch is extracted to C:\libtorch
$env:LIBTORCH = "C:\libtorch"
$env:PATH = "$env:LIBTORCH\lib;$env:PATH"
# 2. Set Environment Variables (Example for Bash)
# export LIBTORCH=/path/to/libtorch
# export LD_LIBRARY_PATH=${LIBTORCH}/lib:$LD_LIBRARY_PATH
# 3. Install via Cargo
cargo install --path .This will compile the project and install the omnimd binary to your Cargo bin directory (usually ~/.cargo/bin).
You can add omniMD as a dependency in your project's Cargo.toml:
[dependencies]
omnimd = {path = "/path/to/omnimd"}A tutorial about how to implement new algorithms in omniMD is coming.
If you want to contribute to omniMD, there are several ways to go: improving the documentation and helping with language issues; testing the code on your systems to find bugs; adding new algorithms and potentials; providing feature requests. providing feature requests. Please open an issue to discuss improvements.
This software is licensed under the MIT license, see the LICENSE file for legal text.
Unless you explicitly state otherwise, any contribution intentionally submitted for inclusion in the work by you, shall be licensed under the same MIT license, without any additional terms or conditions.