[Rdkit-discuss] Which package should be used to improve the drawing quality in win64

2017-05-08 Thread Hongbin Yang






Hi, all,? ??? ? By default, rdkit uses pillow to render images when using 
rdkit.Chem.DrawMolecule. But the quality is not good enough, like this:? ??If 
memory does not fail me, pycairo can solve this problem. But unfortunately, I 
cannot find (a good) win64 pycairo in any channel in anaconda. In rdkit 
document, aggdraw (?http://effbot.org/downloads/#aggdraw?) is suggested to 
install. But I think it's too old, not to speak of the 
support?for?win64-python27. (So is it necessary to update the document?)? ??? ? 
So I wonder which package I should install to improve the drawing quality? 
(rdMolDraw is good, but its not as easy to use as DrawMolecule).


Hongbin Yang?


--
Check out the vibrant tech community on one of the world's most
engaging tech sites, Slashdot.org! http://sdm.link/slashdot___
Rdkit-discuss mailing list
Rdkit-discuss@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/rdkit-discuss


Re: [Rdkit-discuss] difficulties with AllChem.EmbedMultipleConfs() on a macrocycle

2017-05-08 Thread Curt Fischer
Thanks Greg!  This was the impetus I needed to upgrade to 2017.03.

I now confirm that conformer generation happens very quickly.  It's so nice
to be able to visualize so nicely with py3dmol too.

Curt

On Sun, May 7, 2017 at 9:37 PM, Greg Landrum  wrote:

> Going back through old mail I realized that I never did follow up on this
> one.
>
> It looks like these structures now embed (using the 2017.03.1 release). I
> assume that the changes I made to fix #1240 (https://github.com/rdkit/
> rdkit/issues/1240) - which make the code more permissive in how the
> conformers are filtered - are responsible for that.
>
> -greg
>
>
>
>
> On Sat, Mar 4, 2017 at 7:39 AM, Greg Landrum 
> wrote:
>
>> Hi Curt,
>>
>> I believe that the problem here is caused by the number of specified
>> chiral centers in a ring. I'm basing that guess on the fact that if I turn
>> off the option to enforce chirality I get an answer very quickly:
>>
>> In [12]: ps = AllChem.ETKDG()
>>
>> In [13]: ps.randomSeed = 0xf00d
>>
>> In [14]: ps.enforceChirality=False
>>
>> In [15]: AllChem.EmbedMolecule(mh,ps)
>> Out[15]: 0
>>
>>
>> but if I go back to the defaults I get the same lack of results that you
>> were seeing:
>>
>> In [16]: ps.enforceChirality=True
>>
>> In [17]: AllChem.EmbedMolecule(mh,ps)
>> Out[17]: -1
>>
>>
>>
>> I'm not sure that there's a straightforward solution to this problem
>> without code changes, but I'll do a bit of looking to see if I can figure
>> something out.
>>
>> -greg
>>
>>
>>
>> On Thu, Mar 2, 2017 at 7:34 PM, Curt Fischer 
>> wrote:
>>
>>> Hi all,
>>>
>>> I really like combination of rdkit and py3dmol and have been able to
>>> replicate e.g. Greg's notebook here: http://nbviewer.jupyter.
>>> org/github/greglandrum/rdkit_blog/blob/master/notebooks/Tryi
>>> ng%20py3Dmol.ipynb
>>>
>>> But I can't seem to get AllChem.EmbedMultipleConfs() to generate any
>>> valid conformers for a macrotriolide, macrosphelide A.
>>>
>>> *macrosphelide_a_smiles =
>>> 'C[C@H]1CC(O[C@H](C)[C@H](O)/C=C/C(O[C@@H](C)[C@@H](O)/C=C/C(O1)=O)=O)=O'*
>>> *m = Chem.MolFromSmiles(macrosphelide_a_smiles)*
>>> *mh = Chem.AddHs(m)*
>>> *AllChem.EmbedMultipleConfs(mh, useExpTorsionAnglePrefs=True,
>>> useBasicKnowledge=True)*
>>> *mb = Chem.MolToMolBlock(mh)*
>>>
>>> The EmbedMultipleConfs() call never terminates for me.  If I use a
>>> non-zero value for *maxAttempts*, the call does terminate, but when I
>>> look at *mb*, the coordinates for all atoms are zero.
>>>
>>> I've tried playing around with a few of the other options, without
>>> luck.  Either all atom coordinates are still zero after
>>> *EmbedMultipleConfs()*, or the function call never terminates.
>>>
>>> Any chance someone knows how to coax this function into yielding a
>>> useful conformation for my molecule?
>>>
>>> Curt
>>>
>>>
>>> 
>>> --
>>> Check out the vibrant tech community on one of the world's most
>>> engaging tech sites, SlashDot.org! http://sdm.link/slashdot
>>> ___
>>> Rdkit-discuss mailing list
>>> Rdkit-discuss@lists.sourceforge.net
>>> https://lists.sourceforge.net/lists/listinfo/rdkit-discuss
>>>
>>>
>>
>
--
Check out the vibrant tech community on one of the world's most
engaging tech sites, Slashdot.org! http://sdm.link/slashdot___
Rdkit-discuss mailing list
Rdkit-discuss@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/rdkit-discuss