[mt] Support feature selection.#11883
Conversation
There was a problem hiding this comment.
Pull request overview
This PR adds feature selection support to multi-target trees through column sampling and interaction constraints, along with optimization of the GPU histogram scan kernel. The implementation enables the use of colsample_bynode, colsample_bylevel, and colsample_bytree parameters for multi-target trees, and adds support for interaction constraints.
Key changes:
- Column sampling infrastructure for multi-target trees with weighted feature sampling
- Interaction constraint support via
FeatureInteractionConstraintDevice - Scan kernel optimization from block-based to warp-based processing for better GPU utilization
Reviewed changes
Copilot reviewed 15 out of 15 changed files in this pull request and generated 3 comments.
Show a summary per file
| File | Description |
|---|---|
tests/python-gpu/test_gpu_multi_target.py |
Added test for column sampling functionality |
tests/cpp/tree/gpu_hist/test_multi_evaluate_splits.cu |
Updated test with feature set initialization and pointer changes |
tests/cpp/common/test_random.cc |
Updated tests to use HostDeviceVector API for feature weights |
python-package/xgboost/testing/multi_target.py |
Implemented test helper for column sampling with feature weights |
src/tree/updater_gpu_hist.cuh |
Added column sampler and interaction constraints to multi-target histogram maker |
src/tree/updater_gpu_hist.cu |
Updated to pass column sampler to multi-target implementation |
src/tree/updater_colmaker.cc |
Updated column sampler initialization to use new API |
src/tree/split_evaluator.h |
Removed unused includes and enum, added documentation comments |
src/tree/hist/evaluate_splits.h |
Updated column sampler calls to use new API |
src/tree/gpu_hist/multi_evaluate_splits.cuh |
Changed scan buffer to use DeviceUVector for efficiency |
src/tree/gpu_hist/multi_evaluate_splits.cu |
Optimized scan and evaluation kernels from block-based to warp-based processing |
src/tree/gpu_hist/evaluate_splits.cuh |
Added feature_set and max_active_feature fields, changed pointers to raw pointers |
src/metric/elementwise_metric.cu |
Added NVTX profiling marker |
src/common/random.h |
Updated ColumnSampler::Init to accept HostDeviceVector for GPU compatibility |
src/common/device_helpers.cuh |
Added warp-level helper functions LaneId() and WarpThreads() |
💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.
There was a problem hiding this comment.
Pull request overview
Copilot reviewed 16 out of 16 changed files in this pull request and generated 4 comments.
💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.
|
cc @rongou |
Initmethod of the column sampler to avoid cross device copies.Feature constraint is not working yet. I will take a deeper look after handling other simpler parameters.
Ref #9043