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)
Python Rest Testing

pyresttest Table of Contents What Is It? Status Installation Sample Test Examples Installation How Do I Use It? Running A Simple Test Using JSON Valid

Sam Van Oort 1.1k Dec 28, 2022
A python bot using the Selenium library to auto-buy specified sneakers on the nike.com website.

Sneaker-Bot-UK A python bot using the Selenium library to auto-buy specified sneakers on the nike.com website. This bot is still in development and is

Daniel Hinds 4 Dec 14, 2022
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 01, 2022
Mypy static type checker plugin for Pytest

pytest-mypy Mypy static type checker plugin for pytest Features Runs the mypy static type checker on your source files as part of your pytest test run

Dan Bader 218 Jan 03, 2023
This is a bot that can type without any assistance and have incredible speed.

BulldozerType This is a bot that can type without any assistance and have incredible speed. This bot currently only works on the site https://onlinety

1 Jan 03, 2022
Webscreener is a tool for mass web domains pentesting.

Webscreener is a tool for mass web domains pentesting. It is used to take snapshots for domains that is generated by a tool like knockpy or Sublist3r. It cuts out most of the pentesting time by scree

Seekurity 3 Jun 07, 2021
Public repo for automation scripts

Script_Quickies Public repo for automation scripts Dependencies Chrome webdriver .exe (make sure it matches the version of chrome you are using) Selen

CHR-onicles 1 Nov 04, 2021
Wraps any WSGI application and makes it easy to send test requests to that application, without starting up an HTTP server.

WebTest This wraps any WSGI application and makes it easy to send test requests to that application, without starting up an HTTP server. This provides

Pylons Project 325 Dec 30, 2022
✅ Python web automation and testing. 🚀 Fast, easy, reliable. 💠

Build fast, reliable, end-to-end tests. SeleniumBase is a Python framework for web automation, end-to-end testing, and more. Tests are run with "pytes

SeleniumBase 3k Jan 04, 2023
Tutorial for integrating Oxylabs' Residential Proxies with Selenium

Oxylabs’ Residential Proxies integration with Selenium Requirements For the integration to work, you'll need to install Selenium on your system. You c

Oxylabs.io 8 Dec 08, 2022
Make Selenium work on Github Actions

Make Selenium work on Github Actions Scraping with BeautifulSoup on GitHub Actions is easy-peasy. But what about Selenium?? After you jump through som

Jonathan Soma 33 Dec 27, 2022
A small faсade for the standard python mocker library to make it user-friendly

unittest-mocker Inspired by the pytest-mock, but written from scratch for using with unittest and convenient tool - patch_class Installation pip insta

Vertliba V.V. 6 Jun 10, 2022
Python Testing Crawler 🐍 🩺 🕷️ A crawler for automated functional testing of a web application

Python Testing Crawler 🐍 🩺 🕷️ A crawler for automated functional testing of a web application Crawling a server-side-rendered web application is a

70 Aug 07, 2022
Akulaku Create NewProduct Automation using Selenium Python

Akulaku-Create-NewProduct-Automation Akulaku Create NewProduct Automation using Selenium Python Usage: 1. Install Python 3.9 2. Open CMD on Bot Folde

Rahul Joshua Damanik 1 Nov 22, 2021
A simple asynchronous TCP/IP Connect Port Scanner in Python 3

Python 3 Asynchronous TCP/IP Connect Port Scanner A simple pure-Python TCP Connect port scanner. This application leverages the use of Python's Standa

70 Jan 03, 2023
Simple frontend TypeScript testing utility

TSFTest Simple frontend TypeScript testing utility. Installation Install webpack in your project directory: npm install --save-dev webpack webpack-cli

2 Nov 09, 2021
Pytest-rich - Pytest + rich integration (proof of concept)

pytest-rich Leverage rich for richer test session output. This plugin is not pub

Bruno Oliveira 170 Dec 02, 2022
automate the procedure of 403 response code bypass

403bypasser automate the procedure of 403 response code bypass Description i notice a lot of #bugbountytips describe how to bypass 403 response code s

smackerdodi2 40 Dec 16, 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 03, 2023
Automated mouse clicker script using PyAutoGUI and Typer.

clickpy Automated mouse clicker script using PyAutoGUI and Typer. This app will randomly click your mouse between 1 second and 3 minutes, to prevent y

Joe Fitzgibbons 0 Dec 01, 2021