-
Notifications
You must be signed in to change notification settings - Fork 26
finufft/cufinufft 2.3.0rc1 #1168
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
Conversation
|
Initial findings: The The intel osx wheel appears to not crash, but required loosening the Linux wheel was fine on |
|
Going to mark ready for review so the CI jobs run. No intention of merging at this time. |
|
I'm seeing weird test failures relating to basic |
|
Minor wrinkle, my M1 macs are all on some form of Ventura (13.x) but the ARM wheel is only 14+. I'm going to upgrade one and try again. Might consider supporting older versions as I think they are more common than 14 at this time... |
|
Upgraded to new OS (14.6.1).... in brief, breaks python 3.8; numpy/scipy have blas/lapack issues on this newer OS; bummer (not relating to Tried 3.9. Initially hit problems with Unfortunately this has not reproduced the specifc issue on the |
|
@garrettwrong I see the osx-arm ci failing because of picking up the x86 wheel not the arm wheel. Any idea? On my local m1 or m2, it's picking the correct arm wheel in https://pypi.org/project/finufft/2.3.0rc1/#files |
|
@garrettwrong it seems in the old successful osx-arm ci runs also picked the x86 wheels for all the packages but worked, |
|
Hi Libin, yes, that is what we've recommended users run as more packages are supported via x86 conda. My expectation is that should work.... (as it has been). On my personal M1 machine I am running conda using the ARM install. I ran into issues using python 3.8 after upgrading my OS to use the FI arm wheel. 3.9 was okay. |
It seems falling with the new wheel, if you run some x86_64 generated wheel which has x86_64 instruction sets, is it meaning the conda env is running under some x86_64 virtual machine on arm github hosted machine?
I'm able to run python 3.8, 3.9, 3.11 and 3.12 on my local m1 machine, what is the error for your 3.8. |
Hi Libin the issue with 3.8 on the latest OSX is relating to some lapack calls The x86_64 wheel should run on the Currently we only automatically check the former in our CI. Until recently our code depended on (py)FFTW which was causing a lot trouble on M1 native arm installs before... trouble like illegal instructions.... This is mostly because they just don't support that platform, but it was not a problem under x86 using the x86 installs. To use M1 native I had to alter sources and manually build FFTW and pyFFTW etc. Further, they were not the only packages to have issues on native arm, so the safer route was to recommend and test x86_64. I'd like to support and put both under test but we'll need to remove at least one other problem package first. Thanks |
Do you know which CPU instruction sets conda x86_64 env support if it's the conda x86_64 install running on Mac arm arch machine? CPU instruction sets I mean the Intel sse, avx, avx2, avx512 etc. |
|
@garrettwrong I guess the conda x86 env on Mac arm doesn't support avx2 instructions. That's why the illegal instruction set error comes. I'm guess running low end x86 instructions with an emulator on Mac arm machine will be slow compared to run everything with native arm instructions. |
|
Correct, Rosetta does not provide AVX emulation. Is there not a way to provide a SSE fallback or just not use AVX in the So the other main thing remaining to sort out is how this FINUFFT release is interacting with logging. I suspect it has something to do with the combo of multiprocessing/threading, but haven't looked into it further yet. Where there any logging code changes? |
|
We're recompiling the wheels without Regarding the logging, we're not sure what's happening there. There is no logging in the |
Thanks. Cool, I think that happened a few times before with the x86_64 wheels getting compiled on a specific machine and not working on our x86_64 linux machine. I didn't think of it this time... the linux wheels worked :).
I'm not sure about that. There is definitely a warning capture context (that is most likely not thread safe...). I think I might have put that in before because the last wheel was throwing out all other packages warnings/logs :D :D ... The context patch did work as expected when tested before, no side effects then. Tomorrow I can try to check if it is that warning context, but I'll need to build finufft locally to do so. Good idea. I checked but it does not appear other any other packages change. |
|
@janden . After our discussion this morning I found that commenting out the following lines resolves the logging issue in our pytest. Obviously this breaks |
|
Thanks for this. I'll take a closer look. Both sets of lines have to be commented out then? Very strange. |
|
no, it appears to be the make_plan line. Could alternatively set ier=0. |
|
Ok. I'll continue investigating. |
|
It seems the This only happens for numpy < 1.25.0, for numpy >= 1.25.0, it's good. While for python 3.8, the latest supported numpy version is 1.24.4. Tested with the following tweaks in |
For older (<1.25) versions of NumPy, calling `np.ctypeslib.load_library`
results in the logging level being reset. This workaround checks for
that bug and preserves the logging level.
For more info, see discussion at
ComputationalCryoEM/ASPIRE-Python#1168
Co-authored-by: Libin Lu <llu@flatironinstitute.org>
For older (<1.25) versions of NumPy, calling `np.ctypeslib.load_library`
results in the logging level being reset. This workaround checks for
that bug and preserves the logging level.
For more info, see discussion at
ComputationalCryoEM/ASPIRE-Python#1168
Co-authored-by: Libin Lu <llu@flatironinstitute.org>
For older (<1.25) versions of NumPy, calling `np.ctypeslib.load_library`
results in the logging level being reset. This workaround checks for
that bug and preserves the logging level.
For more info, see discussion at
ComputationalCryoEM/ASPIRE-Python#1168
Co-authored-by: Libin Lu <llu@flatironinstitute.org>
|
Cool. I'm wondering if we no longer need the different tolerance for OSX now that the compile options were change for those wheels. I'll check, but otherwise this is looking good. Thanks for the help! |
|
Merging 🎆 🚀 |


For testing purposes.