Practice
1. When designing a CNN for image classification, why might you choose to use a smaller receptive field in the initial layers?
medium
Solution
Step 1: Understand receptive fields
Smaller receptive fields in initial layers help capture fine-grained local features, which are crucial for understanding detailed patterns.Step 2: Eliminate wrong options
To capture more global features early on is incorrect because global features are captured in deeper layers. To reduce the computational cost of the network is incorrect as smaller receptive fields don't necessarily reduce computational cost. To increase the depth of the network without increasing parameters is incorrect because depth and parameters are not directly related to receptive field size.Final Answer:
Option C -> Option CQuick Check:
Smaller fields capture local details. [OK]
Hint: Smaller fields capture local details. [OK]
Common Mistakes:
2. When deciding between MLflow and Weights & Biases for experiment tracking, which scenario makes MLflow a better choice?
medium
Solution
Step 1: Compare MLflow and W&B features
MLflow is often chosen for self-hosting due to its open-source nature.Step 2: Match features to scenarios
MLflow's self-hosting is ideal for environments with strict data privacy requirements.Final Answer:
Option C -> Option CQuick Check:
MLflow = Self-hosting [OK]
Hint: MLflow = Self-hosting [OK]
Common Mistakes:
3. A machine learning model is consistently overfitting on a dataset. What is the most likely cause?
medium
Solution
Step 1: Identify symptoms of overfitting.
Overfitting occurs when a model learns noise instead of the signal.Step 2: Determine the cause related to model complexity.
Too many parameters can lead to overfitting by capturing noise.Final Answer:
Option B -> Option BQuick Check:
Overfitting often means too complex a model. [OK]
Hint: Overfitting often means too complex a model. [OK]
Common Mistakes:
4. You are tasked with deploying a calibrated model for a real-time fraud detection system. Which approach ensures both calibration and low latency?
hard
Solution
Step 1: Consider latency and calibration.
Real-time systems require low latency, favoring pre-trained models.Step 2: Evaluate each approach.
Batch processing (A) and online learning (B) introduce latency. Pre-trained models (C, D) are faster, but Platt Scaling (C) is more efficient than Isotonic Regression (D).Final Answer:
Option A -> Option AQuick Check:
Pre-trained + Platt = fast calibration. [OK]
Hint: Pre-trained + Platt = fast calibration. [OK]
Common Mistakes:
5. In a real-time system where predictions need to be made quickly, which approach to linear regression is more suitable and why?
hard
Solution
Step 1: Consider real-time constraints
Stochastic Gradient Descent (SGD) updates weights after each data point, allowing for faster, more frequent updates suitable for real-time systems.Step 2: Eliminate wrong options
Batch Gradient Descent (A) is too slow for real-time, Least Squares (C) is not iterative, and Mini-batch (D) is a compromise but not as fast as SGD.Final Answer:
Option A -> Option AQuick Check:
SGD updates weights after each data point. [OK]
Hint: SGD updates weights after each data point. [OK]
Common Mistakes:
