This package is a python library with tools for the Molecular Simulation - Software Gromos.

Overview

Welcome to PyGromosTools

CI codecov Language grade: Python DOI Documentation

General

The aim of the module is to bring GROMOS to the Python3 World! This repository should make it easier to work with GROMOS in Python and should enable the user to write cleaner, more reliable and adaptable code.

General informations about functions can be found in our wiki and usage example for many general functions and theire relations are shown in jupyter notebooks in the examples in the example folder.

Content


  • GROMOS wrappers

    • GromosXX wrapper: for simulation execution
    • GromosPP wrapper: for GROMOS++ program usage
  • File handling of all GROMOS file types for automated creation/modification/analysis :

    • coordinate files CNF:

      • read and analyse CNF files
      • generate CNF files from RDKit
      • generate CNF files from SDF
      cnf = Cnf(input_value="file_name")
      print(cnf.GENBOX)
    • topology files:

      • create topologies from a forcefield
        • GROMOS 2016H66 / 54A7
        • OpenForceField
        • SerenityForceField
      • modify topologies
        • add new atoms
        • modify force parameters
      top = Top(input_value="file_path")
      top.add_new_SOLUTEATOM(ATNM=42)
      print(top)
    • simulation parameter files IMD

      • a wide option of templates provided
      • modify IMD files to fit your simulation
      imd = Imd(input_value="file_path")
      imd.INITIALISE.TEMPI = 137
      print(imd)
      
    • trajectories (tre, trc, trg, ...)

      • analyse trajectories with Pandas data frames
      • standard analysis like RSMD, RDF, ... for trc
      • auto saving of results for later use as hdf5
      • ene_ana like tools for tre
      • easy to add costume analysis tools
      trc = Trc(input_value="file_path")
      print(trc.rmsd().mean())
    • replica exchange files: repdat.dat

    • classes for single blocks of each of these files.

  • Automation and file management system gromos_system

    • offers clean file management for simulations
    • offers a high level of automation
    • equiped with simulation queuing system
    • includes many force fields
    ff=forcefield_system(name="openforcefield")
    gsys = Gromos_System(work_folder="dir", in_smiles="C1CCCCC1", auto_convert=True, Forcefield=ff)
    print(gsys)
  • Simulation Submission and Execution :

    • Different Types of Simulation modules, like MD, SD or Emin.
    • Can be executed locally or on a cluster
    • easy to automatize and combine with analysis routines

    Run on a local machine:

    from pygromos.files.gromos_system import Gromos_System
    from pygromos.hpc_queuing.submission_systems.local import LOCAL as subSystem
    from pygromos.simulations.modules.preset_simulation_modules import emin
    
    #define file paths
    root_dir = "./example_files/SD_Simulation"
    root_in_dir = root_dir+"/SD_input"
    cnf_path = root_in_dir+"/6J29_unitedatom_optimised_geometry.cnf"
    top_path = root_in_dir + "/6J29.top"
    sys_name = "6J29"
    
    #Build gromos System:
    grom_system = Gromos_System(in_cnf_path=cnf_path, in_top_path=top_path,
                                system_name=sys_name, work_folder=root_in_dir)
               
    #Run Emin
    emin_gromos_system, jobID = emin(in_gromos_system=grom_system, project_dir=root_dir,
                            step_name=step_name, submission_system=subSystem())
        

    Run on LSF-Cluster:

    from pygromos.files.gromos_system import Gromos_System
    from pygromos.hpc_queuing.submission_systems.lsf import LSF as subSystem
    from pygromos.simulations.modules.preset_simulation_modules import emin
    
    #define file paths
    root_dir = "./example_files/SD_Simulation"
    root_in_dir = root_dir+"/SD_input"
    cnf_path = root_in_dir+"/6J29_unitedatom_optimised_geometry.cnf"
    top_path = root_in_dir + "/6J29.top"
    sys_name = "6J29"
    
    #Build gromos System:
    grom_system = Gromos_System(in_cnf_path=cnf_path, in_top_path=top_path,
                            system_name=sys_name, work_folder=root_in_dir)
             
    #Run Emin
    sub_system = subSystem(nmpi=4) #allows parallelization
    emin_gromos_system, jobID = emin(in_gromos_system=grom_system, project_dir=root_dir,
                          step_name=step_name, submission_system=sub_system)
      
  • Other utilities:

    • Bash wrappers for GROMOS
    • Amino acid library

General Information

Specifications

  • Python >=3.7:

  • requires: numpy, scipy, pandas, rdkit

  • optional: openforcefield for OpenForceField and Serenityff functions

SETUP

see INSTALL.md file for more informations

Copyright

Copyright (c) 2020, Benjamin Ries, Marc Lehner, Salome Rieder

Acknowledgements

Project based on the Computational Molecular Science Python Cookiecutter version 1.3.

Comments
  • Release3

    Release3

    Release 3 PR

    Content

    -All the developments of the recent months

    • Solvation
    • rework subSys
    • Improved Gromos_System
    • Bug fixes
    • More Gromos++ Wrappers

    TODOS

    • [x] Gromos-Day
    • [x] Solvation
    • [x] Project-Release 3
    • [x] Final clean-up
    Done 
    opened by MTLehner 21
  • GromosBinaryDetectionChangedLocation

    GromosBinaryDetectionChangedLocation

    This is a slight modification to @pultars nice binary directoy changes. Mainly I changed the location of the test and moved it from the gromos system to the Gromos classes in a way, the test can not be circumvented, except explicitly stated. :)

    • [x] Ready to go
    enhancement in progress 
    opened by RiesBen 19
  • PyGromosToolsDay

    PyGromosToolsDay

    Presentation for the PyGromosToolsDay

    Content and Discussions

    1. Current State and Features
    2. Overview over new tools
    3. Release 3
      1. Bug fixes
      2. Restructuring
      3. new features
    4. Final Discussions
    documentation enhancement in progress 
    opened by MTLehner 17
  • Trajectory update trc

    Trajectory update trc

    Description

    Update of TRC using mdtraj.

    Todos

    Notable points that this PR has either accomplished or will accomplish.

    • [x] Write Tests - in progress
    • [x] Include more mdtraj functionality
    • [x] Create dummy topology
    • [x] Refactoring
    • [x] Example notebook visualization
    • [x] Change Cnf to also use nglview
    • [x] Make future promisable
    • [x] Test with gromosSystem
    • [x] Write TRC
    • [x] Load h5 and hdf5
    enhancement feature in progress 
    opened by katzberger 16
  • Minor moving bug fixes

    Minor moving bug fixes

    This branch contains my expirience with Euler and the submission system

    This pull request grew a bit beyond! So it's time to merge !

    Features:

    • minor bug fixes for submission system
    • visualization
    • doc update
    • more testing
    • [x] Ready To Go
    opened by RiesBen 15
  • WIP: Ptp generation

    WIP: Ptp generation

    Description

    This merge should help

    Todos

    Notable points that this PR has either accomplished or will accomplish.

    • [x] add PTP - PERTPROPERDIH Block
    • [x] add functions for ptp generation

    Status

    • [ ] Ready to go
    opened by RiesBen 12
  • ff rework

    ff rework

    Description

    Rework of the forcefield structure in PyGromos

    Introducing a generic_forcfield and all other forcefield have this class as super. This makes code more readable and unifies the structure.

    feature in progress cleaning 
    opened by MTLehner 10
  • examples: TI

    examples: TI

    In the TI example notebook examples/example_TI_gromos_simulation.ipynb, the file /examples/example_files/TI_Calculation/TI_input/M030_6KET.disres is specified, but this file isn't in the repository. This leads to the following error:

    ---------------------------------------------------------------------------
    OSError                                   Traceback (most recent call last)
    <ipython-input-13-14f2d2d90c97> in <module>
          6 grom_system = Gromos_System(in_cnf_path=cnf_path, in_top_path=top_path,
          7                             in_disres_path=disres_path,
    ----> 8                             system_name=sys_name, work_folder=input_dir)
          9 
         10 
    
    /cluster/work/igc/wsalome/anaconda3/envs/pygromos/lib/python3.7/site-packages/PyGromos-0+untagged.176.g9b9886d-py3.7.egg/pygromos/files/gromos_system/gromos_system.py in __init__(self, work_folder, system_name, in_smiles, in_top_path, in_cnf_path, in_imd_path, in_disres_path, in_ptp_path, in_posres_path, in_refpos_path, in_gromosXX_bin_dir, in_gromosPP_bin_dir, rdkitMol, readIn, Forcefield, auto_convert, adapt_imd_automatically, verbose)
        136                         "refpos": in_refpos_path,
        137                         }
    --> 138         self.parse_attribute_files(file_mapping, readIn=readIn, verbose=verbose)
        139 
        140         ##System Information:
    
    /cluster/work/igc/wsalome/anaconda3/envs/pygromos/lib/python3.7/site-packages/PyGromos-0+untagged.176.g9b9886d-py3.7.egg/pygromos/files/gromos_system/gromos_system.py in parse_attribute_files(self, file_mapping, readIn, verbose)
        523         [check_file_paths.append(x) for k, x in file_mapping.items() if (not x is None)]
        524         if (len(check_file_paths) > 0):
    --> 525             bash.check_path_dependencies(check_file_paths, verbose=verbose)
        526 
        527         # SET Attribute-FILES
    
    /cluster/work/igc/wsalome/anaconda3/envs/pygromos/lib/python3.7/site-packages/PyGromos-0+untagged.176.g9b9886d-py3.7.egg/pygromos/utils/bash.py in check_path_dependencies(check_required_paths, check_warn_paths, verbose)
        123         print("\n==================\nAUTSCH\n==================\n")
        124         missing_str = "\n\t".join(map(str, missing))
    --> 125         raise IOError("COULD NOT FIND all DEPENDENCY!\n\t Could not find path to: \n\t" + str(missing_str), "\n\n")
        126     elif verbose:
        127         print("All dependencies are correct!", "\n\n")
    
    OSError: [Errno COULD NOT FIND all DEPENDENCY!
    	 Could not find path to: 
    	./example_files/TI_Calculation/TI_input/M030_6KET.disres] 
    

    @SchroederB I think you originally wrote this tutorial. Do you still have the file on one of your local branches?

    tutorial/exampes 
    opened by SalomeRonja 10
  • WIP:Pymaketop

    WIP:Pymaketop

    Description

    • restructuring forcefield class in pygromos and making a generic-ff class from which others inherit to remove code duplication and make the usage of ffs more clear.
    • adding a python version of make_top to the gromosff class to create topologies in python

    Todos

    a lot

    feature in progress 
    opened by MTLehner 9
  • Improve speed of unit tests

    Improve speed of unit tests

    Can we improve the speed of the unit test?

    A few points possible points:

    • [x] reduce size of trajectories
      • [x] trc
      • [x] tre
      • [x] trg (seem to take the longest)
    • [x] remove unnecessary dependencies from conda incubator
    • [x] TI submission
    • [x] dummy submissions
    enhancement question in progress testing 
    opened by MTLehner 9
  • Qmmm functionality and more gromos++ wrapper functions

    Qmmm functionality and more gromos++ wrapper functions

    Description

    More gromos++ functions are wrapped (sasa, filter). There was also a minor bug in the way rgyr is wrapped.

    In addition, qmmm blocks are now supported in imd files. An example notebook is provided with example files. It is also planned to support qmmm specification files and for that purpose some code has been copy/pasted in place.

    enhancement feature in progress 
    opened by pultar 8
  • changes to the RE-EDS and EDS blocks

    changes to the RE-EDS and EDS blocks

    Removed duplicate code from a fix a long time ago (RE-EDS block no longer having the ALPHALJ / ALPHAC) parameters. I also tweaked the EDS block so it is compatible with the current up to date gromosXX code. Added a comment in the electrostatics block to account for the recent work from Salomé.

    Status

    • [ ] Ready to go
    opened by candidechamp 0
  • Add CodeQL workflow for GitHub code scanning

    Add CodeQL workflow for GitHub code scanning

    Hi rinikerlab/PyGromosTools!

    This is a one-off automatically generated pull request from LGTM.com :robot:. You might have heard that we’ve integrated LGTM’s underlying CodeQL analysis engine natively into GitHub. The result is GitHub code scanning!

    With LGTM fully integrated into code scanning, we are focused on improving CodeQL within the native GitHub code scanning experience. In order to take advantage of current and future improvements to our analysis capabilities, we suggest you enable code scanning on your repository. Please take a look at our blog post for more information.

    This pull request enables code scanning by adding an auto-generated codeql.yml workflow file for GitHub Actions to your repository — take a look! We tested it before opening this pull request, so all should be working :heavy_check_mark:. In fact, you might already have seen some alerts appear on this pull request!

    Where needed and if possible, we’ve adjusted the configuration to the needs of your particular repository. But of course, you should feel free to tweak it further! Check this page for detailed documentation.

    Questions? Check out the FAQ below!

    FAQ

    Click here to expand the FAQ section

    How often will the code scanning analysis run?

    By default, code scanning will trigger a scan with the CodeQL engine on the following events:

    • On every pull request — to flag up potential security problems for you to investigate before merging a PR.
    • On every push to your default branch and other protected branches — this keeps the analysis results on your repository’s Security tab up to date.
    • Once a week at a fixed time — to make sure you benefit from the latest updated security analysis even when no code was committed or PRs were opened.

    What will this cost?

    Nothing! The CodeQL engine will run inside GitHub Actions, making use of your unlimited free compute minutes for public repositories.

    What types of problems does CodeQL find?

    The CodeQL engine that powers GitHub code scanning is the exact same engine that powers LGTM.com. The exact set of rules has been tweaked slightly, but you should see almost exactly the same types of alerts as you were used to on LGTM.com: we’ve enabled the security-and-quality query suite for you.

    How do I upgrade my CodeQL engine?

    No need! New versions of the CodeQL analysis are constantly deployed on GitHub.com; your repository will automatically benefit from the most recently released version.

    The analysis doesn’t seem to be working

    If you get an error in GitHub Actions that indicates that CodeQL wasn’t able to analyze your code, please follow the instructions here to debug the analysis.

    How do I disable LGTM.com?

    If you have LGTM’s automatic pull request analysis enabled, then you can follow these steps to disable the LGTM pull request analysis. You don’t actually need to remove your repository from LGTM.com; it will automatically be removed in the next few months as part of the deprecation of LGTM.com (more info here).

    Which source code hosting platforms does code scanning support?

    GitHub code scanning is deeply integrated within GitHub itself. If you’d like to scan source code that is hosted elsewhere, we suggest that you create a mirror of that code on GitHub.

    How do I know this PR is legitimate?

    This PR is filed by the official LGTM.com GitHub App, in line with the deprecation timeline that was announced on the official GitHub Blog. The proposed GitHub Action workflow uses the official open source GitHub CodeQL Action. If you have any other questions or concerns, please join the discussion here in the official GitHub community!

    I have another question / how do I get in touch?

    Please join the discussion here to ask further questions and send us suggestions!

    opened by lgtm-com[bot] 0
  • Consistent indices in PyGromos

    Consistent indices in PyGromos

    GROMOS starts counting from "1" in topologies (and other places). However, sometimes atom indices are 0 indexed (for example functions that use mdtraj). We should make this more consistent before too many people use functions.

    I think we should stick to GROMOS convention and start everywhere from "1".

    @MTLehner ideas?

    documentation cleaning 
    opened by pultar 0
  • replica exchange simulation submission + minor reeds tweaks

    replica exchange simulation submission + minor reeds tweaks

    I reimplemented (and re-tested) the changes in #222 (as I didn't want to have trouble with merge conflicts, although they all seemed super minor and would have been easily fixed).

    The code in here is essentially the same as in #222 with the exception of some imd related functions, where I simplified a call to str2bool (previously was put in an if, else block based on input given to function, which already happens in the function).

    To do

    • [ ] Pre-commit passed

    Status

    • [ ] Ready to go

    PS: Please don't delete the pygromos3_for_reeds branch after merge. I would like to keep this branch in parallel at all times (and probably also have a "release" for it so that there is an easily accessible version for RE-EDS users once I have implemented all I need to).

    opened by candidechamp 2
  • PyMakeTop

    PyMakeTop

    PyMakeTop

    Content

    With the new addition of the mtb files a python version of make_top should be possible. The resnames are already stored in a dict after the mtb parsing.

    TODOs

    • [ ] Option to just call the resname and get back a top
      • [ ] parse all mtb blocks to top blocks
      • [ ] add solvent
    • [ ] Option to pass a rdkit molecule (matching to a resname) and get a gromos topology
      • [ ] all of the above
      • [ ] mtb -> rdkit mol or smiles parser from atoms and bond blocks
    • [ ] Option to pass a rdkit molecule (any) and get a gromos topology
      • [ ] all of the above
      • [ ] fragment based matching
    enhancement feature in progress 
    opened by MTLehner 0
