Error while running MMPBSA

58 views
Skip to first unread message

Chardi Shahiya

unread,
Feb 27, 2023, 3:15:43 PM2/27/23
to gmx_MMPBSA
Hello I am getting this error can you please assist me with this?

(gmxMMPBSA) chardi@chardi-Modern-15-B11M:~/Desktop/newgromacs$ gmx_MMPBSA -O -i mmpbsa.in -cs HPCD_EST.tpr -ci test.ndx -cg 3 2 -ct HPCD_EST_corrected.xtc -cp topol.top -o FINAL_RESULTS_MMPBSA.dat -eo FINAL_RESULTS_MMPBSA.csv
[INFO   ] Starting gmx_MMPBSA v1.5.7
[INFO   ] Command-line
  gmx_MMPBSA -O -i mmpbsa.in -cs HPCD_EST.tpr -ci test.ndx -cg 3 2 -ct HPCD_EST_corrected.xtc -cp topol.top -o FINAL_RESULTS_MMPBSA.dat -eo FINAL_RESULTS_MMPBSA.csv

[INFO   ] Checking mmpbsa.in input file...
[INFO   ] Checking mmpbsa.in input file...Done.

[INFO   ] Checking external programs...
[INFO   ] cpptraj found! Using /home/chardi/miniconda3/envs/gmxMMPBSA/bin/cpptraj
[INFO   ] tleap found! Using /home/chardi/miniconda3/envs/gmxMMPBSA/bin/tleap
[INFO   ] parmchk2 found! Using /home/chardi/miniconda3/envs/gmxMMPBSA/bin/parmchk2
[INFO   ] sander found! Using /home/chardi/miniconda3/envs/gmxMMPBSA/bin/sander
[INFO   ] Using GROMACS version > 5.x.x!
[INFO   ] gmx found! Using /home/chardi/miniconda3/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...
[INFO   ] Normal Complex: Saving group 3_2 in _GMXMMPBSA_COM_index.ndx file as _GMXMMPBSA_COM.pdb
[ERROR  ] MMPBSA_Error /home/chardi/miniconda3/envs/gmxMMPBSA/bin.AVX2_256/gmx trjconv failed when querying HPCD_EST_corrected.xtc.
           Check the gmx_MMPBSA.log file to report the problem.
  File "/home/chardi/miniconda3/envs/gmxMMPBSA/bin/gmx_MMPBSA", line 8, in <module>
    sys.exit(gmxmmpbsa())
  File "/home/chardi/miniconda3/envs/gmxMMPBSA/lib/python3.9/site-packages/GMXMMPBSA/app.py", line 98, in gmxmmpbsa
    app.make_prmtops()
  File "/home/chardi/miniconda3/envs/gmxMMPBSA/lib/python3.9/site-packages/GMXMMPBSA/main.py", line 548, in make_prmtops
    self.FILES.mutant_receptor_prmtop, self.FILES.mutant_ligand_prmtop) = maketop.buildTopology()
  File "/home/chardi/miniconda3/envs/gmxMMPBSA/lib/python3.9/site-packages/GMXMMPBSA/make_top.py", line 116, in buildTopology
    self.gmx2pdb()
  File "/home/chardi/miniconda3/envs/gmxMMPBSA/lib/python3.9/site-packages/GMXMMPBSA/make_top.py", line 277, in gmx2pdb
    GMXMMPBSA_ERROR('%s failed when querying %s' % (' '.join(comprog), self.FILES.complex_trajs[0]))
  File "/home/chardi/miniconda3/envs/gmxMMPBSA/lib/python3.9/site-packages/GMXMMPBSA/exceptions.py", line 169, in __init__
    raise exc(msg + '\nCheck the gmx_MMPBSA.log file to report the problem.')
MMPBSA_Error: /home/chardi/miniconda3/envs/gmxMMPBSA/bin.AVX2_256/gmx trjconv failed when querying HPCD_EST_corrected.xtc
Check the gmx_MMPBSA.log file to report the problem.
Exiting. All files have been retained.
gmx_MMPBSA.log

Mario Sergio Valdes

unread,
Feb 27, 2023, 3:22:20 PM2/27/23
to gmx_MMPBSA
The problem is that it uses gromacs 2021 installed in conda to process a trajectory generated with gromacs 2023. You can uninstall gromacs from conda (conda remove gromacs) to use your custom gmx or define the path to the other gromacs in the input file through gmx_path variable (https://valdes-tresanco-ms.github.io/gmx_MMPBSA/dev/input_file/#general-namelist-variables)

Chardi Shahiya

unread,
Feb 27, 2023, 3:36:16 PM2/27/23
to gmx_MMPBSA
oh, okay I see. I did the MD simulation on gromacs 2023 and I am using the  MMPBSA compiled with conda on a different systems. is there no way for me to just update the gromacs on conda to 2023?

Mario Sergio Valdes

unread,
Feb 27, 2023, 6:05:41 PM2/27/23
to gmx_MMPBSA
As I know, you don´t. There is no gromacs 2023 for conda. You can install gromacs in your PC easily

Chardi Shahiya

unread,
Feb 27, 2023, 7:07:01 PM2/27/23
to Mario Sergio Valdes, gmx_MMPBSA
okay, I installed gromacs 2023 but I got this error? how do I make the installed gromacs recognized by GMXMMPBSA?
NAL_RESULTS_MMPBSA.csv
[INFO   ] Starting gmx_MMPBSA v1.5.7
[INFO   ] Command-line
  gmx_MMPBSA -O -i mmpbsa.in -cs HPCD_EST.tpr -ci test.ndx -cg 3 2 -ct HPCD_EST_corrected.xtc -cp topol.top -o FINAL_RESULTS_MMPBSA.dat -eo FINAL_RESULTS_MMPBSA.csv

[INFO   ] Checking mmpbsa.in input file...
[INFO   ] Checking mmpbsa.in input file...Done.

[INFO   ] Checking external programs...
[INFO   ] cpptraj found! Using /home/chardi/miniconda3/envs/gmxMMPBSA/bin/cpptraj
[INFO   ] tleap found! Using /home/chardi/miniconda3/envs/gmxMMPBSA/bin/tleap
[INFO   ] parmchk2 found! Using /home/chardi/miniconda3/envs/gmxMMPBSA/bin/parmchk2
[INFO   ] sander found! Using /home/chardi/miniconda3/envs/gmxMMPBSA/bin/sander
[INFO   ] Using GROMACS version 4.x.x!
[ERROR  ] MMPBSA_Error Could not find necessary program [ GROMACS ].

           Check the gmx_MMPBSA.log file to report the problem.
  File "/home/chardi/miniconda3/envs/gmxMMPBSA/bin/gmx_MMPBSA", line 8, in <module>
    sys.exit(gmxmmpbsa())
  File "/home/chardi/miniconda3/envs/gmxMMPBSA/lib/python3.9/site-packages/GMXMMPBSA/app.py", line 98, in gmxmmpbsa
    app.make_prmtops()
  File "/home/chardi/miniconda3/envs/gmxMMPBSA/lib/python3.9/site-packages/GMXMMPBSA/main.py", line 538, in make_prmtops
    external_progs = utils.find_progs(self.INPUT, self.mpi_size) if self.master else {}
  File "/home/chardi/miniconda3/envs/gmxMMPBSA/lib/python3.9/site-packages/GMXMMPBSA/utils.py", line 740, in find_progs
    GMXMMPBSA_ERROR('Could not find necessary program [ GROMACS ]')

  File "/home/chardi/miniconda3/envs/gmxMMPBSA/lib/python3.9/site-packages/GMXMMPBSA/exceptions.py", line 169, in __init__
    raise exc(msg + '\nCheck the gmx_MMPBSA.log file to report the problem.')
MMPBSA_Error: Could not find necessary program [ GROMACS ]

Check the gmx_MMPBSA.log file to report the problem.
Exiting. All files have been retained.
--
You received this message because you are subscribed to a topic in the Google Groups "gmx_MMPBSA" group.
To unsubscribe from this topic, visit https://groups.google.com/d/topic/gmx_mmpbsa/ErYOU8LjOzs/unsubscribe.
To unsubscribe from this group and all its topics, send an email to gmx_mmpbsa+...@googlegroups.com.
To view this discussion on the web visit https://groups.google.com/d/msgid/gmx_mmpbsa/68ee0f9f-61b0-4bda-8dcd-4b5a6bcab07cn%40googlegroups.com.
For more options, visit https://groups.google.com/d/optout.

Mario Sergio Valdes

unread,
Feb 27, 2023, 10:06:01 PM2/27/23
to gmx_MMPBSA
If you follow the Gromacs installation instructions, you must have sourced the GMXRC file (it is recommended to add that command to your .bashrc). After that, you can check if gmx is accessible. If yes, then gmx_MMPBSA will detect it with no problem

Chardi Shahiya

unread,
Feb 27, 2023, 10:32:23 PM2/27/23
to Mario Sergio Valdes, gmx_MMPBSA
yes, I managed to do it but then I had this error.

(gmxMMPBSA) chardi@chardi-Modern-15-B11M:~/Desktop/newgromacs$ gmx_MMPBSA -O -i mmpbsa.in -cs HPCD_EST.tpr -ci index.ndx -cg 2 3 -ct HPCD_EST_corrected.xtc -cp topol.top -o FINAL_RESULTS_MMPBSA.dat -eo FINAL_RESULTS_MMPBSA.csv

[INFO   ] Starting gmx_MMPBSA v1.5.7
[INFO   ] Command-line
  gmx_MMPBSA -O -i mmpbsa.in -cs HPCD_EST.tpr -ci index.ndx -cg 2 3 -ct HPCD_EST_corrected.xtc -cp topol.top -o FINAL_RESULTS_MMPBSA.dat -eo FINAL_RESULTS_MMPBSA.csv


[INFO   ] Checking mmpbsa.in input file...
[INFO   ] Checking mmpbsa.in input file...Done.

[INFO   ] Checking external programs...
[INFO   ] cpptraj found! Using /home/chardi/miniconda3/envs/gmxMMPBSA/bin/cpptraj
[INFO   ] tleap found! Using /home/chardi/miniconda3/envs/gmxMMPBSA/bin/tleap
[INFO   ] parmchk2 found! Using /home/chardi/miniconda3/envs/gmxMMPBSA/bin/parmchk2
[INFO   ] sander found! Using /home/chardi/miniconda3/envs/gmxMMPBSA/bin/sander
[INFO   ] Using GROMACS version > 5.x.x!
[INFO   ] gmx found! Using /home/chardi/gromacs-2023/build/bin/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...
[ERROR  ] MMPBSA_Error /home/chardi/gromacs-2023/build/bin/gmx make_ndx failed when querying index.ndx.

           Check the gmx_MMPBSA.log file to report the problem.
  File "/home/chardi/miniconda3/envs/gmxMMPBSA/bin/gmx_MMPBSA", line 8, in <module>
    sys.exit(gmxmmpbsa())
  File "/home/chardi/miniconda3/envs/gmxMMPBSA/lib/python3.9/site-packages/GMXMMPBSA/app.py", line 98, in gmxmmpbsa
    app.make_prmtops()
  File "/home/chardi/miniconda3/envs/gmxMMPBSA/lib/python3.9/site-packages/GMXMMPBSA/main.py", line 548, in make_prmtops
    self.FILES.mutant_receptor_prmtop, self.FILES.mutant_ligand_prmtop) = maketop.buildTopology()
  File "/home/chardi/miniconda3/envs/gmxMMPBSA/lib/python3.9/site-packages/GMXMMPBSA/make_top.py", line 116, in buildTopology
    self.gmx2pdb()
  File "/home/chardi/miniconda3/envs/gmxMMPBSA/lib/python3.9/site-packages/GMXMMPBSA/make_top.py", line 254, in gmx2pdb
    GMXMMPBSA_ERROR('%s failed when querying %s' % (' '.join(self.make_ndx), self.FILES.complex_index))

  File "/home/chardi/miniconda3/envs/gmxMMPBSA/lib/python3.9/site-packages/GMXMMPBSA/exceptions.py", line 169, in __init__
    raise exc(msg + '\nCheck the gmx_MMPBSA.log file to report the problem.')
MMPBSA_Error: /home/chardi/gromacs-2023/build/bin/gmx make_ndx failed when querying index.ndx

Check the gmx_MMPBSA.log file to report the problem.
Exiting. All files have been retained.
gmx_MMPBSA.log

Mario Sergio Valdes

unread,
Feb 27, 2023, 10:36:00 PM2/27/23
to gmx_MMPBSA
This limitation has already been fixed in the new version (v1.6.0). Please, update gmx_MMPBSA as follow:
python -m pip install gmx_mmpbsa -U

Chardi Shahiya

unread,
Feb 27, 2023, 10:41:59 PM2/27/23
to Mario Sergio Valdes, gmx_MMPBSA
The update worked but then:
INAL_RESULTS_MMPBSA.csv
[INFO   ] Starting gmx_MMPBSA v1.6.0

[INFO   ] Command-line
  gmx_MMPBSA -O -i mmpbsa.in -cs HPCD_EST.tpr -ci index.ndx -cg 2 3 -ct HPCD_EST_corrected.xtc -cp topol.top -o FINAL_RESULTS_MMPBSA.dat -eo FINAL_RESULTS_MMPBSA.csv

[INFO   ] Checking mmpbsa.in input file...
[INFO   ] Checking mmpbsa.in input file...Done.

