sklears-ensemble
Latest release:
0.2.0(July 14, 2026). See the workspace release notes for highlights and upgrade guidance.
Overview
sklears-ensemble delivers bagging, gradient boosting, AdaBoost, stacking, and voting implementations with scikit-learn parity and Rust-first performance. (Tree-based ensembles such as RandomForest live in the separate sklears-tree crate.)
Key Features
- Ensemble Methods: Bagging, AdaBoost, Gradient Boosting (binary classification + regression), single- and multi-layer Stacking, Voting classifiers. (
sklears-tree's RandomForest/ExtraTrees are a separate crate — this crate does not re-export them, and there is no IsolationForest or histogram-based boosting here;GradientBoostingConfig::tree_typecurrently accepts aHistogramTreevariant but it has no effect on training.) - Model Selection & Analysis: Bias-variance decomposition, ensemble diversity metrics, and cross-validation via the
model_selectionmodule (BiasVarianceAnalyzer,DiversityAnalyzer,EnsembleCrossValidator). - GPU Acceleration (optional
gpufeature, CUDA viaoxicuda-*): real device detection, memory management, and GEMM/elementwise tensor ops (GpuTensorOps) backing ensemble prediction; default builds stay 100% Pure Rust CPU. There is no GPU-side split-finding/histogram/tree-update training path — those kernels were removed in the 0.2.0 release because they only ever returnedNotImplemented. - CPU Optimization: Cache-optimized matrix ops, vectorized ensemble scoring, and SIMD kernels via
scirs2_core::simd_ops.
Quick Start
use GradientBoostingClassifier;
use ;
let x = array!;
let y = from;
let gbc = builder
.n_estimators
.learning_rate
.max_depth
.random_state
.build;
let fitted = gbc.fit?;
let predictions = fitted.predict?;
Status
- Validated by 291 passing crate tests for
0.2.0(1 skipped). - Benchmarks demonstrate 5–30× faster training versus scikit-learn on medium to large datasets.
- Roadmap items (GPU-side gradient-boosting training kernels, federated ensembles) live in this crate’s
TODO.md.