Skip to content

Conversation

trivialfis
Copy link
Member

@trivialfis trivialfis commented Oct 15, 2025

  • Support leaf, QDM, inplace prediction for multi-target.
  • Replace device model with tree-internal storage.
  • Cleanup predict kernel.

@trivialfis trivialfis requested a review from Copilot October 15, 2025 10:08
Copy link
Contributor

@Copilot Copilot AI left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Pull Request Overview

This PR replaces the previous GPU device model with tree-internal storage and updates predictors to support leaf and multi-target predictions, alongside cleanup in prediction kernels.

  • Replace uses of GetNodes().size() with Size() across code/tests.
  • Introduce device-side tree views stored as cuda::std::variant and refactor GPU predictor kernels to consume them.
  • Add device qualifiers and APIs in tree view for categorical splits; rework SHAP path extraction to use tree views.

Reviewed Changes

Copilot reviewed 5 out of 5 changed files in this pull request and generated 3 comments.

Show a summary per file
File Description
tests/cpp/tree/test_tree_model.cc Update test to use RegTree::Size() API.
src/tree/tree_view.h Return categories matrix by const reference; add device qualifiers; minor doc update.
src/tree/hist/evaluate_splits.h Use RegTree::Size() for snode_ sizing.
src/predictor/gpu_predictor.cu Major refactor: remove per-kernel MakeScalarTreeView; use device-resident variant of tree views; unify prediction kernels; add SHAP path extraction based on tree views.
src/predictor/cpu_predictor.cc Use RegTree::Size() for tree_sizes_.

Tip: Customize your code reviews with copilot-instructions.md. Create the file or learn how to get started.

@trivialfis trivialfis changed the title [WIP] Replace device model Replace the device model. Oct 15, 2025
@trivialfis trivialfis marked this pull request as ready for review October 15, 2025 21:06
@trivialfis
Copy link
Member Author

cc @rongou

@trivialfis trivialfis requested a review from Copilot October 15, 2025 21:26
Copy link
Contributor

@Copilot Copilot AI left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Pull Request Overview

Copilot reviewed 14 out of 14 changed files in this pull request and generated 6 comments.


Tip: Customize your code reviews with copilot-instructions.md. Create the file or learn how to get started.

@trivialfis trivialfis merged commit 425d136 into dmlc:master Oct 16, 2025
73 of 87 checks passed
@trivialfis trivialfis deleted the replace-device-model branch October 16, 2025 09:21
@trivialfis trivialfis mentioned this pull request Oct 16, 2025
41 tasks
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants