Rosetta
|
A set of related grids. More...
#include <GridSet.hh>
Public Types | |
typedef std::map< std::string, core::Real > | ScoreMap |
Public Member Functions | |
GridSet () | |
GridSet (GridSet const &src) | |
~GridSet () override | |
GridSetOP | clone () const |
void | width (core::Real width) |
set width (must be done before initialization) More... | |
void | resolution (core::Real resolution) |
set resolution (must be done before initialization) More... | |
void | chain (char chain) |
set ligand chain (must be done before initialization) More... | |
core::Real | width () const |
get grid width More... | |
core::Real | resolution () const |
get grid resoultion More... | |
char | chain () const |
get ligand chain More... | |
void | set_normalization_function (std::string norm_function_name) |
set normalization function More... | |
bool | is_normalization_enabled () const |
is normalization applied during scoring? More... | |
void | set_qsar_map (qsarMapCOP qsar_map) |
set the qsar_map More... | |
bool | is_qsar_map_attached () const |
is a qsar map attached to the grid manager? More... | |
void | reinitialize (core::pose::Pose const &pose, core::Vector const ¢er) |
Reinitialize the included grids with the given information. More... | |
GridBaseCOP | get_grid (std::string const &name) const |
void | add_grid (std::string const &name, GridBaseOP grid, core::Real weight=1.0) |
Add a grid to the GridSet under the given name. More... | |
void | make_new_grid (utility::tag::TagCOP tag) |
make a new grid from grid tag, and insert it into the grid manager More... | |
bool | has_grid (std::string const &name) const |
Returns true if we already have a grid with the given name. More... | |
utility::vector1< std::string > | get_grid_names () const |
get a list of grid names More... | |
core::Size | size () const |
return the number of grids More... | |
core::Real | average_score (utility::vector1< core::conformation::UltraLightResidue > &residues) const |
return the average score of multiple residues on the grid More... | |
core::Real | total_score (core::conformation::UltraLightResidue const &residue) const |
return the total score of a residue on the grid More... | |
core::Real | total_score (core::conformation::Residue const &residue) const |
return the total score of a residue on the grid More... | |
core::Real | total_score (core::pose::Pose const &pose, core::Size const chain_id) const |
return the total score of a chain on the grid More... | |
core::Real | total_score (core::pose::Pose const &pose, utility::vector1< core::Size > const &residues) const |
return the total score for a set of residues on the grid More... | |
ScoreMap | grid_scores (core::conformation::Residue const &residue) const |
ScoreMap | grid_scores (core::pose::Pose const &pose, utility::vector1< core::Size > const &residues) const |
ScoreMap | atom_score (core::pose::Pose const &pose, core::conformation::Residue const &residue, core::Size atomindex) const |
get a map of (unweighted, unnormalized) scoring terms and scores for each term given a residue and atom number More... | |
bool | is_in_grid (utility::vector1< core::conformation::UltraLightResidue > const &residues) const |
check if all atoms in all the ligands are in grid More... | |
bool | is_in_grid (core::conformation::UltraLightResidue const &residue) const |
check to see if all atoms in the ligand are in the grid More... | |
bool | is_in_grid (core::conformation::Residue const &residue) const |
check to see if all atoms in the ligand are in the grid More... | |
std::string | hash_fingerprint () const |
Return a string representing the settings of this GridSet. More... | |
void | write_grids (std::string prefix) const |
write all grids out using the BRIX format More... | |
utility::json_spirit::Value | serialize () const |
serialize the current map to a JSON object. More... | |
void | deserialize (utility::json_spirit::mArray data) |
deserialize the JSON object to a map. More... | |
Private Types | |
typedef std::map< std::string, GridBaseOP > | MappingType |
Private Member Functions | |
template<class GridScorable > | |
core::Real | total_score (utility::vector1< GridScorable const * > const &items) const |
Return a single weighted, normalized score for all items Templated to allow for common implementation between Residue and UltraLightResidue. More... | |
core::Real | normalize (core::Real total_score, utility::vector1< core::conformation::UltraLightResidue const * > const &items) const |
Normalize a score based on the passed items;. More... | |
core::Real | normalize (core::Real total_score, utility::vector1< core::conformation::Residue const * > const &items) const |
Normalize a score based on the passed items;. More... | |
template<class GridScorable > | |
ScoreMap | grid_scores (utility::vector1< GridScorable const * > const &items) const |
Return a map of summed unweighted, unormalized scores for each grid. Templated to allow for common implementation between Residue and UltraLightResidue. More... | |
Private Attributes | |
MappingType | grids_ |
std::map< std::string, core::Real > | grid_weights_ |
core::Real | width_ = 40 |
core::Real | resolution_ = 0.25 |
char | chain_ = 'X' |
qsar::qsarMapCOP | qsar_map_ |
ScoreNormalizationCOP | norm_function_ |
A set of related grids.
|
private |
typedef std::map< std::string, core::Real > protocols::qsar::scoring_grid::GridSet::ScoreMap |
|
default |
protocols::qsar::scoring_grid::GridSet::GridSet | ( | GridSet const & | src | ) |
References grids_, and core::scoring::pair.
|
overridedefault |
void protocols::qsar::scoring_grid::GridSet::add_grid | ( | std::string const & | name, |
GridBaseOP | grid, | ||
core::Real | weight = 1.0 |
||
) |
Add a grid to the GridSet under the given name.
References grid_weights_, and grids_.
Referenced by make_new_grid().
GridSet::ScoreMap protocols::qsar::scoring_grid::GridSet::atom_score | ( | core::pose::Pose const & | pose, |
core::conformation::Residue const & | residue, | ||
core::Size | atomindex | ||
) | const |
get a map of (unweighted, unnormalized) scoring terms and scores for each term given a residue and atom number
References grid_weights_, grids_, and qsar_map_.
core::Real protocols::qsar::scoring_grid::GridSet::average_score | ( | utility::vector1< core::conformation::UltraLightResidue > & | residues | ) | const |
return the average score of multiple residues on the grid
References protocols::hybridization::score, and total_score().
|
inline |
get ligand chain
References chain_.
|
inline |
GridSetOP protocols::qsar::scoring_grid::GridSet::clone | ( | ) | const |
Referenced by protocols::qsar::scoring_grid::GridManager::get_grids().
void protocols::qsar::scoring_grid::GridSet::deserialize | ( | utility::json_spirit::mArray | data | ) |
deserialize the JSON object to a map.
References grids_.
GridBaseCOP protocols::qsar::scoring_grid::GridSet::get_grid | ( | std::string const & | name | ) | const |
References grids_.
utility::vector1< std::string > protocols::qsar::scoring_grid::GridSet::get_grid_names | ( | ) | const |
get a list of grid names
References grids_.
GridSet::ScoreMap protocols::qsar::scoring_grid::GridSet::grid_scores | ( | core::conformation::Residue const & | residue | ) | const |
Referenced by grid_scores(), and total_score().
GridSet::ScoreMap protocols::qsar::scoring_grid::GridSet::grid_scores | ( | core::pose::Pose const & | pose, |
utility::vector1< core::Size > const & | residues | ||
) | const |
References grid_scores(), and core::pose::Pose::residue().
|
private |
Return a map of summed unweighted, unormalized scores for each grid. Templated to allow for common implementation between Residue and UltraLightResidue.
Yes, raw pointer. This is for speed reasons (don't have to copy objects) and because this is a class-internal implementation detail. Do not publically expose this interface.
bool protocols::qsar::scoring_grid::GridSet::has_grid | ( | std::string const & | name | ) | const |
Returns true if we already have a grid with the given name.
References grids_.
Referenced by make_new_grid().
std::string protocols::qsar::scoring_grid::GridSet::hash_fingerprint | ( | ) | const |
Return a string representing the settings of this GridSet.
This should encapsulate everything that doesn't change with a call to reinitialize() The string is not meant to be interpretable.
References chain_, grid_weights_, grids_, norm_function_, core::scoring::pair, qsar_map_, resolution_, and width_.
Referenced by protocols::qsar::scoring_grid::GridManager::compute_hash().
bool protocols::qsar::scoring_grid::GridSet::is_in_grid | ( | core::conformation::Residue const & | residue | ) | const |
check to see if all atoms in the ligand are in the grid
References grids_.
bool protocols::qsar::scoring_grid::GridSet::is_in_grid | ( | core::conformation::UltraLightResidue const & | residue | ) | const |
check to see if all atoms in the ligand are in the grid
References grids_.
bool protocols::qsar::scoring_grid::GridSet::is_in_grid | ( | utility::vector1< core::conformation::UltraLightResidue > const & | residues | ) | const |
check if all atoms in all the ligands are in grid
bool protocols::qsar::scoring_grid::GridSet::is_normalization_enabled | ( | ) | const |
is normalization applied during scoring?
References norm_function_.
bool protocols::qsar::scoring_grid::GridSet::is_qsar_map_attached | ( | ) | const |
is a qsar map attached to the grid manager?
References qsar_map_.
void protocols::qsar::scoring_grid::GridSet::make_new_grid | ( | utility::tag::TagCOP | tag | ) |
make a new grid from grid tag, and insert it into the grid manager
References add_grid(), has_grid(), and protocols::qsar::scoring_grid::TR().
|
private |
Normalize a score based on the passed items;.
Yes, raw pointer. This is to interface with the other functions. Do not publically expose this interface.
References norm_function_, protocols::hybridization::score, and protocols::qsar::scoring_grid::TR().
|
private |
Normalize a score based on the passed items;.
Yes, raw pointer. This is to interface with the other functions. Do not publically expose this interface.
References norm_function_, protocols::hybridization::score, and protocols::qsar::scoring_grid::TR().
Referenced by total_score().
void protocols::qsar::scoring_grid::GridSet::reinitialize | ( | core::pose::Pose const & | pose, |
core::Vector const & | center | ||
) |
Reinitialize the included grids with the given information.
References core::conformation::membrane::center, chain_, grids_, resolution_, protocols::qsar::scoring_grid::TR(), and width_.
|
inline |
get grid resoultion
References resolution_.
|
inline |
set resolution (must be done before initialization)
References resolution(), and resolution_.
Referenced by resolution().
utility::json_spirit::Value protocols::qsar::scoring_grid::GridSet::serialize | ( | ) | const |
serialize the current map to a JSON object.
References grids_.
void protocols::qsar::scoring_grid::GridSet::set_normalization_function | ( | std::string | norm_function_name | ) |
set normalization function
References protocols::qsar::scoring_grid::get_score_normalization_function(), and norm_function_.
void protocols::qsar::scoring_grid::GridSet::set_qsar_map | ( | qsarMapCOP | qsar_map | ) |
set the qsar_map
References qsar_map_.
core::Size protocols::qsar::scoring_grid::GridSet::size | ( | ) | const |
return the number of grids
References grids_.
Referenced by protocols::ligand_docking::get_ligand_grid_scores().
core::Real protocols::qsar::scoring_grid::GridSet::total_score | ( | core::conformation::Residue const & | residue | ) | const |
return the total score of a residue on the grid
References total_score().
core::Real protocols::qsar::scoring_grid::GridSet::total_score | ( | core::conformation::UltraLightResidue const & | residue | ) | const |
return the total score of a residue on the grid
Referenced by average_score(), and total_score().
core::Real protocols::qsar::scoring_grid::GridSet::total_score | ( | core::pose::Pose const & | pose, |
core::Size const | chain_id | ||
) | const |
return the total score of a chain on the grid
References core::pose::get_resnums_for_chain_id(), and total_score().
core::Real protocols::qsar::scoring_grid::GridSet::total_score | ( | core::pose::Pose const & | pose, |
utility::vector1< core::Size > const & | residues | ||
) | const |
return the total score for a set of residues on the grid
References core::pose::Pose::residue(), and total_score().
|
private |
Return a single weighted, normalized score for all items Templated to allow for common implementation between Residue and UltraLightResidue.
Yes, raw pointer. This is for speed reasons (don't have to copy objects) and because this is a class-internal implementation detail. Do not publically expose this interface.
References grid_scores(), grid_weights_, norm_function_, normalize(), and protocols::hybridization::score.
|
inline |
get grid width
References width_.
|
inline |
void protocols::qsar::scoring_grid::GridSet::write_grids | ( | std::string | prefix | ) | const |
write all grids out using the BRIX format
References grids_.
|
private |
Referenced by chain(), hash_fingerprint(), and reinitialize().
|
private |
Referenced by add_grid(), atom_score(), hash_fingerprint(), and total_score().
|
private |
Referenced by add_grid(), atom_score(), deserialize(), get_grid(), get_grid_names(), grid_scores(), GridSet(), has_grid(), hash_fingerprint(), is_in_grid(), reinitialize(), serialize(), size(), and write_grids().
|
private |
Referenced by hash_fingerprint(), is_normalization_enabled(), normalize(), set_normalization_function(), and total_score().
|
private |
Referenced by atom_score(), grid_scores(), hash_fingerprint(), is_qsar_map_attached(), and set_qsar_map().
|
private |
Referenced by hash_fingerprint(), reinitialize(), and resolution().
|
private |
Referenced by hash_fingerprint(), reinitialize(), and width().