|
Rosetta
|
Within EvolutionOptions class combines all options and settings are collected, defaults saved and sanity checks performed before running. More...
#include <EvolutionOptions.hh>
Public Member Functions | |
| EvolutionOptions () | |
| Prepares the all options with standard settings. More... | |
| EvolutionOptions (std::string const &path_to_option_file) | |
| Loads settings from file and fills missing settings with standards. More... | |
| core::Size | get_max_generations () const |
| Returns maximum number of generations. More... | |
| core::Size | get_external_scoring () const |
| Returns number of external scoring runs or zero if evolutionary optimization should be used. More... | |
| utility::vector1< std::string > | get_selector_names () const |
| Returns all selector names. More... | |
| std::string const & | get_selector_type (std::string const &name) const |
| Returns the type of one selector. More... | |
| core::Real | get_selector_parameter (std::string const &name, std::string const ¶meter) const |
| Returns a required parameter for one selector. More... | |
| utility::vector1< std::string > | get_factory_names () const |
| Returns all factory names. More... | |
| std::string const & | get_factory_type (std::string const &name) const |
| Returns the type of one factory. More... | |
| core::Real | get_factory_parameter (std::string const &name, std::string const ¶meter) const |
| Returns a required parameter for one factory. More... | |
| utility::vector1< std::pair< std::string, std::string > > const & | get_selector_factory_links () const |
| Return the list of factory and selector links. The order defines the order of appliance. More... | |
| std::string const & | get_path_to_external_smiles () const |
| Returns the path to a list of smiles which will all be scored. More... | |
| std::string const & | get_path_to_reactions () const |
| Returns the path to a list of reactions in SMARTS, defining combinatorial rules. More... | |
| std::string const & | get_path_to_reagents () const |
| Returns the path to a list of reagents in SMILES defining the fragments for combination. More... | |
| std::map< std::string, std::map< std::string, core::Size > > const & | get_pop_init_options () const |
| Returns a map of all used pop initialization procedures. More... | |
| core::Size | get_population_supported_size () const |
| Returns how many individuals are supported per generation, essentially defining how many can survive. More... | |
| std::string const & | get_main_selector () const |
| Returns the name of the main selector. More... | |
| std::string const & | get_main_scfx () const |
| Returns the name of the score function used for the main scores within the scorer. More... | |
| std::string const & | get_path_score_memory () const |
| Returns the path to a score memory file. More... | |
| std::string const & | get_ligand_chain () const |
| Returns the name of the ligand chain used by all movers. More... | |
| core::Size | get_n_scoring_runs () const |
| Returns the number of scoring runs. More... | |
| std::string const & | get_pose_dir_path () const |
| Returns the path to directory where all poses will be saved. More... | |
| core::Real | get_similarity_penalty () const |
| Return the similarity penalty for similar ligands in one generation. More... | |
| core::Real | get_similarity_penalty_threshold () const |
| Return the identity penalty threshold after which the penalty is applied to the lower scoring molecule. More... | |
| std::string const & | get_main_term () const |
| Returns the name of the score term to optimize for. More... | |
| std::string const & | get_protocol_path () const |
| core::pose::PoseOP | get_pose_from_stream () |
| numeric::xyzVector< core::Real > | get_start_xyz () const |
Private Member Functions | |
| void | parse_cmdline () |
| void | parse_option_file (std::string const &option_file) |
| void | check_validity () |
| void | check_scorer_setup () |
| void | check_selectors () |
| void | check_factories () |
| void | check_pop_init () |
Private Attributes | |
| core::Size | error_counter_ = 0 |
| Counts how many errors are encountered during parsing to allow report of as many errors as possible per program call. More... | |
| numeric::xyzVector< core::Real > | xyz_ |
| coordinate where centroid of designed ligands will be placed More... | |
| core::import_pose::pose_stream::MetaPoseInputStream | pose_stream_ |
| Stores all input streams to obtain poses. More... | |
| std::string | protocol_path_ |
| Stores the path to the xml protocol. More... | |
| core::Size | external_scoring_ = 0 |
| If set to something else than 0, this will search for smiles list of ligands to score and score them as often as defined here. This is for benchmarking. More... | |
| std::string | path_to_external_smiles_ |
| If external scoring is set to something else than 0, this path will be visited to open a smiles list which will be scored. More... | |
| std::string | path_to_score_memory_ |
| If this is set, the Scorer will try to load scores from this file to use during optimization. More... | |
| core::Size | generations_ |
| Set the number of generations for evolutionary optimization. More... | |
| std::string | path_to_reactions_ |
| Path where to find the reaction definitions. The standard settings assume you use a input and run directory structure. More... | |
| std::string | path_to_reagents_ |
| Path where to find reagents definitions. The standard settings assume you use a input and run directory structure. More... | |
| bool | selectors_defined_ = false |
| std::map< std::string, std::pair< std::string, std::map< std::string, core::Real > > > | selector_options_ |
| Maps selector names to types and parameter list. More... | |
| bool | factories_defined_ = false |
| std::map< std::string, std::pair< std::string, std::map< std::string, core::Real > > > | factory_options_ |
| Maps offspring factory names to types and parameter list. More... | |
| bool | evolution_protocol_defined_ = false |
| utility::vector1< std::pair< std::string, std::string > > | selector_factory_links_ |
| Links a selector to a factory. More... | |
| std::map< std::string, std::map< std::string, core::Size > > | pop_init_options_ |
| Defines how the starting population is generated. For more detail look at Population. More... | |
| core::Size | supported_population_size_ = 50 |
| Defines the size of maximum supported individuals in a population. More... | |
| std::string | main_selector_ = "std_tournament" |
| Sets the name of the main selector. This is used to shrink the population to its supported size. More... | |
| core::Size | score_runs_ |
| Sets how often all movers are applied to a ligand and how often that ligand is scored. More... | |
| std::string | ligand_chain_ |
| Sets the name of the ligand chain. More... | |
| std::string | main_score_term_ |
| Sets which score term will be used for optimization. More... | |
| core::Real | similarity_penalty_ = 0.5 |
| If a molecule has better scoring molecules with a Tanimoto similarity exceeding the set threshold, it will receive a score penalty of for each of them. Penalty is added up. More... | |
| core::Real | similarity_penalty_threshold_ = 0.95 |
| Threshold after which molecules considered being similar and therefore qualified for a penalty. More... | |
| std::string | pose_dump_directory_ |
| Subdirectory within current run directory where all poses will be saved. More... | |
| std::string | scoring_function_ |
| Name of the scoring function used calculate the final base score. More... | |
Within EvolutionOptions class combines all options and settings are collected, defaults saved and sanity checks performed before running.
| protocols::ligand_evolution::EvolutionOptions::EvolutionOptions | ( | ) |
Prepares the all options with standard settings.
References check_validity(), parse_cmdline(), and protocols::TR().
|
explicit |
Loads settings from file and fills missing settings with standards.
References check_validity(), parse_cmdline(), parse_option_file(), and protocols::TR().
|
private |
References error_counter_, factory_options_, selector_factory_links_, selector_options_, supported_population_size_, and protocols::TR().
Referenced by check_validity().
|
private |
References error_counter_, path_to_score_memory_, pop_init_options_, supported_population_size_, and protocols::TR().
Referenced by check_validity().
|
private |
References error_counter_, ligand_chain_, main_score_term_, path_to_score_memory_, pose_dump_directory_, score_runs_, protocols::ligand_evolution::score_terms_, scoring_function_, and protocols::TR().
Referenced by check_validity().
|
private |
References error_counter_, main_selector_, selector_factory_links_, selector_options_, supported_population_size_, and protocols::TR().
Referenced by check_validity().
|
private |
References check_factories(), check_pop_init(), check_scorer_setup(), check_selectors(), error_counter_, external_scoring_, generations_, main_selector_, path_to_external_smiles_, path_to_reactions_, path_to_reagents_, supported_population_size_, core::id::to_string(), and protocols::TR().
Referenced by EvolutionOptions().
| core::Size protocols::ligand_evolution::EvolutionOptions::get_external_scoring | ( | ) | const |
Returns number of external scoring runs or zero if evolutionary optimization should be used.
References external_scoring_.
| utility::vector1< std::string > protocols::ligand_evolution::EvolutionOptions::get_factory_names | ( | ) | const |
Returns all factory names.
References factory_options_.
| core::Real protocols::ligand_evolution::EvolutionOptions::get_factory_parameter | ( | std::string const & | name, |
| std::string const & | parameter | ||
| ) | const |
Returns a required parameter for one factory.
References factory_options_.
| std::string const & protocols::ligand_evolution::EvolutionOptions::get_factory_type | ( | std::string const & | name | ) | const |
Returns the type of one factory.
References factory_options_.
| std::string const & protocols::ligand_evolution::EvolutionOptions::get_ligand_chain | ( | ) | const |
Returns the name of the ligand chain used by all movers.
References ligand_chain_.
| std::string const & protocols::ligand_evolution::EvolutionOptions::get_main_scfx | ( | ) | const |
Returns the name of the score function used for the main scores within the scorer.
References scoring_function_.
| std::string const & protocols::ligand_evolution::EvolutionOptions::get_main_selector | ( | ) | const |
Returns the name of the main selector.
References main_selector_.
| std::string const & protocols::ligand_evolution::EvolutionOptions::get_main_term | ( | ) | const |
Returns the name of the score term to optimize for.
References main_score_term_.
| core::Size protocols::ligand_evolution::EvolutionOptions::get_max_generations | ( | ) | const |
Returns maximum number of generations.
References generations_.
| core::Size protocols::ligand_evolution::EvolutionOptions::get_n_scoring_runs | ( | ) | const |
Returns the number of scoring runs.
References score_runs_.
| std::string const & protocols::ligand_evolution::EvolutionOptions::get_path_score_memory | ( | ) | const |
Returns the path to a score memory file.
References path_to_score_memory_.
| std::string const & protocols::ligand_evolution::EvolutionOptions::get_path_to_external_smiles | ( | ) | const |
Returns the path to a list of smiles which will all be scored.
References path_to_external_smiles_.
| std::string const & protocols::ligand_evolution::EvolutionOptions::get_path_to_reactions | ( | ) | const |
Returns the path to a list of reactions in SMARTS, defining combinatorial rules.
References path_to_reactions_.
| std::string const & protocols::ligand_evolution::EvolutionOptions::get_path_to_reagents | ( | ) | const |
Returns the path to a list of reagents in SMILES defining the fragments for combination.
References path_to_reagents_.
| std::map< std::string, std::map< std::string, core::Size > > const & protocols::ligand_evolution::EvolutionOptions::get_pop_init_options | ( | ) | const |
Returns a map of all used pop initialization procedures.
References pop_init_options_.
Referenced by protocols::ligand_evolution::Population::initialize_from_evotoptions().
| core::Size protocols::ligand_evolution::EvolutionOptions::get_population_supported_size | ( | ) | const |
Returns how many individuals are supported per generation, essentially defining how many can survive.
References supported_population_size_.
Referenced by protocols::ligand_evolution::Population::initialize_from_evotoptions().
| std::string const & protocols::ligand_evolution::EvolutionOptions::get_pose_dir_path | ( | ) | const |
Returns the path to directory where all poses will be saved.
References pose_dump_directory_.
| core::pose::PoseOP protocols::ligand_evolution::EvolutionOptions::get_pose_from_stream | ( | ) |
| std::string const & protocols::ligand_evolution::EvolutionOptions::get_protocol_path | ( | ) | const |
References protocol_path_.
| utility::vector1< std::pair< std::string, std::string > > const & protocols::ligand_evolution::EvolutionOptions::get_selector_factory_links | ( | ) | const |
Return the list of factory and selector links. The order defines the order of appliance.
References selector_factory_links_.
| utility::vector1< std::string > protocols::ligand_evolution::EvolutionOptions::get_selector_names | ( | ) | const |
Returns all selector names.
References selector_options_.
| core::Real protocols::ligand_evolution::EvolutionOptions::get_selector_parameter | ( | std::string const & | name, |
| std::string const & | parameter | ||
| ) | const |
Returns a required parameter for one selector.
References selector_options_.
| std::string const & protocols::ligand_evolution::EvolutionOptions::get_selector_type | ( | std::string const & | name | ) | const |
Returns the type of one selector.
References selector_options_.
| core::Real protocols::ligand_evolution::EvolutionOptions::get_similarity_penalty | ( | ) | const |
Return the similarity penalty for similar ligands in one generation.
References similarity_penalty_.
| core::Real protocols::ligand_evolution::EvolutionOptions::get_similarity_penalty_threshold | ( | ) | const |
Return the identity penalty threshold after which the penalty is applied to the lower scoring molecule.
References similarity_penalty_threshold_.
| numeric::xyzVector< core::Real > protocols::ligand_evolution::EvolutionOptions::get_start_xyz | ( | ) | const |
References xyz_.
|
private |
References error_counter_, external_scoring_, generations_, core::import_pose::pose_stream::MetaPoseInputStream::has_another_pose(), ligand_chain_, main_score_term_, path_to_external_smiles_, path_to_reactions_, path_to_reagents_, path_to_score_memory_, pose_dump_directory_, pose_stream_, protocol_path_, score_runs_, scoring_function_, core::import_pose::pose_stream::streams_from_cmd_line(), protocols::TR(), protocols::kinmatch::xyz(), and xyz_.
Referenced by EvolutionOptions().
|
private |
References error_counter_, evolution_protocol_defined_, factories_defined_, factory_options_, main_selector_, pop_init_options_, selector_factory_links_, selector_options_, selectors_defined_, similarity_penalty_, similarity_penalty_threshold_, supported_population_size_, and protocols::TR().
Referenced by EvolutionOptions().
|
private |
Counts how many errors are encountered during parsing to allow report of as many errors as possible per program call.
Referenced by check_factories(), check_pop_init(), check_scorer_setup(), check_selectors(), check_validity(), parse_cmdline(), and parse_option_file().
|
private |
Referenced by parse_option_file().
|
private |
If set to something else than 0, this will search for smiles list of ligands to score and score them as often as defined here. This is for benchmarking.
Referenced by check_validity(), get_external_scoring(), and parse_cmdline().
|
private |
Referenced by parse_option_file().
|
private |
Maps offspring factory names to types and parameter list.
Referenced by check_factories(), get_factory_names(), get_factory_parameter(), get_factory_type(), and parse_option_file().
|
private |
Set the number of generations for evolutionary optimization.
Referenced by check_validity(), get_max_generations(), and parse_cmdline().
|
private |
Sets the name of the ligand chain.
Referenced by check_scorer_setup(), get_ligand_chain(), and parse_cmdline().
|
private |
Sets which score term will be used for optimization.
Referenced by check_scorer_setup(), get_main_term(), and parse_cmdline().
|
private |
Sets the name of the main selector. This is used to shrink the population to its supported size.
Referenced by check_selectors(), check_validity(), get_main_selector(), and parse_option_file().
|
private |
If external scoring is set to something else than 0, this path will be visited to open a smiles list which will be scored.
Referenced by check_validity(), get_path_to_external_smiles(), and parse_cmdline().
|
private |
Path where to find the reaction definitions. The standard settings assume you use a input and run directory structure.
Referenced by check_validity(), get_path_to_reactions(), and parse_cmdline().
|
private |
Path where to find reagents definitions. The standard settings assume you use a input and run directory structure.
Referenced by check_validity(), get_path_to_reagents(), and parse_cmdline().
|
private |
If this is set, the Scorer will try to load scores from this file to use during optimization.
Referenced by check_pop_init(), check_scorer_setup(), get_path_score_memory(), and parse_cmdline().
|
private |
Defines how the starting population is generated. For more detail look at Population.
Referenced by check_pop_init(), get_pop_init_options(), and parse_option_file().
|
private |
Subdirectory within current run directory where all poses will be saved.
Referenced by check_scorer_setup(), get_pose_dir_path(), and parse_cmdline().
|
private |
Stores all input streams to obtain poses.
Referenced by get_pose_from_stream(), and parse_cmdline().
|
private |
Stores the path to the xml protocol.
Referenced by get_protocol_path(), and parse_cmdline().
|
private |
Sets how often all movers are applied to a ligand and how often that ligand is scored.
Referenced by check_scorer_setup(), get_n_scoring_runs(), and parse_cmdline().
|
private |
Name of the scoring function used calculate the final base score.
Referenced by check_scorer_setup(), get_main_scfx(), and parse_cmdline().
|
private |
Links a selector to a factory.
Referenced by check_factories(), check_selectors(), get_selector_factory_links(), and parse_option_file().
|
private |
Maps selector names to types and parameter list.
Referenced by check_factories(), check_selectors(), get_selector_names(), get_selector_parameter(), get_selector_type(), and parse_option_file().
|
private |
Referenced by parse_option_file().
|
private |
If a molecule has better scoring molecules with a Tanimoto similarity exceeding the set threshold, it will receive a score penalty of for each of them. Penalty is added up.
Referenced by get_similarity_penalty(), and parse_option_file().
|
private |
Threshold after which molecules considered being similar and therefore qualified for a penalty.
Referenced by get_similarity_penalty_threshold(), and parse_option_file().
|
private |
Defines the size of maximum supported individuals in a population.
Referenced by check_factories(), check_pop_init(), check_selectors(), check_validity(), get_population_supported_size(), and parse_option_file().
|
private |
coordinate where centroid of designed ligands will be placed
Referenced by get_start_xyz(), and parse_cmdline().