Rosetta
|
Special Mover designed to send Pose information into PyMOL instance running. More...
#include <PyMOLMover.hh>
Public Member Functions | |
PyMOLMover (std::string const &address=default_address(), unsigned int port=default_port(), unsigned int max_packet_size=0) | |
ctor More... | |
void | apply (Pose &) override |
Main Method. More... | |
virtual void | apply (Pose const &) |
Actually our mover does not change the Pose object, so we have additional const version... More... | |
void | print (std::string const &message) |
Send message for PyMOL to print. More... | |
void | send_energy (Pose const &, core::scoring::ScoreType stype=core::scoring::total_score) |
Send specified energy to PyMOL. More... | |
void | send_energy (Pose const &, std::string const &stype) |
Send specified energy to PyMOL. More... | |
void | send_RAW_Energies (Pose const &, std::string energyType, utility::vector1< int > const &energies) |
Send RAW energy array for coloring by PyMOL already implemented. More... | |
void | send_membrane_planes (Pose const &) |
Send Membrane Planes to PyMOL. More... | |
void | send_any (std::string ptype, core::pose::Pose const &pose, utility::vector1< std::string > data, core::Size size=6) |
Xiyao's Code. More... | |
void | label_energy (Pose const &input_pose, std::string energy_type) |
Xiyao's Code. More... | |
void | send_hbonds (Pose const &pose) |
void | send_ss (Pose &pose, std::string ss) |
void | send_polars (Pose const &pose) |
void | send_movemap (Pose const &pose, core::kinematics::MoveMap const &movemap) |
void | send_foldtree (Pose const &pose, core::kinematics::FoldTree const &foldtree) |
virtual void | send_colors (Pose const &, std::map< int, int > const &colors, X11Colors default_color=protocols::moves::XC_blue) |
End Xiyao's Code. More... | |
std::string | pymol_name () |
Specify PyMOL model name. More... | |
void | pymol_name (std::string new_pymol_name) |
bool | update_energy () |
Flag that specify if PyMOL mover should send current Pose energy on every apply. If name set to empty string (default) then name derived from pdb_info will be used. More... | |
void | update_energy (bool f) |
core::scoring::ScoreType | energy_type (void) |
void | energy_type (core::scoring::ScoreType t) |
void | keep_history (bool kh) |
Set the keep history flag. If set to True - PyMOL will keep track of all frames that was sent. More... | |
bool | keep_history (void) |
Return current keep_history flag. More... | |
void | update_interval (core::Real t) |
Set current minimum update interval 't' in seconds. Mover will not send anyinformation to PyMOL before atleast 't' secons has passes since last packet was sent. default value is 0, - no packets are skipped. More... | |
core::Real | update_interval () |
Return current update interval. More... | |
void | show (std::ostream &output=std::cout) const override |
Outputs details about the Mover, including current settings. More... | |
void | parse_my_tag (utility::tag::TagCOP tag, basic::datacache::DataMap &) override |
Parses tag for rosetta scripts. More... | |
protocols::moves::MoverOP | fresh_instance () const override |
required in the context of the parser/scripting scheme More... | |
protocols::moves::MoverOP | clone () const override |
required in the context of the parser/scripting scheme More... | |
void | set_PyMOL_model_name (std::string name) |
Set the pymol model name. More... | |
void | set_link (UDPSocketClient const &link) |
UDPSocketClient const & | get_link () const |
std::string | get_PyMOL_model_name (Pose const &pose) const |
std::string | get_name () const override |
Each derived class must specify its name. The class name. More... | |
![]() | |
Mover () | |
virtual MoverOP | create () |
MoverCOP | get_self_ptr () const |
MoverOP | get_self_ptr () |
MoverCAP | get_self_weak_ptr () const |
MoverAP | get_self_weak_ptr () |
Mover (std::string const &type_name) | |
sets the type for a mover; name_ has been removed (2010/05/14) More... | |
virtual void | test_move (Pose &pose) |
: Unit test support function. Apply one move to a given pose. Allows extra test specific functions to be called before applying More... | |
virtual bool | reinitialize_for_each_job () const |
Inform the Job Distributor (August '08 vintage) whether this object needs to be freshly regenerated on each use. More... | |
virtual bool | reinitialize_for_new_input () const |
Inform the Job Distributor (August '08 vintage) whether this object needs to be regenerated when the input pose is about to change, (for example, if the Mover has special code on the first apply() that is only valid for that one input pose). More... | |
MoverStatus | get_last_move_status () const |
end parser interface, start Job Distributor interface///////////// More... | |
void | reset_status () |
resets status to SUCCESS, meant to be used before an apply(). The job distributor (august 08 vintage) uses this to ensure non-accumulation of status across apply()s. More... | |
virtual core::pose::PoseOP | get_additional_output () |
Mechanism by which a mover may return multiple output poses from a single input pose. More... | |
void | set_type (std::string const &setting) |
Set the 'type' string. More... | |
std::string | get_type () const |
void | type (const std::string &type_in) |
Set the 'type' string. More... | |
std::string const & | type () const |
Get the set 'type' string. More... | |
virtual void | set_input_pose (PoseCOP pose) |
setter for poses contained for rms More... | |
virtual void | set_native_pose (PoseCOP pose) |
setter for native poses contained for rms -— we should get rid of this method? it is widely used, but a bit unsafe More... | |
PoseCOP | get_input_pose () const |
PoseCOP | get_native_pose () const |
void | set_current_job (protocols::jobdist::BasicJobCOP job) |
jobdist::BasicJobCOP | get_current_job () const |
virtual void | set_current_tag (std::string const &new_tag) |
std::string | get_current_tag () const |
A tag is a unique identifier used to identify structures produced by this Mover. get_current_tag() returns the tag, and set_current_tag( std::string tag ) sets the tag. This functionality is not intended for use with the 2008 job distributor. More... | |
virtual core::Real | last_proposal_density_ratio () |
virtual void | clear_info () |
Strings container can be used to return miscellaneous info (as std::string) from a mover, such as notes about the results of apply(). The job distributor (Apr 09 vintage) will check this function to see if your protocol wants to add string info to the Job that ran this mover. One way this can be useful is that later, a JobOutputter may include/append this info to an output file. More... | |
virtual Strings & | info () |
non-const accessor More... | |
virtual Strings const & | info () const |
const accessor More... | |
virtual void | provide_citation_info (basic::citation_manager::CitationCollectionList &) const |
Provide citations to the passed CitationCollectionList Subclasses should add the info for themselves and any other classes they use. More... | |
Static Public Member Functions | |
static std::string | mover_name () |
static void | provide_xml_schema (utility::tag::XMLSchemaDefinition &xsd) |
![]() | |
static std::string | name () |
static void | register_options () |
Overload this static method if you access options within the mover. More... | |
Private Member Functions | |
utility::vector1< core::Real > | get_energies (Pose const &pose, core::scoring::ScoreType energy_type) |
return vector of energy_type energy for each residue More... | |
std::string | get_pose_name (Pose const &pose) |
return name, stripped of path and ".pdb" More... | |
bool | is_it_time () |
End Xiyao's code. More... | |
Static Private Member Functions | |
static std::string | default_address () |
static unsigned int | default_port () |
static unsigned int | default_max_packet_size (std::string const &address) |
Private Attributes | |
UDPSocketClient | link_ |
Actual link object. More... | |
bool | update_energy_ |
core::scoring::ScoreType | energy_type_ |
bool | update_membrane_ |
If pose is a membrane pose, send planes. More... | |
bool | keep_history_ |
Should PyMOL keep history of all models that was sent? - Default is false. More... | |
core::Real | update_interval_ |
Update interval in seconds. More... | |
core::Real | last_packet_sent_time_ |
Time stamp from where last packet was sent. More... | |
std::string | pymol_name_ |
Name of model in pymol. More... | |
Additional Inherited Members | |
![]() | |
typedef utility::tag::TagCOP | TagCOP |
typedef core::pose::Pose | Pose |
typedef core::pose::PoseCOP | PoseCOP |
typedef std::list< std::string > | Strings |
![]() | |
void | set_last_move_status (MoverStatus status) |
nonvirtual setter for MoverStatus last_status_. Protected means that only the mover itself will be able to change its own status. The job distributor (august 08 vintage) is aware of status set with this function and will do what the MoverStatus says. More... | |
Special Mover designed to send Pose information into PyMOL instance running.
protocols::moves::PyMOLMover::PyMOLMover | ( | std::string const & | address = default_address() , |
unsigned int | port = default_port() , |
||
unsigned int | max_packet_size = 0 |
||
) |
ctor
|
overridevirtual |
|
virtual |
Actually our mover does not change the Pose object, so we have additional const version...
References core::pose::Pose::conformation(), core::pose::Pose::dump_pdb(), energy_type_, get_PyMOL_model_name(), is_it_time(), core::conformation::Conformation::is_membrane(), keep_history_, link_, protocols::moves::Mover::name(), send_energy(), send_membrane_planes(), protocols::moves::UDPSocketClient::sendMessage(), protocols::moves::TR(), update_energy_, and update_membrane_.
|
overridevirtual |
required in the context of the parser/scripting scheme
Reimplemented from protocols::moves::Mover.
|
staticprivate |
Referenced by parse_my_tag(), and provide_xml_schema().
|
staticprivate |
Referenced by parse_my_tag(), and provide_xml_schema().
|
staticprivate |
Referenced by parse_my_tag(), and provide_xml_schema().
|
inline |
References energy_type_, and protocols::hybridization::t.
|
inline |
References energy_type_.
Referenced by protocols::moves::get_energies().
|
overridevirtual |
required in the context of the parser/scripting scheme
Reimplemented from protocols::moves::Mover.
|
private |
return vector of energy_type energy for each residue
Xiyao's code
|
inline |
References link_.
|
overridevirtual |
Each derived class must specify its name. The class name.
Implements protocols::moves::Mover.
References mover_name().
|
private |
return name, stripped of path and ".pdb"
std::string protocols::moves::PyMOLMover::get_PyMOL_model_name | ( | Pose const & | pose | ) | const |
References protocols::moves::Mover::info(), core::pose::Pose::pdb_info(), and pymol_name_.
Referenced by protocols::carbohydrates::GlycanSampler::apply(), apply(), send_any(), send_energy(), send_hbonds(), send_membrane_planes(), and send_RAW_Energies().
|
private |
End Xiyao's code.
References last_packet_sent_time_, protocols::hybridization::t, and update_interval_.
Referenced by apply(), print(), send_energy(), send_membrane_planes(), and send_RAW_Energies().
|
inline |
Set the keep history flag. If set to True - PyMOL will keep track of all frames that was sent.
References keep_history_.
Referenced by protocols::carbohydrates::GlycanSampler::apply().
|
inline |
void protocols::moves::PyMOLMover::label_energy | ( | Pose const & | input_pose, |
std::string | energy_type = "total_score" |
||
) |
Xiyao's Code.
References core::pose::Pose::energies(), protocols::buns::energy, and send_energy().
|
static |
Referenced by get_name(), protocols::moves::PyMOLMoverCreator::keyname(), and provide_xml_schema().
|
overridevirtual |
Parses tag for rosetta scripts.
PyMOLMoverCreator interface, name of the mover.
PyMOLMoverCreator interface, returns a unique key name to be used in xml file
PyMOLMoverCreator interface, return a new instance
allows for the setting of certain variabel from the rosetta scripts interface, only keep history
Reimplemented from protocols::moves::Mover.
References default_address(), default_max_packet_size(), default_port(), keep_history(), keep_history_, and link_.
void protocols::moves::PyMOLMover::print | ( | std::string const & | message | ) |
Send message for PyMOL to print.
References is_it_time(), keep_history_, link_, and protocols::moves::UDPSocketClient::sendMessage().
|
static |
|
inline |
Specify PyMOL model name.
References pymol_name_.
|
inline |
References pymol_name_.
void protocols::moves::PyMOLMover::send_any | ( | std::string | ptype, |
core::pose::Pose const & | pose, | ||
utility::vector1< std::string > | data, | ||
core::Size | size = 6 |
||
) |
Xiyao's Code.
References get_PyMOL_model_name(), protocols::moves::Mover::info(), keep_history_, link_, protocols::moves::Mover::name(), core::pose::Pose::pdb_info(), protocols::moves::UDPSocketClient::sendMessage(), core::pose::Pose::size(), and core::id::to_string().
Referenced by send_foldtree(), send_movemap(), send_polars(), and send_ss().
|
virtual |
End Xiyao's Code.
Tell PyMOL to color protein with supplied custom colors
References send_RAW_Energies(), core::pose::Pose::size(), protocols::moves::XC_first_color, and protocols::moves::XC_last_color.
void protocols::moves::PyMOLMover::send_energy | ( | Pose const & | pose, |
core::scoring::ScoreType | stype = core::scoring::total_score |
||
) |
Send specified energy to PyMOL.
References core::pose::Pose::energies(), core::scoring::Energies::energies_updated(), get_PyMOL_model_name(), protocols::moves::Mover::info(), is_it_time(), keep_history_, link_, protocols::mean_field::max(), protocols::mean_field::min(), protocols::moves::Mover::name(), core::scoring::name_from_score_type(), core::pose::Pose::pdb_info(), core::scoring::Energies::residue_total_energies(), core::scoring::Energies::residue_total_energy(), protocols::moves::UDPSocketClient::sendMessage(), core::pose::Pose::size(), and core::scoring::total_score.
Referenced by apply(), label_energy(), and send_energy().
void protocols::moves::PyMOLMover::send_energy | ( | Pose const & | pose, |
std::string const & | stype | ||
) |
Send specified energy to PyMOL.
References core::scoring::ScoreTypeManager::score_type_from_name(), and send_energy().
void protocols::moves::PyMOLMover::send_foldtree | ( | Pose const & | pose, |
core::kinematics::FoldTree const & | foldtree | ||
) |
References core::kinematics::FoldTree::is_cutpoint(), core::kinematics::FoldTree::is_jump_point(), core::kinematics::FoldTree::jump_edge(), core::kinematics::FoldTree::num_jump(), send_any(), core::pose::Pose::size(), core::kinematics::Edge::start(), core::kinematics::Edge::stop(), and core::id::to_string().
void protocols::moves::PyMOLMover::send_hbonds | ( | Pose const & | pose | ) |
References core::scoring::hbonds::HBond::acc_atm(), core::scoring::hbonds::HBond::acc_res(), core::conformation::Residue::atom_name(), core::scoring::hbonds::HBond::don_hatm(), core::scoring::hbonds::HBond::don_res(), core::pose::Pose::energies(), core::scoring::Energies::energies_updated(), core::scoring::hbonds::HBond::energy(), core::scoring::hbonds::fill_hbond_set(), get_PyMOL_model_name(), core::scoring::hbonds::HBondSet::hbond(), protocols::moves::Mover::info(), keep_history_, link_, protocols::moves::Mover::name(), core::scoring::hbonds::HBondSet::nhbonds(), core::pose::Pose::pdb_info(), core::pose::Pose::residue(), protocols::moves::UDPSocketClient::sendMessage(), and core::id::to_string().
void protocols::moves::PyMOLMover::send_membrane_planes | ( | Pose const & | pose | ) |
Send Membrane Planes to PyMOL.
If pose is a membrane pose pymol viewer will build CGO planes from points specified
References core::energy_methods::RG_Energy_Fast::calculate_rg_score(), core::conformation::membrane::center, core::pose::Pose::conformation(), get_PyMOL_model_name(), is_it_time(), core::conformation::Conformation::is_membrane(), keep_history_, link_, core::conformation::Conformation::membrane_info(), protocols::moves::Mover::name(), core::conformation::membrane::normal, core::scoring::rg, protocols::moves::UDPSocketClient::sendMessage(), core::pose::Pose::size(), core::conformation::membrane::thickness, and core::id::to_string().
Referenced by apply().
void protocols::moves::PyMOLMover::send_movemap | ( | Pose const & | pose, |
core::kinematics::MoveMap const & | movemap | ||
) |
void protocols::moves::PyMOLMover::send_polars | ( | Pose const & | pose | ) |
void protocols::moves::PyMOLMover::send_RAW_Energies | ( | Pose const & | pose, |
std::string | energyType, | ||
utility::vector1< int > const & | energies | ||
) |
Send RAW energy array for coloring by PyMOL already implemented.
References get_PyMOL_model_name(), protocols::moves::Mover::info(), is_it_time(), keep_history_, link_, protocols::moves::Mover::name(), core::pose::Pose::pdb_info(), and protocols::moves::UDPSocketClient::sendMessage().
Referenced by send_colors().
void protocols::moves::PyMOLMover::send_ss | ( | Pose & | pose, |
std::string | ss = "" |
||
) |
References protocols::simple_filters::dssp(), and send_any().
|
inline |
References link_.
void protocols::moves::PyMOLMover::set_PyMOL_model_name | ( | std::string | name | ) |
Set the pymol model name.
References protocols::moves::Mover::name(), and pymol_name_.
Referenced by protocols::carbohydrates::GlycanSampler::apply().
|
overridevirtual |
Outputs details about the Mover, including current settings.
Ideally, a child Mover should call Mover.show() and add additional information particular to that Mover.
Reimplemented from protocols::moves::Mover.
References keep_history_, last_packet_sent_time_, link_, protocols::moves::Mover::show(), update_energy_, and update_interval_.
Referenced by protocols::moves::operator<<().
|
inline |
Flag that specify if PyMOL mover should send current Pose energy on every apply. If name set to empty string (default) then name derived from pdb_info will be used.
References update_energy_.
|
inline |
References update_energy_.
|
inline |
Return current update interval.
References update_interval_.
|
inline |
Set current minimum update interval 't' in seconds. Mover will not send anyinformation to PyMOL before atleast 't' secons has passes since last packet was sent. default value is 0, - no packets are skipped.
References protocols::hybridization::t, and update_interval_.
|
private |
Referenced by apply(), and energy_type().
|
private |
Should PyMOL keep history of all models that was sent? - Default is false.
Referenced by apply(), keep_history(), parse_my_tag(), print(), send_any(), send_energy(), send_hbonds(), send_membrane_planes(), send_RAW_Energies(), and show().
|
private |
Time stamp from where last packet was sent.
Referenced by is_it_time(), and show().
|
private |
Actual link object.
Referenced by apply(), get_link(), parse_my_tag(), print(), send_any(), send_energy(), send_hbonds(), send_membrane_planes(), send_RAW_Energies(), set_link(), and show().
|
private |
Name of model in pymol.
Referenced by get_PyMOL_model_name(), pymol_name(), and set_PyMOL_model_name().
|
private |
Referenced by apply(), show(), and update_energy().
|
private |
Update interval in seconds.
Referenced by is_it_time(), show(), and update_interval().
|
private |
If pose is a membrane pose, send planes.
Referenced by apply().