Releases(v3.0)
  • v3.0(Apr 6, 2022)

    Release 3

    Major changes

    • QM/MM support
    • Solvation free energy approach
    • rework of the submission systems
    • rework of the forcfield system
    • rework of the trajectory classes
    • addition of a logo
    • addition of pre-commit and code-standards

    Minor changes

    • Simplification and cleanup of gromos_system class
    • mtb file class support
    • more GROMOS++ wrappers
    • rework of the python classes for GROMOS
    • better typing
    • more documentation
    • better example notebooks
    • and of course some more bug fixes

    Acknowledgments

    Benjamin Ries, Marc Lehner, Salome Rieder, Felix Pultar, Paul Katzberger, Candide Champion, Robin Wolf

    Source code(tar.gz)
    Source code(zip)
  • v2.1(May 28, 2021)

  • v2.0(May 28, 2021)

  • v1.0.0(Mar 19, 2021)

    This release is used by the reeds repository. It is not further developed please and definetly not perfect. Please use the main branch if you want to have the newest features of PyGromosTools.

    We generate this release for backwards compatibility with the reeds repository.

    Source code(tar.gz)
    Source code(zip)
The (Python-based) mining software required for the Game Boy mining project.

ntgbtminer - Game Boy edition This is a version of ntgbtminer that works with the Game Boy bitcoin miner. ntgbtminer ntgbtminer is a no thrills getblo

