[Numpy-discussion] Deprecate numpy.dual?

Robert Kern robert.kern at gmail.com
Fri Jan 3 13:13:14 EST 2020


On Fri, Jan 3, 2020 at 11:55 AM Warren Weckesser <warren.weckesser at gmail.com>
wrote:

> In the notes, I listed the internal uses of `numpy.dual` within numpy
> that I found:
>
> 1. In the code that generates random variates from the multivariate normal
>    distribution, one of `svd`, `eigh` or `cholesky` are used from
> `numpy.dual`.
>

This was always a bad idea (originally mine, FWIW). The variability in
arithmetic introduced by using possibly-different LAPACK versions depending
on whether or not scipy is installed (and how it was built) is not worth
the very minor speed advantages. The covariance matrices are typically
small. And where they are large (e.g. Gaussian processes), you should
probably be doing your own decompositions instead of using
`multivariate_normal()`.

-- 
Robert Kern
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://mail.python.org/pipermail/numpy-discussion/attachments/20200103/4d555180/attachment.html>


More information about the NumPy-Discussion mailing list