Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

EVP errors on native-arm builds on apple silicon #202

Open
kburns opened this issue May 28, 2022 · 7 comments
Open

EVP errors on native-arm builds on apple silicon #202

kburns opened this issue May 28, 2022 · 7 comments
Labels
stack Issue related to building on certain machines
Milestone

Comments

@kburns
Copy link
Member

kburns commented May 28, 2022

It looks like theres a variety of problems with both the dense and sparse eigenvalue solvers when using a native-arm build on apple silicon. For now I've changed the conda install scripts to build the stack for x86 on apple silicon by default. This comes at a 1.5-2x performance penalty, but seems much more robust for eigenvalue problems.

For dense problems, it seems like pinning libopenblas < 0.3.20 helps things, otherwise there are ggev errors. But for sparse problems, there are still ARPACK convergence errors for problems that work fine on x86.

@kburns kburns added the stack Issue related to building on certain machines label Jun 23, 2022
@kburns
Copy link
Member Author

kburns commented Aug 15, 2022

Still getting ggev errors with libopenblas 0.3.21.

@kburns
Copy link
Member Author

kburns commented Aug 15, 2022

Opened an issue on the openblas repo: OpenMathLib/OpenBLAS#3735.

@martin-frbg
Copy link

Less expensive workaround should be to build OpenBLAS on M1 with TARGET=ARMV8

@kburns
Copy link
Member Author

kburns commented Aug 22, 2022

The dense eigenvalue (ggev) errors are fixed with conda-forge/openblas-feedstock#144 and conda-forge/openblas-feedstock#145, so builds 1+ for libopenblas 0.3.21 from conda-forge should work. Sparse problems still persist.

@kburns
Copy link
Member Author

kburns commented Sep 16, 2022

Sparse problems seem to be fixed with scipy 1.9.1, so native-arm conda builds now pass all tests and run the examples. They still don't have higher-precision support in numpy, though, so we should add tests that can explicitly tell when e.g. spherical harmonic polynomial construction is failing due to underflow issues with the envelopes.

@kburns kburns added this to the 3.0.0 milestone Jun 14, 2023
@BenWibking
Copy link

Is this fixed with the conda-forge packages for Dedalus3? (The documentation still says to install the x86_64 packages.)

@kburns
Copy link
Member Author

kburns commented Feb 1, 2024

No, we still need to work around the lack of higher-precision support on apple silicon for spherical problems. But for Cartesian problems I expect everything to work fine. But that said, we haven't tested thoroughly on arm builds yet.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
stack Issue related to building on certain machines
Projects
None yet
Development

No branches or pull requests

3 participants