-
Notifications
You must be signed in to change notification settings - Fork 96
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
GPU Acceleration on Newest Version Not Working #2339
Comments
Hi Dario, Your message puzzles me somehow because I was not aware that pyFAI was actually running on Apple-silicon GPU. There is something else that puzzles me even further: Sorry for answering to your message with so many questions ... Jerome |
FYI the clinfo on a macbook M3 Pro:
|
So basically, it confirms the bug ... |
Some tests passes, some don't on Apple silicon GPU: Passes:
Broken
Since preproc is used by all other kernels ... makes sense to investigate there |
Apparently the bug is related to the treatment of |
Hi Jerome, here are the outputs of the clinfo and clpeak.
– As for the question of if the computer ran out of memory, no. I had about 40 GB of RAM left. So I really don't understand the memory error either. |
Hi Dario, Thanks for the feed-back. Indeed, the computer has apparently enough resources. I managed to reproduce the bug with the help of VinceFN. Double precision (aka fp64) is not a first class citizen on GPU, and was never supported on Apple hardware, but at the intel CPU time, the compiler was actually reporting properly it was not usable. As a consequence, the compilation fails when encountering the double precision section... of course, without clear error message. This pull request should fix this issue ... Could you please validate try it ? |
I just checked on MacOS on Intel hardware and the bug was not present. Thus it is a regression introduced with Apple Silicon. |
Hi Jerome, I just approved the request. I tested on my Mac and things seem to be working. |
I have been trying to update a piece of code I wrote to run on an M1 Max MacBook Pro with 64 GB of RAM to make use of the gpu. In a previous version of pyFAI, this was accomplished easily using the method: ('full', 'csr', 'opencl', 'gpu'). Now, that method does not work. I tried going through the tutorial on the pyfai documentation (https://pyfai.readthedocs.io/en/stable/usage/tutorial/Parallelization/GPU-decompression.html) and the issue remains.
When I run this code, it fails when it uses the method: ('full', 'csr', 'opencl', target).
The warning thrown is: WARNING:pyFAI.azimuthalIntegrator:MemoryError: falling back on default forward implementation
pyFAI can't recover from this and it seems to be stemming from not being able to reset the engine. It just gets stuck in an infinite wait loop.
The text was updated successfully, but these errors were encountered: