![]() |
RDKit
Open-source cheminformatics and machine learning.
|
#include <RGroupDecompData.h>
Classes | |
class | UsedLabels |
Public Member Functions | |
RGroupDecompData (const RWMol &inputCore, RGroupDecompositionParameters inputParams) | |
RGroupDecompData (const std::vector< ROMOL_SPTR > &inputCores, RGroupDecompositionParameters inputParams) | |
void | addCore (const ROMol &inputCore) |
void | prepareCores () |
void | setRlabel (Atom *atom, int rlabel) |
int | getRlabel (Atom *atom) const |
double | scoreFromPrunedData (const std::vector< size_t > &permutation, bool reset=true) |
void | prune () |
std::vector< RGroupMatch > | GetCurrentBestPermutation () const |
void | addCoreUserLabels (const RWMol &core, std::set< int > &userLabels) |
void | addAtoms (RWMol &mol, const std::vector< std::pair< Atom *, Atom * > > &atomsToAdd) |
void | relabelCore (RWMol &core, std::map< int, int > &mappings, UsedLabels &used_labels, const std::set< int > &indexLabels, const std::map< int, std::vector< int > > &extraAtomRLabels) |
void | relabelRGroup (RGroupData &rgroup, const std::map< int, int > &mappings) |
void | relabel () |
double | score (const std::vector< size_t > &permutation, FingerprintVarianceScoreData *fingerprintVarianceScoreData=nullptr) const |
RGroupDecompositionProcessResult | process (bool pruneMatches, bool finalize=false) |
Public Attributes | |
std::map< int, RCore > | cores |
std::map< std::string, int > | newCores |
int | newCoreLabel = EMPTY_CORE_LABEL |
size_t | permutationProduct = 1 |
size_t | previousMatchSize = 0 |
bool | prunePermutations = true |
RGroupDecompositionParameters | params |
std::vector< std::vector< RGroupMatch > > | matches |
std::set< int > | labels |
std::vector< size_t > | permutation |
unsigned int | pruneLength = 0U |
FingerprintVarianceScoreData | prunedFingerprintVarianceScoreData |
std::map< int, std::vector< int > > | userLabels |
std::vector< int > | processedRlabels |
std::map< int, int > | finalRlabelMapping |
RGroupScorer | rGroupScorer |
Definition at line 29 of file RGroupDecompData.h.
|
inline |
Definition at line 57 of file RGroupDecompData.h.
References addCore(), and prepareCores().
|
inline |
Definition at line 64 of file RGroupDecompData.h.
References addCore(), and prepareCores().
|
inline |
Definition at line 277 of file RGroupDecompData.h.
References RDKit::RWMol::addAtom(), RDKit::RWMol::addBond(), RDKit::ROMol::getNumConformers(), RDKit::MolOps::setTerminalAtomCoords(), and RDKit::Bond::SINGLE.
Referenced by relabelCore(), and relabelRGroup().
|
inline |
Definition at line 73 of file RGroupDecompData.h.
References RDKit::RGroupDecompositionParameters::addDummyAtomsToUnlabelledCoreAtoms(), RDKit::RGroupDecompositionParameters::allowMultipleRGroupsOnUnlabelled, cores, and params.
Referenced by RGroupDecompData().
|
inline |
Definition at line 268 of file RGroupDecompData.h.
References RDKit::getRlabels(), and userLabels.
Referenced by relabel().
|
inline |
Definition at line 184 of file RGroupDecompData.h.
References cores, RDKit::getRlabels(), labels, matches, params, permutation, RDKit::RGroupDecompositionParameters::removeAllHydrogenRGroups, and RDKit::RGroupDecompositionParameters::removeAllHydrogenRGroupsAndLabels.
Referenced by relabel().
|
inline |
Definition at line 110 of file RGroupDecompData.h.
References RDKit::common_properties::_MolFileRLabel, RDKit::AtomMap, CHECK_INVARIANT, RDKit::Atom::getAtomMapNum(), RDKit::Atom::getIsotope(), RDKit::RDProps::getPropIfPresent(), RDKit::Isotope, RDKit::MDLRGroup, params, and RDKit::RGroupDecompositionParameters::rgroupLabelling.
|
inline |
Definition at line 83 of file RGroupDecompData.h.
References CHECK_INVARIANT, cores, params, and RDKit::RGroupDecompositionParameters::prepareCore().
Referenced by RGroupDecompData().
|
inline |
Definition at line 565 of file RGroupDecompData.h.
References RDKit::RGroupScorer::breakTies(), RDKit::checkForTimeout(), RDKit::RGroupScorer::clearTieStore(), RDKit::Exhaustive, RDKit::FingerprintVariance, RDKit::GA, RDKit::RGroupDecompositionParameters::gaNumberRuns, RDKit::RGroupScorer::getBestPermutation(), RDKit::RGroupScorer::getBestScore(), labels, matches, RDKit::RGroupDecompositionParameters::matchingStrategy, RDKit::RGroupGa::numberPermutations(), params, permutation, previousMatchSize, prune(), RDKit::RGroupScorer::pushTieToStore(), relabel(), rGroupScorer, RDKit::RGroupGa::run(), RDKit::RGroupGa::runBatch(), score(), scoreFromPrunedData(), RDKit::RGroupDecompositionParameters::scoreMethod, RDKit::RGroupScorer::setBestPermutation(), RDKit::RGroupScorer::startProcessing(), RDKit::RGroupScorer::tieStoreSize(), and RDKit::RGroupDecompositionParameters::timeout.
|
inline |
Definition at line 164 of file RGroupDecompData.h.
References RDKit::FingerprintVariance, RDKit::GA, matches, RDKit::RGroupDecompositionParameters::matchingStrategy, params, permutation, PRECONDITION, scoreFromPrunedData(), and RDKit::RGroupDecompositionParameters::scoreMethod.
Referenced by process().
|
inline |
Definition at line 472 of file RGroupDecompData.h.
References RDKit::RGroupDecompData::UsedLabels::add(), addCoreUserLabels(), CHECK_INVARIANT, cores, finalRlabelMapping, GetCurrentBestPermutation(), RDKit::RGroupDecompositionParameters::onlyMatchAtRGroups, params, relabelCore(), relabelRGroup(), and userLabels.
Referenced by process().
|
inline |
Definition at line 289 of file RGroupDecompData.h.
References RDKit::RGroupDecompData::UsedLabels::add(), addAtoms(), CHECK_INVARIANT, RDKit::Atom::getAtomicNum(), RDKit::Atom::getDegree(), RDKit::getRlabels(), RDKit::isAnyAtomWithMultipleNeighborsOrNotUserRLabel(), RDKit::RGroupDecompData::UsedLabels::next(), RDKit::RLABEL, RDKit::RLABEL_TYPE, setRlabel(), and RDKit::ROMol::updatePropertyCache().
Referenced by relabel().
|
inline |
Definition at line 388 of file RGroupDecompData.h.
References RDKit::_rgroupInputDummy, addAtoms(), RDKit::ROMol::beginAtoms(), CHECK_INVARIANT, RDKit::RDProps::clearProp(), RDKit::RGroupData::combinedMol, RDKit::done, RDKit::ROMol::endAtoms(), RDKit::Atom::getAtomicNum(), RDKit::RDProps::getProp(), RDKit::RDProps::hasProp(), RDKit::RGroupData::labelled, RDKit::MolToSmiles(), params, PRECONDITION, RDKit::MolOps::removeHs(), RDKit::RGroupDecompositionParameters::removeHydrogensPostMatch, RDKit::RLABEL_CORE_INDEX, RDKit::Atom::setAtomicNum(), RDKit::Atom::setIsotope(), RDKit::Atom::setNoImplicit(), RDKit::RDProps::setProp(), setRlabel(), RDKit::SIDECHAIN_RLABELS, and RDKit::ROMol::updatePropertyCache().
Referenced by relabel().
|
inline |
Definition at line 548 of file RGroupDecompData.h.
References RDKit::FingerprintVariance, RDKit::fingerprintVarianceScore(), labels, RDKit::Match, matches, RDKit::RGroupScorer::matchScore(), params, permutation, rGroupScorer, and RDKit::RGroupDecompositionParameters::scoreMethod.
Referenced by process(), and scoreFromPrunedData().
|
inline |
Definition at line 128 of file RGroupDecompData.h.
References RDKit::FingerprintVarianceScoreData::addVarianceData(), RDKit::FingerprintVarianceScoreData::clear(), RDKit::FingerprintVariance, RDKit::FingerprintVarianceScoreData::fingerprintVarianceGroupScore(), RDKit::fingerprintVarianceScore(), labels, matches, params, permutation, PRECONDITION, prunedFingerprintVarianceScoreData, pruneLength, RDKit::FingerprintVarianceScoreData::removeVarianceData(), score(), and RDKit::RGroupDecompositionParameters::scoreMethod.
|
inline |
Definition at line 93 of file RGroupDecompData.h.
References RDKit::AtomMap, RDKit::common_properties::dummyLabel, RDKit::Isotope, RDKit::MDLRGroup, params, PRECONDITION, RDKit::RGroupDecompositionParameters::rgroupLabelling, RDKit::Atom::setAtomMapNum(), RDKit::setAtomRLabel(), RDKit::Atom::setIsotope(), RDKit::RDProps::setProp(), and RDKit::CIPLabeler::to_string().
Referenced by relabelCore(), and relabelRGroup().
std::map<int, RCore> RDKit::RGroupDecompData::cores |
Definition at line 31 of file RGroupDecompData.h.
Referenced by addCore(), GetCurrentBestPermutation(), prepareCores(), and relabel().
std::map<int, int> RDKit::RGroupDecompData::finalRlabelMapping |
Definition at line 54 of file RGroupDecompData.h.
Referenced by relabel().
std::set<int> RDKit::RGroupDecompData::labels |
Definition at line 46 of file RGroupDecompData.h.
Referenced by GetCurrentBestPermutation(), process(), score(), and scoreFromPrunedData().
std::vector<std::vector<RGroupMatch> > RDKit::RGroupDecompData::matches |
Definition at line 45 of file RGroupDecompData.h.
Referenced by GetCurrentBestPermutation(), process(), prune(), score(), and scoreFromPrunedData().
int RDKit::RGroupDecompData::newCoreLabel = EMPTY_CORE_LABEL |
Definition at line 33 of file RGroupDecompData.h.
std::map<std::string, int> RDKit::RGroupDecompData::newCores |
Definition at line 32 of file RGroupDecompData.h.
RGroupDecompositionParameters RDKit::RGroupDecompData::params |
Definition at line 43 of file RGroupDecompData.h.
Referenced by addCore(), GetCurrentBestPermutation(), getRlabel(), prepareCores(), process(), prune(), relabel(), relabelRGroup(), score(), scoreFromPrunedData(), and setRlabel().
std::vector<size_t> RDKit::RGroupDecompData::permutation |
Definition at line 47 of file RGroupDecompData.h.
Referenced by GetCurrentBestPermutation(), process(), prune(), score(), and scoreFromPrunedData().
size_t RDKit::RGroupDecompData::permutationProduct = 1 |
Definition at line 36 of file RGroupDecompData.h.
size_t RDKit::RGroupDecompData::previousMatchSize = 0 |
Definition at line 39 of file RGroupDecompData.h.
Referenced by process().
std::vector<int> RDKit::RGroupDecompData::processedRlabels |
Definition at line 52 of file RGroupDecompData.h.
FingerprintVarianceScoreData RDKit::RGroupDecompData::prunedFingerprintVarianceScoreData |
Definition at line 49 of file RGroupDecompData.h.
Referenced by scoreFromPrunedData().
unsigned int RDKit::RGroupDecompData::pruneLength = 0U |
Definition at line 48 of file RGroupDecompData.h.
Referenced by scoreFromPrunedData().
bool RDKit::RGroupDecompData::prunePermutations = true |
Definition at line 42 of file RGroupDecompData.h.
|
mutable |
Definition at line 55 of file RGroupDecompData.h.
std::map<int, std::vector<int> > RDKit::RGroupDecompData::userLabels |
Definition at line 50 of file RGroupDecompData.h.
Referenced by addCoreUserLabels(), and relabel().