 |
RDKit
Open-source cheminformatics and machine learning.
|
Go to the documentation of this file.
12 #ifndef RD_MORGANGEN_H_2018_07
13 #define RD_MORGANGEN_H_2018_07
20 namespace MorganFingerprint {
29 const bool df_includeRingMembership;
53 std::vector<const ROMol *> *dp_patterns;
78 const bool df_useBondTypes;
79 const bool df_useChirality;
91 const bool useChirality =
false);
104 template <
typename OutputType>
132 const bool includeChirality =
false,
133 const bool onlyNonzeroInvariants =
false,
134 const std::vector<std::uint32_t> countBounds = {1, 2, 4, 8},
135 const std::uint32_t fpSize = 2048);
143 template <
typename OutputType>
146 const OutputType d_code;
147 const unsigned int d_atomId;
148 const unsigned int d_layer;
152 const std::vector<std::uint32_t> *atomInvariants,
153 const std::vector<std::uint32_t> *bondInvariants,
155 const bool hashResults =
false)
const;
165 const unsigned int layer);
172 template <
typename OutputType>
178 const std::vector<std::uint32_t> *fromAtoms,
179 const std::vector<std::uint32_t> *ignoreAtoms,
const int confId,
181 const std::vector<std::uint32_t> *atomInvariants,
182 const std::vector<std::uint32_t> *bondInvariants,
183 const bool hashResults =
false)
const;
227 template <
typename OutputType>
229 const unsigned int radius,
const bool countSimulation =
false,
230 const bool includeChirality =
false,
const bool useBondTypes =
true,
231 const bool onlyNonzeroInvariants =
false,
234 const std::uint32_t fpSize = 2048,
235 const std::vector<std::uint32_t> countBounds = {1, 2, 4, 8},
236 const bool ownsAtomInvGen =
false,
const bool ownsBondInvGen =
false);
Class for holding Morgan fingerprint specific arguments.
class that generates same fingerprint style for different output formats
MorganAtomInvGenerator * clone() const
OutputType getBitId(FingerprintArguments< OutputType > *arguments, const std::vector< std::uint32_t > *atomInvariants, const std::vector< std::uint32_t > *bondInvariants, const AdditionalOutput *additionalOutput, const bool hashResults=false) const
calculates and returns the bit id to be set for this atom-environment
std::vector< AtomEnvironment< OutputType > * > getEnvironments(const ROMol &mol, FingerprintArguments< OutputType > *arguments, const std::vector< std::uint32_t > *fromAtoms, const std::vector< std::uint32_t > *ignoreAtoms, const int confId, const AdditionalOutput *additionalOutput, const std::vector< std::uint32_t > *atomInvariants, const std::vector< std::uint32_t > *bondInvariants, const bool hashResults=false) const
generate and return all atom-envorinments from a molecule
MorganBondInvGenerator(const bool useBondTypes=true, const bool useChirality=false)
Construct a new MorganBondInvGenerator object.
MorganFeatureAtomInvGenerator(std::vector< const ROMol * > *patterns=nullptr)
Construct a new MorganFeatureAtomInvGenerator object.
MorganFeatureAtomInvGenerator * clone() const
const bool df_onlyNonzeroInvariants
std::vector< std::uint32_t > * getBondInvariants(const ROMol &mol) const
get bond invariants from a molecule
MorganArguments(const unsigned int radius, const bool countSimulation=false, const bool includeChirality=false, const bool onlyNonzeroInvariants=false, const std::vector< std::uint32_t > countBounds={1, 2, 4, 8}, const std::uint32_t fpSize=2048)
Construct a new MorganArguments object.
Class that generates atom environments for Morgan fingerprint.
MorganAtomInvGenerator(const bool includeRingMembership=true)
Construct a new MorganAtomInvGenerator object.
const bool df_includeChirality
RDKIT_FINGERPRINTS_EXPORT FingerprintGenerator< OutputType > * getMorganGenerator(const unsigned int radius, const bool countSimulation=false, const bool includeChirality=false, const bool useBondTypes=true, const bool onlyNonzeroInvariants=false, AtomInvariantsGenerator *atomInvariantsGenerator=nullptr, BondInvariantsGenerator *bondInvariantsGenerator=nullptr, const std::uint32_t fpSize=2048, const std::vector< std::uint32_t > countBounds={1, 2, 4, 8}, const bool ownsAtomInvGen=false, const bool ownsBondInvGen=false)
Get a fingerprint generator for Morgan fingerprint.
Alternative atom invariants generator for Morgan fingerprint, generate FCFP-type invariants.
MorganBondInvGenerator * clone() const
abstract base class for atom invariants generators
abstract base class for bond invariants generators
std::string infoString() const
method that returns information about this /c AtomInvariantsGenerator and its arguments
Bond invariants generator for Morgan fingerprint.
abstract base class that holds atom-environments that will be hashed to generate the fingerprint
~MorganBondInvGenerator()
abstract base class that generates atom-environments from a molecule
Default atom invariants generator for Morgan fingerprint, generates ECFP-type invariants.
std::string infoString() const
method that returns information about this /c BondInvariantsGenerator and its arguments
#define RDKIT_FINGERPRINTS_EXPORT
std::vector< std::uint32_t > * getAtomInvariants(const ROMol &mol) const
get atom invariants from a molecule
Class for holding the bit-id created from Morgan fingerprint environments and the additional data nec...
const unsigned int d_radius
std::string infoString() const
method that returns information string about the fingerprint specific argument set and the arguments ...
MorganAtomEnv(const std::uint32_t code, const unsigned int atomId, const unsigned int layer)
Construct a new MorganAtomEnv object.
std::string infoString() const
method that returns information about this /c AtomEnvironmentGenerator and its arguments if any
std::string infoString() const
method that returns information about this /c AtomInvariantsGenerator and its arguments
Abstract base class that holds molecule independent arguments that are common amongst all fingerprint...
std::vector< std::uint32_t > * getAtomInvariants(const ROMol &mol) const
get atom invariants from a molecule
OutputType getResultSize() const
Returns the size of the fingerprint based on arguments.