Ghidra Ninja 31 Nov 4, 2022
An interactive TLS-capable intercepting HTTP proxy for penetration testers and software developers.

mitmproxy mitmproxy is an interactive, SSL/TLS-capable intercepting proxy with a console interface for HTTP/1, HTTP/2, and WebSockets. mitmdump is the

mitmproxy 29.7k Jan 2, 2023
This is a simple software for fetching new changes to remote repositories automatically.

Git Autofetch Git Autofetch is a simple software for fetching new changes from a repo to local repositories after a set time interval. This program is

Shreyas Ashtamkar 10 Jul 21, 2022
Python tools for penetration testing

pyTools_PT python tools for penetration testing Please don't use these tool for illegal purposes. These tools is meant for penetration testing for leg

Gourab 1 Dec 1, 2021
A Python Selenium library inspired by the Testing Library

Selenium Testing Library Slenium Testing Library (STL) is a Python library for Selenium inspired by Testing-Library. Dependencies Python 3.6, 3.7, 3.8

Anže Pečar 12 Dec 26, 2022
fsociety Hacking Tools Pack – A Penetration Testing Framework

Fsociety Hacking Tools Pack A Penetration Testing Framework, you will have every script that a hacker needs. Works with Python 2. For a Python 3 versi

Manisso 8.2k Jan 3, 2023
PENBUD is penetration testing buddy which helps you in penetration testing by making various important tools interactive.

