0
0
Computer Visionml~20 mins

Why computer vision teaches machines to see - Challenge Your Understanding

Choose your learning style9 modes available
Challenge - 5 Problems
🎖️
Computer Vision Mastery
Get all challenges correct to earn this badge!
Test your skills under time pressure!
🧠 Conceptual
intermediate
1:30remaining
What is the main goal of computer vision?
Computer vision helps machines understand images and videos. What is the main goal of teaching machines to see?
ATo allow machines to write text without any visual input
BTo make machines generate random images without understanding
CTo teach machines to hear sounds from images
DTo enable machines to recognize and interpret visual information like humans do
Attempts:
2 left
💡 Hint
Think about what seeing means for humans and how machines might do the same.
Predict Output
intermediate
1:30remaining
Output of image pixel normalization code
What is the output of this Python code that normalizes pixel values of an image array?
Computer Vision
import numpy as np
image = np.array([[0, 128], [255, 64]])
normalized = image / 255
print(normalized)
ATypeError: unsupported operand type(s) for /: 'list' and 'int'
B[[0, 0.5], [1, 0.25]]
C[[0.0, 0.50196078], [1.0, 0.25098039]]
D[[0, 128], [255, 64]]
Attempts:
2 left
💡 Hint
Division by 255 converts pixel values to a 0-1 range as floats.
Model Choice
advanced
2:00remaining
Best model type for object detection in images
You want to build a system that finds and labels objects in photos. Which model type is best suited for this task?
AConvolutional Neural Network (CNN) with region proposal networks
BRecurrent Neural Network (RNN) for sequence prediction
CLinear Regression model for numeric prediction
DK-Means clustering for grouping unlabeled data
Attempts:
2 left
💡 Hint
Object detection needs spatial understanding of images.
Metrics
advanced
1:30remaining
Choosing the right metric for image classification accuracy
You trained a model to classify images into categories. Which metric best shows how often the model predicts the correct category?
AMean Squared Error
BAccuracy
CSilhouette Score
DPerplexity
Attempts:
2 left
💡 Hint
Think about a metric that measures correct predictions over total predictions.
🔧 Debug
expert
2:30remaining
Why does this image preprocessing code raise an error?
What error does this code raise and why? import cv2 image = cv2.imread('photo.jpg') gray = cv2.cvtColor(image, cv2.COLOR_BGR2GRAY) resized = cv2.resize(gray, (100, 100)) print(resized.shape)
Computer Vision
import cv2
image = cv2.imread('photo.jpg')
gray = cv2.cvtColor(image, cv2.COLOR_BGR2GRAY)
resized = cv2.resize(gray, (100, 100))
print(resized.shape)
AAttributeError because 'image' is None if file not found
BTypeError because cv2.resize expects a list, not a numpy array
CValueError because color conversion code is invalid
DNo error, prints (100, 100)
Attempts:
2 left
💡 Hint
Check if the image file was loaded correctly before processing.