Member Site › Forums › PyRosetta › PyRosetta – General › How to optimize the orientations of polar hydrogens in PyRosetta
- This topic has 5 replies, 3 voices, and was last updated 12 years, 7 months ago by Anonymous.
-
AuthorPosts
-
-
April 28, 2012 at 11:33 pm #1260Anonymous
Hi,
I wonder if there is a way to trigger the optimization of polar hydrogens in PyRosetta just like the “-no_optH” option in Rosetta when reading structure information from PDB files into Pose. Because I found many potential hydrogen bonds in the original PDB structures were interrupted by the wrongly added hydrogens by default which result very high energy scores.
I have not found any routines to set free the movemenet of hydrogens in the MoveMap settings.
And by the way, is there a way to supress the std outputs like “core” and “basic” in PyRosetta, just like the “-mute” or “-output:level” options in Rosetta? Because the debug outputs of my scripts are always flooded by them…
Many thx!
xfliu
-
April 29, 2012 at 2:13 am #7039Anonymous
PyRosetta accepts the same flags as C++ rosetta – you just have to manually set the flags. -optH and -mute will work in the same fashion.
I know there’s a thread somewhere around here explaining how to do it, but I can’t find it at the moment – if you can’t find it, or don’t already know how to set options in pyrosetta, post again and I’ll find someone who does.
Note you’d need the opth option set before reading the pose from PDB; I hope the tracer system re-checks that option at some time other than initialization. It may be possible to get the tracers to allow access to muting them in-code.
If you want to optimize hydrogens directly, try the TaskOperation “OptH” or the function core::pack::optimizeH.
-
April 29, 2012 at 3:13 am #7040Anonymous
Suppressing std output in PyRosetta is done the same way as in Rosetta – by specifying “-mute” command line option. In PyRosetta you can do this by adding “extra_options” keyword argument to init, like this:
import rosetta
rosetta.init(extra_options=”-mute basic core”)You can also use ‘-mute all’ if you want to mute all channels.
-
April 29, 2012 at 5:26 am #7041Anonymous
Hi Steven and Sergey,
Thanks a lot for the prompt replies! The core::pack::optimizeH function works well for my requirement.
But setteing “extra_options” by rosetta.init(extra_options=”-mute basic core”) is not accepted by PyRosetta. An exception was thrown as “TypeError: init() got an unexpected keyword argument ‘extra_options’ “. The rosetta.init(*argv) function seems to require a string argument. So I tried to pass the string “app -database Program FilesPyRosettarosetta_database -ex1 -ex2aro -mute basic core” to it, but another warning was thrown:
“core.init: ROSETTA3_DB not defined
Warning: Unable to locate database file chemical/atom_type_sets/fa_standard/”Since the atom types cannot be located, the structure cannot be loaded from PDB and the program exit. Is there anything I did stupid? Or is my PyRosetta version too old (mine is PyRosetta.Windows-v2.011-r45995)?
Thx a lot and best regards
xfliu
-
April 30, 2012 at 2:59 pm #7050Anonymous
Hi xfliu,
You right, version v2.011-r45995 is too old for this. Could you try the following? I think it could work on your version:
Try: rosetta.init()
-
April 30, 2012 at 3:29 pm #7051Anonymous
Yes, Sergey, this list formatted argument can be accepted by my current PyRosetta. But I will update it to the latest version anyway later.
Thanks a lot!
xfliu
-
-
AuthorPosts
- You must be logged in to reply to this topic.