12 #ifndef RD_EMBEDDER_H_GUARD
13 #define RD_EMBEDDER_H_GUARD
18 #include <boost/shared_ptr.hpp>
22 namespace DGeomHelpers {
93 unsigned int maxIterations{0};
96 bool clearConfs{
true};
97 bool useRandomCoords{
false};
98 double boxSizeMult{2.0};
99 bool randNegEig{
true};
100 unsigned int numZeroFail{1};
101 const std::map<int, RDGeom::Point3D> *coordMap{
nullptr};
102 double optimizerForceTol{1e-3};
103 bool ignoreSmoothingFailures{
false};
104 bool enforceChirality{
true};
105 bool useExpTorsionAnglePrefs{
false};
106 bool useBasicKnowledge{
false};
108 double basinThresh{5.0};
109 double pruneRmsThresh{-1.0};
110 bool onlyHeavyAtomsForRMS{
false};
111 unsigned int ETversion{1};
112 boost::shared_ptr<const DistGeom::BoundsMatrix>
boundsMat;
113 bool embedFragmentsSeparately{
true};
114 bool useSmallRingTorsions{
false};
115 bool useMacrocycleTorsions{
false};
116 bool useMacrocycle14config{
false};
117 std::shared_ptr<std::map<std::pair<unsigned int, unsigned int>,
double>>
CPCI;
124 unsigned int maxIterations,
int numThreads,
int randomSeed,
125 bool clearConfs,
bool useRandomCoords,
double boxSizeMult,
126 bool randNegEig,
unsigned int numZeroFail,
127 const std::map<int, RDGeom::Point3D> *coordMap,
double optimizerForceTol,
128 bool ignoreSmoothingFailures,
bool enforceChirality,
129 bool useExpTorsionAnglePrefs,
bool useBasicKnowledge,
bool verbose,
130 double basinThresh,
double pruneRmsThresh,
bool onlyHeavyAtomsForRMS,
131 unsigned int ETversion = 1,
133 bool embedFragmentsSeparately =
true,
bool useSmallRingTorsions =
false,
134 bool useMacrocycleTorsions =
false,
bool useMacrocycle14config =
false,
135 std::shared_ptr<std::map<std::pair<unsigned int, unsigned int>,
double>>
137 : maxIterations(maxIterations),
138 numThreads(numThreads),
139 randomSeed(randomSeed),
140 clearConfs(clearConfs),
141 useRandomCoords(useRandomCoords),
142 boxSizeMult(boxSizeMult),
143 randNegEig(randNegEig),
144 numZeroFail(numZeroFail),
146 optimizerForceTol(optimizerForceTol),
147 ignoreSmoothingFailures(ignoreSmoothingFailures),
148 enforceChirality(enforceChirality),
149 useExpTorsionAnglePrefs(useExpTorsionAnglePrefs),
150 useBasicKnowledge(useBasicKnowledge),
152 basinThresh(basinThresh),
153 pruneRmsThresh(pruneRmsThresh),
154 onlyHeavyAtomsForRMS(onlyHeavyAtomsForRMS),
155 ETversion(ETversion),
156 boundsMat(boundsMat),
157 embedFragmentsSeparately(embedFragmentsSeparately),
158 useSmallRingTorsions(useSmallRingTorsions),
159 useMacrocycleTorsions(useMacrocycleTorsions),
160 useMacrocycle14config(useMacrocycle14config),
182 if (confIds.size()) {
260 ROMol &mol,
unsigned int maxIterations = 0,
int seed = -1,
261 bool clearConfs =
true,
bool useRandomCoords =
false,
262 double boxSizeMult = 2.0,
bool randNegEig =
true,
263 unsigned int numZeroFail = 1,
264 const std::map<int, RDGeom::Point3D> *coordMap =
nullptr,
265 double optimizerForceTol = 1e-3,
bool ignoreSmoothingFailures =
false,
266 bool enforceChirality =
true,
bool useExpTorsionAnglePrefs =
false,
267 bool useBasicKnowledge =
false,
bool verbose =
false,
268 double basinThresh = 5.0,
bool onlyHeavyAtomsForRMS =
false,
269 unsigned int ETversion = 1,
bool useSmallRingTorsions =
false,
270 bool useMacrocycleTorsions =
false,
bool useMacrocycle14config =
false) {
272 maxIterations, 1,
seed, clearConfs, useRandomCoords, boxSizeMult,
273 randNegEig, numZeroFail, coordMap, optimizerForceTol,
274 ignoreSmoothingFailures, enforceChirality, useExpTorsionAnglePrefs,
275 useBasicKnowledge, verbose, basinThresh, -1.0, onlyHeavyAtomsForRMS,
276 ETversion,
nullptr,
true, useSmallRingTorsions, useMacrocycleTorsions,
277 useMacrocycle14config);
358 ROMol &mol,
INT_VECT &res,
unsigned int numConfs = 10,
int numThreads = 1,
359 unsigned int maxIterations = 30,
int seed = -1,
bool clearConfs =
true,
360 bool useRandomCoords =
false,
double boxSizeMult = 2.0,
361 bool randNegEig =
true,
unsigned int numZeroFail = 1,
362 double pruneRmsThresh = -1.0,
363 const std::map<int, RDGeom::Point3D> *coordMap =
nullptr,
364 double optimizerForceTol = 1e-3,
bool ignoreSmoothingFailures =
false,
365 bool enforceChirality =
true,
bool useExpTorsionAnglePrefs =
false,
366 bool useBasicKnowledge =
false,
bool verbose =
false,
367 double basinThresh = 5.0,
bool onlyHeavyAtomsForRMS =
false,
368 unsigned int ETversion = 1,
bool useSmallRingTorsions =
false,
369 bool useMacrocycleTorsions =
false,
bool useMacrocycle14config =
false) {
371 maxIterations, numThreads,
seed, clearConfs, useRandomCoords, boxSizeMult,
372 randNegEig, numZeroFail, coordMap, optimizerForceTol,
373 ignoreSmoothingFailures, enforceChirality, useExpTorsionAnglePrefs,
374 useBasicKnowledge, verbose, basinThresh, pruneRmsThresh,
375 onlyHeavyAtomsForRMS, ETversion,
nullptr,
true, useSmallRingTorsions,
376 useMacrocycleTorsions, useMacrocycle14config);
381 ROMol &mol,
unsigned int numConfs = 10,
unsigned int maxIterations = 30,
382 int seed = -1,
bool clearConfs =
true,
bool useRandomCoords =
false,
383 double boxSizeMult = 2.0,
bool randNegEig =
true,
384 unsigned int numZeroFail = 1,
double pruneRmsThresh = -1.0,
385 const std::map<int, RDGeom::Point3D> *coordMap =
nullptr,
386 double optimizerForceTol = 1e-3,
bool ignoreSmoothingFailures =
false,
387 bool enforceChirality =
true,
bool useExpTorsionAnglePrefs =
false,
388 bool useBasicKnowledge =
false,
bool verbose =
false,
389 double basinThresh = 5.0,
bool onlyHeavyAtomsForRMS =
false,
390 unsigned int ETversion = 1,
bool useSmallRingTorsions =
false,
391 bool useMacrocycleTorsions =
false,
bool useMacrocycle14config =
false) {
393 maxIterations, 1,
seed, clearConfs, useRandomCoords, boxSizeMult,
394 randNegEig, numZeroFail, coordMap, optimizerForceTol,
395 ignoreSmoothingFailures, enforceChirality, useExpTorsionAnglePrefs,
396 useBasicKnowledge, verbose, basinThresh, pruneRmsThresh,
397 onlyHeavyAtomsForRMS, ETversion,
nullptr,
true, useSmallRingTorsions,
398 useMacrocycleTorsions, useMacrocycle14config);
Defines the primary molecule class ROMol as well as associated typedefs.
Class to store the distance bound.
#define RDKIT_DISTGEOMHELPERS_EXPORT
RDKIT_DISTGEOMHELPERS_EXPORT const EmbedParameters ETKDGv2
Parameters corresponding to Sereina Riniker's ETKDG approach - version 2.
RDKIT_DISTGEOMHELPERS_EXPORT const EmbedParameters ETDG
Parameters corresponding to Sereina Riniker's ETDG approach.
RDKIT_DISTGEOMHELPERS_EXPORT const EmbedParameters ETKDGv3
int EmbedMolecule(ROMol &mol, const EmbedParameters ¶ms)
Compute an embedding (in 3D) for the specified molecule using Distance.
RDKIT_DISTGEOMHELPERS_EXPORT void EmbedMultipleConfs(ROMol &mol, INT_VECT &res, unsigned int numConfs, const EmbedParameters ¶ms)
RDKIT_DISTGEOMHELPERS_EXPORT const EmbedParameters ETKDG
Parameters corresponding to Sereina Riniker's ETKDG approach.
RDKIT_DISTGEOMHELPERS_EXPORT const EmbedParameters srETKDGv3
RDKIT_DISTGEOMHELPERS_EXPORT const EmbedParameters KDG
Parameters corresponding to Sereina Riniker's KDG approach.
std::vector< int > INT_VECT
Parameter object for controlling embedding.
EmbedParameters(unsigned int maxIterations, int numThreads, int randomSeed, bool clearConfs, bool useRandomCoords, double boxSizeMult, bool randNegEig, unsigned int numZeroFail, const std::map< int, RDGeom::Point3D > *coordMap, double optimizerForceTol, bool ignoreSmoothingFailures, bool enforceChirality, bool useExpTorsionAnglePrefs, bool useBasicKnowledge, bool verbose, double basinThresh, double pruneRmsThresh, bool onlyHeavyAtomsForRMS, unsigned int ETversion=1, const DistGeom::BoundsMatrix *boundsMat=nullptr, bool embedFragmentsSeparately=true, bool useSmallRingTorsions=false, bool useMacrocycleTorsions=false, bool useMacrocycle14config=false, std::shared_ptr< std::map< std::pair< unsigned int, unsigned int >, double >> CPCI=nullptr)
boost::shared_ptr< const DistGeom::BoundsMatrix > boundsMat
std::shared_ptr< std::map< std::pair< unsigned int, unsigned int >, double > > CPCI