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

TypeError: ChamberParm does not support all potential terms defined in the input Structure #447

Closed rodrisantiago closed 8 months ago

rodrisantiago commented 8 months ago

Bug summary

Hi, I ran protein-ligand MD simulations using gromacs with the OPLS-AA FF. When the ligand is a fatty acid, gmxMMPBA works fine, but when the ligand is another one, ChamberParm is not able to process this ligand (TypeError: ChamberParm does not support all potential terms defined in the input Structure). If someone could help me it would be great! Thanks in advance.

Terminal output

mpirun -np 4 gmx_MMPBSA -O -i mmpbsa.in -cs md_0_20.tpr -ct md_0_20_center.xtc -ci index_mmpbsa.ndx -cg 0 1 -cp topol.top -o FINAL_RESULTS_MMPBSA.dat -eo FINAL_RESULTS_MMPBSA.csv
[INFO   ] Starting gmx_MMPBSA v1.6.2+13.ge1831fe
[INFO   ] Command-line
  mpirun -np 4 gmx_MMPBSA -O -i mmpbsa.in -cs md_0_20.tpr -ct md_0_20_center.xtc -ci index_mmpbsa.ndx -cg 0 1 -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/santiago/miniconda3/envs/gmxMMPBSA/bin/cpptraj
[INFO   ] tleap found! Using /home/santiago/miniconda3/envs/gmxMMPBSA/bin/tleap
[INFO   ] parmchk2 found! Using /home/santiago/miniconda3/envs/gmxMMPBSA/bin/parmchk2
[INFO   ] sander found! Using /home/santiago/miniconda3/envs/gmxMMPBSA/bin/sander
[INFO   ] Using GROMACS version > 5.x.x!
[INFO   ] gmx found! Using /home/santiago/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 Protein_UNL (0_1) 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 Protein (0) 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 UNL (1) 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...
tets
  File "/home/santiago/miniconda3/envs/gmxMMPBSA/bin/gmx_MMPBSA", line 8, in <module>
    sys.exit(gmxmmpbsa())
  File "/home/santiago/miniconda3/envs/gmxMMPBSA/lib/python3.9/site-packages/GMXMMPBSA/app.py", line 98, in gmxmmpbsa
    app.make_prmtops()
  File "/home/santiago/miniconda3/envs/gmxMMPBSA/lib/python3.9/site-packages/GMXMMPBSA/main.py", line 682, in make_prmtops
    self.FILES.mutant_receptor_prmtop, self.FILES.mutant_ligand_prmtop) = maketop.buildTopology()
  File "/home/santiago/miniconda3/envs/gmxMMPBSA/lib/python3.9/site-packages/GMXMMPBSA/make_top.py", line 125, in buildTopology
    tops = self.gmxtop2prmtop()
  File "/home/santiago/miniconda3/envs/gmxMMPBSA/lib/python3.9/site-packages/GMXMMPBSA/make_top.py", line 570, in gmxtop2prmtop
    com_amb_prm = parmed.amber.ChamberParm.from_structure(com_top)
  File "/home/santiago/miniconda3/envs/gmxMMPBSA/lib/python3.9/site-packages/parmed/amber/_chamberparm.py", line 185, in from_structure
    raise TypeError('ChamberParm does not support all potential terms '
TypeError: ChamberParm does not support all potential terms defined in the input Structure
Error occurred on rank 0.
Exiting. All files have been retained.
application called MPI_Abort(MPI_COMM_WORLD, 1) - process 0

gmx_MMPBSA.log

gmx_MMPBSA.log

Operating system

No response

gmx_MMPBSA Version

gmx_MMPBSA v1.6.2+13.ge1831fe based on MMPBSA version 16.0 and AmberTools 20

Python version

Python 3.9.15

Installation

None

marioernestovaldes commented 8 months ago

Could you please share the topology file? Probably there are some special terms that are causing the problems and can be avoided without any major impact on the results

rodrisantiago commented 8 months ago

Here it goes, the topol.top file for the complex, the itp file for the ligand and the gro file for the full system. Please let me know if something else is required!

files.zip

marioernestovaldes commented 8 months ago

There are definitively some terms that are not usual... could you please the rest of the files you are using (input file, tpr, ndx, xtc files) to perform some tests?

rodrisantiago commented 8 months ago

Hi Mario, here goes the rest of the files.

Thanks in advance! rest_files.zip https://drive.google.com/file/d/1EnLQnW14-wmXDrv04sMXRynx_O8Kzb9d/view?usp=drive_web

El vie, 29 dic 2023 a las 20:02, Mario E. Valdés-Tresanco (< @.***>) escribió:

There are definitively some terms that are not usual... could you please the rest of the files you are using (input file, tpr, ndx, xtc files) to perform some tests?

— Reply to this email directly, view it on GitHub https://github.com/Valdes-Tresanco-MS/gmx_MMPBSA/issues/447#issuecomment-1872382065, or unsubscribe https://github.com/notifications/unsubscribe-auth/ARPIW4PUHNM2T37CEM2W5Z3YL5DYBAVCNFSM6AAAAABBGYELX6VHI2DSMVQWIX3LMV43OSLTON2WKQ3PNVWWK3TUHMYTQNZSGM4DEMBWGU . You are receiving this because you authored the thread.Message ID: @.***>

-- Lic. Santiago Rodríguez

PhD Student INIBIOLP (FCM) / LIDeB (FCE) Universidad Nacional de La Plata (UNLP)

Argentina

marioernestovaldes commented 8 months ago

Fortunately, I was able to find the issue with the topology in your system. For some reason, there were repeated data in some fields that were causing the issue. Once I removed the repeated data, everything was fine... I uploaded both the original and the modified file (as *.txt because GitHub doesn't allow .itp format) for you to compare... let me know if anything is unclear...

hdz.itp.txt hdz_original.itp.txt

image

rodrisantiago commented 8 months ago

Hi Mario, now it works!

Thanks a lot!

El lun., 1 ene. 2024 18:50, Mario E. Valdés-Tresanco < @.***> escribió:

Fortunately, I was able to find the issue with the topology in your system. For some reason, there were repeated data in some fields that were causing the issue. Once I removed the repeated data, everything was fine... I uploaded both the original and the modified file (as *.txt because GitHub doesn't allow .itp format) for you to compare... let me know if anything is unclear...

hdz.itp.txt https://github.com/Valdes-Tresanco-MS/gmx_MMPBSA/files/13806078/hdz.itp.txt hdz_original.itp.txt https://github.com/Valdes-Tresanco-MS/gmx_MMPBSA/files/13806079/hdz_original.itp.txt

image.png (view on web) https://github.com/Valdes-Tresanco-MS/gmx_MMPBSA/assets/46581661/9438bb76-682b-4578-8981-dc4647a93c09

— Reply to this email directly, view it on GitHub https://github.com/Valdes-Tresanco-MS/gmx_MMPBSA/issues/447#issuecomment-1873493963, or unsubscribe https://github.com/notifications/unsubscribe-auth/ARPIW4PPU5F4LEBRI3ACALLYMMVR5AVCNFSM6AAAAABBGYELX6VHI2DSMVQWIX3LMV43OSLTON2WKQ3PNVWWK3TUHMYTQNZTGQ4TGOJWGM . You are receiving this because you authored the thread.Message ID: @.***>