Practice
1. In the context of image segmentation, which type of segmentation assigns a unique label to each pixel of an image based on the object class it belongs to, without distinguishing between different instances of the same class?
easy
Solution
Step 1: Understand the segmentation types
Semantic segmentation labels each pixel according to the object class, without distinguishing instances.Step 2: Eliminate wrong options
Instance segmentation distinguishes between instances, panoptic combines both semantic and instance, and object detection is not segmentation.Final Answer:
Option A -> Option AQuick Check:
Semantic = Class labels only [OK]
Hint: Semantic = Class labels only [OK]
Common Mistakes:
2. Given the following Python code snippet for a segmentation task, what will be the output shape if the input image shape is (256, 256, 3) and the model outputs a segmentation map with 10 classes?
import numpy as np
input_image = np.random.rand(256, 256, 3)
model_output = np.random.rand(256, 256, 10)easy
Solution
Step 1: Understand the model output
The model outputs a segmentation map with a shape corresponding to the input spatial dimensions and the number of classes.Step 2: Eliminate wrong options
(256, 256, 3) is the input shape, (256, 256, 1) implies binary segmentation, and (256, 256) lacks class dimension.Final Answer:
Option A -> Option AQuick Check:
Output shape = Input spatial + class channels [OK]
Hint: Output shape = Input spatial + class channels [OK]
Common Mistakes:
3. When should dropout not be used in a neural network model?
medium
Solution
Step 1: Identify when dropout is counterproductive
Dropout is a regularization technique that helps prevent overfitting, not underfitting.Step 2: Eliminate wrong options
When the model is overfitting on the training data. is incorrect because dropout is useful for overfitting. When the model is being used for time series forecasting. is incorrect because dropout can be used in time series if applied correctly. When the model has a large number of parameters. is incorrect because dropout is often used in models with many parameters to prevent overfitting.Final Answer:
Option B -> Option BQuick Check:
Dropout not for underfitting. [OK]
Hint: Dropout not for underfitting. [OK]
Common Mistakes:
4. A deployed model is showing unexpected behavior with high variance in predictions. What is the most likely cause?
medium
Solution
Step 1: Identify the symptom.
High variance in predictions suggests the model is not generalizing well.Step 2: Determine the most likely cause.
Data drift, where the input data distribution changes over time, is a common cause of unexpected behavior in production.Final Answer:
Option D -> Option DQuick Check:
Data drift causes unexpected variance. [OK]
Hint: Data drift causes unexpected variance. [OK]
Common Mistakes:
5. You are designing a recommendation system for a video platform. Which metric would best capture user satisfaction if users tend to watch only the first few recommended videos?
hard
Solution
Step 1: Understand user behavior
Users watching only the first few videos means early precision is crucial.Step 2: Choose the metric
Precision at K directly measures the quality of the top K recommendations, aligning with user behavior.Final Answer:
Option A -> Option AQuick Check:
Precision at K focuses on top results. [OK]
Hint: Precision at K focuses on top results. [OK]
Common Mistakes:
