The stackoverflow link above contains a simple testcase:

>>> from scipy.linalg import get_blas_funcs>>> gemm = get_blas_funcs("gemm", 
>>> [X, Y])>>> np.all(gemm(1, X, Y) == np.dot(X, Y))True

It would be of interest to benchmark gemm against np.dot. Maybe np.dot
doesn't use blas at al for whatever reason?


Am Di., 23. Feb. 2021 um 20:46 Uhr schrieb David Menéndez Hurtado <
davidmen...@gmail.com>:

> On Tue, 23 Feb 2021, 7:41 pm Roman Yurchak, <rth.yurc...@gmail.com> wrote:
>
>> For the first benchmark apparently A.dot(B) with A real and B complex is
>> a known issue performance wise
>> https://github.com/numpy/numpy/issues/10468
>
>
> I splitted B into a vector of size (N, 2) for the real and imaginary part,
> and that makes the multiplication twice as fast.
>
>
> My configuration (also in Fedora 33) np.show_config()
>
>
>
> blas_mkl_info:
>   NOT AVAILABLE
> blis_info:
>   NOT AVAILABLE
> openblas_info:
>     libraries = ['openblas', 'openblas']
>     library_dirs = ['/usr/local/lib']
>     language = c
>     define_macros = [('HAVE_CBLAS', None)]
> blas_opt_info:
>     libraries = ['openblas', 'openblas']
>     library_dirs = ['/usr/local/lib']
>     language = c
>     define_macros = [('HAVE_CBLAS', None)]
> lapack_mkl_info:
>   NOT AVAILABLE
> openblas_lapack_info:
>     libraries = ['openblas', 'openblas']
>     library_dirs = ['/usr/local/lib']
>     language = c
>     define_macros = [('HAVE_CBLAS', None)]
> lapack_opt_info:
>     libraries = ['openblas', 'openblas']
>     library_dirs = ['/usr/local/lib']
>     language = c
>     define_macros = [('HAVE_CBLAS', None)]
> _______________________________________________
> NumPy-Discussion mailing list
> NumPy-Discussion@python.org
> https://mail.python.org/mailman/listinfo/numpy-discussion
>
_______________________________________________
NumPy-Discussion mailing list
NumPy-Discussion@python.org
https://mail.python.org/mailman/listinfo/numpy-discussion

Reply via email to