Skip to main content

This module can be used to analyse the Phi and Psi dihedral (or torsion) angle distribution in a protein structural ensemble (e.g., from Chemical-Shift-Rosetta), define potential energy functions (PEFs), and replace the original dihedral energy terms in GROMACS for molecular dynamics (MD) simulations.

Project description

Ensembe-Driven Molecular Dynamics (EDMD)

This module can be used to analyse the Phi and Psi dihedral (or torsion) angle distribution in a protein structural ensemble (e.g., from Chemical-Shift-Rosetta), define potential energy functions (PEFs), and replace the original dihedral energy terms in GROMACS for molecular dynamics (MD) simulations.

  1. You need an ensemble of individual PDB files (e.g. from CS-Rosetta) and "name.scores.txt" stored in a directory, e.g. "ExtractedPDBs". The "name.scores.txt" file should contain the filenames and belonging scores.

  2. Set up the system for the MD simulation from the very best structure in the ensemble. This will be your e.g. "protein.gro" file.

  3. Set your configuration in the "EDMD_config.json" file.

  4. Run the EDMD modul. This is a pipeline to run "save_dihedrals.py", "fit_dihedrals.py" and "create_tables.py". Optionally it can also call "visualize_dihedrals.py" and "visualize_pef.py" if "VISUALIZE": True in the JSON.

  5. The new files for the simulation will be written in a folder called "for_gmx" within the "GMX_FOLDER". When running the simulation you can use the NEW.TOP as a topology file for gmx grompp -p and use the tabulated potentials for gmx mdrun -tableb tables_of_potentials/table_d*.xvg.

How to install?

Requirements: Python ≥ 3.10

Start by updating the pip version:

python3 -m pip install --upgrade pip

Install the EDMD_package:

python3 -m pip install EDMD_package

EDMD_config.json file

  • ExtractedPDBs_FOLDER: str Path of the "ExtractedPDBs" folder with the individual PDB files of the ensemble and a "name.scores.txt" containing model names and Rosetta-scores.

  • GMX_FOLDER: str Path of the folder, where you have your GRO and processed TOP files.

  • RESI_IDX_SHIFT: int Shift the residue numbering (if it was e.g. trimmed).

  • VISUALIZE: bool Set True, if you want to run the visualize_dihedrals.py and visualize_pef.py scripts as well.

  • SCORE_SCALE: float or int Set to scale the Rosetta-score for weighting during the PEF definition.

  • TEMPERATURE: float or int Temperature of your simulation in Kelvin. Needed for the Boltzmann-inversion during the PEF definition.

  • GRO_FILENAME: str Name of your GRO file ("e.g. protein.gro"), which is ready for the simulation, so is solvated, etc.

  • PROCESSED_TOP_FILENAME: str Name of you processed TOP file (e.g. "protein_processed.top"), created e.g. by gmx grompp -pp flag in gromacs.

How to use?

If you have set the EDMD_config.json , you can simply call:

python3 -m EDMD_package -c {path_to_JSON}

You can also call individual scripts:

python3 -m EDMD_package -c {path_to_JSON} -fn {name_of_script}

Individual scripts

save_dihedrals.py The dihedral angles in your ensemble will be measured and saved to a pickle.

fit_dihedrals.py The probability density functions (PDF) will be defined for each backbone dihedral angle, according to the dihedral angle distributions using kernel density estimation. Finally, the PEFs will be created.

create_tables.py You need to have a ".gro" file and a "_processed.top" file about your solvated system. By running this script you will get a "_processed_new.top" file, which you should use as a topology file for your GROMACS MD simulation.

visualize_dihedrals.py Optionally, you can prepare figures about the dihedral angle distribution for every residue.

visualize_pef.py You can look at the angle distributions and the PEFs in case of each residue.

format_scores_csrosetta If you e.g. run CS-Rosetta locally, and the models are already rescored (e.g. by running score_jd2 of Rosetta3) and you have a "score.cs" file, you can call this script to format the model names and scores to generate "name.scores.txt". Later "save_dihedrals.py" can read "name.scores.txt" and "fit_dihedrals.py" can use the Rosetta-score for weighting. The CS-Rosetta server generates this output automatically.

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

edmd_package-2.0.6.tar.gz (14.4 kB view details)

Uploaded Source

Built Distribution

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

edmd_package-2.0.6-py3-none-any.whl (17.1 kB view details)

Uploaded Python 3

File details

Details for the file edmd_package-2.0.6.tar.gz.

File metadata

  • Download URL: edmd_package-2.0.6.tar.gz
  • Upload date:
  • Size: 14.4 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/6.1.0 CPython/3.10.8

File hashes

Hashes for edmd_package-2.0.6.tar.gz
Algorithm Hash digest
SHA256 132e41f8ef3ec15f10b8dfd87bdd2c1a00c89b39cbf8293ee61997ee526e9ffb
MD5 a3e4e8d1b1613d76e4399b6d9861ed55
BLAKE2b-256 dfc82a65b2cf6591390328cb36adc3d2324eef9e69c3ef01b6fcc9c33044c309

See more details on using hashes here.

File details

Details for the file edmd_package-2.0.6-py3-none-any.whl.

File metadata

  • Download URL: edmd_package-2.0.6-py3-none-any.whl
  • Upload date:
  • Size: 17.1 kB
  • Tags: Python 3
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/6.1.0 CPython/3.10.8

File hashes

Hashes for edmd_package-2.0.6-py3-none-any.whl
Algorithm Hash digest
SHA256 a0a86c6494b4aaae69e72ffd05b71addc0fd0b52f3e26cce00eb7a092a9fb6d9
MD5 510a4a3e99466ed2336d87fbc00fa749
BLAKE2b-256 91271ea5abe9d49a23602dc181c2382814d9ff212442514fe8dc4234bc1882ee

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