[SciPy-User] Modify package dependencies, or issue a runtime warning, if a fast BLAS implementation not found?

David Cournapeau cournape@gmail....
Wed Sep 12 04:28:36 CDT 2012

On Wed, Sep 12, 2012 at 3:12 AM, Hugh Perkins <hughperkins@gmail.com> wrote:
> (Was "How to efficiently do dot(dot( A.T, diag(d) ), A ) ?")
> On Wed, Sep 12, 2012 at 2:30 AM, Pauli Virtanen <pav@iki.fi> wrote:
>> 11.09.2012 20:15, Pauli Virtanen kirjoitti:
>>> Here are results on one (slowish) machine:
>> Ok, just for completeness: the bad performance for `np.dot` on this
>> machine comes from the fact that Numpy is not linked with any BLAS
>> library, so it falls back to a slow and naive algorithm. (You can check
>> this as follows: if `numpy.dot.__module__` is 'numpy.core._dotblas', you
>> have some BLAS.)
> Considering the amount of emails and effort that it took in order for
> one naive user (ie myself) to find this, perhaps it might be worth
> doing one or more of the following? :
> - ensure that openblas is a dependency of scipy in the ubuntu packages
> (and/or debian, redhat etc packages)

This is out of our hands, and mostly an issue with distributions.
Distributions often have different priorities than people looking for
best performances, so there is always a tradeoff between
distribution/platform support/performance.

> - issue a check for a reasonably performing blas when these functions
> are used in scipy, and issue a warning if only reference blas is found

you can do the check with scipy.show_config(), although I reckon its
usage is not very obvious/straightfoward.


More information about the SciPy-User mailing list