Skip to content

Commit

Permalink
cugraph: Build CUDA 12 packages (#3456)
Browse files Browse the repository at this point in the history
First attempt at building libcugraph with CUDA 12 and nvidia channel packages

Closes #3271

Authors:
  - Vyas Ramasubramani (https://github.com/vyasr)
  - Rick Ratzel (https://github.com/rlratzel)
  - Bradley Dice (https://github.com/bdice)

Approvers:
  - Ray Douglass (https://github.com/raydouglass)
  - Chuck Hastings (https://github.com/ChuckHastings)
  - Bradley Dice (https://github.com/bdice)
  - Rick Ratzel (https://github.com/rlratzel)
  - https://github.com/jakirkham

URL: #3456
  • Loading branch information
vyasr authored Jul 20, 2023
1 parent 145a92b commit 54b43e1
Show file tree
Hide file tree
Showing 12 changed files with 192 additions and 135 deletions.
4 changes: 1 addition & 3 deletions .github/workflows/build.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -30,7 +30,6 @@ jobs:
secrets: inherit
uses: rapidsai/shared-action-workflows/.github/workflows/[email protected]
with:
matrix_filter: map(select(.CUDA_VER | startswith("11")))
build_type: ${{ inputs.build_type || 'branch' }}
branch: ${{ inputs.branch }}
date: ${{ inputs.date }}
Expand All @@ -40,7 +39,6 @@ jobs:
secrets: inherit
uses: rapidsai/shared-action-workflows/.github/workflows/[email protected]
with:
matrix_filter: map(select(.CUDA_VER | startswith("11")))
build_type: ${{ inputs.build_type || 'branch' }}
branch: ${{ inputs.branch }}
date: ${{ inputs.date }}
Expand All @@ -63,7 +61,7 @@ jobs:
arch: "amd64"
branch: ${{ inputs.branch }}
build_type: ${{ inputs.build_type || 'branch' }}
container_image: "rapidsai/ci:cuda11.8.0-ubuntu22.04-py3.10"
container_image: "rapidsai/ci:latest"
date: ${{ inputs.date }}
node_type: "gpu-v100-latest-1"
run_script: "ci/build_docs.sh"
Expand Down
8 changes: 2 additions & 6 deletions .github/workflows/pr.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -35,29 +35,25 @@ jobs:
secrets: inherit
uses: rapidsai/shared-action-workflows/.github/workflows/[email protected]
with:
matrix_filter: map(select(.CUDA_VER | startswith("11")))
build_type: pull-request
node_type: cpu16
conda-cpp-tests:
needs: conda-cpp-build
secrets: inherit
uses: rapidsai/shared-action-workflows/.github/workflows/[email protected]
with:
matrix_filter: map(select(.CUDA_VER | startswith("11")))
build_type: pull-request
conda-python-build:
needs: conda-cpp-build
secrets: inherit
uses: rapidsai/shared-action-workflows/.github/workflows/[email protected]
with:
matrix_filter: map(select(.CUDA_VER | startswith("11")))
build_type: pull-request
conda-python-tests:
needs: conda-python-build
secrets: inherit
uses: rapidsai/shared-action-workflows/.github/workflows/[email protected]
with:
matrix_filter: map(select(.CUDA_VER | startswith("11")))
build_type: pull-request
conda-notebook-tests:
needs: conda-python-build
Expand All @@ -67,7 +63,7 @@ jobs:
build_type: pull-request
node_type: "gpu-v100-latest-1"
arch: "amd64"
container_image: "rapidsai/ci:cuda11.8.0-ubuntu22.04-py3.10"
container_image: "rapidsai/ci:latest"
run_script: "ci/test_notebooks.sh"
docs-build:
needs: conda-python-build
Expand All @@ -77,7 +73,7 @@ jobs:
build_type: pull-request
node_type: "gpu-v100-latest-1"
arch: "amd64"
container_image: "rapidsai/ci:cuda11.8.0-ubuntu22.04-py3.10"
container_image: "rapidsai/ci:latest"
run_script: "ci/build_docs.sh"
wheel-build-pylibcugraph:
needs: checks
Expand Down
2 changes: 0 additions & 2 deletions .github/workflows/test.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -18,7 +18,6 @@ jobs:
secrets: inherit
uses: rapidsai/shared-action-workflows/.github/workflows/[email protected]
with:
matrix_filter: map(select(.CUDA_VER | startswith("11")))
build_type: nightly
branch: ${{ inputs.branch }}
date: ${{ inputs.date }}
Expand All @@ -27,7 +26,6 @@ jobs:
secrets: inherit
uses: rapidsai/shared-action-workflows/.github/workflows/[email protected]
with:
matrix_filter: map(select(.CUDA_VER | startswith("11")))
build_type: nightly
branch: ${{ inputs.branch }}
date: ${{ inputs.date }}
Expand Down
54 changes: 31 additions & 23 deletions ci/build_python.sh
Original file line number Diff line number Diff line change
Expand Up @@ -26,28 +26,36 @@ rapids-mamba-retry mambabuild \
--channel "${RAPIDS_CONDA_BLD_OUTPUT_DIR}" \
conda/recipes/cugraph

rapids-mamba-retry mambabuild \
--no-test \
--channel "${CPP_CHANNEL}" \
--channel "${RAPIDS_CONDA_BLD_OUTPUT_DIR}" \
conda/recipes/cugraph-service

rapids-mamba-retry mambabuild \
--no-test \
--channel "${CPP_CHANNEL}" \
--channel "${RAPIDS_CONDA_BLD_OUTPUT_DIR}" \
--channel pyg \
--channel pytorch \
--channel pytorch-nightly \
conda/recipes/cugraph-pyg

rapids-mamba-retry mambabuild \
--no-test \
--channel "${CPP_CHANNEL}" \
--channel "${RAPIDS_CONDA_BLD_OUTPUT_DIR}" \
--channel dglteam \
--channel pytorch \
--channel pytorch-nightly \
conda/recipes/cugraph-dgl
RAPIDS_CUDA_MAJOR="${RAPIDS_CUDA_VERSION%%.*}"

if [[ ${RAPIDS_CUDA_MAJOR} == "11" ]]; then
# Only one CUDA configuration is needed, so we choose CUDA 11 arbitrarily.
# Nothing in the cugraph-service packages is CUDA-specific.
rapids-mamba-retry mambabuild \
--no-test \
--channel "${CPP_CHANNEL}" \
--channel "${RAPIDS_CONDA_BLD_OUTPUT_DIR}" \
conda/recipes/cugraph-service

# Only CUDA 11 is supported right now due to PyTorch requirement.
rapids-mamba-retry mambabuild \
--no-test \
--channel "${CPP_CHANNEL}" \
--channel "${RAPIDS_CONDA_BLD_OUTPUT_DIR}" \
--channel pyg \
--channel pytorch \
--channel pytorch-nightly \
conda/recipes/cugraph-pyg

# Only CUDA 11 is supported right now due to PyTorch requirement.
rapids-mamba-retry mambabuild \
--no-test \
--channel "${CPP_CHANNEL}" \
--channel "${RAPIDS_CONDA_BLD_OUTPUT_DIR}" \
--channel dglteam \
--channel pytorch \
--channel pytorch-nightly \
conda/recipes/cugraph-dgl
fi

rapids-upload-conda-to-s3 python
3 changes: 2 additions & 1 deletion conda/environments/all_cuda-118_arch-x86_64.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -12,7 +12,8 @@ dependencies:
- aiohttp
- c-compiler
- cmake>=3.26.4
- cudatoolkit=11.8
- cuda-version=11.8
- cudatoolkit
- cudf==23.8.*
- cupy>=12.0.0
- cxx-compiler
Expand Down
18 changes: 3 additions & 15 deletions conda/recipes/cugraph/conda_build_config.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -5,6 +5,9 @@ cxx_compiler_version:
- 11

cuda_compiler:
- cuda-nvcc

cuda11_compiler:
- nvcc

cmake_version:
Expand All @@ -15,18 +18,3 @@ sysroot_version:

ucx_py_version:
- "0.33.*"

# The CTK libraries below are missing from the conda-forge::cudatoolkit
# package. The "*_host_*" version specifiers correspond to `11.8` packages.

libcublas_host_version:
- "=11.11.3.6"

libcurand_host_version:
- "=10.3.0.86"

libcusolver_host_version:
- "=11.4.1.48"

libcusparse_host_version:
- "=11.7.5.86"
40 changes: 20 additions & 20 deletions conda/recipes/cugraph/meta.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -39,36 +39,38 @@ build:
requirements:
build:
- {{ compiler('c') }}
- {{ compiler('cuda') }} {{ cuda_version }}
- {{ compiler('cxx') }}
{% if cuda_major == "11" %}
- {{ compiler('cuda11') }} {{ cuda_version }}
{% else %}
- {{ compiler('cuda') }}
{% endif %}
- cuda-version ={{ cuda_version }}
- cmake {{ cmake_version }}
- ninja
- sysroot_{{ target_platform }} {{ sysroot_version }}
host:
- cudatoolkit ={{ cuda_version }}
- cuda-version ={{ cuda_version }}
{% if cuda_major == "11" %}
- cudatoolkit
{% endif %}
- cudf ={{ minor_version }}
- cython >=0.29,<0.30
- libcublas {{ libcublas_host_version }}
- libcublas-dev {{ libcublas_host_version }}
- libcugraph ={{ version }}
- libcurand {{ libcurand_host_version }}
- libcurand-dev {{ libcurand_host_version }}
- libcusolver {{ libcusolver_host_version }}
- libcusolver-dev {{ libcusolver_host_version }}
- libcusparse {{ libcusparse_host_version }}
- libcusparse-dev {{ libcusparse_host_version }}
- libraft ={{ minor_version }}
- libraft-headers ={{ minor_version }}
- pylibraft ={{ minor_version}}
- pylibraft ={{ minor_version }}
- python
- raft-dask ={{ minor_version }}
- rmm ={{ minor_version }}
- scikit-build >=0.13.1
- setuptools
- ucx-proc=*=gpu
- ucx-py {{ ucx_py_version }}
run:
- {{ pin_compatible('cudatoolkit', max_pin='x', min_pin='x') }}
- cuda-python >=11.7.1,<12.0
- {{ pin_compatible('cuda-version', max_pin='x', min_pin='x') }}
{% if cuda_major == "11" %}
- cudatoolkit
- cuda-python >=11.7.1,<12.0a0
{% else %}
- cuda-python >=12.0,<13.0a0
{% endif %}
- cudf ={{ minor_version }}
- cupy >=12.0.0
- dask-cuda ={{ minor_version }}
Expand All @@ -77,8 +79,6 @@ requirements:
- dask-core >=2023.5.1
- distributed >=2023.5.1
- libcugraph ={{ version }}
- libraft ={{ minor_version }}
- libraft-headers ={{ minor_version }}
- pylibcugraph ={{ version }}
- pylibraft ={{ minor_version }}
- python
Expand All @@ -88,7 +88,7 @@ requirements:

tests:
requirements:
- cudatoolkit ={{ cuda_version }}
- cuda-version ={{ cuda_version }}
imports:
- cugraph

Expand Down
39 changes: 31 additions & 8 deletions conda/recipes/libcugraph/conda_build_config.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -5,6 +5,9 @@ cxx_compiler_version:
- 11

cuda_compiler:
- cuda-nvcc

cuda11_compiler:
- nvcc

cmake_version:
Expand All @@ -19,23 +22,43 @@ nccl_version:
gtest_version:
- ">=1.13.0"

cuda_profiler_api_version:
- ">=11.8.86,<12"

sysroot_version:
- "2.17"

# The CTK libraries below are missing from the conda-forge::cudatoolkit
# package. The "*_host_*" version specifiers correspond to `11.8` packages.
# package. The "*_host_*" version specifiers correspond to `11.8` packages
# and the "*_run_*" version specifiers correspond to `11.x` packages.

libcublas_host_version:
cuda11_libcublas_host_version:
- "=11.11.3.6"

libcurand_host_version:
cuda11_libcublas_run_version:
- ">=11.5.2.43,<12.0.0"

cuda11_libcurand_host_version:
- "=10.3.0.86"

libcusolver_host_version:
cuda11_libcurand_run_version:
- ">=10.2.5.43,<10.3.1"

cuda11_libcusolver_host_version:
- "=11.4.1.48"

libcusparse_host_version:
cuda11_libcusolver_run_version:
- ">=11.2.0.43,<11.4.2"

cuda11_libcusparse_host_version:
- "=11.7.5.86"

cuda11_libcusparse_run_version:
- ">=11.6.0.43,<12.0.0"

# `cuda-profiler-api` only has `11.8.0` and `12.0.0` packages for all
# architectures. The "*_host_*" version specifiers correspond to `11.8` packages and the
# "*_run_*" version specifiers correspond to `11.x` packages.

cuda11_cuda_profiler_api_host_version:
- "=11.8.86"

cuda11_cuda_profiler_api_run_version:
- ">=11.4.240,<12"
Loading

0 comments on commit 54b43e1

Please sign in to comment.