Practice
1. In the context of object detection, which of the following is a key advantage of YOLO over R-CNN?
easy
Solution
Step 1: Identify YOLO's strengths
YOLO is known for its real-time processing capabilities due to its single-stage architecture.Step 2: Eliminate wrong options
Higher accuracy on small objects: R-CNN is generally better for small objects. Better handling of occlusions: Handling occlusions is not a specific strength of YOLO. More robust to varying lighting conditions: Lighting conditions are not specifically addressed by YOLO.Final Answer:
Option A -> Option AQuick Check:
YOLO = Speed, R-CNN = Precision [OK]
Hint: YOLO = Speed, R-CNN = Precision [OK]
Common Mistakes:
2. What is the output of the following Python code snippet using NumPy for logistic regression log-odds calculation?
import numpy as np
coefficients = np.array([0.5, -0.25])
features = np.array([2, 3])
log_odds = np.dot(coefficients, features)
print(log_odds)easy
Solution
Step 1: Calculate the dot product.
The dot product is calculated as (0.5 * 2) + (-0.25 * 3) = 1.0 - 0.75 = 0.25.Step 2: Identify the correct output.
-0.25 is correct because the calculation results in 0.25. 1.25 is incorrect as it suggests a miscalculation. 0.25 is incorrect due to a sign error. 2.75 is incorrect due to a misunderstanding of dot product.Final Answer:
Option A -> Option AQuick Check:
Dot product = sum of products [OK]
Hint: Dot product = sum of products [OK]
Common Mistakes:
3. 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:
4. In a CI/CD pipeline for ML, when should you prefer using a canary deployment over a blue-green deployment?
medium
Solution
Step 1: Understand deployment strategies.
Canary deployment gradually rolls out changes to a small subset, while blue-green switches between two environments.Step 2: Match scenarios to strategies.
Canary is ideal for testing on a small subset (B), blue-green is for zero downtime (A) and quick rollback (D).Final Answer:
Option D -> Option DQuick Check:
Canary = gradual rollout. [OK]
Hint: Canary = gradual rollout. [OK]
Common Mistakes:
5. A recurrent neural network is not learning effectively. The loss plateaus early during training. What is the most likely cause?
medium
Solution
Step 1: Identify symptoms of vanishing gradient.
Early plateauing of loss often indicates vanishing gradients.Step 2: Eliminate other causes.
High learning rate (A) would cause erratic loss, overfitting (B) would show low training loss, and small dataset (D) would not cause early plateau.Final Answer:
Option C -> Option CQuick Check:
Early plateau = vanishing gradient. [check]
Hint: Early plateau = vanishing gradient. [check]
Common Mistakes:
