[moving back onto the discuss list since this is no longer a detailed
configuration discussion]

On Thu, Jul 9, 2009 at 9:23 PM, Aryeh
Gold-Parker<[email protected]> wrote:
> Things are getting better and better. Abhinav kindly gave me binaries for
> aggdraw, so that is set now. Indeed, a.draw() works beautifully. However, I
> am having trouble with Chem.Draw, specifically:
>
>>>> Draw.MolToImageFile(a, 'a.png').
>
>> AttributeError                            Traceback (most recent call
>> last)
>>
>> /home/aryeh/Desktop/<ipython console> in <module>()
>>
>> /usr/lib/python2.6/dist-packages/rdkit/Chem/Draw/__init__.py in
>> MolToImageFile(mol, filename, size, kekulize, wedgeBonds)
>>      46
>>      47 def MolToImageFile(mol,filename,size=(300,300),kekulize=True,
>> wedgeBonds=True):
>> ---> 48   img =
>> MolToImage(mol,size=size,kekulize=kekulize,wedgeBonds=wedgeBonds)
>>      49   img.save(filename)
>>      50
>>
>> /usr/lib/python2.6/dist-packages/rdkit/Chem/Draw/__init__.py in
>> MolToImage(mol, size, kekulize, wedgeBonds)
>>      32   if kekulize:
>>      33     from rdkit import Chem
>> ---> 34     mol = Chem.Mol(mol.ToBinary())
>>      35     Chem.Kekulize(mol)
>>      36
>>
>> AttributeError: 'Molecule' object has no attribute 'ToBinary'
>
> Any idea what might cause this?

Where did that "Molecule" come from? I don't think that's an RDKit
object. Can you please show the line where you construct a?

-greg

Reply via email to