Skip to content

PLUMED 2.10.1 - User Guide

Cluster: XLence (UNIMI Dipartimento di Scienze Farmacologiche e Biomolecolari) Date: September 30, 2026 Installation: /sw/plumed/2.10.1/ (one build for login and compute nodes)


πŸ“¦ Version Information

PLUMED: 2.10.1 (latest stable release, July 2026), all modules MPI: OpenMPI 4.1.6 PyTorch CVs: LibTorch 2.13.0 (C++, CPU) in /sw/libtorch/2.13.0-cpu Trajectory formats: all VMD molfile plugins (Amber NetCDF, DCD, XTC, TRR, PDB, ...) GSL: 2.7.1 FFTW: 3.3.10

It does not depend on any Python environment.

Available versions

Module Notes
plumed/2.10.1 default: use this one, with amber/26 and gromacs/2025.0
plumed/2.9 the previous version

πŸš€ Loading the Module

module load plumed           # plumed/2.10.1

# Verify
plumed info --version        # 2.10
echo $PLUMED_KERNEL          # /sw/plumed/2.10.1/lib/libplumedKernel.so

The module sets PLUMED_KERNEL, which programs that load PLUMED at run time use (Amber 26, and the plumed Python package).


πŸ’» Integration with MD Codes

AMBER 26

Integration: loaded at run time through PLUMED_KERNEL

module load amber plumed

Enable it in the &cntrl namelist of the MD input (there is no -plumed command-line option):

 &cntrl
  ...
  plumed=1, plumedfile='plumed.dat',
 /
pmemd.cuda -O -i md.in -p system.prmtop -c input.rst -o md.out -r md.rst -x md.nc

Works with pmemd.cuda, pmemd, pmemd.MPI and sander.

GROMACS 2025.0

Integration: patched with PLUMED 2.10.1, kernel loaded at run time through PLUMED_KERNEL

module load gromacs          # gromacs/2025.0, also loads plumed/2.10.1
gmx_mpi mdrun -v -deffnm md -plumed plumed.dat

Multiple walkers and replica exchange (-multidir, -replex) need the same nsteps in every simulation; with -replex, PLUMED can print but not bias. See GROMACS.


πŸ“– Example PLUMED Input Files

1. Distance Restraint

# plumed.dat - Monitor distance between atoms 1 and 10
d1: DISTANCE ATOMS=1,10

# Add harmonic restraint
RESTRAINT ARG=d1 AT=0.5 KAPPA=100.0

# Print every 100 steps
PRINT ARG=d1 FILE=COLVAR STRIDE=100

2. Metadynamics

# Define collective variable
phi: TORSION ATOMS=5,7,9,15
psi: TORSION ATOMS=7,9,15,17

# Metadynamics
METAD ARG=phi,psi SIGMA=0.2,0.2 HEIGHT=1.2 PACE=500 FILE=HILLS

# Print
PRINT ARG=phi,psi FILE=COLVAR STRIDE=100

3. Umbrella Sampling

# Distance
d1: DISTANCE ATOMS=1,100

# Umbrella potential
RESTRAINT ARG=d1 AT=1.0 KAPPA=1000.0

# Print
PRINT ARG=d1 FILE=COLVAR STRIDE=10

4. Coordination Number

# Coordination number
c1: COORDINATION GROUPA=1-10 GROUPB=11-50 R_0=0.3 NN=6 MM=12

# Moving restraint
MOVINGRESTRAINT ARG=c1 STEP0=0 AT0=5.0 KAPPA0=100.0 STEP1=100000 AT1=10.0 KAPPA1=100.0

PRINT ARG=c1 FILE=COLVAR STRIDE=100

5. PyTorch Collective Variables

d1: DISTANCE ATOMS=1,10
d2: DISTANCE ATOMS=5,20

# A model exported with TorchScript (e.g. from mlcolvar), taking d1 and d2 as inputs
cv: PYTORCH_MODEL FILE=model.ptc ARG=d1,d2
PRINT ARG=cv.node-0 FILE=COLVAR STRIDE=100

PLUMED evaluates these models on the CPU.


πŸ”§ PLUMED Standalone Tools

Driver (Reprocess Trajectories)

module load plumed

# Amber NetCDF trajectory
plumed driver --plumed plumed.dat --mf_netcdf traj.nc

# GROMACS trajectory
plumed driver --plumed plumed.dat --mf_xtc traj.xtc --trajectory-stride 10

The --mf_ options are named after the VMD plugins, not after the file extensions. To list them all:

plumed driver --help | grep -o -- "--mf_[A-Za-z0-9_]*"

Sum Hills (Free Energy from Metadynamics)

plumed sum_hills --hills HILLS --outfile fes.dat

Python Interface

The installation has no Python bindings. Install them in your own environment, and point them at this kernel:

module load plumed
pip install plumed           # in your own conda/venv environment

python3 << 'EOF'
import plumed

# Uses the kernel in $PLUMED_KERNEL
p = plumed.Plumed()
p.cmd("setNatoms", 10)
p.cmd("init")
p.cmd("readInputLine", "d: DISTANCE ATOMS=1,10")
p.cmd("readInputLine", "PRINT ARG=d FILE=output.dat")
EOF

πŸ“Š Analysis Examples

Extract Free Energy Surface

# From metadynamics HILLS file
plumed sum_hills --hills HILLS --outfile fes_phi_psi.dat

# For 1D:
plumed sum_hills --hills HILLS --outfile fes_phi.dat --idw phi

# Plot with gnuplot
gnuplot << 'EOF'
set pm3d
set palette defined (0 "blue", 1 "white", 2 "red")
splot "fes_phi_psi.dat" u 1:2:3 w pm3d
EOF

πŸ› Troubleshooting

Amber: "+++ ERROR: You are trying to use an invalid plumed object. +++"

  • module load plumed was not run, so PLUMED_KERNEL is not set

"Unknown action in input"

  • Check PLUMED version: plumed info --version
  • Check available actions: plumed info --list-actions

"Atom index out of bounds"

  • Verify atom indices in your system
  • PLUMED uses 1-based indexing

πŸ“š Documentation

Local: - Build, validation and choices: /sw/plumed/2.10.1/README-xlence.md

Online: - PLUMED Manual: https://www.plumed.org/doc-v2.10/user-doc/html/ - Masterclass: https://www.plumed.org/masterclass - NEST (collective variables library): https://www.plumed-nest.org/

Mailing List: - https://groups.google.com/g/plumed-users


πŸ“ Citation

Tribello, G.A., Bonomi, M., Branduardi, D., Camilloni, C., Bussi, G. PLUMED 2: New feathers for an old bird Computer Physics Communications 185, 604 (2014)


πŸ”„ Integration Summary

MD Code PLUMED How to Use
AMBER 26 2.10.1, at run time module load amber plumed, plumed=1 in &cntrl
GROMACS 2025.0 2.10.1, patched, at run time module load gromacs, gmx_mpi mdrun -plumed plumed.dat

For questions contact: Cluster administrators Installation: September 30, 2026 Installed by: Claude Code + Uliano Guerrini