Practice
1. In the context of cross-validation, which method is most appropriate for imbalanced datasets?
easy
Solution
Step 1: Identify the need for balanced class distribution.
Imbalanced datasets require maintaining class distribution in each fold.Step 2: Eliminate wrong options.
K-Fold does not ensure class balance (A), Time Series Split is for temporal data (C), Leave-One-Out is computationally expensive and doesn't address imbalance (D).Final Answer:
Option C -> Option CQuick Check:
Stratified keeps class balance. [OK]
Hint: Stratified keeps class balance. [OK]
Common Mistakes:
2. In the context of statistical significance testing in ML, which of the following best describes a p-value?
easy
Solution
Step 1: Understand p-value definition
A p-value is the probability of observing the data, or something more extreme, given that the null hypothesis is true.Step 2: Eliminate wrong options
The probability that the null hypothesis is true. is incorrect because p-value is not the probability that the null hypothesis is true. The probability of the alternative hypothesis being true. is incorrect because it does not relate to the alternative hypothesis. The probability of making a Type I error. is incorrect because it confuses p-value with Type I error probability.Final Answer:
Option A -> Option AQuick Check:
P-value is about data given null hypothesis [OK]
Hint: P-value is about data given null hypothesis [OK]
Common Mistakes:
3. When training a deep neural network, which approach is more suitable to mitigate the vanishing gradient problem?
medium
Solution
Step 1: Identify methods to mitigate vanishing gradients
ReLU activation functions help mitigate the vanishing gradient problem by maintaining gradients through layers.Step 2: Eliminate wrong options
Use a very small learning rate. is incorrect because a small learning rate doesn't address vanishing gradients. Increase the number of layers. exacerbates the problem. Use L2 regularization. is unrelated to gradient flow.Final Answer:
Option D -> Option DQuick Check:
ReLU helps maintain gradients. [OK]
Hint: ReLU helps maintain gradients. [OK]
Common Mistakes:
4. A model trained with K-Fold cross-validation is underperforming on unseen data. What is a likely cause?
medium
Solution
Step 1: Consider data leakage as a common issue.
Data leakage can occur if the same data points appear in both training and validation sets.Step 2: Eliminate wrong options.
Too many folds (A) typically doesn't cause overfitting, too few folds (C) would not cause underperformance on unseen data, model complexity (D) is unrelated to cross-validation setup.Final Answer:
Option B -> Option BQuick Check:
Check for data leakage in CV. [OK]
Hint: Check for data leakage in CV. [OK]
Common Mistakes:
5. When dealing with high-dimensional data, which approach is more suitable for reducing dimensionality while preserving variance?
medium
Solution
Step 1: Identify the goal of preserving variance.
PCA is designed to reduce dimensions while preserving variance.Step 2: Eliminate wrong options.
Use L1 regularization to select features. selects features, not reduce dimensions. Use k-means clustering to group similar data points. clusters data, not reduce dimensions. Apply dropout to randomly ignore features during training. is for regularization, not dimensionality reduction.Final Answer:
Option C -> Option CQuick Check:
PCA reduces dimensions, keeps variance. [OK]
Hint: PCA reduces dimensions, keeps variance. [OK]
Common Mistakes:
