Repository navigation
Add build scripts for CUDA testing on gpuCI - #7499
Conversation
Co-authored-by: Graham Markall <535640+gmarkall@users.noreply.github.com>
Co-authored-by: Graham Markall <535640+gmarkall@users.noreply.github.com>
|
I've added some docs that explain how we can trigger the CI. At this point I think the PR / setup is ready for discussion with @esc @stuartarchibald @sklam. |
|
gpuci run tests |
|
We are currently stuck on getting GPUCI to report it's status back to Github. |
|
I've got it to report manually using a token I generated myself with the |
|
gpuci rerun tests |
|
gpuci run tests |
|
gpuci run tests |
1 similar comment
|
gpuci run tests |
| RAPIDS_VER: | ||
| - "21.12" | ||
|
|
||
| excludes: |
There was a problem hiding this comment.
Nitpick: what does this do, is it needed?
There was a problem hiding this comment.
This file defines a matrix of configurations that is the cross-product of all the axes, excludes can be used to remove some configurations from the generated set of configurations, so you don't have to run the cross-product, but only the subset you're interested in. This will probably get a few entries once i start making changes to the config to test the NVIDIA conda packages and the NVIDIA CUDA Python bindings with Numba.
It is documented at: https://github.com/jenkinsci/yaml-axis-plugin/blob/master/README.md#excluding-logic
| @@ -0,0 +1,64 @@ | |||
| ############################################## | |||
| # Numba GPU build and test script for CI # | |||
There was a problem hiding this comment.
the final hash # symbol appears to be misaligned.
No functional change, just to improve the aesthetics of the script.
|
@esc Many thanks for the review! Comments added on discussion points. |
stuartarchibald
left a comment
There was a problem hiding this comment.
Thanks for the patch and for setting this up. It's great to see Numba having this integration as it means that PRs can be tested by more people without reliance on the build farm (which is often under pressure near releases/needs to be maintained at times!). I've a few suggestions, otherwise looks good! Thanks again!
|
|
||
| gpuci_logger "Create testing env" | ||
| . /opt/conda/etc/profile.d/conda.sh | ||
| gpuci_mamba_retry create -n numba -y \ |
There was a problem hiding this comment.
| gpuci_mamba_retry create -n numba -y \ | |
| gpuci_mamba_retry create -n numba_ci -y \ |
suggest using a different env name to the package name as it can help with debugging.
| "numpy" \ | ||
| "scipy" \ | ||
| "cffi" | ||
| conda activate numba |
There was a problem hiding this comment.
| conda activate numba | |
| conda activate numba_ci |
for consistency with the above suggestion.
| . /opt/conda/etc/profile.d/conda.sh | ||
| gpuci_mamba_retry create -n numba -y \ | ||
| "python=${PYTHON_VER}" \ | ||
| "cudatoolkit=${CUDA_TOOLKIT_VER}" \ |
There was a problem hiding this comment.
I think the Anaconda distro compilers should ideally be used here such that the gpuCI build is testing issues arising solely from CUDA and not through the use of different compilers. Think the Anaconda compiler packages are gcc_linux-64=7 and gxx_linux-64=7 (pin to 7 at present for libc etc compat).
There was a problem hiding this comment.
WIll add the Anaconda compilers.
| gpuci_logger "Check Python version" | ||
| python --version | ||
| $CC --version | ||
| $CXX --version |
There was a problem hiding this comment.
Can probably remove this if the compilers are set from Anaconda distro. Also numba -s (below) dumps python info.
There was a problem hiding this comment.
I'll remove the Python info, but I'll leave in the compiler checks in case some oddity results in the Anaconda compilers being installed but not used (e.g. in case there's something about the image we run on that is / becomes unanticipated).
| gpuci_logger "Check conda environment" | ||
| conda info | ||
| conda config --show-sources | ||
| conda list --show-channel-urls |
There was a problem hiding this comment.
Is this covered by numba -s?
| NUMARGS=$# | ||
| ARGS=$* | ||
|
|
||
| # Arg parsing function | ||
| function hasArg { | ||
| (( ${NUMARGS} != 0 )) && (echo " ${ARGS} " | grep -q " $1 ") | ||
| } |
- Rename conda env to numba_ci so it's not "numba", which will be less confusing (e.g. reading paths). - Use Anaconda compilers. - Remove Python version check, which comes from numba -s also. - Remove conda list, which comes from numba -s also A couple of other changes not based on the feedback: - Install psutil, suggested by numba -s - Run in verbose mode, so if there's a crash in a test we can see which one.
|
gpuci run tests |
|
@stuartarchibald Thanks for the review! I believe all comments are addressed (and gpuCI still passes). |
stuartarchibald
left a comment
There was a problem hiding this comment.
Patch looks good! Thanks for the implementation, setup and fixes @charlesbluca and @gmarkall!
|
@charlesbluca Congratulations on your first contribution to Numba! |
* python3.10: (61 commits) fix branch pruner tests alternative error for unsupported predicates for 3.10 enable peephole for list_to_tuple in 3.10 implement GEN_START bytecode instruction for 3.10 fix unroller defeat 3.10 optimizer fix polarity of offset correction Fixup instruction pointer offsets fix cpython tracing API bump max python version gpuCI build.sh: Remove dead hasArg code gpuCI config changes based on PR numba#7499 feedback build.sh: Align a hash in a comment More fixes Fix missing arg to _add_subprogram() README: Remove macOS from CUDA support list. Fixup for NvvmDIBuilder Correct line number Fix unit test wrt new DWARF producer flake8 Add test for break on symbol ...
This PR adds the relevant build scripts to run Numba's CUDA tests on gpuCI for pull requests. Some key things to note:
currently the phrase we're considering is
gpuci run tests, happy to discuss that more in this issue thoughtests will be ran with Python 3.8 and CUDA toolkit 9.2, 10.0, 10.2, 11.0, 11.2, and 11.4; this can be changed by modifying the
axis.yamladded by this PR accordinglytests are ran in the
gpuci/rapidsaidocker container, with a separate environment being created with Numba's build requirements; in the future, we should be able to move to custom Numba images with all requirements preinstalled if timing is an issue (note that this is why we specify aRAPIDS_VERandCUDA_VERinaxis.yaml, even though these go unused for the testing)currently Numba does not support outputting these test results in JUnit XML format (to my knowledge); if this functionality is added, we can modify these scripts so that the results of each individual gpuCI job (i.e. cudatoolkit=9.2, 10.0, etc.) are posted to the triggering PR
Once this PR is merged in, we can do the internal work to target gpuCI to this repo, and verify that things are working properly with a follow-up test PR; for an example of the tests in action, view charlesbluca#1
Reference an existing issue
This is a second attempt at #5123.