QUIZ
Generative models
8 questions on Generative models, from 6 lessons. Pick an answer in your head, then open it.
On the roadmap for: ML Engineering.
Question 1 of 8
What does an embedding learn, for example for foods like biryani and pulao?
- A. A vector where similar items end up close together
- B. The number of letters in each item's name
- C. A random ID number for each item
- D. A single category label for each item, stored as a one-hot vector
View answer
✓ A. A vector where similar items end up close together
Embeddings place similar items near each other, so similarity can be measured with distances or cosine.
Question 2 of 8
What makes a variational autoencoder able to generate new data, unlike a plain autoencoder?
- A. It has more layers than a plain autoencoder
- B. It skips the decoder when generating new data
- C. A smooth latent space tied to a prior, for sampling
- D. It uses class labels to guide the decoder
View answer
✓ C. A smooth latent space tied to a prior, for sampling
The KL term keeps the latent space well organised, so random samples decode into plausible outputs.
Lesson: Autoencoders and VAEs
Question 3 of 8
Why are GANs hard to train?
- A. They have no loss function at all for the optimiser to work on
- B. Two competing networks can oscillate or collapse
- C. They can't be trained on GPUs
- D. They need labelled data for every image
View answer
✓ B. Two competing networks can oscillate or collapse
The generator and discriminator must stay balanced; tricks like better losses and normalisation help.
Lesson: GANs
Question 4 of 8
How does a diffusion model generate an image?
- A. From pure noise, it removes a little noise each step
- B. It draws the image pixel by pixel, row after row
- C. It copies and blends training images
- D. It uses a GAN discriminator to pick images
View answer
✓ A. From pure noise, it removes a little noise each step
Training adds noise to real images and learns to undo it; generation runs that denoising many times.
Lesson: Diffusion Models
Question 5 of 8
How did CLIP learn to match images and text without hand-labelled classes?
- A. By translating captions into other languages
- B. Matching image–caption pairs scored above mismatches
- C. From manual labels for every image
- D. By predicting the pixels of each image from the caption's words
View answer
✓ B. Matching image–caption pairs scored above mismatches
Contrastive learning pulls matching pairs together and pushes others apart, enabling zero-shot classification.
Question 6 of 8
In contrastive learning, what are the 'negatives'?
- A. Images with negative pixel values
- B. Examples with wrong labels in the dataset
- C. Other examples in the batch that don't match
- D. Training runs that failed to converge
View answer
✓ C. Other examples in the batch that don't match
More and harder negatives usually make the learned representation more useful.
Question 7 of 8
Which family usually gives the most stable training and best image quality today, at the cost of slower generation?
- A. Diffusion models
- B. GANs
- C. Plain autoencoders
- D. Linear regression
View answer
✓ A. Diffusion models
Diffusion trains stably and covers the data well; it needs many denoising steps, which faster samplers reduce.
Lesson: Diffusion Models
Question 8 of 8
What is the intersection over union (IoU) of two 10×10 boxes that overlap in a 5×10 area?
- A. About 0.25
- B. About 0.33
- C. Exactly 1.0
- D. About 0.5
View answer
✓ B. About 0.33
Intersection 50, union 100 + 100 − 50 = 150, so IoU = 50 / 150 ≈ 0.33.
Lesson: Deep Learning Practice