You are here

A problem with "molfile_to_params.py"

9 posts / 0 new
Last post
A problem with "molfile_to_params.py"
#1

Hello everyone,

I was trying to use "mofile_to_params.py" to generate a parameter file for several ligands that are to be used in RosettaLigand, while there seemed to be kinda bugs.

I downloaded ".sdf" file of the ligands from PDB;
added hydrogens to the ligands in Pymol;
used "babel" to create a new ".sdf" file in which hydrogens were added to the ligands;
used "molefile_to_params.py" and the new ".sdf" file to create a parameter file as well as the ligand conformer libraries.

After running "moefile_to_params.py", a "Ligand.params" file and one/several "conformer.pdb" files were generated.
The problem is, the "conformer.pdb" files didn't appear right. The valence of some atoms were changed, for example, from "-2" to "-3" for oxygen, from "-3" to "-4" for nitrogen and from "-4" to "-5" for carbon.

Here I am attaching the input files "xxx.sdf" and output files "xxx.params" and "xxx_confs.pdb"

Eg. 1: generating "NDP.params" and "NDP_confs.pdb" from "NDP.sdf"
Flag: /users/cheuser/rosetta3.4-build/rosetta_source/src/python/apps/public/molfile_to_params.py -n NDP -p NDP NDP_w_H.sdf
CAT NDP_00*.pdb>NDP_confs.pdb

AttachmentSize
NDP_w_H_sdf.txt6.46 KB
NDP_params.txt12.02 KB
NDP_confs_pdb.txt7.59 KB
Post Situation: 
Mon, 2013-08-19 19:35
Rosettasz

Eg. 2: generating "MTX.params" and "MTX_conf.pdb" from "MTX.sdf", one conformer of MTX

Flag: /users/cheuser/rosetta3.4-build/rosetta_source/src/python/apps/public/molfile_to_params.py -n MTX -p MTX MTX.sdf
CAT MTX_00*.pdb>MTX_confs.pdb

Mon, 2013-08-19 19:38
Rosettasz

Eg. 3: generating "MTX.params" and "MTX_confs.pdb" from "MTX_w_H.sdf", all conformers of MTX used

Flag: /users/cheuser/rosetta3.4-build/rosetta_source/src/python/apps/public/molfile_to_params.py -n MTX -p MTX MTX.sdf
CAT MTX_00*.pdb>MTX_confs.pdb

Mon, 2013-08-19 19:39
Rosettasz

Is there anything that i did wrong to lead to these wrong pdb files?

Thanks in advance!

Mon, 2013-08-19 19:40
Rosettasz

I ignored this problem ever, and am interested in this. Look forward someone's reply.

Tue, 2013-08-20 20:11
myputer

From 3.4 - 3.5 and the weekly releases, the molfile_to_params script has gone through some changes thanks to people actively developing it. Can you try the same thing with the 3.5 version, or better yet, the first weekly release version? If you still have problems, I'll contact someone who should be able to help.

-J

Wed, 2013-08-21 08:43
jadolfbr

You get the extra hydrogens because your sdf files already have the extra hydrogens in them. E.g., with NDP, atom 66 is pointing off to the middle of the nicotinimide ring, hydrogen 71 is almost coincident with the N-C bond, etc. molfile_to_params.py is rather simple, and will assume that all the atoms in the input file are meant to be there. There's no sanity checking of chemical realism. (Somewhat deliberate, as it needs to work for enzyme design theozyme structures which are frequently not physically possible as a stable compound.)

Pymol isn't really suited to adding hydrogens for small molecule compounds - it's a macromolecule display program. In this particular case it looks like the problem is aromaticity detection. All your aromatic rings are coming up as singly bonded. Not only is that a problem for adding hydrogens, the atom typing in molfile_to_params.py will be off as well.

I'd recommend getting a program which specializes in small molecule display and editing. I personally use Avogadro, which uses the OpenBabel machinery. With it you can load your small molecule structure (PDB, sdf or mol2), make bonds the appropriate type, and even add hydrogens.

Alternatively, you can do the conversion and proton addition on the commandline with (open)babel. Using the command "babel -p 7.4 NDP.pdb NDP.sdf", where NDP.pdb is a no-hydrogen PDB formatted structure, gives an sdf file with no extraneous hydrogens, and with hydrogens placed for pH 7.4 (i.e. the phosphates aren't protonated). Unfortunately it isn't ideal for molfile_to_params.py, as bonding is Kekule, rather than with aromatic typing. Using mol2 file output instead of sdf gives better results. (molfile_to_params.py can take mol2 file input)

Thu, 2013-08-22 11:23
rmoretti

Rocco,

You are crazy awesome. Thanks for staying in the community. If you ever leave, I think we should all ask you a million questions before you go!

-Jared

Fri, 2013-08-23 08:01
jadolfbr

Thank you very much, rmoretti and jadolfbr!
I used the Avogadro as you suggested and I could get the right ligands with added hydrogen finally.

Fri, 2013-08-23 14:04
Rosettasz