InterviewStack.io LogoInterviewStack.io

Model Selection, Tuning, and Generalization Questions

Choosing and tuning models so they generalize to unseen data rather than memorizing the training set. Covers the bias-variance tradeoff and its decomposition, diagnosing over- and under-fitting from learning curves, and regularization techniques such as L1/L2 penalties, dropout, and early stopping, alongside cross-validation strategies and grid, random, and Bayesian hyperparameter search. Emphasizes a principled, reproducible process for selecting model complexity and tuning against a real compute-versus-accuracy budget rather than ad-hoc trial and error.

MediumTechnical
74 practiced

You have 10,000 features but expect only about 50 are truly predictive. Compare L1, L2, and Elastic Net for this setting: which handles correlated-but-relevant features better, and why would you reach for Elastic Net's mixing parameter instead of pure L1?

HardTechnical
64 practiced

Simulate and compare nested cross-validation against a simple train/validation/test split to measure the optimistic bias the simple split introduces when you're also tuning hyperparameters. Set up a small synthetic experiment with a known ground truth and show the size of the gap.

HardTechnical
69 practiced

Describe a protocol for nested cross-validation when your data is non-iid: there's time ordering (you can't shuffle across time) AND group structure (multiple rows per user/session that must stay together). How do the inner and outer splitting strategies both need to change?

MediumTechnical
78 practiced

After running a Bayesian hyperparameter search you have hundreds of trials logged. Describe how you'd analyze the results beyond just picking the single best trial: what would you look at to understand which hyperparameters actually mattered?

MediumTechnical
65 practiced

Design a benchmark suite for comparing candidate models across multiple business units in the same company. What's your dataset-selection strategy so the comparison is fair across units with different data distributions?

Unlock Full Question Bank

Get access to all Model Selection, Tuning, and Generalization interview questions and detailed answers.

Sign in to Continue

Join thousands of developers preparing for their dream job.