Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Upgrade Treelite to 3.0.0 #4885

Merged
merged 7 commits into from
Sep 22, 2022
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Jump to
Jump to file
Failed to load files.
Diff view
Diff view
2 changes: 1 addition & 1 deletion conda/environments/cuml_dev_cuda11.0.yml
Original file line number Diff line number Diff line change
Expand Up @@ -30,7 +30,7 @@ dependencies:
- umap-learn
- scikit-learn=0.24
- sphinx-markdown-tables
- treelite=2.4.0
- treelite=3.0.0
- statsmodels
- seaborn
- hdbscan
Expand Down
2 changes: 1 addition & 1 deletion conda/environments/cuml_dev_cuda11.2.yml
Original file line number Diff line number Diff line change
Expand Up @@ -30,7 +30,7 @@ dependencies:
- umap-learn
- scikit-learn=0.24
- sphinx-markdown-tables
- treelite=2.4.0
- treelite=3.0.0
- statsmodels
- seaborn
- hdbscan
Expand Down
2 changes: 1 addition & 1 deletion conda/environments/cuml_dev_cuda11.4.yml
Original file line number Diff line number Diff line change
Expand Up @@ -30,7 +30,7 @@ dependencies:
- umap-learn
- scikit-learn=0.24
- sphinx-markdown-tables
- treelite=2.4.0
- treelite=3.0.0
- statsmodels
- seaborn
- hdbscan
Expand Down
2 changes: 1 addition & 1 deletion conda/environments/cuml_dev_cuda11.5.yml
Original file line number Diff line number Diff line change
Expand Up @@ -30,7 +30,7 @@ dependencies:
- umap-learn
- scikit-learn=0.24
- sphinx-markdown-tables
- treelite=2.4.0
- treelite=3.0.0
- statsmodels
- seaborn
- hdbscan
Expand Down
4 changes: 2 additions & 2 deletions conda/recipes/cuml/meta.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -36,7 +36,7 @@ requirements:
- setuptools
- scikit-build>=0.13.1
- cython>=0.29,<0.30
- treelite=2.4.0
- treelite=3.0.0
- cudf {{ minor_version }}
- libcuml={{ version }}
- libcumlprims {{ minor_version }}
Expand All @@ -53,7 +53,7 @@ requirements:
- libcumlprims {{ minor_version }}
- pyraft {{ minor_version }}
- cupy>=7.8.0,<12.0.0a0
- treelite=2.4.0
- treelite=3.0.0
- nccl>=2.9.9
- ucx-py {{ ucx_py_version }}
- ucx-proc=*=gpu
Expand Down
2 changes: 1 addition & 1 deletion conda/recipes/libcuml/conda_build_config.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -20,7 +20,7 @@ ucx_version:
- "1.13.0"

treelite_version:
- "2.4.0"
- "3.0.0"

gtest_version:
- "1.10.0"
Expand Down
4 changes: 2 additions & 2 deletions cpp/cmake/thirdparty/get_treelite.cmake
Original file line number Diff line number Diff line change
Expand Up @@ -88,6 +88,6 @@ function(find_and_configure_treelite)
rapids_export_find_package_root(BUILD Treelite [=[${CMAKE_CURRENT_LIST_DIR}]=] cuml-exports)
endfunction()

find_and_configure_treelite(VERSION 2.4.0
PINNED_TAG dcd54779ce9324c69452db9b906f2d258374d5b9
find_and_configure_treelite(VERSION 3.0.0
PINNED_TAG a8e688b7f0486227fe723229e4cbb77e3a669148
BUILD_STATIC_LIBS ${CUML_USE_TREELITE_STATIC})
2 changes: 1 addition & 1 deletion cpp/src/decisiontree/decisiontree.cuh
Original file line number Diff line number Diff line change
Expand Up @@ -41,7 +41,7 @@

/** check for treelite runtime API errors and assert accordingly */

#define TREELITE_CHECK(call) \
#define TREELITE_CHECK_RET(call) \
do { \
int status = call; \
ASSERT(status >= 0, "TREELITE FAIL: call='%s'. Reason:%s\n", #call, TreeliteGetLastError()); \
Expand Down
4 changes: 2 additions & 2 deletions cpp/src/randomforest/randomforest.cu
Original file line number Diff line number Diff line change
Expand Up @@ -341,11 +341,11 @@ void compare_concat_forest_to_subforests(ModelHandle concat_tree_handle,
size_t total_num_trees = 0;
for (std::size_t forest_idx = 0; forest_idx < treelite_handles.size(); forest_idx++) {
size_t num_trees_each_forest;
TREELITE_CHECK(TreeliteQueryNumTree(treelite_handles[forest_idx], &num_trees_each_forest));
TREELITE_CHECK_RET(TreeliteQueryNumTree(treelite_handles[forest_idx], &num_trees_each_forest));
total_num_trees = total_num_trees + num_trees_each_forest;
}

TREELITE_CHECK(TreeliteQueryNumTree(concat_tree_handle, &concat_forest));
TREELITE_CHECK_RET(TreeliteQueryNumTree(concat_tree_handle, &concat_forest));

ASSERT(concat_forest == total_num_trees,
"Error! the number of trees in the concatenated forest and the sum "
Expand Down