Challenge - 5 Problems
Generative Model Mastery
Get all challenges correct to earn this badge!
Test your skills under time pressure!
🧠 Conceptual
intermediate1:30remaining
Purpose of Generative Models
Why do generative models create new data samples?
Attempts:
2 left
💡 Hint
Think about what it means to 'generate' data in machine learning.
✗ Incorrect
Generative models learn the patterns and structure of the original data so they can create new, similar data points. This is different from classification or compression.
❓ Model Choice
intermediate1:30remaining
Choosing a Generative Model for Image Creation
Which model is best suited to generate new images similar to a training set?
Attempts:
2 left
💡 Hint
Look for a model designed to create new data, not just analyze or classify.
✗ Incorrect
GANs are designed to generate new data samples, especially images, by learning the data distribution through a generator and discriminator.
❓ Predict Output
advanced2:00remaining
Output Shape of Generated Data
What is the shape of the output tensor from the generator in this PyTorch GAN code snippet?
PyTorch
import torch import torch.nn as nn class Generator(nn.Module): def __init__(self): super().__init__() self.net = nn.Sequential( nn.Linear(100, 256), nn.ReLU(), nn.Linear(256, 784), nn.Tanh() ) def forward(self, x): return self.net(x) g = Generator() noise = torch.randn(16, 100) output = g(noise) output_shape = output.shape
Attempts:
2 left
💡 Hint
Check the input batch size and the final layer output size.
✗ Incorrect
The input noise has shape (16, 100). The generator outputs a tensor with shape (batch_size, 784), so (16, 784).
❓ Metrics
advanced1:30remaining
Evaluating Generative Model Quality
Which metric is commonly used to evaluate the quality of images generated by a GAN?
Attempts:
2 left
💡 Hint
This metric measures how realistic and diverse generated images are.
✗ Incorrect
Inception Score evaluates both the quality and diversity of generated images by using a pretrained classifier.
🔧 Debug
expert2:00remaining
Identifying the Cause of Mode Collapse in GAN Training
During GAN training, the generator produces very similar images repeatedly, showing mode collapse. What is the most likely cause?
Attempts:
2 left
💡 Hint
Mode collapse often happens when one part of the GAN dominates the other.
✗ Incorrect
If the discriminator is too strong, the generator struggles to improve and collapses to producing limited outputs.