[Rdkit-discuss] If someone has build problems using conda currently ...

2017-01-16 Thread Markus Sitzmann
... I just suffered this:

https://github.com/conda/conda/issues/4309

Going back to a previous conda version (4.2.12) helps.

Other than that:
Happy New Year (a late one :-)
--
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] PMI API

2017-01-16 Thread Greg Landrum
On Mon, Jan 16, 2017 at 10:22 AM, Chris Earnshaw 
wrote:

>
> Either way, it makes it rather hard to trust their derivations generally -
> especially as there appear to be other errors (e.g. the denominator in eq.
> 16 should be the square root of the given sum of squares, according to
> their reference).
>

Indeed. Given the problems encountered, I went back and checked some
additional references to find definitions of the descriptors. The results
are in this PR, which I'd love feedback on if you have time to take a look:
https://github.com/rdkit/rdkit/pull/1265

I didn't manage to find any information about "inertial shape factor" and
don't have access to the references cited in the Todeschini paper, but I
think the others are now reasonably reliable.

-greg
--
Developer Access Program for Intel Xeon Phi Processors
Access to Intel Xeon Phi processor-based developer platforms.
With one year of Intel Parallel Studio XE.
Training and support from Colfax.
Order your platform today. http://sdm.link/xeonphi___
Rdkit-discuss mailing list
Rdkit-discuss@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/rdkit-discuss


Re: [Rdkit-discuss] PMI API

2017-01-16 Thread Chris Earnshaw
Dear Guillaume

Thanks - looks like we agree about reality (good!) and that Todeschini et
al. are wrong in their discussion about planar molecules. Whether this is a
simple mistaken assertion, or if they've mixed up another quantity (e.g.
the eigenvalues of the covariance matrix) with the PMIs is impossible to
say.

Either way, it makes it rather hard to trust their derivations generally -
especially as there appear to be other errors (e.g. the denominator in eq.
16 should be the square root of the given sum of squares, according to
their reference).

Best regards,
Chris

Dr Chris Earnshaw
CGE Computational Chemistry
Phone: +44(0) 1223 426000
Mobile: 07944 707773
E-mail: ch...@cge-compchem.co.uk

On 16 January 2017 at 08:54, Guillaume GODIN 
wrote:

> Dear Chris,
>
>
> No prob let me explain:
>
>
> I Aggree on monoatomics center of mass is the atom so  (for all x axis:
> Ix= 0)
>
> ​
>
> Now I consider the mathematics only not the physics.
>
>
> I suggest that they (Todeschini) are not really computing the "real
> physical" PMi on the 3 axis but arbitrary said that for 2D molecules the
> 3nd axis PMi is zero.
>
>
> BR
>
>
>
> *Dr. Guillaume GODIN*
> Principal Scientist
> Chemoinformatic & Datamining
> Innovation
> CORPORATE R&D DIVISION
> DIRECT LINE +41 (0)22 780 3645 <+41%2022%20780%2036%2045>
> MOBILE  +41 (0)79 536 1039 <+41%2079%20536%2010%2039>
> Firmenich SA
> RUE DES JEUNES 1 | CASE POSTALE 239 | CH-1211 GENEVE 8
>
> --
> *De :* Chris Earnshaw 
> *Envoyé :* lundi 16 janvier 2017 09:36
> *À :* Guillaume GODIN
> *Cc :* Greg Landrum; RDKit Discuss
>
> *Objet :* Re: [Rdkit-discuss] PMI API
>
>
>
> On 16 January 2017 at 06:25, Guillaume GODIN <
> guillaume.go...@firmenich.com> wrote:
>
>> reading carefully the Todeschini article, them said that Ic,Ib,Ia are
>> determine as max & min values of I other all 3D axis passing throught the
>> center of mass!
>>
> I don't quite understand this comment. The inequality Ia <= Ib <= Ic is
> one of the errors in the Todeschini article pointed out by Greg yesterday.
> By definition, the Principal Moment of Inertia axes pass through the centre
> of mass.
>
> The "global PM" is never zero (sum of mi*ri*ri) idem for PMi even for
>> planar molecule.
>>
> The global Moment of Inertia is only zero for monatomics.
>
>
>> But When you have a planar molecule, the matrix is no more 3D but 2D! so
>> it's normal to consider that the 3nd PM is zero.
>>
> I really don't understand this - it's simply wrong. The molecule may be 2D
> but the three principal moments of inertia are most definitely non-zero for
> a planar structure. For a fully symmetrical molecule like benzene the
> largest PMI is around the axis perpendicular to the plane of the molecule
> and there are two equivalent, smaller, PMIs perpendicular to each other in
> the plane of the molecule. For a less symmetrical molecule like
> naphthalene, the largest PMI is again around the axis perpendicular to the
> plane, the intermediate PMI is along the fusion bond between the rings and
> the smallest PMI is around the long axis of the molecule. There's no way it
> can be correct to consider the 3rd PMI as zero in any planar molecule -
> it's never equal to zero and is only degenerate with the 2nd PMI for fully
> symmetric molecules. Only in the special case of a completely linear
> molecule (e.g. acetylene, HCN) is the 3rd PMI (along the axis of the
> molecule) equal to zero.
>
> Apologies - I appear to have opened a can of worms here...
>
> Chris
>
>> --
>> *De :* Greg Landrum 
>> *Envoyé :* dimanche 15 janvier 2017 17:42
>> *À :* Guillaume GODIN; RDKit Discuss
>>
>> *Objet :* Re: [Rdkit-discuss] PMI API
>>
>> Thanks Guillaume!
>>
>> On Sun, Jan 15, 2017 at 5:01 PM, Guillaume GODIN <
>> guillaume.go...@firmenich.com> wrote:
>>
>>> Here, Dragon results for the 3 molecules: I've included both  Whim and
>>> 3D descriptors but I don't have access to PMi!
>>>
>>>
>>> I found the second document in agreement with Peter answer...
>>>
>>>
>>> BR,
>>>
>>> *Dr. Guillaume GODIN*
>>> Principal Scientist
>>> Chemoinformatic & Datamining
>>> Innovation
>>> CORPORATE R&D DIVISION
>>> DIRECT LINE +41 (0)22 780 3645 <+41%2022%20780%2036%2045>
>>> MOBILE  +41 (0)79 536 1039 <+41%2079%20536%2010%2039>
>>> Firmenich SA
>>> RUE DES JEUNES 1 | CASE POSTALE 239 | CH-1211 GENEVE 8
>>>
>>> --
>>> *De :* Peter Gedeck 
>>> *Envoyé :* dimanche 15 janvier 2017 15:07
>>> *À :* Greg Landrum; RDKit Discuss; Guillaume GODIN
>>>
>>> *Objet :* Re: [Rdkit-discuss] PMI API
>>>
>>> According to this:
>>> https://en.wikipedia.org/wiki/List_of_moments_of_inertia
>>> The moments of inertia of a disk (something like benzene) are:
>>>
>>> Iz = mr^2/2
>>> Ix = Iy = mr^2/4
>>>
>>> None of them is zero. The smallest moment of inertia of a rod-like
>>> molecule (e.g. C#C) is zero.
>>>
>>> Best,
>>>
>>> Peter
>>>
>>>
>>>
>>> On Sun, Jan 15, 

Re: [Rdkit-discuss] PMI API

2017-01-16 Thread Greg Landrum
On Mon, Jan 16, 2017 at 9:36 AM, Chris Earnshaw 
wrote:

>
> Apologies - I appear to have opened a can of worms here...
>

No need whatsoever to apologize. You identified and pointed out a bug in
the implementation of the new 3D descriptors, which is something very much
appreciated.
The fact that I picked a seemingly unreliable source for the definitions of
those descriptors and that it's turning out to be difficult than I might
like to find reliable definitions for some of them is just the way things
are.

I'll have an updated version checked in (hopefully) in the next couple
hours. It would be great if you could take a look at it and let me know if
it looks right.

-greg
--
Developer Access Program for Intel Xeon Phi Processors
Access to Intel Xeon Phi processor-based developer platforms.
With one year of Intel Parallel Studio XE.
Training and support from Colfax.
Order your platform today. http://sdm.link/xeonphi___
Rdkit-discuss mailing list
Rdkit-discuss@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/rdkit-discuss


Re: [Rdkit-discuss] PMI API

2017-01-16 Thread Guillaume GODIN
Dear Chris,


No prob let me explain:


I Aggree on monoatomics center of mass is the atom so  (for all x axis: Ix= 0)

​

Now I consider the mathematics only not the physics.


I suggest that they (Todeschini) are not really computing the "real physical" 
PMi on the 3 axis but arbitrary said that for 2D molecules the 3nd axis PMi is 
zero.


BR


Dr. Guillaume GODIN
Principal Scientist
Chemoinformatic & Datamining
Innovation
CORPORATE R&D DIVISION
DIRECT LINE +41 (0)22 780 3645
MOBILE  +41 (0)79 536 1039
Firmenich SA
RUE DES JEUNES 1 | CASE POSTALE 239 | CH-1211 GENEVE 8


De : Chris Earnshaw 
Envoyé : lundi 16 janvier 2017 09:36
À : Guillaume GODIN
Cc : Greg Landrum; RDKit Discuss
Objet : Re: [Rdkit-discuss] PMI API



On 16 January 2017 at 06:25, Guillaume GODIN 
mailto:guillaume.go...@firmenich.com>> wrote:

reading carefully the Todeschini article, them said that Ic,Ib,Ia are determine 
as max & min values of I other all 3D axis passing throught the center of mass!

I don't quite understand this comment. The inequality Ia <= Ib <= Ic is one of 
the errors in the Todeschini article pointed out by Greg yesterday. By 
definition, the Principal Moment of Inertia axes pass through the centre of 
mass.


The "global PM" is never zero (sum of mi*ri*ri) idem for PMi even for planar 
molecule.

The global Moment of Inertia is only zero for monatomics.


But When you have a planar molecule, the matrix is no more 3D but 2D! so it's 
normal to consider that the 3nd PM is zero.

I really don't understand this - it's simply wrong. The molecule may be 2D but 
the three principal moments of inertia are most definitely non-zero for a 
planar structure. For a fully symmetrical molecule like benzene the largest PMI 
is around the axis perpendicular to the plane of the molecule and there are two 
equivalent, smaller, PMIs perpendicular to each other in the plane of the 
molecule. For a less symmetrical molecule like naphthalene, the largest PMI is 
again around the axis perpendicular to the plane, the intermediate PMI is along 
the fusion bond between the rings and the smallest PMI is around the long axis 
of the molecule. There's no way it can be correct to consider the 3rd PMI as 
zero in any planar molecule - it's never equal to zero and is only degenerate 
with the 2nd PMI for fully symmetric molecules. Only in the special case of a 
completely linear molecule (e.g. acetylene, HCN) is the 3rd PMI (along the axis 
of the molecule) equal to zero.

Apologies - I appear to have opened a can of worms here...

Chris


De : Greg Landrum mailto:greg.land...@gmail.com>>
Envoyé : dimanche 15 janvier 2017 17:42
À : Guillaume GODIN; RDKit Discuss

Objet : Re: [Rdkit-discuss] PMI API

Thanks Guillaume!

On Sun, Jan 15, 2017 at 5:01 PM, Guillaume GODIN 
mailto:guillaume.go...@firmenich.com>> wrote:

Here, Dragon results for the 3 molecules: I've included both  Whim and 3D 
descriptors but I don't have access to PMi!


I found the second document in agreement with Peter answer...


BR,

Dr. Guillaume GODIN
Principal Scientist
Chemoinformatic & Datamining
Innovation
CORPORATE R&D DIVISION
DIRECT LINE +41 (0)22 780 3645
MOBILE  +41 (0)79 536 1039
Firmenich SA
RUE DES JEUNES 1 | CASE POSTALE 239 | CH-1211 GENEVE 8


De : Peter Gedeck mailto:peter.ged...@gmail.com>>
Envoyé : dimanche 15 janvier 2017 15:07
À : Greg Landrum; RDKit Discuss; Guillaume GODIN

Objet : Re: [Rdkit-discuss] PMI API

According to this:
https://en.wikipedia.org/wiki/List_of_moments_of_inertia
The moments of inertia of a disk (something like benzene) are:

Iz = mr^2/2
Ix = Iy = mr^2/4

None of them is zero. The smallest moment of inertia of a rod-like molecule 
(e.g. C#C) is zero.

Best,

Peter



On Sun, Jan 15, 2017 at 8:15 AM Greg Landrum 
mailto:greg.land...@gmail.com>> wrote:
Hi Guillaume,

I think it this case it's something else. According to the Todeschini article 
the smallest moment of inertia of a planar molecule like benzene should be 
zero. The eigenvalues of the inertia matrix for benzene, however, are 
definitely not zero (and not close enough that it's likely to be round-off 
error).
It would be very nice if you could run the three files I mention through Dragon 
and let me know what it calculates for those descriptors.

-greg


_
From: Guillaume GODIN 
mailto:guillaume.go...@firmenich.com>>
Sent: Sunday, January 15, 2017 1:11 PM
Subject: RE: [Rdkit-discuss] PMI API
To: Greg Landrum mailto:greg.land...@gmail.com>>, RDKit 
Discuss 
mailto:rdkit-discuss@lists.sourceforge.net>>,
 Chris Earnshaw mailto:cgearns...@gmail.com>>




Dear Greg,


I  suspect that it's a precision error or eigen algorithm shift between rdkit 
c++ & dragon.


To obtain good value, I suggest to try to implement a test on the eigen values 
like i did in gateway.cpp implementation.



JacobiSVD getSVD(MatrixXd 

Re: [Rdkit-discuss] PMI API

2017-01-16 Thread Chris Earnshaw
On 16 January 2017 at 06:25, Guillaume GODIN 
wrote:

> reading carefully the Todeschini article, them said that Ic,Ib,Ia are
> determine as max & min values of I other all 3D axis passing throught the
> center of mass!
>
I don't quite understand this comment. The inequality Ia <= Ib <= Ic is one
of the errors in the Todeschini article pointed out by Greg yesterday. By
definition, the Principal Moment of Inertia axes pass through the centre of
mass.

The "global PM" is never zero (sum of mi*ri*ri) idem for PMi even for
> planar molecule.
>
The global Moment of Inertia is only zero for monatomics.


> But When you have a planar molecule, the matrix is no more 3D but 2D! so
> it's normal to consider that the 3nd PM is zero.
>
I really don't understand this - it's simply wrong. The molecule may be 2D
but the three principal moments of inertia are most definitely non-zero for
a planar structure. For a fully symmetrical molecule like benzene the
largest PMI is around the axis perpendicular to the plane of the molecule
and there are two equivalent, smaller, PMIs perpendicular to each other in
the plane of the molecule. For a less symmetrical molecule like
naphthalene, the largest PMI is again around the axis perpendicular to the
plane, the intermediate PMI is along the fusion bond between the rings and
the smallest PMI is around the long axis of the molecule. There's no way it
can be correct to consider the 3rd PMI as zero in any planar molecule -
it's never equal to zero and is only degenerate with the 2nd PMI for fully
symmetric molecules. Only in the special case of a completely linear
molecule (e.g. acetylene, HCN) is the 3rd PMI (along the axis of the
molecule) equal to zero.

Apologies - I appear to have opened a can of worms here...

Chris

> --
> *De :* Greg Landrum 
> *Envoyé :* dimanche 15 janvier 2017 17:42
> *À :* Guillaume GODIN; RDKit Discuss
>
> *Objet :* Re: [Rdkit-discuss] PMI API
>
> Thanks Guillaume!
>
> On Sun, Jan 15, 2017 at 5:01 PM, Guillaume GODIN <
> guillaume.go...@firmenich.com> wrote:
>
>> Here, Dragon results for the 3 molecules: I've included both  Whim and 3D
>> descriptors but I don't have access to PMi!
>>
>>
>> I found the second document in agreement with Peter answer...
>>
>>
>> BR,
>>
>> *Dr. Guillaume GODIN*
>> Principal Scientist
>> Chemoinformatic & Datamining
>> Innovation
>> CORPORATE R&D DIVISION
>> DIRECT LINE +41 (0)22 780 3645 <+41%2022%20780%2036%2045>
>> MOBILE  +41 (0)79 536 1039 <+41%2079%20536%2010%2039>
>> Firmenich SA
>> RUE DES JEUNES 1 | CASE POSTALE 239 | CH-1211 GENEVE 8
>>
>> --
>> *De :* Peter Gedeck 
>> *Envoyé :* dimanche 15 janvier 2017 15:07
>> *À :* Greg Landrum; RDKit Discuss; Guillaume GODIN
>>
>> *Objet :* Re: [Rdkit-discuss] PMI API
>>
>> According to this:
>> https://en.wikipedia.org/wiki/List_of_moments_of_inertia
>> The moments of inertia of a disk (something like benzene) are:
>>
>> Iz = mr^2/2
>> Ix = Iy = mr^2/4
>>
>> None of them is zero. The smallest moment of inertia of a rod-like
>> molecule (e.g. C#C) is zero.
>>
>> Best,
>>
>> Peter
>>
>>
>>
>> On Sun, Jan 15, 2017 at 8:15 AM Greg Landrum 
>> wrote:
>>
>>> Hi Guillaume,
>>>
>>> I think it this case it's something else. According to the Todeschini
>>> article the smallest moment of inertia of a planar molecule like benzene
>>> should be zero. The eigenvalues of the inertia matrix for benzene, however,
>>> are definitely not zero (and not close enough that it's likely to be
>>> round-off error).
>>> It would be very nice if you could run the three files I mention through
>>> Dragon and let me know what it calculates for those descriptors.
>>>
>>> -greg
>>>
>>>
>>> _
>>> From: Guillaume GODIN 
>>> Sent: Sunday, January 15, 2017 1:11 PM
>>> Subject: RE: [Rdkit-discuss] PMI API
>>> To: Greg Landrum , RDKit Discuss <
>>> rdkit-discuss@lists.sourceforge.net>, Chris Earnshaw <
>>> cgearns...@gmail.com>
>>>
>>>
>>>
>>> Dear Greg,
>>>
>>>
>>> I  suspect that it's a precision error or eigen algorithm shift between
>>> rdkit c++ & dragon.
>>>
>>>
>>> To obtain good value, I suggest to try to implement a test on the eigen
>>> values like i did in gateway.cpp implementation.
>>>
>>>
>>>
>>> JacobiSVD getSVD(MatrixXd A) {
>>>
>>> JacobiSVD mysvd(A,  ComputeThinU | ComputeThinV);
>>>
>>> return mysvd;
>>>
>>> }
>>>
>>>
>>> // get the A-1 matrix using
>>>
>>> MatrixXd GetPinv(MatrixXd A){
>>>
>>> JacobiSVD svd = getSVD(A);
>>>
>>> double  pinvtoler=1.e-2;// choose your tolerance wisely!
>>>
>>> VectorXd vs=svd.singularValues();
>>>
>>> VectorXd vsinv=svd.singularValues();
>>>
>>>
>>> for (unsignedint i=0; i>>
>>> if ( vs(i) > pinvtoler )
>>>
>>>vsinv(i)=1.0/vs(i);
>>>
>>>else vsinv(i)=0.0;
>>>
>>> }
>>>
>>>
>>> MatrixXd S =  vsinv.asDiagonal();
>>>
>>> MatrixXd Ap = svd.matrixV() * S * svd.matrixU().transpose();
>>>
>>> ret