Skip to content

Commit

Permalink
Merge branch 'branch-24.12' into bug/device_ptrs_can_be_host_ptrs
Browse files Browse the repository at this point in the history
  • Loading branch information
robertmaynard authored Nov 4, 2024
2 parents 5bf3358 + a0186c7 commit d8637a5
Show file tree
Hide file tree
Showing 8 changed files with 38 additions and 7 deletions.
2 changes: 1 addition & 1 deletion .pre-commit-config.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -77,7 +77,7 @@ repos:
python/cuml/cuml/_thirdparty
- id: verify-alpha-spec
- repo: https://github.com/rapidsai/dependency-file-generator
rev: v1.13.11
rev: v1.16.0
hooks:
- id: rapids-dependency-file-generator
args: ["--clean"]
Expand Down
4 changes: 4 additions & 0 deletions ci/build_cpp.sh
Original file line number Diff line number Diff line change
Expand Up @@ -15,6 +15,10 @@ rapids-print-env

rapids-logger "Begin cpp build"

sccache --zero-stats

RAPIDS_PACKAGE_VERSION=$(rapids-generate-version) rapids-conda-retry mambabuild conda/recipes/libcuml

sccache --show-adv-stats

rapids-upload-conda-to-s3 cpp
8 changes: 8 additions & 0 deletions ci/build_python.sh
Original file line number Diff line number Diff line change
Expand Up @@ -19,20 +19,28 @@ rapids-logger "Begin py build"

CPP_CHANNEL=$(rapids-download-conda-from-s3 cpp)

sccache --zero-stats

# TODO: Remove `--no-test` flag once importing on a CPU
# node works correctly
RAPIDS_PACKAGE_VERSION=$(head -1 ./VERSION) rapids-conda-retry mambabuild \
--no-test \
--channel "${CPP_CHANNEL}" \
conda/recipes/cuml

sccache --show-adv-stats

# Build cuml-cpu only in CUDA 11 jobs since it only depends on python
# version
RAPIDS_CUDA_MAJOR="${RAPIDS_CUDA_VERSION%%.*}"
if [[ ${RAPIDS_CUDA_MAJOR} == "11" ]]; then
sccache --zero-stats

RAPIDS_PACKAGE_VERSION=$(head -1 ./VERSION) rapids-conda-retry mambabuild \
--no-test \
conda/recipes/cuml-cpu

sccache --show-adv-stats
fi

rapids-upload-conda-to-s3 python
8 changes: 6 additions & 2 deletions ci/build_wheel.sh
Original file line number Diff line number Diff line change
Expand Up @@ -40,14 +40,18 @@ case "${RAPIDS_CUDA_VERSION}" in
;;
esac

sccache --zero-stats

SKBUILD_CMAKE_ARGS="-DDETECT_CONDA_ENV=OFF;-DDISABLE_DEPRECATION_WARNINGS=ON;-DCPM_cumlprims_mg_SOURCE=${GITHUB_WORKSPACE}/cumlprims_mg/;-DUSE_CUVS_WHEEL=ON${EXTRA_CMAKE_ARGS}" \
python -m pip wheel . \
-w dist \
-vvv \
-v \
--no-deps \
--disable-pip-version-check

sccache --show-adv-stats

mkdir -p final_dist
python -m auditwheel repair -w final_dist "${EXCLUDE_ARGS[@]}" dist/*

RAPIDS_PY_WHEEL_NAME="cuml_${RAPIDS_PY_CUDA_SUFFIX}" rapids-upload-wheels-to-s3 final_dist
RAPIDS_PY_WHEEL_NAME="cuml_${RAPIDS_PY_CUDA_SUFFIX}" rapids-upload-wheels-to-s3 python final_dist
4 changes: 3 additions & 1 deletion cpp/CMakeLists.txt
Original file line number Diff line number Diff line change
Expand Up @@ -228,7 +228,9 @@ endif()
include(cmake/thirdparty/get_cccl.cmake)
include(cmake/thirdparty/get_rmm.cmake)
include(cmake/thirdparty/get_raft.cmake)
include(cmake/thirdparty/get_cuvs.cmake)
if(LINK_CUVS)
include(cmake/thirdparty/get_cuvs.cmake)
endif()

if(LINK_TREELITE)
include(cmake/thirdparty/get_treelite.cmake)
Expand Down
8 changes: 7 additions & 1 deletion cpp/cmake/modules/ConfigureAlgorithms.cmake
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
#=============================================================================
# Copyright (c) 2022-2023, NVIDIA CORPORATION.
# Copyright (c) 2022-2024, NVIDIA CORPORATION.
#
# Licensed under the Apache License, Version 2.0 (the "License");
# you may not use this file except in compliance with the License.
Expand All @@ -20,6 +20,7 @@ if(CUML_ALGORITHMS STREQUAL "ALL")
set(CUML_RAFT_COMPILED ON)
set(LINK_TREELITE ON)
set(LINK_CUFFT ON)
set(LINK_CUVS ON)
set(all_algo ON)
# setting treeshap to ON to get the gputreeshap include in the cuml_cpp_target
set(treeshap_algo ON)
Expand Down Expand Up @@ -122,5 +123,10 @@ else()
if(metrics_algo)
set(CUML_RAFT_COMPILED ON)
endif()

if(dbscan_algo OR hdbscan_algo OR kmeans_algo OR knn_algo
OR metrics_algo OR tsne_algo OR umap_algo)
set(LINK_CUVS ON)
endif()
endif()

7 changes: 7 additions & 0 deletions cpp/cmake/thirdparty/get_cuvs.cmake
Original file line number Diff line number Diff line change
Expand Up @@ -38,6 +38,11 @@ function(find_and_configure_cuvs)
set(CUVS_LIB cuvs::cuvs PARENT_SCOPE)
endif()

set(CUVS_BUILD_MG_ALGOS ON)
if(SINGLEGPU)
set(CUVS_BUILD_MG_ALGOS OFF)
endif()

rapids_cpm_find(cuvs ${PKG_VERSION}
GLOBAL_TARGETS cuvs::cuvs
BUILD_EXPORT_SET cuml-exports
Expand All @@ -50,6 +55,8 @@ function(find_and_configure_cuvs)
OPTIONS
"BUILD_TESTS OFF"
"BUILD_BENCH OFF"
"BUILD_MG_ALGOS ${CUVS_BUILD_MG_ALGOS}"

)

if(cuvs_ADDED)
Expand Down
4 changes: 2 additions & 2 deletions dependencies.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -66,14 +66,14 @@ files:
- py_version
- test_cuml
- test_notebooks
py_build:
py_build_cuml:
output: pyproject
pyproject_dir: python/cuml
extras:
table: build-system
includes:
- rapids_build_backend
py_rapids_build:
py_rapids_build_cuml:
output: pyproject
pyproject_dir: python/cuml
extras:
Expand Down

0 comments on commit d8637a5

Please sign in to comment.