marrink-lab / vermouth-martinize

Describe and apply transformation on molecular structures and topologies
Apache License 2.0
89 stars 40 forks source link

Neutralization of termini ignored for MARTINI3 #395

Closed rversin closed 2 years ago

rversin commented 2 years ago

Hello everyone,

I would like to use martinize2 to build a structure of protein in MARTINI3, with neutral termini.

I used the following command : "martinize2 -f box_AA.gro -ff martini3001 -x box_M3.pdb -o topol_M3.top -ignh -dssp dssp -nt -scfix -cys auto -ff-dir martini3/martini_v300/martini_v3.0.0_proteins/force_fields/ -map-dir martini3/martini_v300/martini_v3.0.0_proteins/mappings/" with the -nt flag that is supposed to neutralize the N-ter and C-ter.

This command did not produce any warning or error, however I noticed that the termini were charged in the itp file.

Is there any way to fix this issue ? Thank you :)

pckroon commented 2 years ago

Interesting. the -nt flag should indeed patch your termini to neutral by applying the COOH-ter and NH2-ter modifications. Could you run with -v and post the output?

rversin commented 2 years ago

Here is the output (I shortened it, and kept only the output regarding the modifications) :

   DEBUG - step - vermouth - Annotating required mutations and modifications.
   DEBUG - general - vermouth.processors.annotate_mut_mod - Annotating SER1 with modification NH2-ter
   DEBUG - general - vermouth.processors.annotate_mut_mod - Annotating SER29 with modification COOH-ter
    INFO - step - vermouth - Repairing the graph.
   DEBUG - step - vermouth.processors.repair_graph - Making reference graph
    INFO - general - vermouth.processors.repair_graph - Applying modification NH2-ter to residue -SER1
   DEBUG - step - vermouth.processors.repair_graph - Matching residue -SER1 to its reference
   DEBUG - step - vermouth.processors.repair_graph - Matching residue -LYS2 to its reference
   DEBUG - step - vermouth.processors.repair_graph - Matching residue -ILE3 to its reference
   DEBUG - step - vermouth.processors.repair_graph - Matching residue -PRO4 to its reference
   DEBUG - step - vermouth.processors.repair_graph - Matching residue -THR5 to its reference
   DEBUG - step - vermouth.processors.repair_graph - Matching residue -LEU6 to its reference
   DEBUG - step - vermouth.processors.repair_graph - Matching residue -THR7 to its reference
   DEBUG - step - vermouth.processors.repair_graph - Matching residue -LEU8 to its reference
   DEBUG - step - vermouth.processors.repair_graph - Matching residue -TYR9 to its reference
   DEBUG - step - vermouth.processors.repair_graph - Matching residue -PHE10 to its reference
   DEBUG - step - vermouth.processors.repair_graph - Matching residue -LEU11 to its reference
   DEBUG - step - vermouth.processors.repair_graph - Matching residue -GLY12 to its reference
   DEBUG - step - vermouth.processors.repair_graph - Matching residue -SER13 to its reference
   DEBUG - step - vermouth.processors.repair_graph - Matching residue -THR14 to its reference
   DEBUG - step - vermouth.processors.repair_graph - Matching residue -LYS15 to its reference
   DEBUG - step - vermouth.processors.repair_graph - Matching residue -VAL16 to its reference
   DEBUG - step - vermouth.processors.repair_graph - Matching residue -VAL17 to its reference
   DEBUG - step - vermouth.processors.repair_graph - Matching residue -GLY18 to its reference
   DEBUG - step - vermouth.processors.repair_graph - Matching residue -ASN19 to its reference
   DEBUG - step - vermouth.processors.repair_graph - Matching residue -ILE20 to its reference
   DEBUG - step - vermouth.processors.repair_graph - Matching residue -ILE21 to its reference
   DEBUG - step - vermouth.processors.repair_graph - Matching residue -LEU22 to its reference
   DEBUG - step - vermouth.processors.repair_graph - Matching residue -ASN23 to its reference
   DEBUG - step - vermouth.processors.repair_graph - Matching residue -GLY24 to its reference
   DEBUG - step - vermouth.processors.repair_graph - Matching residue -ILE25 to its reference
   DEBUG - step - vermouth.processors.repair_graph - Matching residue -LYS26 to its reference
   DEBUG - step - vermouth.processors.repair_graph - Matching residue -LEU27 to its reference
   DEBUG - step - vermouth.processors.repair_graph - Matching residue -SER28 to its reference
    INFO - general - vermouth.processors.repair_graph - Applying modification COOH-ter to residue -SER29
   DEBUG - step - vermouth.processors.repair_graph - Matching residue -SER29 to its reference
   DEBUG - step - vermouth.processors.repair_graph - Repairing residue SER1
   DEBUG - step - vermouth.processors.repair_graph - Repairing residue LYS2
   DEBUG - step - vermouth.processors.repair_graph - Repairing residue ILE3
   DEBUG - step - vermouth.processors.repair_graph - Repairing residue PRO4
   DEBUG - step - vermouth.processors.repair_graph - Repairing residue THR5
   DEBUG - step - vermouth.processors.repair_graph - Repairing residue LEU6
   DEBUG - step - vermouth.processors.repair_graph - Repairing residue THR7
   DEBUG - step - vermouth.processors.repair_graph - Repairing residue LEU8
   DEBUG - step - vermouth.processors.repair_graph - Repairing residue TYR9
   DEBUG - step - vermouth.processors.repair_graph - Repairing residue PHE10
   DEBUG - step - vermouth.processors.repair_graph - Repairing residue LEU11
   DEBUG - step - vermouth.processors.repair_graph - Repairing residue GLY12
   DEBUG - step - vermouth.processors.repair_graph - Repairing residue SER13
   DEBUG - step - vermouth.processors.repair_graph - Repairing residue THR14
   DEBUG - step - vermouth.processors.repair_graph - Repairing residue LYS15
   DEBUG - step - vermouth.processors.repair_graph - Repairing residue VAL16
   DEBUG - step - vermouth.processors.repair_graph - Repairing residue VAL17
   DEBUG - step - vermouth.processors.repair_graph - Repairing residue GLY18
   DEBUG - step - vermouth.processors.repair_graph - Repairing residue ASN19
   DEBUG - step - vermouth.processors.repair_graph - Repairing residue ILE20
   DEBUG - step - vermouth.processors.repair_graph - Repairing residue ILE21
   DEBUG - step - vermouth.processors.repair_graph - Repairing residue LEU22
   DEBUG - step - vermouth.processors.repair_graph - Repairing residue ASN23
   DEBUG - step - vermouth.processors.repair_graph - Repairing residue GLY24
   DEBUG - step - vermouth.processors.repair_graph - Repairing residue ILE25
   DEBUG - step - vermouth.processors.repair_graph - Repairing residue LYS26
   DEBUG - step - vermouth.processors.repair_graph - Repairing residue LEU27
   DEBUG - step - vermouth.processors.repair_graph - Repairing residue SER28
   DEBUG - step - vermouth.processors.repair_graph - Repairing residue SER29
    INFO - step - vermouth - Dealing with modifications.
    INFO - general - vermouth.processors.canonicalize_modifications - Identified the modifications ['NH2-ter'] on residues ['SER1', 'SER1', 'SER1']
   DEBUG - change-atom - vermouth.processors.canonicalize_modifications - Changing attribute atomname from HN to HN1 for atom 218-SER1:HN
    INFO - general - vermouth.processors.canonicalize_modifications - Identified the modifications ['COOH-ter'] on residues ['SER29', 'SER29', 'SER29']
    INFO - step - vermouth - Read input.
   DEBUG - step - vermouth - Read molecule molecule with 462 atoms, and 464 edges.
   DEBUG - general - vermouth.dssp.dssp - DSSP input file written to /home/rversin/Documents/scripts_utils/TEST_MARTINIZE/dssp_in__xwrasea.pdb
    INFO - step - vermouth - Creating the graph at the target resolution.
    INFO - general - vermouth.processors.do_mapping - Applying modification mapping ('NH2-ter',)
    INFO - general - vermouth.processors.do_mapping - Applying modification mapping ('COOH-ter',)
    INFO - step - vermouth - Averaging the coordinates.
    INFO - step - vermouth - Applying the links.
    INFO - step - vermouth - Placing the charge dummies.
    INFO - step - vermouth - Writing output.
   DEBUG - step - vermouth - Writing molecule molecule_0 with 63 atoms, 65 edges, 39 bonds, 43 constraints, 110 angles, 50 dihedrals, 1 impropers, and 7 exclusions.
pckroon commented 2 years ago

Sorry for the slow reply. Holidays came (and went :( ), and I'm pretty swamped at the moment.

   DEBUG - general - vermouth.processors.annotate_mut_mod - Annotating SER1 with modification NH2-ter
   DEBUG - general - vermouth.processors.annotate_mut_mod - Annotating SER29 with modification COOH-ter
    INFO - general - vermouth.processors.repair_graph - Applying modification NH2-ter to residue -SER1
    INFO - general - vermouth.processors.repair_graph - Applying modification COOH-ter to residue -SER29
    INFO - general - vermouth.processors.canonicalize_modifications - Identified the modifications ['NH2-ter'] on residues ['SER1', 'SER1', 'SER1']
   DEBUG - change-atom - vermouth.processors.canonicalize_modifications - Changing attribute atomname from HN to HN1 for atom 218-SER1:HN
    INFO - general - vermouth.processors.canonicalize_modifications - Identified the modifications ['COOH-ter'] on residues ['SER29', 'SER29', 'SER29']
    INFO - general - vermouth.processors.do_mapping - Applying modification mapping ('NH2-ter',)
    INFO - general - vermouth.processors.do_mapping - Applying modification mapping ('COOH-ter',)

So at least the -nt flag is working as intended. What are the atomtypes of the BB beads of the terminal residues? What's the output of martinize2 -V?

rversin commented 2 years ago

Hello, I am very sorry for the late answer.

The lines of the itp file corresponding to the BB beads of the terminal residues are the following :

The output of "martinize2 -V" is the following :

martinize with vermouth 0.7.0

I have not updated the repository since I last tested it.

Thank you very much :)

pckroon commented 2 years ago

Could you update to the latest version before I start digging? Although there probably is some digging for me to do.