OEScore

class OEScore

OEScore is a class for scoring and optimizing poses within the active site. Use of this class is as follows:

  1. Initialize the active site by passing either a receptor (see chapter_receptor chapter) or a protein and box to the OEScore.Initialize method.

  2. Score or optimize the molecules using:

Constructor

OEScore(const unsigned int scoring = OEScoreType::Default)

Constructs OEScore to use the specified scoring function from the OEScoreType namespace.

IsInitialized

bool IsInitialized() const

Returns true if this object has been successfully initialized and is ready to score poses.

Initialize

bool Initialize(const OEBio::OEDesignUnit& receptor)
bool Initialize(const OEChem::OEMolBase& receptor)
bool Initialize(const OEChem::OEMolBase& protein, const OEBoxBase& box)

Sets up this object to score poses within an active site. This function returns true if initialization was successful. This object does not depend upon receptor once this call is completed (i.e. receptor can be destroyed after calling this method). The first overload expects a design unit that contains a receptor. The second overload works on a variation of molecule that contains receptor data. The last overload works with a protein and box enclosing the active site. Method returns true if setup was successful.

GetName

std::string GetName() const

Returns the name of the scoring function.

GetComponentNames

OESystem::OEIterBase<const std::string>* GetComponentNames() const

Returns the name of the scoring function components.

GetHighScoresAreBetter

bool GetHighScoresAreBetter() const

Returns true if higher scores indicate a better result.

Returns false if lower scores indicate a better result.

ScoreLigand

float ScoreLigand(const OEChem::OEMolBase& pose)

Scores a pose within the active site.

pose

Structure of a pose within the active site

If an error occurs this function will return FLT_MAX if OEScore.GetHighScoresAreBetter returns false or -FLT_MAX otherwise.

ScoreAtom

float ScoreAtom(const OEChem::OEAtomBase& atom,
                const OEChem::OEMolBase& pose)

Returns the score of an atom of a given pose within the active site.

atom

Atom of pose to score.

pose

Structure of a pose within the active site

If an error occurs this function will return FLT_MAX if OEScore.GetHighScoresAreBetter returns false or -FLT_MAX otherwise.

ScoreLigandComponent

float ScoreLigandComponent(const OEChem::OEMolBase& pose,
                           std::string compName)

Returns the given component’s contribution to the total score.

pose

Structure of a pose within the active site

compName

Name of the score component to report. Name must be one returned by OEScore.GetComponentNames.

If an error occurs this function will return FLT_MAX if OEScore.GetHighScoresAreBetter returns false or -FLT_MAX otherwise.

ScoreAtomComponent

float ScoreAtomComponent(const OEChem::OEAtomBase& atom,
                         const OEChem::OEMolBase& pose,
                         std::string compName)

Returns the given components contribution to the score of a given atom score.

atom

Atom of pose to score.

pose

Structure of a pose within the active site

compName

Name of the score component to report. Name must be one returned by OEScore.GetComponentNames.

If an error occurs this function will return FLT_MAX if OEScore.GetHighScoresAreBetter returns false or -FLT_MAX otherwise.

SystematicSolidBodyOptimize

Performs a solid body optimization on the pose or poses passed. Three rotational and three translational degrees of freedom are explored, the pose (and protein) are held rigid. A plus and minus rotational step is taken for each rotational and translational degree of freedom (for a total of 3^6 or 729 positions tested for each pose).

Both overloads return true if no error occurred.

bool SystematicSolidBodyOptimize(OEChem::OEMCMolBase& poses,
                                 unsigned int searchResolution
                                   = OESearchResolution::Default)

This overload of OEScore.SystematicSolidBodyOptimize optimizes all poses of an OEMCMolBase.

poses

An OEMCMolBase with conformers that are poses within the active site to be optimized.

searchResolution

Search resolution of the optimization (see OESearchResolution constant namespace).

The optimized poses are returned in poses. This poses retain their original ordering and are not ordered by the new optimized score.

bool SystematicSolidBodyOptimize(OEChem::OEMolBase& pose,
                                 unsigned int searchResolution
                                   = OESearchResolution::Default)

This overload of OEScore.SystematicSolidBodyOptimize optimizes a single pose.

pose

A pose within the active site to be optimized.

searchResolution

Search resolution of the optimization (see OESearchResolution constant namespace).

AnnotatePose

Adds VIDA scoring annotation to the pose or poses passed.

The annotated poses must be written out in either oeb or oeb.gz format and are only viewable in VIDA.

bool AnnotatePose(OEChem::OEMolBase& pose)

This overload of OEScore.AnnotatePose annotates a single pose.

pose

Structure of a pose within the active site

bool AnnotatePose(OEChem::OEMCMolBase& poses)

This overload of OEScore.AnnotatePose annotates all poses of a given ligand.

poses

An OEMCMolBase the conformers of which are poses within the active site.

CacheScoringSetup

This function caches the current scoring setup of the OEScore object onto a receptor object. When another OEScore object is initialized with this receptor the it will read in the cached score data rather than recalculating it from scratch, thus improving the startup time of the OEScore object.

bool CacheScoringSetup(OEBio::OEDesignUnit& receptor, bool clearOldData = true)
bool CacheScoringSetup(OEChem::OEMolBase& receptor, bool clearOldData = true)
receptor

A receptor object. This must be the same receptor object the OEScore object was initialized with or an exact copy.

clearOldData

Flag to clear cached data from a prior call to CacheScoringSetup with this receptor. The cached data can be quite sizable (hundreds of megabytes), so leaving this flag at the default value of true is recommended.

Note

The cached score data on a receptor will be saved when the receptor is written to a file.