Hi,
I was playing with ipython notebook and I get interesting error:
from rdkit import Chem
from rdkit.Chem import Draw
from rdkit.Chem.Draw import IPythonConsole
mol = Chem.MolFromSmarts('c1ccccc1')
mol
<draws benzene>
Draw.MolsToGridImage([mol])
---------------------------------------------------------------------------ValueError
Traceback (most recent call
last)<ipython-input-71-4f0b315d518e> in <module>()----> 1
Draw.MolsToGridImage([mol])
/usr/lib/python2.7/site-packages/rdkit/Chem/Draw/__init__.py in
MolsToGridImage(mols, molsPerRow, subImgSize, legends, **kwargs)
263 row = i//molsPerRow 264 col = i%molsPerRow--> 265
res.paste(MolToImage(mol,subImgSize,legend=legends[i],**kwargs),(col*subImgSize[0],row*subImgSize[1]))
266 return res 267
/usr/lib/python2.7/site-packages/rdkit/Chem/Draw/__init__.py in
MolToImage(mol, size, kekulize, wedgeBonds, **kwargs) 70 from
rdkit import Chem 71 mol = Chem.Mol(mol.ToBinary())---> 72
Chem.Kekulize(mol) 73 74 if not mol.GetNumConformers():
ValueError: Sanitization error: Can't kekulize mol
It works normally on aliphatic structures or if I use MolFromSmiles
instead of MolFromSmarts. Is kekulization of mols obtained from SMARTS
wanted behaviour? Is it possible to turn it off?
Regards,
Samo
------------------------------------------------------------------------------
Get 100% visibility into Java/.NET code with AppDynamics Lite!
It's a free troubleshooting tool designed for production.
Get down to code-level detail for bottlenecks, with <2% overhead.
Download for free and get started troubleshooting in minutes.
http://pubads.g.doubleclick.net/gampad/clk?id=48897031&iu=/4140/ostg.clktrk
_______________________________________________
Rdkit-discuss mailing list
[email protected]
https://lists.sourceforge.net/lists/listinfo/rdkit-discuss