|
Rosetta 3.5
|
Defines the interaction graph that will keep track of changes to the hpatch score. More...
#include <HPatchInteractionGraph.fwd.hh>


Public Types | |
| typedef AdditionalBackgroundNodesInteractionGraph < V, E, G > | parent |
Public Types inherited from core::pack::interaction_graph::AdditionalBackgroundNodesInteractionGraph< V, E, G > | |
| typedef std::vector < BackgroundNode< V, E, G > * > | BackgroundNodeVector |
| typedef std::list < BackgroundToFirstClassEdge < V, E, G > * > | BackgroundEdgeList |
| typedef std::list < BackgroundToFirstClassEdge < V, E, G > * >::iterator | BackgroundEdgeListIter |
| typedef std::list < BackgroundToFirstClassEdge < V, E, G > * >::const_iterator | BackgroundEdgeListConstIter |
Public Member Functions | |
| HPatchInteractionGraph (int num_nodes) | |
| virtual | ~HPatchInteractionGraph () |
| pose::Pose const & | pose () const |
| void | set_pose (pose::Pose const &pose) |
| task::PackerTask const & | packer_task () const |
| void | set_packer_task (task::PackerTask const &task) |
| We need a copy of the packer task to figure out which residues are being packed and/or designed. We have to figure the packing options because it determines whether a residue becomes a FirstClass (HPatchNode) node or a background node. This method gets called in IGSupport.cc. More... | |
| rotamer_set::RotamerSets const & | rotamer_sets () const |
| void | set_rotamer_sets (rotamer_set::RotamerSets const &rotsets) |
| void | set_score_weight (Real weight) |
| void | initialize (rotamer_set::RotamerSetsBase const &rot_sets) |
| void | set_num_residues_in_protein (Size num_res) |
| tells the graph how many residues there are total in the protein More... | |
| void | set_num_background_residues (Size num_background_residues) |
| tells the graph how many residues there are as part of the protein that are not part of the combinatorial optimization process – they are part of the background More... | |
| void | set_residue_as_background_residue (int residue) |
| informs the graph that a particular residue is part of the background More... | |
| void | set_background_residue_rotamer_dots (Size residue, conformation::Residue const &rotamer) |
| Creates and inits a RotamerDots object for a background residue. the residue must first have been declared to be a background residue. More... | |
| void | set_rotamer_dots_for_node_state (Size node_index, Size state, conformation::Residue const &rotamer) |
| store the coordinates for a particular rotamer More... | |
| virtual void | prepare_for_simulated_annealing () |
| Prepares the graph to begin simulated annealing. More... | |
| virtual void | blanket_assign_state_0 () |
| assigns state 0 – the unassigned state – to all (first class) vertices in the graph More... | |
| Real | get_hpatch_score () |
| virtual void | set_errorfull_deltaE_threshold (core::PackerEnergy deltaE) |
| Allows the sim-annealer to specify a deltaE threshold above which, it is no longer necessary to be very accurate. More... | |
| virtual void | consider_substitution (int node_ind, int new_state, core::PackerEnergy &delta_energy, core::PackerEnergy &prev_energy_for_node) |
| Returns the (possibly approximate) change in energy induced by switching a particular node from its currently assigned state to some alternate state. More... | |
| core::PackerEnergy | calculate_hpatch_deltaE () |
| void | register_fc_node_in_state0 () |
| void | register_fc_node_affected_by_rotsub (int fc_node_ind) |
| Called by HPatchNodes to specify which first-class Nodes are affected by a given rotamer substitution. If a given consider gets rejected, then fc_nodes_near_rotsub_ gets cleared when reset_from_previous_deltaHpatch_comp. More... | |
| void | register_bg_node_affected_by_rotsub (int bg_node_ind) |
| void | update_disjoint_sets_using_cache (conformation::Residue const &rsd, InvRotamerDots const &invdots, utility::vector1< Size > const &exp_hphobes, Size residue_djs_offset, utility::vector1< utility::vector1< bool > > const &atom_atom_self_overlap, graph::DisjointSets &ds) |
| Helper function for calculating the hpatch score. This function is specific for intra-residue overlaps, the one below is for inter-residue overlaps. The reason they're separate is because the inner loops have different start locations. intra-residue nested loops only have to go over greater-indexed atoms because of commutativity. inter-residue nested loops have to do all ii-res x jj-res atom-atom overlaps. More... | |
| void | update_disjoint_sets_using_cache (conformation::Residue const &rsd1, InvRotamerDots const &invdots1, utility::vector1< Size > const &exp_hphobes1, Size djs_offset_1, conformation::Residue const &rsd2, InvRotamerDots const &invdots2, utility::vector1< Size > const &exp_hphobes2, Size djs_offset_2, utility::vector1< utility::vector1< bool > > const &atom_atom_overlaps, graph::DisjointSets &ds) |
| Helper function for calculating the hpatch score. More... | |
| Real | calculate_alt_state_hpatch_score () |
| Constructs an atom-level graph for the alternate state assignment on the IG and then runs the union-find algorithm on it to obtain the connected components. Each connected component is a surface hydrophobic patch. What the total energy of the IG should be hasn't yet been decided. One possibility will be to assign every CC/patch a score and return the sum as the total score. More... | |
| virtual core::PackerEnergy | commit_considered_substitution () |
| Commits the substitution that the sim annealer had previously asked the graph to consider. Returns the accurate total energy for the graph. More... | |
| virtual core::PackerEnergy | set_network_state (FArray1_int &node_states) |
| Switch the state assignment of every first class node in the graph. Useful, for instance, if you want to switch to the best network state that you've found so far. More... | |
| virtual core::PackerEnergy | get_energy_current_state_assignment () |
| returns the energy of the entire graph under the current network state assignment. Also sends a bunch of information to standard error. Only seems to be called by the MultiCoolAnnealer. More... | |
| virtual int | get_edge_memory_usage () const |
| Should write the state assigned to each first class vertex to the screen. More... | |
| virtual unsigned int | count_static_memory () const |
| virtual unsigned int | count_dynamic_memory () const |
| virtual Real | get_energy_sum_for_vertex_group (Size group_id) |
| returns the sum of the PD energy and the hpatch energy for all members first class members of a user-defined vertex subset. Unimplemented. More... | |
| void | print_internal_energies_for_current_state_assignment () |
| void | print () const |
| useful for debugging More... | |
| int | bg_node_2_resid (Size node_index) |
| Provides read access to the bg to resid array. Returns -1 if the index is not in bounds. More... | |
| std::vector< int > | get_network_state () const |
| Returns the state on each FCNode, but not necessarily in pose resid order. Only used by the unit tests. More... | |
| void | set_observed_sufficient_boolean_true () |
| Sets the observed_sufficient_hpatch_E_to_predict_min_ to true. Only used by the unit tests. More... | |
| void | get_all_sasas (utility::vector1< Real > &node_sasas, utility::vector1< Real > &bgnode_sasas) |
| Iterates over all nodes and bgnodes brute-force recounting. More... | |
| HPatchNode< V, E, G > * | get_hpatch_node (int index) const |
| HPatchBackgroundNode< V, E, G > * | get_hpatch_bg_node (int index) const |
Public Member Functions inherited from core::pack::interaction_graph::AdditionalBackgroundNodesInteractionGraph< V, E, G > | |
| AdditionalBackgroundNodesInteractionGraph (int num_nodes) | |
| AdditionalBackgroundNodesInteractionGraph constructor; no default or copy constructors; no operator =. More... | |
| virtual | ~AdditionalBackgroundNodesInteractionGraph () |
| AdditionalBackgroundNodesInteractionGraph destructor. More... | |
| virtual unsigned int | getTotalMemoryUsage () const |
| Returns an int representing the total amount of memory in bytes used by this graph. More... | |
| int | get_num_background_nodes () const |
Static Public Member Functions | |
| static void | print_hpatch_avoidance_stats () |
| reports on the level of success for hpatch score calculation procrastination More... | |
| static void | reset_hpatch_avoidance_stats () |
| resets static member variables of HPatchIG that measure how worthwhile hpatch calculation procrastination is. More... | |
Protected Member Functions | |
| virtual NodeBase * | create_new_node (int node_index, int num_states) |
| factory method pattern for instantiation of HPatchNode objects, used by InteractionGraphBase class. More... | |
| virtual EdgeBase * | create_new_edge (int index1, int index2) |
| factory method pattern for instantiation of HPatchEdge objects, used by InteractionGraphBase class. More... | |
| virtual BackgroundNode< V, E, G > * | create_background_node (int node_index) |
| factory method pattern for instantiation of HPatchBackgroundNode objects, used by AdditionalBackgroundNodesInteractionGraph class. More... | |
| virtual BackgroundToFirstClassEdge< V, E, G > * | create_background_edge (int fc_node_index, int bg_node_index) |
| factory method pattern for instantiation of HPatchBackgroundEdge objects, used by AdditionalBackgroundNodesInteractionGraph class. More... | |
| void | track_hpatch_E_min () |
| Keeps track of the minimum hpatch score seen. Every 100 substitutions, updates the variable hpatch_score_min_last_100. More... | |
| void | update_internal_energy_totals_hpatch () |
| After every 2^10 commits, the graph traverses its nodes and edges and re-tallies the total energy of the current state assignment. This update prevents the accumulation of numerical drift, increasing accuracy. More... | |
Protected Member Functions inherited from core::pack::interaction_graph::AdditionalBackgroundNodesInteractionGraph< V, E, G > | |
| void | drop_background_edge (BackgroundEdgeListIter iter) |
| Constant time edge removal. More... | |
| void | set_num_background_nodes (int num_bg_nodes) |
| sets the number of background nodes in the graph. Should be called no more than once. Some problem instances do not require background nodes. More... | |
| void | add_background_edge (int first_class_node_index, int bg_node_index) |
| adds a BackgroundToFirstClassEdge to the graph and performs the requisite bookkeepking. More... | |
| BackgroundToFirstClassEdge< V, E, G > * | find_background_edge (int first_class_node_index, int bg_node_index) const |
| returns a pointer to the background edge, identified by the indices of the first and second class nodes it connects. Returns the null pointer if the edge does not exist. Possibly linear time operation (in the number of BackgroundToFirstClassEdges). More... | |
| int | get_num_bg_edges () const |
| BackgroundNode< V, E, G > * | get_background_node (int index) const |
| void | prepare_for_simulated_annealing () |
| invokes prepare_for_simulated_annealing on each of the BackgroundToFirstClassEdges and then invokes prepare_for_simulated_annealing on each of the BackgroundNodes. More... | |
| BackgroundEdgeListConstIter | get_bg_edge_list_begin () const |
| BackgroundEdgeListConstIter | get_bg_edge_list_end () const |
Private Member Functions | |
| void | reset_from_previous_deltaHpatch_comp () |
| Iterates through all FCNodes and BGNodes affected by the last deltaHpatch computation, and resets their state. More... | |
| bool | decide_procrastinate_hpatch_computations (Real const pd_deltaE, Real const threshold) const |
| void | detect_background_residue_and_first_class_residue_overlap () |
| iterates across all pairs of first- and second-class nodes to determine which share sphere overlaps. Adds a HPatchBackgroundEdge between any pair that do. More... | |
| void | initialize_bg_bg_overlaps () |
| computes the background overlaps for all background node pairs More... | |
| void | initialize_bg_bg_atom_atom_overlaps () |
| initializes the atom-atom overlap vector stored by the IG for all the bg-bg node overlaps. More... | |
| utility::vector1 < utility::vector1< bool > > const & | get_bg_bg_atom_atom_overlaps (Size node1_index, Size node2_index) |
| void | init_SASA_radii_from_database () |
| Puts the SASA radii values in the database into the passed in radii array. Temporary location. Should only be done once. More... | |
| HPatchInteractionGraph () | |
| HPatchInteractionGraph (HPatchInteractionGraph< V, E, G > const &) | |
| HPatchInteractionGraph< V, E, G > & | operator= (HPatchInteractionGraph< V, E, G > const &) |
Static Private Attributes | |
| static Size | num_state_substitutions_considered_ = 0 |
| static Size | num_hpatch_comps_procrastinated_ = 0 |
| static Size | num_hpatch_comps_later_made_ = 0 |
| static utility::vector1< Real > | radii_ |
| static bool | initialized_SASA_radii = false |
| static const int | COMMIT_LIMIT_BETWEEN_UPDATES = 4096 |
| static std::string | carbon_atom = "C" |
| static std::string | sulfur_atom = "S" |
Defines the interaction graph that will keep track of changes to the hpatch score.
In addition to implementing the virtual base class methods, this class additionally defines methods relating to keeping track of data relating to hpatch.
Definition at line 29 of file HPatchInteractionGraph.fwd.hh.
| typedef AdditionalBackgroundNodesInteractionGraph< V, E, G > core::pack::interaction_graph::HPatchInteractionGraph< V, E, G >::parent |
Definition at line 576 of file HPatchInteractionGraph.hh.
| core::pack::interaction_graph::HPatchInteractionGraph< V, E, G >::HPatchInteractionGraph | ( | int | num_nodes) |
HPatchInteractionGraph::HPatchInteractionGraph
Definition at line 2868 of file HPatchInteractionGraph.hh.
References core::pack::interaction_graph::HPatchInteractionGraph< V, E, G >::fc_nodes_near_rotsub_.
|
virtual |
HPatchInteractionGraph::~HPatchInteractionGraph
Definition at line 2903 of file HPatchInteractionGraph.hh.
|
private |
|
private |
| int core::pack::interaction_graph::HPatchInteractionGraph< V, E, G >::bg_node_2_resid | ( | Size | node_index) |
Provides read access to the bg to resid array. Returns -1 if the index is not in bounds.
HPatchInteractionGraph::bg_node_2_resid
Definition at line 5045 of file HPatchInteractionGraph.hh.
|
virtual |
assigns state 0 – the unassigned state – to all (first class) vertices in the graph
HPatchInteractionGraph::blanket_assign_state_0
Definition at line 3576 of file HPatchInteractionGraph.hh.
References core::pack::interaction_graph::TR_HIG().
| Real core::pack::interaction_graph::HPatchInteractionGraph< V, E, G >::calculate_alt_state_hpatch_score | ( | ) |
Constructs an atom-level graph for the alternate state assignment on the IG and then runs the union-find algorithm on it to obtain the connected components. Each connected component is a surface hydrophobic patch. What the total energy of the IG should be hasn't yet been decided. One possibility will be to assign every CC/patch a score and return the sum as the total score.
HPatchInteractionGraph::calculate_alt_state_hpatch_score()
Queries all of the Nodes and BGNodes to determine the connectivity assuming the alternate state.
Definition at line 4091 of file HPatchInteractionGraph.hh.
References core::conformation::Residue::atom_name(), core::conformation::Residue::atom_type(), core::graph::DisjointSets::disjoint_set_sizes(), core::graph::DisjointSets::ds_find(), core::chemical::AtomType::element(), core::pack::interaction_graph::SurfacePotential::get_instance(), core::pack::interaction_graph::SurfacePotential::hpatch_score(), core::pack::interaction_graph::SurfacePotential::MAX_HPATCH_AREA, core::pack::interaction_graph::SurfacePotential::MAX_HPATCH_SCORE, core::graph::DisjointSets::node(), core::graph::DS_Node::rank, core::graph::DisjointSets::sets(), core::io::serialization::size(), and core::pack::interaction_graph::TR_HIG().
| core::PackerEnergy core::pack::interaction_graph::HPatchInteractionGraph< V, E, G >::calculate_hpatch_deltaE | ( | ) |
HPatchInteractionGraph< V, E, G >::calculate_hpatch_deltaE()
Definition at line 3876 of file HPatchInteractionGraph.hh.
References core::pack::interaction_graph::TR_HIG().
|
virtual |
Commits the substitution that the sim annealer had previously asked the graph to consider. Returns the accurate total energy for the graph.
HPatchInteractionGraph::commit_considered_substitution
Definition at line 4661 of file HPatchInteractionGraph.hh.
References core::pack::interaction_graph::TR_HIG().
|
virtual |
Returns the (possibly approximate) change in energy induced by switching a particular node from its currently assigned state to some alternate state.
HPatchInteractionGraph::consider_substitution
This function is the 4th major entry point from the Annealer into the HIG.
Also returns the sum of the two body energies for the node in its current state; the sim-annealer accepts state substitutions at higher chance if the original state was also at a poor energy.
| node_ind | - [in] - the index of the (first class) node new_state - [in] - the alternate state that the node should consider delta_energy - [out] - the change in energy induced on the entire graph by substituting a node's current state with the alternate. This energy may be inaccurate if it exceeds a threshold set by the sim-annealer. prev_energy_for_node - [out] - the sum of the pair-wise decomposable portion of the energy function for the node's currently assigned state |
Definition at line 3825 of file HPatchInteractionGraph.hh.
References core::pack::interaction_graph::TR_HIG().
|
virtual |
HPatchInteractionGraph::count_dynamic_memory
Reimplemented from core::pack::interaction_graph::AdditionalBackgroundNodesInteractionGraph< V, E, G >.
Definition at line 4842 of file HPatchInteractionGraph.hh.
|
virtual |
HPatchInteractionGraph::count_static_memory
Definition at line 4833 of file HPatchInteractionGraph.hh.
|
protectedvirtual |
factory method pattern for instantiation of HPatchBackgroundEdge objects, used by AdditionalBackgroundNodesInteractionGraph class.
HPatchInteractionGraph::create_background_edge
Implements core::pack::interaction_graph::AdditionalBackgroundNodesInteractionGraph< V, E, G >.
Definition at line 3155 of file HPatchInteractionGraph.hh.
References core::pack::interaction_graph::TR_HIG().
|
protectedvirtual |
factory method pattern for instantiation of HPatchBackgroundNode objects, used by AdditionalBackgroundNodesInteractionGraph class.
HPatchInteractionGraph::create_background_node
Implements core::pack::interaction_graph::AdditionalBackgroundNodesInteractionGraph< V, E, G >.
Definition at line 3140 of file HPatchInteractionGraph.hh.
References core::pack::interaction_graph::TR_HIG().
|
protectedvirtual |
factory method pattern for instantiation of HPatchEdge objects, used by InteractionGraphBase class.
HPatchInteractionGraph::create_new_edge
Definition at line 3125 of file HPatchInteractionGraph.hh.
References core::pack::interaction_graph::TR_HIG().
|
protectedvirtual |
factory method pattern for instantiation of HPatchNode objects, used by InteractionGraphBase class.
HPatchInteractionGraph::create_new_node
Definition at line 3110 of file HPatchInteractionGraph.hh.
References core::pack::interaction_graph::TR_HIG().
|
private |
HPatchInteractionGraph< V, E, G >::decide_procrastinate_hpatch_computations()
Definition at line 4572 of file HPatchInteractionGraph.hh.
References core::pack::interaction_graph::TR_HIG().
|
private |
iterates across all pairs of first- and second-class nodes to determine which share sphere overlaps. Adds a HPatchBackgroundEdge between any pair that do.
HPatchInteractionGraph::detect_background_residue_and_first_class_residue_overlap
Definition at line 3373 of file HPatchInteractionGraph.hh.
References core::pack::interaction_graph::TR_HIG().
| void core::pack::interaction_graph::HPatchInteractionGraph< V, E, G >::get_all_sasas | ( | utility::vector1< Real > & | node_sasas, |
| utility::vector1< Real > & | bgnode_sasas | ||
| ) |
Iterates over all nodes and bgnodes brute-force recounting.
HPatchInteractionGraph< V, E, G >::get_all_sasas
Definition at line 5025 of file HPatchInteractionGraph.hh.
|
private |
HPatchBackgroundNode::get_bg_bg_atom_atom_overlaps
Definition at line 3429 of file HPatchInteractionGraph.hh.
|
virtual |
Should write the state assigned to each first class vertex to the screen.
HPatchInteractionGraph::print_current_state_assignment HPatchInteractionGraph::get_edge_memory_usage
Should return a measurement of the memory used by the interaction graph to store the rotamer pair energies. Unimplemented.
Definition at line 4824 of file HPatchInteractionGraph.hh.
|
virtual |
returns the energy of the entire graph under the current network state assignment. Also sends a bunch of information to standard error. Only seems to be called by the MultiCoolAnnealer.
HPatchInteractionGraph::get_energy_current_state_assignment
Definition at line 4766 of file HPatchInteractionGraph.hh.
|
virtual |
returns the sum of the PD energy and the hpatch energy for all members first class members of a user-defined vertex subset. Unimplemented.
HPatchInteractionGraph::get_energy_sum_for_vertex_group
Definition at line 4860 of file HPatchInteractionGraph.hh.
|
inline |
Definition at line 687 of file HPatchInteractionGraph.hh.
References core::pack::interaction_graph::AdditionalBackgroundNodesInteractionGraph< V, E, G >::get_background_node().
|
inline |
Definition at line 682 of file HPatchInteractionGraph.hh.
| Real core::pack::interaction_graph::HPatchInteractionGraph< V, E, G >::get_hpatch_score | ( | ) |
| std::vector< int > core::pack::interaction_graph::HPatchInteractionGraph< V, E, G >::get_network_state | ( | ) | const |
Returns the state on each FCNode, but not necessarily in pose resid order. Only used by the unit tests.
HPatchInteractionGraph::get_network_state
Definition at line 4995 of file HPatchInteractionGraph.hh.
|
private |
Puts the SASA radii values in the database into the passed in radii array. Temporary location. Should only be done once.
HPatchInteractionGraph::init_SASA_radii_from_database()
Definition at line 3937 of file HPatchInteractionGraph.hh.
References core::chemical::AtomTypeSet::extra_parameter_index(), and core::chemical::AtomTypeSet::n_atomtypes().
| void core::pack::interaction_graph::HPatchInteractionGraph< V, E, G >::initialize | ( | rotamer_set::RotamerSetsBase const & | rot_sets_base) |
HPatchInteractionGraph::initialize()
Oldest comments: In ++, there's a file InteractionGraphSupport.cc which is an analog of the InteractionGraphFactory in mini. In ++, the InteractionGraphSupport file instantiates and initializes, depending on the command line switches, the right interaction graph. For the HPatchInteractionGraph, it first initializes the PDInteractionGraph (which is the base) and then calls the HPatchIG initialize method.
The thing is that this initialize method can't be called when the graph is constructed in the InteractionGraphFactory. The reason is that the PDInteractionGraph base initialize() method is NOT called until later in the pack rotamers process. (Actually it's called from within rotsets->compute_energies().) Only after the rotsets->compute energies returns can I stick in an initialize() method call for the HPatchInteractionGraph (HIG). But then that's too late because the rotsets object has already computed some energies. Perhaps that's ok though. The rotsets object only calculates the PD energy terms - it doesn't do anything with non-PD terms.
If a HIG init method is called during construction of the HIG, then the init method that's called by the rotsets object causes all the node info that was set in the HIG init method to be lost because the rotsets init method recreates all the nodes in the interaction graph when it runs. (That was a fun behaviour to figure out.)
So the solution I'm going for is to call this init method in the prepare for simulated annealing method of this class. That gets called just before SA starts, so it will do the task above then. It doesn't really matter when the task gets done as long as it happens before SA starts. This also means that the HIG will now have to keep a reference to the Pose, the Task, and the RotamerSets objects since it needs all of these things to do tasks 1) and 2). (For the port of this HPatchIG, we might not need the task and rotamer sets objects.)
prepare_for_simulated_annealing gets called by the FixbbSA::run() method. Before this method, the rotamersets object has called compute_energies() (the whole process being started in pack_rotamers) which calls initialize() on the IG. I need to place the HIG init method directly after the IG init method that the RS object calls.
Newest comments: Don't call the parent classes initialize method because that calls create_new_node for all designable positions, making every node in the graph a first class residue (erroneously!). Then after that, some residues are set as background residues so I'm surprised things were even working at all! Unfortunately, the class hierarchy makes setting designable residues that are surface-exposed be the only FirstClassNodes difficult. What has to happen is that non-designable positions will be the BGNodes and molten positions will be FCNodes. Then, each type of node will store a boolean flagging whether it is surface-exposed or not. Then, when a consider sub call is made, the nodes will immediately check the value of the boolean and return 0 immediately if it's not surface-exposed.
07/16/2008- Unfortunately, I can't just replicate all of the functionality of the parent classes initialize method here because it's different for PDIGs and LMIGs. And some of the their corresponding function calls are not defined in both classes so I get compile errors if I try to do it this way. There are a few possible solutions I could use for the problem of schizophrenic node (nodes which are getting assigned as BG and FC nodes). 1) I could just use Andrew's LFs designation that any designable or packable node is a FC node and any node not being packed or designed is a BGNode. This approach is the easiest to implement but since nodes that are only being packed aren't changing in sequence, their surface score shouldn't be changing so it's an inefficiency. 2) I could change the "create_node" call in this class to return either a Node or BGNode depending on what the packer_task has in it. Then the parent templated IG classes would get the right kind of node. But then, I would have to potentially change the AddtlBGNodesIG class method "setNumResiduesAsBackground" because in that call is a for loop which creates background nodes. This would complicate creating new non-PD terms in mini, because it would be specific for this case (surface). 3) Figure out some OO way of handling the distinction between packable and nonpackable residues. The OO-correct way to do this would probably be to subclass AdditionalBackgroundNodesInteractionGraph to something like SASAExposedNodesInteractionGraph and then make the HPatchInteractionGraph inherit that one. Then "FirstClassNodes" would be nodes that are designable and surface-exposed; all other nodes would be "BackgroundNodes".
Since it would require alot of work to write another derived class for probably not that significant (or necessary) performance improvement, I'll just make packable residues be FC nodes also. So continue to call the parent classes initialize() method. Just set residues which are not packable nor designable to BG nodes.
Newest Newest comments": The above text was the case for the SurfaceIG. Turns out that we really do want all packable and designable positions to be FC Nodes. So there's no inefficiency here, as was the case for the SurfaceIG.
Definition at line 3030 of file HPatchInteractionGraph.hh.
References core::pack::rotamer_set::RotamerSets::nmoltenres(), and core::pack::interaction_graph::TR_HIG().
|
private |
initializes the atom-atom overlap vector stored by the IG for all the bg-bg node overlaps.
HPatchBackgroundNode::initialize_bg_bg_atom_atom_overlaps
The hard part is figuring out what kind of data structure I can use here that will make it easy for the IG to get what it needs when it's calculating a score.
Making the data structure a 4D vector, i.e. a vector of vectors of vectors of vectors of bools. The outer two vectors are the two bgnode ids we're checking overlap for. The innermost two vectors are the atom-atom overlap information for two given bgnode ids. Only the higher indexed nodes have to contain vectors of vectors of bools. For instance, the outer two vectors will have (1,2), (1,3), (1,4), ... (2,3), (2,4), (2,5), ..., (3,4), (3,5), (3,6), etc The inner two vectors is just an all-atoms-in-ii x all-atoms-in-jj.
Definition at line 3464 of file HPatchInteractionGraph.hh.
References core::kinematics::tree::distance_squared(), and core::scoring::get_overlap().
|
private |
computes the background overlaps for all background node pairs
HPatchInteractionGraph::initialize_bg_bg_overlaps
Definition at line 3411 of file HPatchInteractionGraph.hh.
|
private |
|
inline |
Definition at line 585 of file HPatchInteractionGraph.hh.
References core::pack::interaction_graph::HPatchInteractionGraph< V, E, G >::packer_task_.
|
inline |
Definition at line 582 of file HPatchInteractionGraph.hh.
References core::pack::interaction_graph::HPatchInteractionGraph< V, E, G >::pose_.
|
virtual |
Prepares the graph to begin simulated annealing.
HPatchInteractionGraph::prepare_for_simulated_annealing
Definition at line 3309 of file HPatchInteractionGraph.hh.
References core::pack::interaction_graph::TR_HIG().
| void core::pack::interaction_graph::HPatchInteractionGraph< V, E, G >::print | ( | ) | const |
useful for debugging
HPatchInteractionGraph::write_dot_kinemage HPatchInteractionGraph::print
Definition at line 4934 of file HPatchInteractionGraph.hh.
|
static |
reports on the level of success for hpatch score calculation procrastination
HPatchInteractionGraph::print_hpatch_avoidance_stats
Definition at line 3763 of file HPatchInteractionGraph.hh.
References core::pack::interaction_graph::TR_STATS().
Referenced by core::pack::interaction_graph::HPatchInteractionGraph< V, E, G >::set_errorfull_deltaE_threshold(), and core::pack::interaction_graph::HPatchInteractionGraph< V, E, G >::update_internal_energy_totals_hpatch().
| void core::pack::interaction_graph::HPatchInteractionGraph< V, E, G >::print_internal_energies_for_current_state_assignment | ( | ) |
HPatchInteractionGraph::print_internal_energies_for_current_state_assignment
Definition at line 4870 of file HPatchInteractionGraph.hh.
References core::pack::interaction_graph::TR_HIG().
| void core::pack::interaction_graph::HPatchInteractionGraph< V, E, G >::register_bg_node_affected_by_rotsub | ( | int | bg_node_ind) |
Definition at line 3922 of file HPatchInteractionGraph.hh.
| void core::pack::interaction_graph::HPatchInteractionGraph< V, E, G >::register_fc_node_affected_by_rotsub | ( | int | fc_node_ind) |
Called by HPatchNodes to specify which first-class Nodes are affected by a given rotamer substitution. If a given consider gets rejected, then fc_nodes_near_rotsub_ gets cleared when reset_from_previous_deltaHpatch_comp.
HPatchInteractionGraph::register_fc_node_affected_by_rotsub()
Definition at line 3914 of file HPatchInteractionGraph.hh.
| void core::pack::interaction_graph::HPatchInteractionGraph< V, E, G >::register_fc_node_in_state0 | ( | ) |
Definition at line 3900 of file HPatchInteractionGraph.hh.
|
private |
Iterates through all FCNodes and BGNodes affected by the last deltaHpatch computation, and resets their state.
HPatchInteractionGraph::reset_from_previous_deltaHpatch_comp
Definition at line 4615 of file HPatchInteractionGraph.hh.
References core::pack::interaction_graph::TR_HIG().
|
static |
resets static member variables of HPatchIG that measure how worthwhile hpatch calculation procrastination is.
HPatchInteractionGraph::reset_hpatch_avoidance_stats
Definition at line 3788 of file HPatchInteractionGraph.hh.
Referenced by core::pack::interaction_graph::HPatchInteractionGraph< V, E, G >::set_errorfull_deltaE_threshold().
|
inline |
Definition at line 588 of file HPatchInteractionGraph.hh.
References core::pack::interaction_graph::HPatchInteractionGraph< V, E, G >::rotamer_sets_.
| void core::pack::interaction_graph::HPatchInteractionGraph< V, E, G >::set_background_residue_rotamer_dots | ( | Size | residue, |
| conformation::Residue const & | rotamer | ||
| ) |
Creates and inits a RotamerDots object for a background residue. the residue must first have been declared to be a background residue.
HPatchInteractionGraph::set_background_residue_rotamer_dots
Definition at line 3254 of file HPatchInteractionGraph.hh.
|
virtual |
Allows the sim-annealer to specify a deltaE threshold above which, it is no longer necessary to be very accurate.
HPatchInteractionGraph::set_errorfull_deltaE_threshold
Definition at line 3741 of file HPatchInteractionGraph.hh.
References core::pack::interaction_graph::HPatchInteractionGraph< V, E, G >::print_hpatch_avoidance_stats(), core::pack::interaction_graph::HPatchInteractionGraph< V, E, G >::reset_hpatch_avoidance_stats(), and core::pack::interaction_graph::TR_HIG().
|
virtual |
Switch the state assignment of every first class node in the graph. Useful, for instance, if you want to switch to the best network state that you've found so far.
HPatchInteractionGraph::set_network_state
Definition at line 4737 of file HPatchInteractionGraph.hh.
References core::pack::interaction_graph::TR_HIG().
| void core::pack::interaction_graph::HPatchInteractionGraph< V, E, G >::set_num_background_residues | ( | Size | num_background_residues) |
tells the graph how many residues there are as part of the protein that are not part of the combinatorial optimization process – they are part of the background
HPatchInteractionGraph::set_num_background_residues
Definition at line 3198 of file HPatchInteractionGraph.hh.
References core::pack::interaction_graph::TR_HIG().
| void core::pack::interaction_graph::HPatchInteractionGraph< V, E, G >::set_num_residues_in_protein | ( | Size | num_res) |
tells the graph how many residues there are total in the protein
HPatchInteractionGraph::set_num_residues_in_protein
Definition at line 3175 of file HPatchInteractionGraph.hh.
| void core::pack::interaction_graph::HPatchInteractionGraph< V, E, G >::set_observed_sufficient_boolean_true | ( | ) |
Sets the observed_sufficient_hpatch_E_to_predict_min_ to true. Only used by the unit tests.
HPatchInteractionGraph::set_observed_sufficient_boolean_true
Definition at line 5012 of file HPatchInteractionGraph.hh.
| void core::pack::interaction_graph::HPatchInteractionGraph< V, E, G >::set_packer_task | ( | task::PackerTask const & | the_task) |
We need a copy of the packer task to figure out which residues are being packed and/or designed. We have to figure the packing options because it determines whether a residue becomes a FirstClass (HPatchNode) node or a background node. This method gets called in IGSupport.cc.
HPatchInteractionGraph::set_packer_task
Definition at line 2943 of file HPatchInteractionGraph.hh.
References core::pack::task::PackerTask::clone().
| void core::pack::interaction_graph::HPatchInteractionGraph< V, E, G >::set_pose | ( | pose::Pose const & | pose) |
HPatchInteractionGraph::set_pose
Definition at line 2918 of file HPatchInteractionGraph.hh.
References protocols::comparative_modeling::features::G, and core::pack::interaction_graph::TR_HIG().
| void core::pack::interaction_graph::HPatchInteractionGraph< V, E, G >::set_residue_as_background_residue | ( | int | residue) |
informs the graph that a particular residue is part of the background
HPatchInteractionGraph::set_residue_as_background_residue
Definition at line 3227 of file HPatchInteractionGraph.hh.
References core::pack::interaction_graph::TR_HIG().
| void core::pack::interaction_graph::HPatchInteractionGraph< V, E, G >::set_rotamer_dots_for_node_state | ( | Size | node_index, |
| Size | state, | ||
| conformation::Residue const & | rotamer | ||
| ) |
store the coordinates for a particular rotamer
HPatchInteractionGraph::set_rotamer_dots_for_node_state
Definition at line 3277 of file HPatchInteractionGraph.hh.
References core::conformation::Residue::name1(), core::conformation::Residue::seqpos(), and core::pack::interaction_graph::TR_NODE().
| void core::pack::interaction_graph::HPatchInteractionGraph< V, E, G >::set_rotamer_sets | ( | rotamer_set::RotamerSets const & | rotsets) |
HPatchInteractionGraph::set_rotamer_sets
Definition at line 2957 of file HPatchInteractionGraph.hh.
|
inline |
Definition at line 591 of file HPatchInteractionGraph.hh.
References core::pack::interaction_graph::HPatchInteractionGraph< V, E, G >::hpatch_score_weight_.
|
protected |
Keeps track of the minimum hpatch score seen. Every 100 substitutions, updates the variable hpatch_score_min_last_100.
HPatchInteractionGraph< V, E, G >::track_hpatch_E_min
Definition at line 4706 of file HPatchInteractionGraph.hh.
| void core::pack::interaction_graph::HPatchInteractionGraph< V, E, G >::update_disjoint_sets_using_cache | ( | conformation::Residue const & | rsd, |
| InvRotamerDots const & | invdots, | ||
| utility::vector1< Size > const & | exp_hphobes, | ||
| Size | residue_djs_offset, | ||
| utility::vector1< utility::vector1< bool > > const & | atom_atom_overlaps, | ||
| graph::DisjointSets & | ds | ||
| ) |
Helper function for calculating the hpatch score. This function is specific for intra-residue overlaps, the one below is for inter-residue overlaps. The reason they're separate is because the inner loops have different start locations. intra-residue nested loops only have to go over greater-indexed atoms because of commutativity. inter-residue nested loops have to do all ii-res x jj-res atom-atom overlaps.
HPatchInteractionGraph::update_disjoint_sets_using_cache()
Definition at line 3960 of file HPatchInteractionGraph.hh.
References core::pack::interaction_graph::InvRotamerDots::atom_overlap_is_exposed(), core::graph::DisjointSets::ds_find(), and core::graph::DisjointSets::ds_union().
| void core::pack::interaction_graph::HPatchInteractionGraph< V, E, G >::update_disjoint_sets_using_cache | ( | conformation::Residue const & | rsd1, |
| InvRotamerDots const & | invdots1, | ||
| utility::vector1< Size > const & | exp_hphobes1, | ||
| Size | djs_offset_1, | ||
| conformation::Residue const & | rsd2, | ||
| InvRotamerDots const & | invdots2, | ||
| utility::vector1< Size > const & | exp_hphobes2, | ||
| Size | djs_offset_2, | ||
| utility::vector1< utility::vector1< bool > > const & | atom_atom_overlaps, | ||
| graph::DisjointSets & | ds | ||
| ) |
Helper function for calculating the hpatch score.
HPatchInteractionGraph::update_disjoint_sets_using_cache()
Definition at line 4013 of file HPatchInteractionGraph.hh.
References core::pack::interaction_graph::InvRotamerDots::atom_overlap_is_exposed(), core::graph::DisjointSets::ds_find(), and core::graph::DisjointSets::ds_union().
|
protected |
After every 2^10 commits, the graph traverses its nodes and edges and re-tallies the total energy of the current state assignment. This update prevents the accumulation of numerical drift, increasing accuracy.
HPatchInteractionGraph::update_internal_energy_totals_hpatch
Definition at line 3619 of file HPatchInteractionGraph.hh.
References core::pack::interaction_graph::HPatchInteractionGraph< V, E, G >::print_hpatch_avoidance_stats().
|
private |
Definition at line 735 of file HPatchInteractionGraph.hh.
|
private |
Definition at line 775 of file HPatchInteractionGraph.hh.
|
private |
Definition at line 733 of file HPatchInteractionGraph.hh.
|
private |
Definition at line 732 of file HPatchInteractionGraph.hh.
|
private |
Definition at line 747 of file HPatchInteractionGraph.hh.
|
private |
Definition at line 748 of file HPatchInteractionGraph.hh.
|
private |
Definition at line 741 of file HPatchInteractionGraph.hh.
|
private |
Definition at line 742 of file HPatchInteractionGraph.hh.
|
private |
Definition at line 730 of file HPatchInteractionGraph.hh.
|
private |
Definition at line 771 of file HPatchInteractionGraph.hh.
|
staticprivate |
Definition at line 789 of file HPatchInteractionGraph.hh.
|
staticprivate |
Definition at line 787 of file HPatchInteractionGraph.hh.
|
private |
Definition at line 734 of file HPatchInteractionGraph.hh.
|
private |
Definition at line 772 of file HPatchInteractionGraph.hh.
|
private |
Definition at line 783 of file HPatchInteractionGraph.hh.
|
private |
Definition at line 750 of file HPatchInteractionGraph.hh.
|
private |
Definition at line 756 of file HPatchInteractionGraph.hh.
|
private |
Definition at line 752 of file HPatchInteractionGraph.hh.
|
private |
"djs" for DisJoint Sets. An abuse of the idea of an acronym.
Definition at line 745 of file HPatchInteractionGraph.hh.
|
private |
Definition at line 746 of file HPatchInteractionGraph.hh.
|
private |
Definition at line 739 of file HPatchInteractionGraph.hh.
Referenced by core::pack::interaction_graph::HPatchInteractionGraph< V, E, G >::HPatchInteractionGraph().
|
private |
Definition at line 740 of file HPatchInteractionGraph.hh.
|
private |
Definition at line 780 of file HPatchInteractionGraph.hh.
|
private |
Definition at line 779 of file HPatchInteractionGraph.hh.
|
private |
Definition at line 767 of file HPatchInteractionGraph.hh.
|
private |
Definition at line 768 of file HPatchInteractionGraph.hh.
|
private |
Definition at line 725 of file HPatchInteractionGraph.hh.
Referenced by core::pack::interaction_graph::HPatchInteractionGraph< V, E, G >::set_score_weight().
|
staticprivate |
Definition at line 786 of file HPatchInteractionGraph.hh.
|
private |
Definition at line 774 of file HPatchInteractionGraph.hh.
|
private |
Definition at line 782 of file HPatchInteractionGraph.hh.
|
staticprivate |
Definition at line 765 of file HPatchInteractionGraph.hh.
|
staticprivate |
Definition at line 764 of file HPatchInteractionGraph.hh.
|
private |
Definition at line 728 of file HPatchInteractionGraph.hh.
|
staticprivate |
Definition at line 763 of file HPatchInteractionGraph.hh.
|
private |
Definition at line 769 of file HPatchInteractionGraph.hh.
|
private |
Definition at line 727 of file HPatchInteractionGraph.hh.
|
private |
Definition at line 761 of file HPatchInteractionGraph.hh.
|
private |
Definition at line 722 of file HPatchInteractionGraph.hh.
Referenced by core::pack::interaction_graph::HPatchInteractionGraph< V, E, G >::packer_task().
|
private |
Definition at line 721 of file HPatchInteractionGraph.hh.
Referenced by core::pack::interaction_graph::HPatchInteractionGraph< V, E, G >::pose().
|
private |
Definition at line 759 of file HPatchInteractionGraph.hh.
|
staticprivate |
Definition at line 785 of file HPatchInteractionGraph.hh.
|
private |
extract the disjoint sets connected component information by hand (faster)
Definition at line 755 of file HPatchInteractionGraph.hh.
|
private |
Definition at line 729 of file HPatchInteractionGraph.hh.
|
private |
Definition at line 723 of file HPatchInteractionGraph.hh.
Referenced by core::pack::interaction_graph::HPatchInteractionGraph< V, E, G >::rotamer_sets().
|
private |
Definition at line 757 of file HPatchInteractionGraph.hh.
|
private |
Definition at line 738 of file HPatchInteractionGraph.hh.
|
staticprivate |
Definition at line 790 of file HPatchInteractionGraph.hh.
|
private |
Definition at line 777 of file HPatchInteractionGraph.hh.
|
private |
Definition at line 776 of file HPatchInteractionGraph.hh.
1.8.4