Re: [Rdkit-discuss] GetSubstructMatches
Open-Source Cheminformatics and Machine Learning
Brought to you by:
glandrum
From: Greg L. <gre...@gm...> - 2016-12-14 16:43:43
|
Hi Jean-Marc, The answer is in the error message, once you know how to read it, which isn't really trivial: On Wed, Dec 14, 2016 at 5:35 PM, Jean-Marc Nuzillard < jm....@un...> wrote: > > Traceback (most recent call last): > File "glmap.py", line 11, in <module> > matches = mol.GetSubstructMatches(skel) > Boost.Python.ArgumentError: Python argument types in > Mol.GetSubstructMatches(Mol, str) > did not match C++ signature: > GetSubstructMatches(class RDKit::ROMol self, class RDKit::ROMol > query, bool uniquify=True, bool useChirality=False, bool > useQueryQueryMatches=False, unsigned int maxMatches=1000) > It's telling you that you called Mol.GetSubstructMatches was called with a Mol and a string (the "Mol" is the object you're calling "mol" and the string is the object you are calling "skel"). It expects, however, to be called with a Mol and a Mol. If you convert skel into an RDKit molecule everything should work. -greg |