Hello Developers
This issue is regarding with the building scipy-openblas library on windows x64. As building scipy from source requires scipy-openblas library, I was able to find the wheel file of these openblas library through pypi website. The project links provided in the pypi website does not provide any build instructions on this scipy-openblas. We planning to provide support for scipy for unsupported arch. So kindly provide the source and build instructions for scipy-openblas library.
Thanks in advance
Having the scipy-openblas library isn’t necessary, one can use a range of BLAS variants. scipy-openblas is just a convenient way for numpy and scipy to obtain a bundled version of OpenBLAS. There is already a wheel for win-x64 on PyPI. If you want to build OpenBLAS from source then follow the build from source instructions at GitHub - OpenMathLib/OpenBLAS: OpenBLAS is an optimized BLAS library based on GotoBLAS2 1.13 BSD version..
Thanks for the reply, I am trying to build scipy on win arm64, while installing scipy-openblas, I getting some error, since the wheel for scipy-openblas is only available for win x64 not for arm64 win. So i am planning to build scipy-openblas for win arm64, but the github link you shared is not scipy-openblas, rather it is openblas
Could you ensure that the openblas link you shared can be used for building scipy for unsupported archs?
It’s suitable for a wide variety of archs. It’ll have already been built for win arm.
I was able to build openblas git repo you provided for win arm64, the build dir contains a lib file as output, Any idea/suggestions how to use this file for scipy building?
Thanks
Can you build the DLL instead, we mainly use dynamic linking.
Hi Developers,
I have built SciPy from source with scipy-openblas
using the following command:
python dev.py build --with-scipy-openblas
python -m build --wheel -wnx -Cbuild-dir=build
The build completed successfully, and I was able to generate a scipy.whl
.
However, when I try to run a simple program that calls an OpenBLAS function, the execution gets stuck at linalg.solve()
:
import numpy as np
from scipy import linalg
a = np.array([[3, 2, 0], [1, -1, 0], [0, 5, 1]])
b = np.array([2, 4, -1])
x = linalg.solve(a, b) # Execution hangs here
To debug, I checked the _flapack.pyd
and _fblas.pyd
files inside my scipy.whl
using Dependency Walker. I found that they reference openblas.dll
, but it shows an error indicating that openblas.dll
is missing or cannot be located.
However, my scipy_openblas.whl
does include openblas.dll
, and I confirmed that the file exists in the expected location.
What could be causing this issue? Are there additional steps I need to take to ensure openblas.dll
is correctly linked and loaded at runtime?
And also what is the major difference between using scipy-openblas.whl and using openblas by pkg-config method for linking it with scipy?
Thanks!