How fh-prevail/ur2cute_torch works
UR2CUTE is a PyTorch library for intermittent-demand forecasting. A user fits its scikit-learn-style estimator on a time series, then predicts a multi-step horizon: shared temporal features feed separate occurrence and magnitude models, whose outputs are combined using a threshold. The README also documents rolling-origin backtesting, forecast components, and model persistence. Most runtime responsibilities are implemented in the single UR2CUTE/model.py module; relationships below follow README descriptions where source excerpts do not show the complete method flow.
Main entry points: model.py UR2CUTE estimator
Components 14
Estimator and evaluation
- UR2CUTE estimator
UR2CUTE/model.py - Rolling backtest
UR2CUTE/model.py - Demand metrics
UR2CUTE/model.py
Input preparation
- Input validation
UR2CUTE/model.py - Feature engineering
UR2CUTE/model.py - Windowing and split
UR2CUTE/model.py - Scaling transforms
UR2CUTE/model.py
Dual CNN models
- Occurrence CNN
UR2CUTE/model.py - Magnitude CNN
UR2CUTE/model.py
Forecast and persistence
- Threshold selection
UR2CUTE/model.py - Forecast output
UR2CUTE/model.py - Model persistence
UR2CUTE/model.py
Other components
- Analyst
- Serialized model
Connections 15
- Analyst → UR2CUTE estimator: fits or predicts
README.md - UR2CUTE estimator → Input validation: validates inputs
README.md - UR2CUTE estimator → Feature engineering: builds channels
README.md - Feature engineering → Windowing and split: forms windows
README.md - Windowing and split → Scaling transforms: scales partitions
README.md - UR2CUTE estimator → Occurrence CNN: trains and predicts
README.md - UR2CUTE estimator → Magnitude CNN: trains and predicts
README.md - Occurrence CNN → Threshold selection: supplies occurrence probability
README.md - Magnitude CNN → Forecast output: supplies quantity
README.md - Threshold selection → Forecast output: gates quantity
README.md - UR2CUTE estimator → Rolling backtest: runs rolling origins
README.md - Rolling backtest → Demand metrics: summarizes errors
README.md - UR2CUTE estimator → Model persistence: saves or loads
README.md - Model persistence → Serialized model: serializes parameters
README.md - Forecast output → Analyst: returns forecasts
README.md