Open
Conversation
Collaborator
Author
|
cscs-ci run |
Collaborator
Author
|
cscs-ci run |
1 similar comment
Collaborator
Author
|
cscs-ci run |
Collaborator
Author
|
I've downloaded and tested the pre-built linux-x86 wheel and it works |
Luthaf
reviewed
Mar 30, 2026
Comment on lines
+300
to
+309
| lib.sphericart_cuda_spherical_harmonics_compute_array_with_hessians.restype = None | ||
| lib.sphericart_cuda_spherical_harmonics_compute_array_with_hessians.argtypes = [ | ||
| sphericart_cuda_spherical_harmonics_calculator_t, | ||
| ctypes.POINTER(ctypes.c_double), | ||
| ctypes.c_size_t, | ||
| ctypes.POINTER(ctypes.c_double), | ||
| ctypes.POINTER(ctypes.c_double), | ||
| ctypes.POINTER(ctypes.c_double), | ||
| ctypes.c_void_p, | ||
| ] |
Contributor
There was a problem hiding this comment.
This is fine for now, but should we look into simplifying the API a bit? Maybe adding explicit device parameter like vesin, and a separate sph_kind="SphericalHarmonics | SolidHarmonics"?
Comment on lines
+40
to
+51
| # if CUDA is available, install the appropriate cupy version | ||
| bash -c 'if command -v nvcc >/dev/null 2>&1; then \ | ||
| CUDA_MAJOR=$(nvcc --version | sed -n "s/.*release \([0-9][0-9]*\)\..*/\1/p" | head -n 1); \ | ||
| if [ "$CUDA_MAJOR" = "12" ]; then \ | ||
| python -m pip install -U cupy-cuda12x; \ | ||
| elif [ "$CUDA_MAJOR" = "13" ]; then \ | ||
| python -m pip install -U cupy-cuda13x; \ | ||
| elif [ -n "$CUDA_MAJOR" ]; then \ | ||
| echo "Unsupported CUDA major version for CuPy wheels: $CUDA_MAJOR"; \ | ||
| exit 1; \ | ||
| fi; \ | ||
| fi' |
Contributor
There was a problem hiding this comment.
If you want, I have a slightly more robust script on vesin, that does not required having the cuda toolkit installed, only the drivers: https://github.com/Luthaf/vesin/blob/main/scripts/install-cupy.sh
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
As in the title; closes #217. The implementation follows lab-cosmo/mops#37. CuPy support is also made available through the pre-built wheels