-
Notifications
You must be signed in to change notification settings - Fork 540
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
This PR enables building wheels of cuml. I don't expect tests to pass here until the raft wheels PR is merged, but it should be ready for reviews and hopefully CI will provide some useful feedback in the interim. Authors: - Vyas Ramasubramani (https://github.com/vyasr) - Sevag H (https://github.com/sevagh) - Paul Taylor (https://github.com/trxcllnt) Approvers: - Joseph (https://github.com/jolorunyomi) - Dante Gama Dessavre (https://github.com/dantegd) URL: #5009
- Loading branch information
Showing
26 changed files
with
431 additions
and
239 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,62 @@ | ||
name: cuML wheels | ||
|
||
on: | ||
workflow_call: | ||
inputs: | ||
versioneer-override: | ||
type: string | ||
default: '' | ||
build-tag: | ||
type: string | ||
default: '' | ||
branch: | ||
required: true | ||
type: string | ||
date: | ||
required: true | ||
type: string | ||
sha: | ||
required: true | ||
type: string | ||
build-type: | ||
type: string | ||
default: nightly | ||
|
||
concurrency: | ||
group: "cuml-${{ github.workflow }}-${{ github.ref }}" | ||
cancel-in-progress: true | ||
|
||
jobs: | ||
cuml-wheel: | ||
uses: rapidsai/shared-action-workflows/.github/workflows/wheels-manylinux.yml@main | ||
with: | ||
repo: rapidsai/cuml | ||
|
||
build-type: ${{ inputs.build-type }} | ||
branch: ${{ inputs.branch }} | ||
sha: ${{ inputs.sha }} | ||
date: ${{ inputs.date }} | ||
|
||
package-dir: python | ||
package-name: cuml | ||
|
||
# Note that this approach to cloning repos obviates any modification to | ||
# the CMake variables in get_cumlprims_mg.cmake since CMake will just use | ||
# the clone as is. | ||
extra-repo: rapidsai/cumlprims_mg | ||
extra-repo-sha: branch-22.12 | ||
extra-repo-deploy-key: CUMLPRIMS_SSH_PRIVATE_DEPLOY_KEY | ||
|
||
python-package-versioneer-override: ${{ inputs.versioneer-override }} | ||
python-package-build-tag: ${{ inputs.build-tag }} | ||
|
||
skbuild-configure-options: "-DCUML_BUILD_WHEELS=ON -DDETECT_CONDA_ENV=OFF -DCPM_cumlprims_mg_SOURCE=/project/cumlprims_mg/" | ||
|
||
# Always want to test against latest dask/distributed. | ||
test-before-amd64: "pip install git+https://github.com/dask/dask.git@main git+https://github.com/dask/distributed.git@main git+https://github.com/rapidsai/[email protected]" | ||
# On arm also need to install cupy from the specific webpage and CMake | ||
# because treelite needs to be compiled (no wheels available for arm). | ||
test-before-arm64: "pip install cupy-cuda11x -f https://pip.cupy.dev/aarch64 && pip install cmake && pip install git+https://github.com/dask/dask.git@main git+https://github.com/dask/distributed.git@main git+https://github.com/rapidsai/[email protected]" | ||
test-extras: test | ||
test-unittest: "pytest -v ./python/cuml/tests -k 'not test_silhouette_score_batched'" | ||
secrets: inherit |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -19,21 +19,35 @@ set(CUML_BRANCH_VERSION_cumlprims_mg "${CUML_VERSION_MAJOR}.${CUML_VERSION_MINOR | |
|
||
function(find_and_configure_cumlprims_mg) | ||
|
||
set(oneValueArgs VERSION FORK PINNED_TAG CLONE_ON_PIN) | ||
set(oneValueArgs VERSION FORK PINNED_TAG BUILD_STATIC EXCLUDE_FROM_ALL CLONE_ON_PIN) | ||
cmake_parse_arguments(PKG "" "${oneValueArgs}" "" ${ARGN} ) | ||
|
||
if(PKG_CLONE_ON_PIN AND NOT PKG_PINNED_TAG STREQUAL "branch-${CUML_BRANCH_VERSION_cumlprims_mg}") | ||
message("Pinned tag found: ${PKG_PINNED_TAG}. Cloning cumlprims locally.") | ||
set(CPM_DOWNLOAD_cumlprims_mg ON) | ||
elseif(PKG_BUILD_STATIC AND (NOT CPM_cumlprims_mg_SOURCE)) | ||
message(STATUS "CUML: Cloning cumlprims_mg locally to build static libraries.") | ||
set(CPM_DOWNLOAD_cumlprims_mg ON) | ||
endif() | ||
|
||
set(CUMLPRIMS_MG_BUILD_SHARED_LIBS ON) | ||
if(PKG_BUILD_STATIC) | ||
set(CUMLPRIMS_MG_BUILD_SHARED_LIBS OFF) | ||
endif() | ||
|
||
rapids_cpm_find(cumlprims_mg ${PKG_VERSION} | ||
GLOBAL_TARGETS cumlprims_mg::cumlprims_mg | ||
BUILD_EXPORT_SET cuml-exports | ||
INSTALL_EXPORT_SET cuml-exports | ||
CPM_ARGS | ||
GIT_REPOSITORY [email protected]:${PKG_FORK}/cumlprims_mg.git | ||
GIT_TAG ${PKG_PINNED_TAG} | ||
GIT_REPOSITORY [email protected]:${PKG_FORK}/cumlprims_mg.git | ||
GIT_TAG ${PKG_PINNED_TAG} | ||
EXCLUDE_FROM_ALL ${PKG_EXCLUDE_FROM_ALL} | ||
SOURCE_SUBDIR cpp | ||
OPTIONS | ||
"BUILD_TESTS OFF" | ||
"BUILD_BENCHMARKS OFF" | ||
"BUILD_SHARED_LIBS ${CUMLPRIMS_MG_BUILD_SHARED_LIBS}" | ||
) | ||
|
||
endfunction() | ||
|
@@ -48,9 +62,11 @@ endfunction() | |
# cumlprims_mg as part of building cuml itself, set the CMake variable | ||
# `-D CPM_cumlprims_mg_SOURCE=/path/to/cumlprims_mg` | ||
### | ||
find_and_configure_cumlprims_mg(VERSION ${CUML_MIN_VERSION_cumlprims_mg} | ||
find_and_configure_cumlprims_mg(VERSION ${CUML_MIN_VERSION_cumlprims_mg} | ||
FORK rapidsai | ||
PINNED_TAG branch-${CUML_BRANCH_VERSION_cumlprims_mg} | ||
BUILD_STATIC ${CUML_USE_CUMLPRIMS_MG_STATIC} | ||
EXCLUDE_FROM_ALL ${CUML_EXCLUDE_CUMLPRIMS_MG_FROM_ALL} | ||
# When PINNED_TAG above doesn't match cuml, | ||
# force local cumlprims_mg clone in build directory | ||
# even if it's already installed. | ||
|
Oops, something went wrong.