[gmx-users] Automatically assign the protonation states for pdb2gmx

ZHANG Cheng 272699575 at qq.com
Sun Feb 23 14:21:08 CET 2020


Thank you Mark!


I have tried version 2019.3 as well. 


Again, the manual input works all fine
https://github.com/lanselibai/gromacs-20200223/blob/master/manually_type
but the command using "echo" still had the same problem
https://github.com/lanselibai/gromacs-20200223/blob/master/echo


I also uploaded my protein.pdb at (it would be great if you can test it?)
https://github.com/lanselibai/gromacs-20200223/blob/master/protein.pdb
but I think it is not the pdb issue, also not the Gromacs version problem.


I took a look at the meaning of stdin, stdout, and stderr. So do you mean "echo" is used in the "stdin"? Basically, do you mean it should be possible to use "echo"?


I am sure I have supplied enough numbers to the "echo".
echo 15 0 0 0 0 |gmx pdb2gmx -f protein.pdb -o protein_processed.gro -water spce -inter -ignh -merge interactive
Here, 
) "15" is to choose the OPLS forcefield;
) The second and third number "0" is to assign the charges;
) The last two "0" is to select the terminus type.







------------------ Original ------------------
From:&nbsp;"Mark Abraham"<mark.j.abraham at gmail.com&gt;;
Date:&nbsp;Sun, Feb 23, 2020 06:46 PM
To:&nbsp;"Discussion list for GROMACS users"<gmx-users at gromacs.org&gt;;
Cc:&nbsp;"ZHANG Cheng"<272699575 at qq.com&gt;;"gromacs.org_gmx-users"<gromacs.org_gmx-users at maillist.sys.kth.se&gt;;
Subject:&nbsp;Re: [gmx-users] Automatically assign the protonation states for pdb2gmx



Hi,

On Sat, 22 Feb 2020 at 14:07, ZHANG Cheng <272699575 at qq.com&gt; wrote:

Thank you Mark! Sorry could you please explain the details of "stdin" of "pdb2gmx"? Is there a link for it?


The stdin stream is a fundamental concept in how unix terminals work. The echo tool fills that stream for pdb2gmx to consume. This is a pattern followed by thousands of tools.
&nbsp;
 I think "echo" only works for choosing the force field, but not work for the charge assignment.&amp;nbsp;
 
 
 e.g. when I use:
 
 
 echo 15 0 0 0 0 | gmx pdb2gmx&amp;nbsp; -f protein.pdb -o protein_processed.gro -water spce&amp;nbsp; -inter&amp;nbsp; -ignh -merge interactive
 
 
 I got error message:
 
 
 Which GLUTAMINE type do you want for residue 3
 0. Not protonated (charge 0) (GLN)
 1. Protonated (charge +1) (QLN)
 Type a number:
 -------------------------------------------------------
 Program:&amp;nbsp; &amp;nbsp; &amp;nbsp;gmx pdb2gmx, version 2020-beta2


Please install a proper version of GROMACS, not a pre-release one, which we asked you not to use for scientific work.
&nbsp;
 Source file: src/gromacs/gmxpreprocess/pdb2gmx.cpp (line 130)
 Fatal error:


That's probably because you haven't given enough numbers to echo to satisfy the needs of pdb2gmx, but I can't tell on the information you've given.


Mark
&nbsp;
 Answer me for res GLUTAMINE 3!
 
 
 
 
 
 ------------------&amp;nbsp;Original&amp;nbsp;------------------
 From:&amp;nbsp;"ZHANG Cheng"<272699575 at qq.com&amp;gt;;
 Date:&amp;nbsp;Sat, Feb 22, 2020 04:39 AM
 To:&amp;nbsp;"gromacs.org_gmx-users"<gromacs.org_gmx-users at maillist.sys.kth.se&amp;gt;;
 Cc:&amp;nbsp;"ZHANG Cheng"<272699575 at qq.com&amp;gt;;
 Subject:&amp;nbsp;Automatically assign the protonation states for pdb2gmx
 
 
 
 I want to run more than 300 MD, each with a different PDB (more precisely, variants derived from a same wild type). I need to manually assign the protonation states using the "-inter" option every time, which is impossible for more than 300 times. 
 
 
 gmx pdb2gmx -f protein.pdb -o protein_processed.gro -water spce&amp;nbsp; -inter&amp;nbsp; -ignh -merge interactive 
 
 
 The protonation states come from the pdb2pqr website. Is there an alternative way to obtain the .gro file by providing the necessary inputs (e.g. pdb, protonations), so that I can batch obtain the 300 corresponding .gro files?
 
 
 I know the "echo" could not work for the charge assignment.
 
 
 It would be ultimately possible if I can understand the fundamental codes behind "pdb2gmx", then write a batch code to process multiple PDB files at once. But is there a simpler route?
 -- 
 Gromacs Users mailing list
 
 * Please search the archive at http://www.gromacs.org/Support/Mailing_Lists/GMX-Users_List before posting!
 
 * Can't post? Read http://www.gromacs.org/Support/Mailing_Lists
 
 * For (un)subscribe requests visit
 https://maillist.sys.kth.se/mailman/listinfo/gromacs.org_gmx-users or send a mail to gmx-users-request at gromacs.org.


More information about the gromacs.org_gmx-users mailing list