Build pipeline for imbalanced classification
DRWMachine Learning Engineer · Online AssessmentLast updated
This interview question evaluates ML product requirements, data/labeling, modeling, serving architecture, evaluation, monitoring, and trade-offs in a realistic interview setting. A strong answer for Build pipeline for imbalanced classification states assumptions, handles edge cases, explains trade-offs, and shows how to validate the result clearly.
Question
Using scikit-learn and imbalanced-learn, build a classification pipeline that handles severe class imbalance, performs standard preprocessing, applies an appropriate resampling method, trains a classifier, and outputs precision, recall, and F1-score on a held-out set.
Solution walkthrough is for members
Get the full walkthrough with reference code and complexity analysis, plus Kitty Coach at 300 messages a day. Hints, the code runner and community answers stay free.