|
IMP Reference Guide
develop.7482b7c7af, 2026/12/05
The Integrative Modeling Platform
|
#include <IMP/core/StatisticalPairScore.h>
Create a pairwise statistical potential from a file. The Keys passed as a template argument are used to determine how to map the names of the types as described in the loaded file to indexes. That is, if atom::ResidueKey is passed as the Keys, the potential will expect a file which has one line for each pair of residue names.
The expected file format is:
bin_width number_a number_b [offset]
key_0a key_0b bin0 bin1 bin2...
key_1a key_1b bin0 bin1 bin2...
The order of the lines (after the first one) does not matter. The bin_width is how much distance is allocated per bin (the distance used is that between the points). number_a and number_b are the numbers of particle types (number_b should only be specified if BIPARTITE is set).
| [in] | Key | is an IMP::Key which maps between names and indices |
| [in] | BIPARTITE | If true, the two sets of particles being stored are different (e.g. a protein atom and a ligand atom), otherwise they are assumed to both be the same. Appropriate values must be provided in the file. |
| [in] | INTERPOLATE | If true, even the scores without derivatives are spline interpolated. If false, only the evaluation of derivatives is interpolated with a spline. |
Definition at line 59 of file StatisticalPairScore.h.
Public Member Functions | |
| StatisticalPairScore (IntKey k, double threshold, TextInput data_file) | |
| StatisticalPairScore (IntKey k, double threshold, TextInput data_file, unsigned int shift) | |
| Public Member Functions inherited from IMP::score_functor::DistancePairScore< score_functor::Statistical< Key, BIPARTITE, INTERPOLATE, false > > | |
| DistancePairScore (const DistanceScore &t0, std::string name="FunctorDistancePairScore %1%") | |
| virtual ModelObjectsTemp | do_get_inputs (Model *m, const ParticleIndexes &pis) const override |
| Overload this method to specify the inputs. | |
| double | evaluate_if_good_indexes (Model *m, const ParticleIndexPairs &p, DerivativeAccumulator *da, double max, unsigned int lower_bound, unsigned int upper_bound, bool all_indexes_checked=false) const override |
| virtual double | evaluate_index (Model *m, const ParticleIndexPair &pip, DerivativeAccumulator *da) const override |
| Compute the score and the derivative if needed. | |
| double | evaluate_indexes (Model *m, const ParticleIndexPairs &p, DerivativeAccumulator *da, unsigned int lower_bound, unsigned int upper_bound, bool all_indexes_checked=false) const override final |
| Compute the score and the derivative if needed over a set. | |
| double | evaluate_indexes_delta (Model *m, const ParticleIndexPairs &p, DerivativeAccumulator *da, const std::vector< unsigned > &indexes, std::vector< double > &score, bool all_indexes_checked=false) const override final |
| Compute the change in score and the derivative if needed over a set. | |
| double | evaluate_indexes_scores (Model *m, const ParticleIndexPairs &p, DerivativeAccumulator *da, unsigned int lower_bound, unsigned int upper_bound, std::vector< double > &score, bool all_indexes_checked=false) const override final |
| Compute the score and the derivative if needed over a set. | |
| score_functor::Statistical< Key, BIPARTITE, INTERPOLATE, false > & | get_score_functor () |
| virtual std::string | get_type_name () const override |
| virtual ::IMP::VersionInfo | get_version_info () const override |
| Get information about the module and version of the object. | |
| Public Member Functions inherited from IMP::PairScore | |
| PairScore (std::string name="PairScore %1%") | |
| virtual bool | check_indexes (Model *m, const ParticleIndexes &pis) const |
| Check the given particle indexes for necessary attributes. | |
| Restraints | create_current_decomposition (Model *m, const ParticleIndexPair &vt) const |
| virtual double | evaluate_if_good_index (Model *m, const ParticleIndexPair &vt, DerivativeAccumulator *da, double max) const |
| Compute the score and the derivative if needed, only if "good". | |
| Public Member Functions inherited from IMP::ParticleInputs | |
| ModelObjectsTemp | get_inputs (Model *m, const ParticleIndexes &pis) const |
| Get the ModelObjects read when the given list of particles is used. | |
| Public Member Functions inherited from IMP::Object | |
| CheckLevel | get_check_level () const |
| get_derived_object (self) | |
| Return this object cast to the most derived subclass. | |
| LogLevel | get_log_level () const |
| void | set_check_level (CheckLevel l) |
| void | set_log_level (LogLevel l) |
| Set the logging level used in this object. | |
| const std::string & | get_name () const |
| Get the (not necessarily unique) name of this object. | |
| void | set_name (std::string name) |
| void | set_was_used (bool tf) const |
| void | show (std::ostream &out=std::cout) const |
| virtual void | clear_caches () |
Additional Inherited Members | |
| Public Types inherited from IMP::score_functor::DistancePairScore< score_functor::Statistical< Key, BIPARTITE, INTERPOLATE, false > > | |
| typedef score_functor::Statistical< Key, BIPARTITE, INTERPOLATE, false > | DistanceScore |
| Public Types inherited from IMP::PairScore | |
| typedef ParticlePair | Argument |
| typedef ParticleIndexPair | IndexArgument |
| typedef PairModifier | Modifier |
| typedef const ParticlePair & | PassArgument |
| typedef const ParticleIndexPair & | PassIndexArgument |
| Protected Member Functions inherited from IMP::PairScore | |
| virtual Restraints | do_create_current_decomposition (Model *m, const ParticleIndexPair &vt) const |
| Override this to return your own decomposition. | |
| Protected Member Functions inherited from IMP::Object | |
| Object (std::string name) | |
| Construct an object with the given name. | |
| virtual void | do_destroy () |
| IMP::core::StatisticalPairScore< Key, BIPARTITE, INTERPOLATE, SPARSE >::StatisticalPairScore | ( | IntKey | k, |
| double | threshold, | ||
| TextInput | data_file ) |
| [in] | k | The attribute to use for determining the particle types |
| [in] | threshold | The maximum distance to score |
| [in] | data_file | Where to load the file from. |
Definition at line 70 of file StatisticalPairScore.h.
| IMP::core::StatisticalPairScore< Key, BIPARTITE, INTERPOLATE, SPARSE >::StatisticalPairScore | ( | IntKey | k, |
| double | threshold, | ||
| TextInput | data_file, | ||
| unsigned int | shift ) |
| [in] | k | The attribute to use for determining the particle types |
| [in] | threshold | The maximum distance to score |
| [in] | data_file | Where to load the file from. |
| [in] | shift | The offset for the types of the second set of types. eg, if the score is on protein and ligand atoms, the ligand atom types start with the value shift. |
Definition at line 79 of file StatisticalPairScore.h.