Handle rare events with resampling (undersample, oversample, SMOTE), class weighting, focal loss, and threshold tuning. Inspect PR/ROC curves and the confusion matrix.
| Pred 0 | Pred 1 | |
|---|---|---|
| Actual 0 | — | — |
| Actual 1 | — | — |
Every coffee helps keep the servers running. Every book sale funds the next tool I'm dreaming up. You're not just supporting a site — you're helping me build what developers actually need.
This workshop explores class imbalance strategies: resampling (undersample/oversample), class weights, and threshold tuning. It visualizes confusion matrices, ROC/PR curves, and metrics sensitive to imbalance (F1, MCC).