Valdes-Tresanco-MS / gmx_MMPBSA

gmx_MMPBSA is a new tool based on AMBER's MMPBSA.py aiming to perform end-state free energy calculations with GROMACS files.
https://valdes-tresanco-ms.github.io/gmx_MMPBSA/
GNU General Public License v3.0
215 stars 64 forks source link

[Question]: gmx trjconv failed when querying com_traj.xtc #424

Closed wyplogin closed 11 months ago

wyplogin commented 11 months ago

My Question is...

I am encountering an issue while using gmxMMPBSA to process a trajectory of a protein-ligand-membrane protein. The ligand contains LPH, so I followed the tutorial to handle it. However, like many other users, I encountered the error "gmx trjconv failed when querying com_traj.xtc". I also tried to generate a new index file from the generated str_noLP.pdb as you suggested, and then run the gmxmmpbsa calculation. Unfortunately, it indicated that the number of atoms in the topology and complex are inconsistent. I have uploaded my md files for your review. Thank you very much for your assistance.

wyplogin commented 11 months ago

myfile.zip

wyplogin commented 11 months ago

[INFO ] Starting gmx_MMPBSA v1.6.2 [DEBUG ] WDIR : /home/gromacs/gmxana/mem170c2 [DEBUG ] AMBERHOME : /home/gromacs/anaconda3/envs/gmxMMPBSA [DEBUG ] PYTHON EXE : /home/gromacs/anaconda3/envs/gmxMMPBSA/bin/python [DEBUG ] PYTHON VERSION: 3.9.15 | packaged by conda-forge | (main, Nov 22 2022, 08:45:29) [GCC 10.4.0] [DEBUG ] MPI : /home/gromacs/mpi/mpich4/mpich-install/bin/mpirun [DEBUG ] ParmEd : 3.4.3+11.g41cc9ab [DEBUG ] OS PLATFORM : Linux-6.2.0-34-generic-x86_64-with-glibc2.35 [DEBUG ] OS SYSTEM : Linux [DEBUG ] OS VERSION : #34~22.04.1-Ubuntu SMP PREEMPT_DYNAMIC Thu Sep 7 13:12:03 UTC 2 [DEBUG ] OS PROCESSOR : x86_64

[INFO ] Command-line gmx_MMPBSA -O -i mmpbsa.in -cs str_noLP.pdb -ci index2.ndx -cg 1 13 -ct com_traj.xtc -cp topol.top -o FINAL_RESULTS_MMPBSA.dat -eo FINAL_RESULTS_MMPBSA.csv

[DEBUG ] |Input file: [DEBUG ] |-------------------------------------------------------------- [DEBUG ] |Sample input file for PB calculation [DEBUG ] |This input file is meant to show only that gmx_MMPBSA works. Althought, [DEBUG ] |we tried to used the input files as recommended in the Amber manual, [DEBUG ] |some parameters have been changed to perform more expensive calculations [DEBUG ] |in a reasonable amount of time. Feel free to change the parameters [DEBUG ] |according to what is better for your system. [DEBUG ] | [DEBUG ] |&general [DEBUG ] |sys_name="Prot-Lig-ST", [DEBUG ] |startframe=5, [DEBUG ] |endframe=9, [DEBUG ] |solvated_trajectory=0, [DEBUG ] |# In gmx_MMPBSA v1.5.0 we have added a new PB radii set named charmm_radii. [DEBUG ] |# This radii set should be used only with systems prepared with CHARMM force fields. [DEBUG ] |# Uncomment the line below to use charmm_radii set [DEBUG ] |#PBRadii=7, [DEBUG ] |/ [DEBUG ] |&pb [DEBUG ] |# radiopt=0 is recommended which means using radii from the prmtop file [DEBUG ] |# for both the PB calculation and for the NP calculation [DEBUG ] | [DEBUG ] |istrng=0.15, fillratio=4, radiopt=0, inp=1, [DEBUG ] |/ [DEBUG ] |-------------------------------------------------------------- [DEBUG ] [INFO ] Checking mmpbsa.in input file... [INFO ] Checking mmpbsa.in input file...Done.

[INFO ] Checking external programs... [INFO ] cpptraj found! Using /home/gromacs/anaconda3/envs/gmxMMPBSA/bin/cpptraj [INFO ] tleap found! Using /home/gromacs/anaconda3/envs/gmxMMPBSA/bin/tleap [INFO ] parmchk2 found! Using /home/gromacs/anaconda3/envs/gmxMMPBSA/bin/parmchk2 [INFO ] sander found! Using /home/gromacs/anaconda3/envs/gmxMMPBSA/bin/sander [INFO ] Using GROMACS version > 5.x.x! [INFO ] gmx found! Using /home/gromacs/anaconda3/envs/gmxMMPBSA/bin.AVX2_256/gmx [INFO ] Checking external programs...Done.

[INFO ] Building AMBER topologies from GROMACS files... [INFO ] Get PDB files from GROMACS structures files... [INFO ] Making gmx_MMPBSA index for complex... [DEBUG ] Running command: echo -e "name 1 GMXMMPBSA_REC\n name 13 GMXMMPBSA_LIG\n 1 | 13\n q\n" | /home/gromacs/anaconda3/envs/gmxMMPBSA/bin.AVX2_256/gmx make_ndx -n index2.ndx -o _GMXMMPBSA_COM_index.ndx -f str_noLP.pdb [DEBUG ] :-) GROMACS - gmx make_ndx, 2022.4-conda_forge (-: [DEBUG ] [DEBUG ] Executable: /home/gromacs/anaconda3/envs/gmxMMPBSA/bin.AVX2_256/gmx [DEBUG ] Data prefix: /home/gromacs/anaconda3/envs/gmxMMPBSA [DEBUG ] Working dir: /home/gromacs/gmxana/mem170c2 [DEBUG ] Command line: [DEBUG ] gmx make_ndx -n index2.ndx -o _GMXMMPBSA_COM_index.ndx -f str_noLP.pdb [DEBUG ] [DEBUG ] [DEBUG ] Reading structure file [DEBUG ] [DEBUG ] GROMACS reminds you: "Sacrifices must be made" (Otto Lilienthal, dying after having crashed with his glider in 1896) [DEBUG ] [DEBUG ] Going to read 1 old index file(s) [DEBUG ] [DEBUG ] 0 System : 2706 atoms [DEBUG ] 1 Protein : 2651 atoms [DEBUG ] 2 Protein-H : 1326 atoms [DEBUG ] 3 C-alpha : 170 atoms [DEBUG ] 4 Backbone : 510 atoms [DEBUG ] 5 MainChain : 679 atoms [DEBUG ] 6 MainChain+Cb : 833 atoms [DEBUG ] 7 MainChain+H : 846 atoms [DEBUG ] 8 SideChain : 1805 atoms [DEBUG ] 9 SideChain-H : 647 atoms [DEBUG ] 10 Prot-Masses : 2651 atoms [DEBUG ] 11 non-Protein : 55 atoms [DEBUG ] 12 Other : 55 atoms [DEBUG ] 13 UNK : 55 atoms [DEBUG ] 14 Protein_UNK : 2706 atoms [DEBUG ] [DEBUG ] nr : group '!': not 'name' nr name 'splitch' nr Enter: list groups [DEBUG ] 'a': atom '&': and 'del' nr 'splitres' nr 'l': list residues [DEBUG ] 't': atom type '|': or 'keep' nr 'splitat' nr 'h': help [DEBUG ] 'r': residue 'res' nr 'chain' char [DEBUG ] "name": group 'case': case sensitive 'q': save and quit [DEBUG ] 'ri': residue index [DEBUG ] [DEBUG ] > [DEBUG ] [DEBUG ] > [DEBUG ] [DEBUG ] > [DEBUG ] Copied index group 1 'GMXMMPBSA_REC' [DEBUG ] Copied index group 13 'GMXMMPBSA_LIG' [DEBUG ] Merged two groups with OR: 2651 55 -> 2706 [DEBUG ] [DEBUG ] 15 GMXMMPBSA_REC_GMXMMPBSA_LIG: 2706 atoms [DEBUG ] [DEBUG ] > [INFO ] Normal Complex: Saving group Protein_UNK (1_13) in _GMXMMPBSA_COM_index.ndx file as _GMXMMPBSA_COM.pdb [DEBUG ] Running command: echo -e "GMXMMPBSA_REC_GMXMMPBSA_LIG"| /home/gromacs/anaconda3/envs/gmxMMPBSA/bin.AVX2_256/gmx editconf -f str_noLP.pdb -n _GMXMMPBSA_COM_index.ndx -o _GMXMMPBSA_COM.pdb [DEBUG ] :-) GROMACS - gmx editconf, 2022.4-conda_forge (-: [DEBUG ] [DEBUG ] Executable: /home/gromacs/anaconda3/envs/gmxMMPBSA/bin.AVX2_256/gmx [DEBUG ] Data prefix: /home/gromacs/anaconda3/envs/gmxMMPBSA [DEBUG ] Working dir: /home/gromacs/gmxana/mem170c2 [DEBUG ] Command line: [DEBUG ] gmx editconf -f str_noLP.pdb -n _GMXMMPBSA_COM_index.ndx -o _GMXMMPBSA_COM.pdb [DEBUG ] [DEBUG ] [DEBUG ] Select a group for output: [DEBUG ] Group 0 ( System) has 2706 elements [DEBUG ] Group 1 ( GMXMMPBSA_REC) has 2651 elements [DEBUG ] Group 2 ( Protein-H) has 1326 elements [DEBUG ] Group 3 ( C-alpha) has 170 elements [DEBUG ] Group 4 ( Backbone) has 510 elements [DEBUG ] Group 5 ( MainChain) has 679 elements [DEBUG ] Group 6 ( MainChain+Cb) has 833 elements [DEBUG ] Group 7 ( MainChain+H) has 846 elements [DEBUG ] Group 8 ( SideChain) has 1805 elements [DEBUG ] Group 9 ( SideChain-H) has 647 elements [DEBUG ] Group 10 ( Prot-Masses) has 2651 elements [DEBUG ] Group 11 ( non-Protein) has 55 elements [DEBUG ] Group 12 ( Other) has 55 elements [DEBUG ] Group 13 ( GMXMMPBSA_LIG) has 55 elements [DEBUG ] Group 14 ( Protein_UNK) has 2706 elements [DEBUG ] Group 15 (GMXMMPBSA_REC_GMXMMPBSA_LIG) has 2706 elements [DEBUG ] Select a group: [DEBUG ] GROMACS reminds you: "Sacrifices must be made" (Otto Lilienthal, dying after having crashed with his glider in 1896) [DEBUG ] [DEBUG ] Note that major changes are planned in future for editconf, to improve usability and utility. [DEBUG ] Read 2706 atoms [DEBUG ] Volume: 744.577 nm^3, corresponds to roughly 335000 electrons [DEBUG ] No velocities found [DEBUG ] Selected 15: 'GMXMMPBSA_REC_GMXMMPBSA_LIG' [INFO ] No receptor structure file was defined. Using ST approach... [INFO ] Using receptor structure from complex to generate AMBER topology [INFO ] Normal Receptor: Saving group Protein (1) in _GMXMMPBSA_COM_index.ndx file as _GMXMMPBSA_REC.pdb [DEBUG ] Running command: echo -e "1"| /home/gromacs/anaconda3/envs/gmxMMPBSA/bin.AVX2_256/gmx editconf -f str_noLP.pdb -n _GMXMMPBSA_COM_index.ndx -o _GMXMMPBSA_REC.pdb [DEBUG ] :-) GROMACS - gmx editconf, 2022.4-conda_forge (-: [DEBUG ] [DEBUG ] Executable: /home/gromacs/anaconda3/envs/gmxMMPBSA/bin.AVX2_256/gmx [DEBUG ] Data prefix: /home/gromacs/anaconda3/envs/gmxMMPBSA [DEBUG ] Working dir: /home/gromacs/gmxana/mem170c2 [DEBUG ] Command line: [DEBUG ] gmx editconf -f str_noLP.pdb -n _GMXMMPBSA_COM_index.ndx -o _GMXMMPBSA_REC.pdb [DEBUG ] [DEBUG ] [DEBUG ] Select a group for output: [DEBUG ] Group 0 ( System) has 2706 elements [DEBUG ] Group 1 ( GMXMMPBSA_REC) has 2651 elements [DEBUG ] Group 2 ( Protein-H) has 1326 elements [DEBUG ] Group 3 ( C-alpha) has 170 elements [DEBUG ] Group 4 ( Backbone) has 510 elements [DEBUG ] Group 5 ( MainChain) has 679 elements [DEBUG ] Group 6 ( MainChain+Cb) has 833 elements [DEBUG ] Group 7 ( MainChain+H) has 846 elements [DEBUG ] Group 8 ( SideChain) has 1805 elements [DEBUG ] Group 9 ( SideChain-H) has 647 elements [DEBUG ] Group 10 ( Prot-Masses) has 2651 elements [DEBUG ] Group 11 ( non-Protein) has 55 elements [DEBUG ] Group 12 ( Other) has 55 elements [DEBUG ] Group 13 ( GMXMMPBSA_LIG) has 55 elements [DEBUG ] Group 14 ( Protein_UNK) has 2706 elements [DEBUG ] Group 15 (GMXMMPBSA_REC_GMXMMPBSA_LIG) has 2706 elements [DEBUG ] Select a group: [DEBUG ] GROMACS reminds you: "Sacrifices must be made" (Otto Lilienthal, dying after having crashed with his glider in 1896) [DEBUG ] [DEBUG ] Note that major changes are planned in future for editconf, to improve usability and utility. [DEBUG ] Read 2706 atoms [DEBUG ] Volume: 744.577 nm^3, corresponds to roughly 335000 electrons [DEBUG ] No velocities found [DEBUG ] Selected 1: 'GMXMMPBSA_REC' [INFO ] No ligand structure file was defined. Using ST approach... [INFO ] Using ligand structure from complex to generate AMBER topology [INFO ] Normal Ligand: Saving group UNK (13) in _GMXMMPBSA_COM_index.ndx file as _GMXMMPBSA_LIG.pdb [DEBUG ] Running command: echo -e "13"| /home/gromacs/anaconda3/envs/gmxMMPBSA/bin.AVX2_256/gmx editconf -f str_noLP.pdb -n _GMXMMPBSA_COM_index.ndx -o _GMXMMPBSA_LIG.pdb [DEBUG ] :-) GROMACS - gmx editconf, 2022.4-conda_forge (-: [DEBUG ] [DEBUG ] Executable: /home/gromacs/anaconda3/envs/gmxMMPBSA/bin.AVX2_256/gmx [DEBUG ] Data prefix: /home/gromacs/anaconda3/envs/gmxMMPBSA [DEBUG ] Working dir: /home/gromacs/gmxana/mem170c2 [DEBUG ] Command line: [DEBUG ] gmx editconf -f str_noLP.pdb -n _GMXMMPBSA_COM_index.ndx -o _GMXMMPBSA_LIG.pdb [DEBUG ] [DEBUG ] [DEBUG ] Select a group for output: [DEBUG ] Group 0 ( System) has 2706 elements [DEBUG ] Group 1 ( GMXMMPBSA_REC) has 2651 elements [DEBUG ] Group 2 ( Protein-H) has 1326 elements [DEBUG ] Group 3 ( C-alpha) has 170 elements [DEBUG ] Group 4 ( Backbone) has 510 elements [DEBUG ] Group 5 ( MainChain) has 679 elements [DEBUG ] Group 6 ( MainChain+Cb) has 833 elements [DEBUG ] Group 7 ( MainChain+H) has 846 elements [DEBUG ] Group 8 ( SideChain) has 1805 elements [DEBUG ] Group 9 ( SideChain-H) has 647 elements [DEBUG ] Group 10 ( Prot-Masses) has 2651 elements [DEBUG ] Group 11 ( non-Protein) has 55 elements [DEBUG ] Group 12 ( Other) has 55 elements [DEBUG ] Group 13 ( GMXMMPBSA_LIG) has 55 elements [DEBUG ] Group 14 ( Protein_UNK) has 2706 elements [DEBUG ] Group 15 (GMXMMPBSA_REC_GMXMMPBSA_LIG) has 2706 elements [DEBUG ] Select a group: [DEBUG ] GROMACS reminds you: "Sacrifices must be made" (Otto Lilienthal, dying after having crashed with his glider in 1896) [DEBUG ] [DEBUG ] Note that major changes are planned in future for editconf, to improve usability and utility. [DEBUG ] Read 2706 atoms [DEBUG ] Volume: 744.577 nm^3, corresponds to roughly 335000 electrons [DEBUG ] No velocities found [DEBUG ] Selected 13: 'GMXMMPBSA_LIG' [INFO ] Checking the structures consistency... [INFO ] [INFO ] Using topology conversion. Setting radiopt = 0... [INFO ] Building Normal Complex Amber topology... [ERROR ] MMPBSA_Error

The number of atoms in the topology (2781) and the complex structure (2706) are different. Please check these files and verify that they are correct. Otherwise report the error...

Check the gmx_MMPBSA.log file to report the problem. gmx_MMPBSA.log

wyplogin commented 11 months ago

@Valdes-Tresanco-MS @marioernestovaldes Is this problem very difficult to solve, or what should I do to find a solution?

marioernestovaldes commented 11 months ago

Sorry for the delay. We have been caught up with other projects. We have to go back and revisit the tutorial, but for now, it seems the DPPC mols are not been deleted from the topology file and this is what is causing the issue... Please, in the [ molecules ] section of the topology, delete manually all but "PROA" and "UNK". It should look like this:

[ molecules ] ; Compound #mols PROA 1

UNK 1

let us know if that solves the issue...

PS: I see your system is embedded in a membrane, so you might want to consider the membrane effect in your calculations. Please, check this tutorial

https://valdes-tresanco-ms.github.io/gmx_MMPBSA/dev/examples/Protein_membrane_CHARMMff/

wyplogin commented 11 months ago

YEP, gmx_mmpbsa goes well, thanks for your help.