Skip to content

Commit

Permalink
Merge branch 'branch-24.12' into bug/fix-rmm-imports
Browse files Browse the repository at this point in the history
  • Loading branch information
Matt711 authored Oct 4, 2024
2 parents d755c8e + 82483ac commit 9dfad42
Show file tree
Hide file tree
Showing 16 changed files with 178 additions and 413 deletions.
55 changes: 49 additions & 6 deletions .github/workflows/pr.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -12,6 +12,7 @@ concurrency:
jobs:
pr-builder:
needs:
- changed-files
- checks
- clang-tidy
- conda-cpp-build
Expand All @@ -27,6 +28,42 @@ jobs:
- devcontainer
secrets: inherit
uses: rapidsai/shared-workflows/.github/workflows/[email protected]
if: always()
with:
needs: ${{ toJSON(needs) }}
changed-files:
secrets: inherit
uses: rapidsai/shared-workflows/.github/workflows/[email protected]
with:
files_yaml: |
test_cpp:
- '**'
- '!.devcontainer/**'
- '!.pre-commit-config.yaml'
- '!CONTRIBUTING.md'
- '!README.md'
- '!docs/**'
- '!img/**'
- '!notebooks/**'
- '!python/**'
- '!thirdparty/LICENSES/**'
test_notebooks:
- '**'
- '!.devcontainer/**'
- '!.pre-commit-config.yaml'
- '!CONTRIBUTING.md'
- '!README.md'
- '!thirdparty/LICENSES/**'
test_python:
- '**'
- '!.devcontainer/**'
- '!.pre-commit-config.yaml'
- '!CONTRIBUTING.md'
- '!README.md'
- '!docs/**'
- '!img/**'
- '!notebooks/**'
- '!thirdparty/LICENSES/**'
checks:
secrets: inherit
uses: rapidsai/shared-workflows/.github/workflows/[email protected]
Expand All @@ -51,9 +88,10 @@ jobs:
with:
build_type: pull-request
conda-cpp-tests:
needs: conda-cpp-build
needs: [conda-cpp-build, changed-files]
secrets: inherit
uses: rapidsai/shared-workflows/.github/workflows/[email protected]
if: fromJSON(needs.changed-files.outputs.changed_file_groups).test_cpp
with:
build_type: pull-request
conda-cpp-checks:
Expand All @@ -71,31 +109,35 @@ jobs:
with:
build_type: pull-request
conda-python-tests-singlegpu:
needs: conda-python-build
needs: [conda-python-build, changed-files]
secrets: inherit
uses: rapidsai/shared-workflows/.github/workflows/[email protected]
if: fromJSON(needs.changed-files.outputs.changed_file_groups).test_python
with:
build_type: pull-request
script: "ci/test_python_singlegpu.sh"
optional-job-conda-python-tests-cudf-pandas-integration:
needs: conda-python-build
needs: [conda-python-build, changed-files]
secrets: inherit
uses: rapidsai/shared-workflows/.github/workflows/[email protected]
if: fromJSON(needs.changed-files.outputs.changed_file_groups).test_python
with:
matrix_filter: map(select(.ARCH == "amd64"))
build_type: pull-request
script: "ci/test_python_integration.sh"
conda-python-tests-dask:
needs: conda-python-build
needs: [conda-python-build, changed-files]
secrets: inherit
uses: rapidsai/shared-workflows/.github/workflows/[email protected]
if: fromJSON(needs.changed-files.outputs.changed_file_groups).test_python
with:
build_type: pull-request
script: "ci/test_python_dask.sh"
conda-notebook-tests:
needs: conda-python-build
needs: [conda-python-build, changed-files]
secrets: inherit
uses: rapidsai/shared-workflows/.github/workflows/[email protected]
if: fromJSON(needs.changed-files.outputs.changed_file_groups).test_notebooks
with:
build_type: pull-request
node_type: "gpu-v100-latest-1"
Expand Down Expand Up @@ -123,9 +165,10 @@ jobs:
extra-repo-sha: branch-24.12
extra-repo-deploy-key: CUMLPRIMS_SSH_PRIVATE_DEPLOY_KEY
wheel-tests-cuml:
needs: wheel-build-cuml
needs: [wheel-build-cuml, changed-files]
secrets: inherit
uses: rapidsai/shared-workflows/.github/workflows/[email protected]
if: fromJSON(needs.changed-files.outputs.changed_file_groups).test_python
with:
build_type: pull-request
script: ci/test_wheel.sh
Expand Down
3 changes: 0 additions & 3 deletions conda/environments/all_cuda-118_arch-x86_64.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -50,7 +50,6 @@ dependencies:
- numpydoc
- nvcc_linux-64=11.8
- packaging
- pip
- pydata-sphinx-theme!=0.14.2
- pylibraft==24.12.*,>=0.0.0a0
- pynndescent
Expand Down Expand Up @@ -78,6 +77,4 @@ dependencies:
- sysroot_linux-64==2.17
- treelite==4.3.0
- umap-learn==0.5.6
- pip:
- dask-glm==0.3.0
name: all_cuda-118_arch-x86_64
3 changes: 0 additions & 3 deletions conda/environments/all_cuda-125_arch-x86_64.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -46,7 +46,6 @@ dependencies:
- numpy>=1.23,<3.0a0
- numpydoc
- packaging
- pip
- pydata-sphinx-theme!=0.14.2
- pylibraft==24.12.*,>=0.0.0a0
- pynndescent
Expand Down Expand Up @@ -74,6 +73,4 @@ dependencies:
- sysroot_linux-64==2.17
- treelite==4.3.0
- umap-learn==0.5.6
- pip:
- dask-glm==0.3.0
name: all_cuda-125_arch-x86_64
2 changes: 1 addition & 1 deletion conda/recipes/cuml-cpu/meta.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -45,5 +45,5 @@ tests: # [linux64]
about:
home: https://rapids.ai/
license: Apache-2.0
# license_file: LICENSE
license_file: LICENSE
summary: cuML-CPU library
2 changes: 1 addition & 1 deletion conda/recipes/cuml/meta.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -101,5 +101,5 @@ tests:
about:
home: https://rapids.ai/
license: Apache-2.0
# license_file: LICENSE
license_file: LICENSE
summary: cuML library
2 changes: 2 additions & 0 deletions conda/recipes/libcuml/meta.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -122,6 +122,7 @@ outputs:
about:
home: https://rapids.ai/
license: Apache-2.0
license_file: LICENSE
summary: libcuml library
- name: libcuml-tests
version: {{ version }}
Expand Down Expand Up @@ -155,4 +156,5 @@ outputs:
about:
home: https://rapids.ai/
license: Apache-2.0
license_file: LICENSE
summary: libcuml test & benchmark executables
10 changes: 10 additions & 0 deletions cpp/src/glm/qn/mg/standardization.cuh
Original file line number Diff line number Diff line change
Expand Up @@ -162,6 +162,16 @@ void mean_stddev(const raft::handle_t& handle,
{
auto stream = handle.get_stream();
int D = X.n;

if (X.nnz == 0) {
SimpleVec<T> meanVec(mean_vector, D);
meanVec.fill(0., stream);

SimpleVec<T> stddevVec(stddev_vector, D);
stddevVec.fill(0., stream);
return;
}

mean(handle, X, n_samples, mean_vector);

// calculate stdev.S
Expand Down
8 changes: 0 additions & 8 deletions dependencies.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -518,14 +518,6 @@ dependencies:
- umap-learn==0.5.6
- pynndescent
- setuptools # Needed on Python 3.12 for dask-glm, which requires pkg_resources but Python 3.12 doesn't have setuptools by default
- output_types: conda
packages:
- pip
- pip:
- dask-glm==0.3.0
- output_types: pyproject
packages:
- dask-glm==0.3.0
test_notebooks:
common:
- output_types: [conda, requirements]
Expand Down
11 changes: 9 additions & 2 deletions python/cuml/cuml/cluster/kmeans.pyx
Original file line number Diff line number Diff line change
Expand Up @@ -20,6 +20,7 @@ from cuml.internals.safe_imports import cpu_only_import
np = cpu_only_import('numpy')
from cuml.internals.safe_imports import gpu_only_import
rmm = gpu_only_import('rmm')
from cuml.internals.safe_imports import safe_import_from, return_false
import typing

IF GPUBUILD == 1:
Expand All @@ -46,7 +47,10 @@ from cuml.common import input_to_cuml_array
from cuml.internals.api_decorators import device_interop_preparation
from cuml.internals.api_decorators import enable_device_interop

from sklearn.utils._openmp_helpers import _openmp_effective_n_threads
# from sklearn.utils._openmp_helpers import _openmp_effective_n_threads
_openmp_effective_n_threads = safe_import_from(
"sklearn.utils._openmp_helpers", "_openmp_effective_n_threads", alt=return_false
)


class KMeans(UniversalBase,
Expand Down Expand Up @@ -235,7 +239,10 @@ class KMeans(UniversalBase,
self.cluster_centers_ = None

# For sklearn interoperability
self._n_threads = _openmp_effective_n_threads()
if _openmp_effective_n_threads():
self._n_threads = _openmp_effective_n_threads()
else:
self._n_threads = 1

# cuPy does not allow comparing with string. See issue #2372
init_str = init if isinstance(init, str) else None
Expand Down
Empty file.
27 changes: 0 additions & 27 deletions python/cuml/cuml/dask/extended/linear_model/__init__.py

This file was deleted.

Loading

0 comments on commit 9dfad42

Please sign in to comment.