Repository navigation
v0.2.4
·
40 commits
to main
since this release
Immutable
release. Only release title and notes can be modified.
hessboost v0.2.4
Patch release: single-row prediction that never enters rayon, public read-only model metadata, cross-validation continuation and refit, EBM eval sets with round-level early stopping, and a Python extension pool that survives fork. No breaking changes.
Full Changelog: v0.2.3...v0.2.4
Highlights Since v0.2.3
Prediction
- Prediction transforms are scalar on every platform again, so
predictis bit for bit the transform ofpredict_margin— a row predicted alone matches the same row inside a batch. - New Rust row API:
predict_row,predict_row_into, their margin forms,transform_margin/transform_margins_into, andpredict_rowsover borrowed rows. All matchpredicton aDMatrixbit for bit, allocate nothing, and never enter rayon — so a forked Python child still predicts rows. - Read-only model metadata:
BoostedModel::tree_weights(),num_class(),linear(),shrinkage(), andRegTree::split_categories(nid).
Training
CrossValidation::init_modelcontinues a model in every fold;target_stats_labelsets the per-row target per-fold target statistics are fitted on;refit()returns aCvRefitretrained on every row at the chosen round.- EBM eval sets and early stopping: a classic EBM now stores its trees round by round, so each round's eval score is bit for bit the model through that round; early stopping cuts the model back to the best round. Multi-bag EBM predictions can differ from 0.2.3's at
f32rounding level. linear_treenow trains withreg:absoluteerrorandreg:quantileerror.
Data
DMatrixclones share feature storage throughArc(copy-on-write), dense input is checked and copied in parallel, andfrom_dense_vecis public.from_dense1M × 100 is about 2× faster; a clone with new labels about 48×.
Python bindings
- The extension runs rayon work on its own process-local pool, rebuilt in a forked child — the child of a process that already trained no longer hangs.
Booster.predict_row(row, *, output_margin=False, iteration_range=None, missing=nan, out=None)andBooster.transform_margin/transform_margins(margins, *, out=None);predicton a plain 2-D numeric numpy array reads it in place instead of building aDMatrix.Booster.model_info()returns frozen dataclasses with the model's layout, tree weights, node arrays,gblinearand shrinkage records.cv(..., target_stats_label=, xgb_model=, refit=True)returns a frozenCvRefit;FittedTargetEncodergainsto_bytes/from_bytes/save/loadand pickle support.- EBM
train(evals=..., early_stopping_rounds=...)andcvwork end to end.
Pull Requests by Category
Features
- feat: single-row prediction, model metadata, cv refit, EBM early stopping, fork-safe Python pool (#150)
Bug Fixes
- fix(python): run a callback's hooked call inline on the pool thread (#151)
- fix(python): admit online updates before scheduling their work (#152)