0
0
Prompt Engineering / GenAIml~20 mins

Inpainting and outpainting in Prompt Engineering / GenAI - Practice Problems & Coding Challenges

Choose your learning style9 modes available
Challenge - 5 Problems
🎖️
Inpainting and Outpainting Master
Get all challenges correct to earn this badge!
Test your skills under time pressure!
🧠 Conceptual
intermediate
1:30remaining
Understanding Inpainting Purpose

What is the main goal of inpainting in image generation?

ATo increase the resolution of an image by adding pixels
BTo generate a completely new image from random noise
CTo fill missing or damaged parts of an image using surrounding context
DTo segment an image into different object classes
Attempts:
2 left
💡 Hint

Think about fixing or completing parts of an existing image.

Predict Output
intermediate
2:00remaining
Output of Outpainting Model Code

Given the following pseudocode for an outpainting model, what is the shape of the output image if the input image is 256x256 pixels and the model extends the canvas by 64 pixels on each side?

Prompt Engineering / GenAI
input_image = load_image('input.png')  # shape: (256, 256, 3)
output_image = outpaint_model(input_image, extend=64)
print(output_image.shape)
A(256, 256, 3)
B(256, 320, 3)
C(320, 320, 3)
D(384, 384, 3)
Attempts:
2 left
💡 Hint

Outpainting adds pixels around the original image edges.

Model Choice
advanced
2:00remaining
Best Model Architecture for Inpainting

Which model architecture is best suited for high-quality image inpainting tasks?

AConvolutional Autoencoder with skip connections
BSimple feedforward neural network
CRecurrent Neural Network (RNN)
DK-Nearest Neighbors (KNN) classifier
Attempts:
2 left
💡 Hint

Consider models that capture spatial features and details.

Metrics
advanced
1:30remaining
Evaluating Outpainting Quality

Which metric is most appropriate to quantitatively evaluate the visual quality of an outpainted image compared to the original?

APeak Signal-to-Noise Ratio (PSNR)
BAccuracy of classification labels
CMean Squared Error (MSE) only on masked region
DConfusion matrix
Attempts:
2 left
💡 Hint

Think about measuring similarity between images.

🔧 Debug
expert
2:30remaining
Debugging Inpainting Model Output

You trained an inpainting model but the output images have visible sharp edges around the filled regions, making the inpainted area obvious. What is the most likely cause?

AThe input images were too large for the model
BThe model was trained without using a smooth loss function or perceptual loss
CThe model used too many convolutional layers
DThe training dataset had too many images
Attempts:
2 left
💡 Hint

Consider what helps the model blend filled regions smoothly.