Python package for efficient analysis of HILLS files generated by Plumed metadynamics simulations.
Project description
metadynminer.py
Metadynminer is a package designed to help you analyse output HILLS files from PLUMED metadynamics simulations.
It is inspired by existing Metadynminer package for R. It supports HILLS files with one, two or three collective variables.
All built-in functions can be customized with many parameters. You can learn more about that in the documentation. There are also other predefined functions allowing you to for example to enhance your presentation with animations of your 3D FES or remove a CV from existing FES.
Quickstart: run in Binder
Click the icon bellow and wait (couple of minutes) for the container to build and started on public MyBinder.
Alternatively, for Metacentrum users, somewhat better resources are available:
Once in the Jupyterlab environment, upload your HILLS
file and start the python_metadynminer.ipynb
notebook.
Installation:
pip install metadynminer
or
conda install -c jan8be metadynminer
Sample code:
Load metadynminer:
import metadynminer
Load your HILLS file:
hillsfile = metadynminer.Hills(name="HILLS")
Compute the free energy surface using the fast Bias Sum Algorithm:
fes = metadynminer.Fes(hillsfile)
You can also use slower (but exact) algorithm to sum the hills and compute the free energy surface with the option original=True. This algorithm was checked and it gives the same result (to the machine level precision) as the PLUMED sum_hills function (for plumed v2.8.0).
fes2 = metadynminer.Fes(hillsfile, original=True)
Visualize the free energy surface:
fes.plot()
Visualize and save the picture to a file:
fes.plot(png_name="fes.png")
Find local minima on the FES, print them and save FES with minima as a picture:
minima = metadynminer.Minima(fes)
print(minima.minima)
minima.plot()
You can also plot free energy profile to see, how the differences between each minima were evolving during the simulation. Convergence in the free energy profile suggests that the resulting free energy surface converged to correct values.
fep = metadynminer.FEProfile(minima, hillsfile)
fep.plot()
Project details
Release history Release notifications | RSS feed
Download files
Download the file for your platform. If you're not sure which to choose, learn more about installing packages.
Source Distribution
File details
Details for the file metadynminer-0.8.3.tar.gz
.
File metadata
- Download URL: metadynminer-0.8.3.tar.gz
- Upload date:
- Size: 46.2 kB
- Tags: Source
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/3.8.0 colorama/0.4.4 importlib-metadata/4.6.4 keyring/23.5.0 pkginfo/1.8.2 readme-renderer/34.0 requests-toolbelt/0.9.1 requests/2.31.0 rfc3986/1.5.0 tqdm/4.64.1 urllib3/1.26.5 CPython/3.10.12
File hashes
Algorithm | Hash digest | |
---|---|---|
SHA256 | 668bbdb9ad9aea50a93c47c9868f876c84741f701e0cff9a645193d3dc238dc5 |
|
MD5 | 466de28cadfc21ae8ee12176b0683a30 |
|
BLAKE2b-256 | 55ec56fd9be27996426ab00e474c4b28904855c25b41c6437bb596454645cffc |