0
0
Computer Visionml~10 mins

Why features identify distinctive points in Computer Vision - Test Your Understanding

Choose your learning style9 modes available
Practice - 5 Tasks
Answer the questions below
1fill in blank
easy

Complete the code to extract keypoints using ORB detector.

Computer Vision
import cv2
img = cv2.imread('image.jpg', 0)
orb = cv2.ORB_create()
keypoints = orb.[1](img)
Drag options to blanks, or click blank then click option'
Aextract
BfindFeatures
Cdetect
DdetectAndCompute
Attempts:
3 left
💡 Hint
Common Mistakes
Using detectAndCompute instead of detect
Trying to use non-existent methods like findFeatures
2fill in blank
medium

Complete the code to compute descriptors for the detected keypoints.

Computer Vision
keypoints, descriptors = orb.[1](img, keypoints)
Drag options to blanks, or click blank then click option'
Aextract
BdetectAndCompute
Ccompute
Ddetect
Attempts:
3 left
💡 Hint
Common Mistakes
Using compute which requires keypoints as input and returns descriptors only
Using detect which returns only keypoints
3fill in blank
hard

Fix the error in the code to correctly match descriptors using BFMatcher.

Computer Vision
bf = cv2.BFMatcher(cv2.NORM_HAMMING, crossCheck=True)
matches = bf.[1](des1, des2)
Drag options to blanks, or click blank then click option'
AfindMatches
Bmatches
CknnMatch
Dmatch
Attempts:
3 left
💡 Hint
Common Mistakes
Using matches which is not a method
Using knnMatch when only single matches are needed
4fill in blank
hard

Fill both blanks to create a dictionary of keypoints and their coordinates.

Computer Vision
kp_dict = {kp.[1]: (kp.[2][0], kp.[2][1]) for kp in keypoints}
Drag options to blanks, or click blank then click option'
Aangle
Bpt
Csize
Dresponse
Attempts:
3 left
💡 Hint
Common Mistakes
Using angle or size which are not coordinates
Trying to use response which is a strength measure
5fill in blank
hard

Fill all three blanks to filter good matches based on distance.

Computer Vision
good_matches = [m for m in matches if m.[1] < [2] * min_dist and m.[3] != 0]
Drag options to blanks, or click blank then click option'
Adistance
B0.7
CqueryIdx
DtrainIdx
Attempts:
3 left
💡 Hint
Common Mistakes
Using trainIdx instead of queryIdx
Using wrong threshold values
Checking wrong attributes