ml_fw: an ML toolkit for space-weather forecasting
Published:

ml_fw packages the workflow I use again and again when building forecasting models from solar-wind and geomagnetic data, so each new project starts from tested components rather than a blank notebook.
- Feature preparation: log transforms for wide-dynamic-range drivers, sin/cos encoding for periodic variables (local time, longitude), and time-lagged features.
- Training and tuning: a scikit-learn wrapper with (optionally subsampled) grid search and multi-metric parameter selection.
- Diagnostics: correlation profiling, binned and rolling error metrics, and plotting for residuals by driver or storm phase.
- Uncertainty: an ARIMA-residual perturbed-input ensemble that generates realistic noisy versions of the model inputs (figure above) to show how input uncertainty propagates to the forecast.