penbud - Penetration Tester Buddy PENBUD is penetration testing buddy which helps you in penetration testing by making various important tools interac

Himanshu Shukla 15 Feb 1, 2022
Avocado is a set of tools and libraries to help with automated testing.

Welcome to Avocado Avocado is a set of tools and libraries to help with automated testing. One can call it a test framework with benefits. Native test

Ana Guerrero Lopez 1 Nov 19, 2021
A collection of benchmarking tools.

Benchmark Utilities About A collection of benchmarking tools. PYPI Package Table of Contents Using the library Installing and using the library Manual

Kostas Georgiou 2 Jan 28, 2022
Faker is a Python package that generates fake data for you.

Faker is a Python package that generates fake data for you. Whether you need to bootstrap your database, create good-looking XML documents, fill-in yo

Daniele Faraglia 15.2k Jan 1, 2023
Aioresponses is a helper for mock/fake web requests in python aiohttp package.

aioresponses Aioresponses is a helper to mock/fake web requests in python aiohttp package. For requests module there are a lot of packages that help u

null 402 Jan 6, 2023
Python package to easily work with selenium and manage tabs effectively.

Simple Selenium The aim of this package is to quickly get started with working with selenium for simple browser automation tasks. Installation Install

Vishal Kumar Mishra 1 Oct 27, 2021
Thin-wrapper around the mock package for easier use with pytest

pytest-mock This plugin provides a mocker fixture which is a thin-wrapper around the patching API provided by the mock package: import os class UnixF

pytest-dev 1.5k Jan 5, 2023
Selenium-python but lighter: Helium is the best Python library for web automation.

Selenium-python but lighter: Helium Selenium-python is great for web automation. Helium makes it easier to use. For example: Under the hood, Helium fo

Michael Herrmann 3.2k Dec 31, 2022
A utility for mocking out the Python Requests library.

Responses A utility library for mocking out the requests Python library. Note Responses requires Python 2.7 or newer, and requests >= 2.0 Installing p

Sentry 3.8k Jan 3, 2023
A utility for mocking out the Python Requests library.

Responses A utility library for mocking out the requests Python library. Note Responses requires Python 2.7 or newer, and requests >= 2.0 Installing p

Sentry 3.1k Feb 8, 2021
A command-line tool and Python library and Pytest plugin for automated testing of RESTful APIs, with a simple, concise and flexible YAML-based syntax

1.0 Release See here for details about breaking changes with the upcoming 1.0 release: https://github.com/taverntesting/tavern/issues/495 Easier API t

null 909 Dec 15, 2022
Python version of the Playwright testing and automation library.

?? Playwright for Python Docs | API Playwright is a Python library to automate Chromium, Firefox and WebKit browsers with a single API. Playwright del

Microsoft 7.8k Jan 2, 2023