[INFO   ] Checking external programs...
[INFO   ] cpptraj found! Using /home/chardi/miniconda3/envs/gmxMMPBSA/bin/cpptraj
[INFO   ] tleap found! Using /home/chardi/miniconda3/envs/gmxMMPBSA/bin/tleap
[INFO   ] parmchk2 found! Using /home/chardi/miniconda3/envs/gmxMMPBSA/bin/parmchk2
[INFO   ] sander found! Using /home/chardi/miniconda3/envs/gmxMMPBSA/bin/sander
[INFO   ] Using GROMACS version > 5.x.x!
[INFO   ] gmx found! Using /home/chardi/gromacs-2023/build/bin/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...
[INFO   ] Normal Complex: Saving group 04SBY_03C7X (2_3) in _GMXMMPBSA_COM_index.ndx file as _GMXMMPBSA_COM.pdb
[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 04SBY (2) in _GMXMMPBSA_COM_index.ndx file as _GMXMMPBSA_REC.pdb
[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 03C7X (3) in _GMXMMPBSA_COM_index.ndx file as _GMXMMPBSA_LIG.pdb
[INFO   ] Checking the structures consistency...
[INFO   ]
[INFO   ] Using topology conversion. Setting radiopt = 0...
[INFO   ] Building Normal Complex Amber topology...

  File "/home/chardi/miniconda3/envs/gmxMMPBSA/bin/gmx_MMPBSA", line 8, in <module>
    sys.exit(gmxmmpbsa())
  File "/home/chardi/miniconda3/envs/gmxMMPBSA/lib/python3.9/site-packages/GMXMMPBSA/app.py", line 98, in gmxmmpbsa
    app.make_prmtops()
  File "/home/chardi/miniconda3/envs/gmxMMPBSA/lib/python3.9/site-packages/GMXMMPBSA/main.py", line 689, in make_prmtops
    self.FILES.mutant_receptor_prmtop, self.FILES.mutant_ligand_prmtop) = maketop.buildTopology()
  File "/home/chardi/miniconda3/envs/gmxMMPBSA/lib/python3.9/site-packages/GMXMMPBSA/make_top.py", line 125, in buildTopology
    tops = self.gmxtop2prmtop()
  File "/home/chardi/miniconda3/envs/gmxMMPBSA/lib/python3.9/site-packages/GMXMMPBSA/make_top.py", line 534, in gmxtop2prmtop
    com_top = self.cleantop(self.FILES.complex_top, self.indexes['COM']['COM'])
  File "/home/chardi/miniconda3/envs/gmxMMPBSA/lib/python3.9/site-packages/GMXMMPBSA/make_top.py", line 821, in cleantop
    rtemp_top = parmed.gromacs.GromacsTopologyFile(ttp_file.as_posix())
  File "/home/chardi/miniconda3/envs/gmxMMPBSA/lib/python3.9/site-packages/parmed/gromacs/gromacstop.py", line 251, in __init__
    self.read(fname, defines, parametrize)
  File "/home/chardi/miniconda3/envs/gmxMMPBSA/lib/python3.9/site-packages/parmed/gromacs/gromacstop.py", line 404, in read
    key, knd, t, replace = self._parse_dihedraltypes(line)
  File "/home/chardi/miniconda3/envs/gmxMMPBSA/lib/python3.9/site-packages/parmed/gromacs/gromacstop.py", line 813, in _parse_dihedraltypes
    if words[2] in ('1', '2', '3', '4', '5', '8', '9', '10', '11'):
IndexError: list index out of range

Exiting. All files have been retained.
gmx_MMPBSA.log

Mario Sergio Valdes

unread,
Feb 27, 2023, 10:43:37 PM2/27/23
to gmx_MMPBSA
What ff was used to prepare your system?

Chardi Shahiya

unread,
Feb 27, 2023, 10:45:39 PM2/27/23
to Mario Sergio Valdes, gmx_MMPBSA
I used charmm36 ff

Mario Sergio Valdes

unread,
Feb 27, 2023, 10:47:06 PM2/27/23
to gmx_MMPBSA
Please, send me your files to check them

Chardi Shahiya

unread,
Feb 27, 2023, 10:50:31 PM2/27/23
to Mario Sergio Valdes, gmx_MMPBSA
kindly find attached the files

You received this message because you are subscribed to the Google Groups "gmx_MMPBSA" group.
To unsubscribe from this group and stop receiving emails from it, send an email to gmx_mmpbsa+...@googlegroups.com.
To view this discussion on the web visit https://groups.google.com/d/msgid/gmx_mmpbsa/420878b6-7e37-4275-bb56-c1ca48f0f62dn%40googlegroups.com.
mmpbsa.in
atomguest.itp
index.ndx
HPCD_EST_corrected.xtc
topol.top

Mario Sergio Valdes

unread,
Feb 27, 2023, 10:55:12 PM2/27/23
to gmx_MMPBSA
Please, check the topology file. It has several empty lines. ParmEd does not allow these format problems

Chardi Shahiya

unread,
Feb 27, 2023, 11:09:07 PM2/27/23
to Mario Sergio Valdes, gmx_MMPBSA
I tried to remove all the empty lines but it still gives me the same error.

topol2.top
gmx_MMPBSA.log

Mario Sergio Valdes

unread,
Feb 27, 2023, 11:13:57 PM2/27/23
to gmx_MMPBSA
Please, attach all required files to check them
- topol.top
- charmm36.ff folder
- atomhost.itp
- atomguest.itp
- host.itp
- guest.itp
- posre_EST.itp
- index.ndx
HPCD_EST.tpr
- 10 frames *.xtc

Chardi Shahiya

unread,
Feb 27, 2023, 11:32:31 PM2/27/23
to Mario Sergio Valdes, gmx_MMPBSA
kindly find attached the files.

atomguest.itp
atomhost.itp
guest.itp
host.itp
posre_EST.itp
topol.top
charmm36.ff.rar
index.ndx
HPCD_EST_corrected.xtc

Mario Sergio Valdes

unread,
Feb 28, 2023, 12:07:50 AM2/28/23
to gmx_MMPBSA
please, attach the  HPCD_EST.tpr file

Chardi Shahiya

unread,
Feb 28, 2023, 12:10:10 AM2/28/23
to Mario Sergio Valdes, gmx_MMPBSA
kindly find the file attached

HPCD_EST.tpr

Mario Sergio Valdes

unread,
Feb 28, 2023, 1:25:45 AM2/28/23
to gmx_MMPBSA
(Un)fortunately, I can't reproduce your error. Everything runs smoothly for me with the files you send me.

t.png

Chardi Shahiya

unread,
Feb 28, 2023, 1:28:35 AM2/28/23
to Mario Sergio Valdes, gmx_MMPBSA
Oh,
Can you please send me the command line  you used?

Mario Sergio Valdes

unread,
Feb 28, 2023, 2:09:51 PM2/28/23
to gmx_MMPBSA
I used the same in the gmx_MMPBSA.log file you send me.
gmx_MMPBSA -O -i mmpbsa.in -cs HPCD_EST.tpr -ci index.ndx -cg 2 3 -ct HPCD_EST_corrected.xtc -cp topol2.top

Reply all
Reply to author
Forward
0 new messages