diff --git a/.github/workflows/build.yaml b/.github/workflows/build.yaml index f365c52c7..8679cd61b 100644 --- a/.github/workflows/build.yaml +++ b/.github/workflows/build.yaml @@ -28,7 +28,7 @@ concurrency: jobs: conda-python-build: secrets: inherit - uses: rapidsai/shared-workflows/.github/workflows/conda-python-build.yaml@branch-23.12 + uses: rapidsai/shared-workflows/.github/workflows/conda-python-build.yaml@branch-24.02 with: build_type: ${{ inputs.build_type || 'branch' }} branch: ${{ inputs.branch }} @@ -38,7 +38,7 @@ jobs: if: github.ref_type == 'branch' needs: [conda-python-build] secrets: inherit - uses: rapidsai/shared-workflows/.github/workflows/custom-job.yaml@branch-23.12 + uses: rapidsai/shared-workflows/.github/workflows/custom-job.yaml@branch-24.02 with: arch: "amd64" branch: ${{ inputs.branch }} @@ -51,29 +51,30 @@ jobs: upload-conda: needs: [conda-python-build] secrets: inherit - uses: rapidsai/shared-workflows/.github/workflows/conda-upload-packages.yaml@branch-23.12 + uses: rapidsai/shared-workflows/.github/workflows/conda-upload-packages.yaml@branch-24.02 with: build_type: ${{ inputs.build_type || 'branch' }} branch: ${{ inputs.branch }} date: ${{ inputs.date }} sha: ${{ inputs.sha }} wheel-build: - runs-on: ubuntu-latest - container: - image: rapidsai/ci-conda:latest - defaults: - run: - shell: bash - steps: - - uses: actions/checkout@v3 - with: - fetch-depth: 0 - - name: Build wheel - run: ci/build_python_pypi.sh - env: - GH_TOKEN: ${{ github.token }} - - name: Publish distribution 📦 to PyPI - uses: pypa/gh-action-pypi-publish@release/v1 - with: - password: ${{ secrets.RAPIDSAI_PYPI_TOKEN }} - skip-existing: true + secrets: inherit + uses: rapidsai/shared-workflows/.github/workflows/wheels-build.yaml@branch-24.02 + with: + build_type: ${{ inputs.build_type || 'branch' }} + branch: ${{ inputs.branch }} + sha: ${{ inputs.sha }} + date: ${{ inputs.date }} + script: ci/build_wheel.sh + # Package is pure Python and only ever requires one build. + matrix_filter: map(select(.ARCH == "amd64" and .PY_VER == "3.10" and .CUDA_VER == "12.0.1")) + wheel-publish: + needs: wheel-build + secrets: inherit + uses: rapidsai/shared-workflows/.github/workflows/wheels-publish.yaml@branch-24.02 + with: + build_type: ${{ inputs.build_type || 'branch' }} + branch: ${{ inputs.branch }} + sha: ${{ inputs.sha }} + date: ${{ inputs.date }} + package-name: dask-cuda diff --git a/.github/workflows/pr.yaml b/.github/workflows/pr.yaml index 26a5e8e9c..8d701e0ae 100644 --- a/.github/workflows/pr.yaml +++ b/.github/workflows/pr.yaml @@ -18,26 +18,26 @@ jobs: - docs-build - wheel-build secrets: inherit - uses: rapidsai/shared-workflows/.github/workflows/pr-builder.yaml@branch-23.12 + uses: rapidsai/shared-workflows/.github/workflows/pr-builder.yaml@branch-24.02 checks: secrets: inherit - uses: rapidsai/shared-workflows/.github/workflows/checks.yaml@branch-23.12 + uses: rapidsai/shared-workflows/.github/workflows/checks.yaml@branch-24.02 conda-python-build: needs: checks secrets: inherit - uses: rapidsai/shared-workflows/.github/workflows/conda-python-build.yaml@branch-23.12 + uses: rapidsai/shared-workflows/.github/workflows/conda-python-build.yaml@branch-24.02 with: build_type: pull-request conda-python-tests: needs: conda-python-build secrets: inherit - uses: rapidsai/shared-workflows/.github/workflows/conda-python-tests.yaml@branch-23.12 + uses: rapidsai/shared-workflows/.github/workflows/conda-python-tests.yaml@branch-24.02 with: build_type: pull-request docs-build: needs: conda-python-build secrets: inherit - uses: rapidsai/shared-workflows/.github/workflows/custom-job.yaml@branch-23.12 + uses: rapidsai/shared-workflows/.github/workflows/custom-job.yaml@branch-24.02 with: build_type: pull-request node_type: "gpu-v100-latest-1" @@ -45,18 +45,10 @@ jobs: container_image: "rapidsai/ci-conda:latest" run_script: "ci/build_docs.sh" wheel-build: - needs: checks - runs-on: ubuntu-latest - container: - image: rapidsai/ci-conda:latest - defaults: - run: - shell: bash - steps: - - uses: actions/checkout@v3 - with: - fetch-depth: 0 - - name: Build wheel - run: ci/build_python_pypi.sh - env: - GH_TOKEN: ${{ github.token }} + secrets: inherit + uses: rapidsai/shared-workflows/.github/workflows/wheels-build.yaml@branch-24.02 + with: + build_type: pull-request + # Package is pure Python and only ever requires one build. + matrix_filter: map(select(.ARCH == "amd64" and .PY_VER == "3.10" and .CUDA_VER == "12.0.1")) + script: "ci/build_wheel.sh" diff --git a/.github/workflows/test.yaml b/.github/workflows/test.yaml index 9a5e0428a..9bf068690 100644 --- a/.github/workflows/test.yaml +++ b/.github/workflows/test.yaml @@ -16,7 +16,7 @@ on: jobs: conda-python-tests: secrets: inherit - uses: rapidsai/shared-workflows/.github/workflows/conda-python-tests.yaml@branch-23.12 + uses: rapidsai/shared-workflows/.github/workflows/conda-python-tests.yaml@branch-24.02 with: build_type: nightly branch: ${{ inputs.branch }} diff --git a/.pre-commit-config.yaml b/.pre-commit-config.yaml index c938e133a..492c96f2c 100644 --- a/.pre-commit-config.yaml +++ b/.pre-commit-config.yaml @@ -32,6 +32,11 @@ repos: additional_dependencies: [types-cachetools] args: ["--module=dask_cuda", "--ignore-missing-imports"] pass_filenames: false + - repo: https://github.com/rapidsai/dependency-file-generator + rev: v1.8.0 + hooks: + - id: rapids-dependency-file-generator + args: ["--clean"] default_language_version: python: python3 diff --git a/CHANGELOG.md b/CHANGELOG.md index fa8bd51af..126cf46c2 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -1,3 +1,27 @@ +# dask-cuda 24.02.00 (12 Feb 2024) + +## 🚨 Breaking Changes + +- Publish nightly wheels to NVIDIA index instead of PyPI ([#1294](https://github.com/rapidsai/dask-cuda/pull/1294)) [@pentschev](https://github.com/pentschev) + +## 🐛 Bug Fixes + +- Fix get_device_memory_ids ([#1305](https://github.com/rapidsai/dask-cuda/pull/1305)) [@wence-](https://github.com/wence-) +- Prevent double UCX initialization in `test_dgx` ([#1301](https://github.com/rapidsai/dask-cuda/pull/1301)) [@pentschev](https://github.com/pentschev) +- Update to Dask's `shuffle_method` kwarg ([#1300](https://github.com/rapidsai/dask-cuda/pull/1300)) [@pentschev](https://github.com/pentschev) +- Add timeout to `test_dask_use_explicit_comms` ([#1298](https://github.com/rapidsai/dask-cuda/pull/1298)) [@pentschev](https://github.com/pentschev) +- Publish nightly wheels to NVIDIA index instead of PyPI ([#1294](https://github.com/rapidsai/dask-cuda/pull/1294)) [@pentschev](https://github.com/pentschev) +- Make versions PEP440 compliant ([#1279](https://github.com/rapidsai/dask-cuda/pull/1279)) [@vyasr](https://github.com/vyasr) +- Generate pyproject.toml with dfg ([#1276](https://github.com/rapidsai/dask-cuda/pull/1276)) [@vyasr](https://github.com/vyasr) +- Fix rapids dask dependency version ([#1275](https://github.com/rapidsai/dask-cuda/pull/1275)) [@vyasr](https://github.com/vyasr) + +## 🛠️ Improvements + +- Remove usages of rapids-env-update ([#1304](https://github.com/rapidsai/dask-cuda/pull/1304)) [@KyleFromNVIDIA](https://github.com/KyleFromNVIDIA) +- refactor CUDA versions in dependencies.yaml ([#1303](https://github.com/rapidsai/dask-cuda/pull/1303)) [@jameslamb](https://github.com/jameslamb) +- Start generating conda test environments ([#1291](https://github.com/rapidsai/dask-cuda/pull/1291)) [@charlesbluca](https://github.com/charlesbluca) +- Branch 24.02 merge branch 23.12 ([#1286](https://github.com/rapidsai/dask-cuda/pull/1286)) [@vyasr](https://github.com/vyasr) + # dask-cuda 23.12.00 (6 Dec 2023) ## 🐛 Bug Fixes diff --git a/VERSION b/VERSION index a193fff41..3c6c5e2b7 100644 --- a/VERSION +++ b/VERSION @@ -1 +1 @@ -23.12.00 +24.02.00 diff --git a/ci/build_docs.sh b/ci/build_docs.sh index a283ecc09..2abfce6bd 100755 --- a/ci/build_docs.sh +++ b/ci/build_docs.sh @@ -23,7 +23,7 @@ rapids-mamba-retry install \ --channel "${PYTHON_CHANNEL}" \ dask-cuda -export RAPIDS_VERSION_NUMBER="23.12" +export RAPIDS_VERSION_NUMBER="24.02" export RAPIDS_DOCS_DIR="$(mktemp -d)" rapids-logger "Build Python docs" diff --git a/ci/build_python.sh b/ci/build_python.sh index 23c806704..1883ccf72 100755 --- a/ci/build_python.sh +++ b/ci/build_python.sh @@ -3,7 +3,11 @@ set -euo pipefail -source rapids-env-update +rapids-configure-conda-channels + +source rapids-configure-sccache + +source rapids-date-string export CMAKE_GENERATOR=Ninja diff --git a/ci/build_python_pypi.sh b/ci/build_python_pypi.sh deleted file mode 100755 index e177acf87..000000000 --- a/ci/build_python_pypi.sh +++ /dev/null @@ -1,42 +0,0 @@ -#!/bin/bash - - -python -m pip install build --user - - -version=$(rapids-generate-version) -commit=$(git rev-parse HEAD) -# While conda provides these during conda-build, they are also necessary during -# the setup.py build for PyPI -export GIT_DESCRIBE_TAG=$(git describe --abbrev=0 --tags) -export GIT_DESCRIBE_NUMBER=$(git rev-list ${GIT_DESCRIBE_TAG}..HEAD --count) - -# Build date for PyPI pre-releases using version from `pyproject.toml` as source. -TOML_VERSION=$(grep "version = .*" pyproject.toml | grep -o '".*"' | sed 's/"//g') -if ! rapids-is-release-build; then - export PACKAGE_VERSION_NUMBER="${version}" -fi - -# For nightlies we want to ensure that we're pulling in alphas as well. The -# easiest way to do so is to augment the spec with a constraint containing a -# min alpha version that doesn't affect the version bounds but does allow usage -# of alpha versions for that dependency without --pre -alpha_spec='' -if ! rapids-is-release-build; then - alpha_spec=',>=0.0.0a0' -fi - -sed -r -i "s/rapids-dask-dependency==(.*)\"/rapids-dask-dependency==\1${alpha_spec}\"/g" pyproject.toml - -echo "${version}" | tr -d '"' > VERSION -sed -i "/^__git_commit__/ s/= .*/= \"${commit}\"/g" "dask_cuda/_version.py" - -# Compute/export RAPIDS_DATE_STRING -source rapids-env-update - - -python -m build \ - --sdist \ - --wheel \ - --outdir dist/ \ - . diff --git a/ci/build_wheel.sh b/ci/build_wheel.sh new file mode 100755 index 000000000..9ec826733 --- /dev/null +++ b/ci/build_wheel.sh @@ -0,0 +1,28 @@ +#!/bin/bash +# Copyright (c) 2023, NVIDIA CORPORATION. + +set -euo pipefail + +source rapids-configure-sccache +source rapids-date-string + +version=$(rapids-generate-version) +commit=$(git rev-parse HEAD) + +echo "${version}" | tr -d '"' > VERSION +sed -i "/^__git_commit__/ s/= .*/= \"${commit}\"/g" "dask_cuda/_version.py" + +# For nightlies we want to ensure that we're pulling in alphas as well. The +# easiest way to do so is to augment the spec with a constraint containing a +# min alpha version that doesn't affect the version bounds but does allow usage +# of alpha versions for that dependency without --pre +alpha_spec='' +if ! rapids-is-release-build; then + alpha_spec=',>=0.0.0a0' +fi + +sed -r -i "s/rapids-dask-dependency==(.*)\"/rapids-dask-dependency==\1${alpha_spec}\"/g" pyproject.toml + +python -m pip wheel . -w dist -vvv --no-deps --disable-pip-version-check + +RAPIDS_PY_WHEEL_NAME="dask-cuda" rapids-upload-wheels-to-s3 dist diff --git a/ci/release/update-version.sh b/ci/release/update-version.sh index e57e8b1e4..b2fc490f1 100755 --- a/ci/release/update-version.sh +++ b/ci/release/update-version.sh @@ -22,6 +22,7 @@ CURRENT_SHORT_TAG=${CURRENT_MAJOR}.${CURRENT_MINOR} NEXT_MAJOR=$(echo $NEXT_FULL_TAG | awk '{split($0, a, "."); print a[1]}') NEXT_MINOR=$(echo $NEXT_FULL_TAG | awk '{split($0, a, "."); print a[2]}') NEXT_SHORT_TAG=${NEXT_MAJOR}.${NEXT_MINOR} +NEXT_SHORT_TAG_PEP440=$(python -c "from setuptools.extern import packaging; print(packaging.version.Version('${NEXT_SHORT_TAG}'))") NEXT_UCXPY_VERSION="$(curl -s https://version.gpuci.io/rapids/${NEXT_SHORT_TAG})" echo "Preparing release $CURRENT_TAG => $NEXT_FULL_TAG" @@ -35,11 +36,12 @@ function sed_runner() { echo "${NEXT_FULL_TAG}" | tr -d '"' > VERSION # Bump cudf and dask-cudf testing dependencies -sed_runner "s/cudf=.*/cudf=${NEXT_SHORT_TAG}/g" dependencies.yaml -sed_runner "s/dask-cudf=.*/dask-cudf=${NEXT_SHORT_TAG}/g" dependencies.yaml -sed_runner "s/kvikio=.*/kvikio=${NEXT_SHORT_TAG}/g" dependencies.yaml -sed_runner "s/ucx-py=.*/ucx-py=${NEXT_UCXPY_VERSION}/g" dependencies.yaml -sed_runner "s/rapids-dask-dependency=.*/rapids-dask-dependency=${NEXT_SHORT_TAG}.*/g" dependencies.yaml +sed_runner "s/cudf==.*/cudf==${NEXT_SHORT_TAG_PEP440}.*/g" dependencies.yaml +sed_runner "s/dask-cudf==.*/dask-cudf==${NEXT_SHORT_TAG_PEP440}.*/g" dependencies.yaml +sed_runner "s/kvikio==.*/kvikio==${NEXT_SHORT_TAG_PEP440}.*/g" dependencies.yaml +sed_runner "s/ucx-py==.*/ucx-py==${NEXT_UCXPY_VERSION}.*/g" dependencies.yaml +sed_runner "s/ucxx==.*/ucxx==${NEXT_UCXPY_VERSION}.*/g" dependencies.yaml +sed_runner "s/rapids-dask-dependency==.*/rapids-dask-dependency==${NEXT_SHORT_TAG_PEP440}.*/g" dependencies.yaml # CI files for FILE in .github/workflows/*.yaml; do diff --git a/conda/environments/all_cuda-114_arch-x86_64.yaml b/conda/environments/all_cuda-114_arch-x86_64.yaml new file mode 100644 index 000000000..4b76616ab --- /dev/null +++ b/conda/environments/all_cuda-114_arch-x86_64.yaml @@ -0,0 +1,36 @@ +# This file is generated by `rapids-dependency-file-generator`. +# To make changes, edit ../../dependencies.yaml and run `rapids-dependency-file-generator`. +channels: +- rapidsai +- rapidsai-nightly +- dask/label/dev +- conda-forge +- nvidia +dependencies: +- click >=8.1 +- cuda-version=11.4 +- cudatoolkit +- cudf==24.2.* +- dask-cudf==24.2.* +- distributed-ucxx==0.36.* +- kvikio==24.2.* +- numactl-devel-cos7-x86_64 +- numba>=0.57 +- numpy>=1.21 +- numpydoc>=1.1.0 +- pandas>=1.3,<1.6.0.dev0 +- pre-commit +- pynvml>=11.0.0,<11.5 +- pytest +- pytest-cov +- python>=3.9,<3.11 +- rapids-dask-dependency==24.2.* +- setuptools>=64.0.0 +- sphinx +- sphinx-click>=2.7.1 +- sphinx-rtd-theme>=0.5.1 +- ucx-proc=*=gpu +- ucx-py==0.36.* +- ucxx==0.36.* +- zict>=2.0.0 +name: all_cuda-114_arch-x86_64 diff --git a/conda/environments/all_cuda-118_arch-x86_64.yaml b/conda/environments/all_cuda-118_arch-x86_64.yaml new file mode 100644 index 000000000..bb23025eb --- /dev/null +++ b/conda/environments/all_cuda-118_arch-x86_64.yaml @@ -0,0 +1,36 @@ +# This file is generated by `rapids-dependency-file-generator`. +# To make changes, edit ../../dependencies.yaml and run `rapids-dependency-file-generator`. +channels: +- rapidsai +- rapidsai-nightly +- dask/label/dev +- conda-forge +- nvidia +dependencies: +- click >=8.1 +- cuda-version=11.8 +- cudatoolkit +- cudf==24.2.* +- dask-cudf==24.2.* +- distributed-ucxx==0.36.* +- kvikio==24.2.* +- numactl-devel-cos7-x86_64 +- numba>=0.57 +- numpy>=1.21 +- numpydoc>=1.1.0 +- pandas>=1.3,<1.6.0.dev0 +- pre-commit +- pynvml>=11.0.0,<11.5 +- pytest +- pytest-cov +- python>=3.9,<3.11 +- rapids-dask-dependency==24.2.* +- setuptools>=64.0.0 +- sphinx +- sphinx-click>=2.7.1 +- sphinx-rtd-theme>=0.5.1 +- ucx-proc=*=gpu +- ucx-py==0.36.* +- ucxx==0.36.* +- zict>=2.0.0 +name: all_cuda-118_arch-x86_64 diff --git a/conda/environments/all_cuda-120_arch-x86_64.yaml b/conda/environments/all_cuda-120_arch-x86_64.yaml new file mode 100644 index 000000000..a0dec45da --- /dev/null +++ b/conda/environments/all_cuda-120_arch-x86_64.yaml @@ -0,0 +1,37 @@ +# This file is generated by `rapids-dependency-file-generator`. +# To make changes, edit ../../dependencies.yaml and run `rapids-dependency-file-generator`. +channels: +- rapidsai +- rapidsai-nightly +- dask/label/dev +- conda-forge +- nvidia +dependencies: +- click >=8.1 +- cuda-nvcc-impl +- cuda-nvrtc +- cuda-version=12.0 +- cudf==24.2.* +- dask-cudf==24.2.* +- distributed-ucxx==0.36.* +- kvikio==24.2.* +- numactl-devel-cos7-x86_64 +- numba>=0.57 +- numpy>=1.21 +- numpydoc>=1.1.0 +- pandas>=1.3,<1.6.0.dev0 +- pre-commit +- pynvml>=11.0.0,<11.5 +- pytest +- pytest-cov +- python>=3.9,<3.11 +- rapids-dask-dependency==24.2.* +- setuptools>=64.0.0 +- sphinx +- sphinx-click>=2.7.1 +- sphinx-rtd-theme>=0.5.1 +- ucx-proc=*=gpu +- ucx-py==0.36.* +- ucxx==0.36.* +- zict>=2.0.0 +name: all_cuda-120_arch-x86_64 diff --git a/dask_cuda/explicit_comms/dataframe/shuffle.py b/dask_cuda/explicit_comms/dataframe/shuffle.py index 854115fe0..ca69156dd 100644 --- a/dask_cuda/explicit_comms/dataframe/shuffle.py +++ b/dask_cuda/explicit_comms/dataframe/shuffle.py @@ -577,7 +577,7 @@ def wrapper(*args, **kwargs): kw = kw.arguments # Notice, we only overwrite the default and the "tasks" shuffle # algorithm. The "disk" and "p2p" algorithm, we don't touch. - if kw["shuffle"] in ("tasks", None): + if kw["shuffle_method"] in ("tasks", None): col = kw["col"] if isinstance(col, str): col = [col] diff --git a/dask_cuda/get_device_memory_objects.py b/dask_cuda/get_device_memory_objects.py index c5746c862..cd079f4ed 100644 --- a/dask_cuda/get_device_memory_objects.py +++ b/dask_cuda/get_device_memory_objects.py @@ -124,6 +124,10 @@ def get_device_memory_objects_cudf_index(obj): def get_device_memory_objects_cudf_multiindex(obj): return dispatch(obj._columns) + @dispatch.register(cudf.core.column.ColumnBase) + def get_device_memory_objects_cudf_column(obj): + return dispatch(obj.data) + dispatch(obj.children) + dispatch(obj.mask) + @sizeof.register_lazy("cupy") def register_cupy(): # NB: this overwrites dask.sizeof.register_cupy() diff --git a/dask_cuda/tests/test_dgx.py b/dask_cuda/tests/test_dgx.py index a7b79f327..d57cf1a3c 100644 --- a/dask_cuda/tests/test_dgx.py +++ b/dask_cuda/tests/test_dgx.py @@ -144,6 +144,10 @@ def _test_ucx_infiniband_nvlink( else: skip_queue.put("ok") + # `ucp.get_active_transports()` call above initializes UCX, we must reset it + # so that Dask doesn't try to initialize it again and raise an exception. + ucp.reset() + if enable_infiniband is None and enable_nvlink is None and enable_rdmacm is None: enable_tcp_over_ucx = None cm_tls = ["all"] diff --git a/dask_cuda/tests/test_explicit_comms.py b/dask_cuda/tests/test_explicit_comms.py index 21b35e481..ed34f21f8 100644 --- a/dask_cuda/tests/test_explicit_comms.py +++ b/dask_cuda/tests/test_explicit_comms.py @@ -1,6 +1,9 @@ import asyncio import multiprocessing as mp import os +import signal +import time +from functools import partial from unittest.mock import patch import numpy as np @@ -175,7 +178,7 @@ def test_dataframe_shuffle(backend, protocol, nworkers, _partitions): @pytest.mark.parametrize("in_cluster", [True, False]) -def test_dask_use_explicit_comms(in_cluster): +def _test_dask_use_explicit_comms(in_cluster): def check_shuffle(): """Check if shuffle use explicit-comms by search for keys named 'explicit-comms-shuffle' @@ -217,6 +220,31 @@ def check_shuffle(): check_shuffle() +@pytest.mark.parametrize("in_cluster", [True, False]) +def test_dask_use_explicit_comms(in_cluster): + def _timeout(process, function, timeout): + if process.is_alive(): + function() + timeout = time.time() + timeout + while process.is_alive() and time.time() < timeout: + time.sleep(0.1) + + p = mp.Process(target=_test_dask_use_explicit_comms, args=(in_cluster,)) + p.start() + + # Timeout before killing process + _timeout(p, lambda: None, 60.0) + + # Send SIGINT (i.e., KeyboardInterrupt) hoping we get a stack trace. + _timeout(p, partial(p._popen._send_signal, signal.SIGINT), 3.0) + + # SIGINT didn't work, kill process. + _timeout(p, p.kill, 3.0) + + assert not p.is_alive() + assert p.exitcode == 0 + + def _test_dataframe_shuffle_merge(backend, protocol, n_workers): if backend == "cudf": cudf = pytest.importorskip("cudf") diff --git a/dask_cuda/tests/test_proxify_host_file.py b/dask_cuda/tests/test_proxify_host_file.py index 191f62fe4..2683ea36d 100644 --- a/dask_cuda/tests/test_proxify_host_file.py +++ b/dask_cuda/tests/test_proxify_host_file.py @@ -302,13 +302,24 @@ def test_dataframes_share_dev_mem(root_dir): def test_cudf_get_device_memory_objects(): cudf = pytest.importorskip("cudf") objects = [ - cudf.DataFrame({"a": range(10), "b": range(10)}, index=reversed(range(10))), + cudf.DataFrame( + {"a": [0, 1, 2, 3, None, 5, 6, 7, 8, 9], "b": range(10)}, + index=reversed(range(10)), + ), cudf.MultiIndex( levels=[[1, 2], ["blue", "red"]], codes=[[0, 0, 1, 1], [1, 0, 1, 0]] ), ] res = get_device_memory_ids(objects) - assert len(res) == 4, "We expect four buffer objects" + # Buffers are: + # 1. int data for objects[0].a + # 2. mask data for objects[0].a + # 3. int data for objects[0].b + # 4. int data for objects[0].index + # 5. int data for objects[1].levels[0] + # 6. char data for objects[1].levels[1] + # 7. offset data for objects[1].levels[1] + assert len(res) == 7, "We expect seven buffer objects" def test_externals(root_dir): @@ -403,7 +414,7 @@ def is_proxy_object(x): ddf = dask.dataframe.from_pandas( cudf.DataFrame({"key": np.arange(10)}), npartitions=npartitions ) - res = ddf.shuffle(on="key", shuffle="tasks").persist() + res = ddf.shuffle(on="key", shuffle_method="tasks").persist() # With compatibility mode on, we shouldn't encounter any proxy objects if compatibility_mode: diff --git a/dependencies.yaml b/dependencies.yaml index 7b75d43db..eb7148615 100644 --- a/dependencies.yaml +++ b/dependencies.yaml @@ -1,10 +1,14 @@ # Dependency list for https://github.com/rapidsai/dependency-file-generator files: all: - output: none + output: conda + matrix: + cuda: ["11.4", "11.8", "12.0"] + arch: [x86_64] includes: - build_python - - cudatoolkit + - cuda + - cuda_version - develop - docs - py_version @@ -13,7 +17,8 @@ files: test_python: output: none includes: - - cudatoolkit + - cuda + - cuda_version - py_version - test_python checks: @@ -24,9 +29,40 @@ files: docs: output: none includes: - - cudatoolkit + - cuda + - cuda_version - docs - py_version + py_build: + output: pyproject + pyproject_dir: . + extras: + table: build-system + includes: + - build_python + py_run: + output: pyproject + pyproject_dir: . + extras: + table: project + includes: + - run_python + py_test: + output: pyproject + pyproject_dir: . + extras: + table: project.optional-dependencies + key: test + includes: + - test_python + py_docs: + output: pyproject + pyproject_dir: . + extras: + table: project.optional-dependencies + key: docs + includes: + - docs channels: - rapidsai - rapidsai-nightly @@ -36,37 +72,43 @@ channels: dependencies: build_python: common: - - output_types: [conda, requirements] + - output_types: [conda, requirements, pyproject] packages: - setuptools>=64.0.0 - cudatoolkit: + - output_types: pyproject + packages: + - tomli ; python_version < '3.11' + cuda_version: specific: - output_types: conda matrices: - - matrix: - cuda: "11.2" - packages: - - cuda-version=11.2 - - cudatoolkit - matrix: cuda: "11.4" packages: - cuda-version=11.4 - - cudatoolkit - matrix: cuda: "11.5" packages: - cuda-version=11.5 - - cudatoolkit - matrix: cuda: "11.8" packages: - cuda-version=11.8 - - cudatoolkit - matrix: cuda: "12.0" packages: - cuda-version=12.0 + cuda: + specific: + - output_types: conda + matrices: + - matrix: + cuda: "11.*" + packages: + - cudatoolkit + - matrix: + cuda: "12.*" + packages: - cuda-nvcc-impl - cuda-nvrtc develop: @@ -76,12 +118,12 @@ dependencies: - pre-commit docs: common: - - output_types: [conda, requirements] + - output_types: [conda, requirements, pyproject] packages: - - numpydoc + - numpydoc>=1.1.0 - sphinx - - sphinx-click - - sphinx_rtd_theme + - sphinx-click>=2.7.1 + - sphinx-rtd-theme>=0.5.1 py_version: specific: - output_types: conda @@ -99,27 +141,30 @@ dependencies: - python>=3.9,<3.11 run_python: common: - - output_types: [conda, requirements] + - output_types: [conda, requirements, pyproject] packages: + - click >=8.1 - numba>=0.57 - numpy>=1.21 - - pandas>=1.3,<1.6.0dev0 + - pandas>=1.3,<1.6.0.dev0 - pynvml>=11.0.0,<11.5 - - rapids-dask-dependency=23.12.* + - rapids-dask-dependency==24.2.* - zict>=2.0.0 test_python: common: - - output_types: [conda] + - output_types: [conda, requirements, pyproject] packages: - - cudf=23.12 - - dask-cudf=23.12 - - kvikio=23.12 + - cudf==24.2.* + - dask-cudf==24.2.* + - kvikio==24.2.* - pytest - pytest-cov + - ucx-py==0.36.* + - output_types: [conda] + packages: + - distributed-ucxx==0.36.* - ucx-proc=*=gpu - - ucx-py=0.35 - - ucxx=0.35 - - distributed-ucxx=0.35 + - ucxx==0.36.* specific: - output_types: conda matrices: diff --git a/pyproject.toml b/pyproject.toml index 4f0da0689..6668e3f93 100644 --- a/pyproject.toml +++ b/pyproject.toml @@ -2,8 +2,8 @@ build-backend = "setuptools.build_meta" requires = [ "setuptools>=64.0.0", - "tomli ; python_version < '3.11'", -] + "tomli ; python_version < '3.11'", +] # This list was generated by `rapids-dependency-file-generator`. To make changes, edit dependencies.yaml and run `rapids-dependency-file-generator`. [project] name = "dask-cuda" @@ -17,13 +17,13 @@ license = { text = "Apache-2.0" } requires-python = ">=3.9" dependencies = [ "click >=8.1", - "pynvml >=11.0.0,<11.5", - "numpy >=1.21", - "numba >=0.57", - "pandas >=1.3,<1.6.0.dev0", - "rapids-dask-dependency==23.12.*", - "zict >=2.0.0", -] + "numba>=0.57", + "numpy>=1.21", + "pandas>=1.3,<1.6.0.dev0", + "pynvml>=11.0.0,<11.5", + "rapids-dask-dependency==24.2.*", + "zict>=2.0.0", +] # This list was generated by `rapids-dependency-file-generator`. To make changes, edit dependencies.yaml and run `rapids-dependency-file-generator`. classifiers = [ "Intended Audience :: Developers", "Topic :: Database", @@ -47,10 +47,15 @@ docs = [ "sphinx", "sphinx-click>=2.7.1", "sphinx-rtd-theme>=0.5.1", -] +] # This list was generated by `rapids-dependency-file-generator`. To make changes, edit dependencies.yaml and run `rapids-dependency-file-generator`. test = [ + "cudf==24.2.*", + "dask-cudf==24.2.*", + "kvikio==24.2.*", "pytest", -] + "pytest-cov", + "ucx-py==0.36.*", +] # This list was generated by `rapids-dependency-file-generator`. To make changes, edit dependencies.yaml and run `rapids-dependency-file-generator`. [project.urls] Homepage = "https://github.com/rapidsai/dask-cuda"