Skip to content

Have numpy use openblas for BLAS and LAPACK - #6194

Draft
jjerphan wants to merge 2 commits into
emscripten-forge:mainfrom
jjerphan:numpy-openblas
Draft

Have numpy use openblas for BLAS and LAPACK#6194
jjerphan wants to merge 2 commits into
emscripten-forge:mainfrom
jjerphan:numpy-openblas

Conversation

@jjerphan

@jjerphan jjerphan commented Aug 7, 2026

Copy link
Copy Markdown
Contributor

No description provided.

Signed-off-by: Julien Jerphanion <git@jjerphan.xyz>
Signed-off-by: Julien Jerphanion <git@jjerphan.xyz>

@jjerphan jjerphan Aug 7, 2026

Copy link
Copy Markdown
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I tried using threadpoolctl to test that OpenBLAS DSO are loaded at runtime, but I am getting errors.

test_numpy.py .F....
 │ =================================== FAILURES ===================================_______________________ test_openblas_linked_at_runtime ________________________def test_openblas_linked_at_runtime():
 │         # Load NumPy's BLAS/LAPACK-backed extensions before introspecting.
 │         _ = np.dot(np.eye(2), np.ones(2))
 │     
 │         info = threadpool_info()
 │         openblas = [lib for lib in info if lib["internal_api"] == "openblas"]
 │ >       assert openblas, f"OpenBLAS not detected by threadpoolctl: {info}"E       AssertionError: OpenBLAS not detected by threadpoolctl: []
 │ E       assert []
 │ test_numpy.py:17: AssertionError=============================== warnings summary ===============================test_numpy.py::test_openblas_linked_at_runtime/lib/python3.13/site-packages/threadpoolctl.py:1129: UserWarning: Unable to import LDSO from pyodide_js._module. This should never happen.
 │     warnings.warn(

Given the UserWarning reported, I think threadpoolctl first needs to be adapted for this environment before it can report DSO and other pieces of information at runtime.

@jjerphan
jjerphan marked this pull request as ready for review August 7, 2026 15:46
@jjerphan
jjerphan marked this pull request as draft August 7, 2026 15:49
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant