Skip to content

Commit

Permalink
Sync with xgboost 2.0.3 (#50)
Browse files Browse the repository at this point in the history
* [backport][sklearn] Fix loading model attributes. (dmlc#9808) (dmlc#9880)

* [backport][py] Use the first found native library. (dmlc#9860) (dmlc#9879)

* [backport] [CI] Upload libxgboost4j.dylib (M1) to S3 bucket (dmlc#9887)

* [CI] Set up CI for Mac M1 (dmlc#9699)

* [CI] Improve CI for Mac M1 (dmlc#9748)

* [CI] Build libxgboost4j.dylib with CMAKE_OSX_DEPLOYMENT_TARGET (dmlc#9749)

* [CI] Upload libxgboost4j.dylib (M1) to S3 bucket (dmlc#9886)

* [jvm-packages] Fix POM for xgboost-jvm metapackage (dmlc#9893)

* [jvm-packages] Fix POM for xgboost-jvm metapackage

* Add script for updating the Scala version

* Bump version to 2.0.3 (dmlc#9895)

* Update change_scala_version.py to also change scala.version property (dmlc#9897)

* [backport] Fix compiling with the latest CTX. (dmlc#10263)

---------

Co-authored-by: Jiaming Yuan <[email protected]>
Co-authored-by: Philip Hyunsu Cho <[email protected]>
  • Loading branch information
3 people authored May 15, 2024
1 parent 51c74e6 commit 62ff851
Show file tree
Hide file tree
Showing 2 changed files with 5 additions and 5 deletions.
2 changes: 1 addition & 1 deletion src/common/quantile.cu
Original file line number Diff line number Diff line change
Expand Up @@ -181,7 +181,7 @@ common::Span<thrust::tuple<uint64_t, uint64_t>> MergePath(
merge_path.data(), [=] __device__(Tuple const &t) -> Tuple {
auto ind = get_ind(t); // == 0 if element is from x
// x_counter, y_counter
return thrust::make_tuple<uint64_t, uint64_t>(!ind, ind);
return thrust::make_tuple(static_cast<uint64_t>(!ind), static_cast<uint64_t>(ind));
});

// Compute the index for both x and y (which of the element in a and b are used in each
Expand Down
8 changes: 4 additions & 4 deletions src/data/ellpack_page.cu
Original file line number Diff line number Diff line change
Expand Up @@ -175,11 +175,11 @@ struct WriteCompressedEllpackFunctor {

using Tuple = thrust::tuple<size_t, size_t, size_t>;
__device__ size_t operator()(Tuple out) {
auto e = batch.GetElement(out.get<2>());
auto e = batch.GetElement(thrust::get<2>(out));
if (is_valid(e)) {
// -1 because the scan is inclusive
size_t output_position =
accessor.row_stride * e.row_idx + out.get<1>() - 1;
accessor.row_stride * e.row_idx + thrust::get<1>(out) - 1;
uint32_t bin_idx = 0;
if (common::IsCat(feature_types, e.column_idx)) {
bin_idx = accessor.SearchBin<true>(e.value, e.column_idx);
Expand All @@ -196,8 +196,8 @@ template <typename Tuple>
struct TupleScanOp {
__device__ Tuple operator()(Tuple a, Tuple b) {
// Key equal
if (a.template get<0>() == b.template get<0>()) {
b.template get<1>() += a.template get<1>();
if (thrust::get<0>(a) == thrust::get<0>(b)) {
thrust::get<1>(b) += thrust::get<1>(a);
return b;
}
// Not equal
Expand Down

0 comments on commit 62ff851

Please sign in to comment.