Skip to main content

Module oof

Module oof 

Source
Expand description

Out-of-fold (OOF) prediction generation, used to fit calibration/NNLS. Fold splitting uses our own seeded shuffle (PyRandom) rather than sklearn’s KFold(shuffle=True), which draws from NumPy’s legacy RandomState — a related but distinct RNG family we haven’t ported (see the plan’s scoping note). Statistically equivalent, not bit-identical.

Structs§

KFoldSplit

Functions§

kfold_splits
A shuffled K-fold split of 0..n.
run_oof_classification
Runs the full n_estimators-member ensemble on each of num_folds folds (fold’s validation rows as query, the rest as context), assembling [member][original_train_row][class] un-shifted OOF logits (every training row appears in exactly one fold’s validation set).
run_oof_regression
Regression counterpart: [member][original_train_row] scaled OOF predictions.