0
0
Computer Visionml~10 mins

Blurring and smoothing (Gaussian, median, bilateral) in Computer Vision - Interactive Code Practice

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

Complete the code to apply a Gaussian blur to the image using OpenCV.

Computer Vision
blurred = cv2.[1](image, (5, 5), 0)
Drag options to blanks, or click blank then click option'
Ablur
BGaussianBlur
CbilateralFilter
DmedianBlur
Attempts:
3 left
💡 Hint
Common Mistakes
Using medianBlur instead of GaussianBlur changes the smoothing method.
Using blur applies a simple average filter, not Gaussian.
2fill in blank
medium

Complete the code to apply a median blur with a kernel size of 5.

Computer Vision
blurred = cv2.[1](image, 5)
Drag options to blanks, or click blank then click option'
AmedianBlur
BGaussianBlur
CbilateralFilter
Dblur
Attempts:
3 left
💡 Hint
Common Mistakes
Using GaussianBlur instead of medianBlur changes the smoothing effect.
Using bilateralFilter requires more parameters.
3fill in blank
hard

Fix the error in the code to apply a bilateral filter correctly.

Computer Vision
blurred = cv2.bilateralFilter(image, [1], 75, 75)
Drag options to blanks, or click blank then click option'
A9
B3
C1
D5
Attempts:
3 left
💡 Hint
Common Mistakes
Using too small diameter like 1 reduces smoothing effect.
Using even numbers may cause unexpected behavior.
4fill in blank
hard

Fill both blanks to create a dictionary with keys as filter names and values as their OpenCV function calls.

Computer Vision
filters = {'gaussian': cv2.[1], 'median': cv2.[2]
Drag options to blanks, or click blank then click option'
AGaussianBlur
BmedianBlur
CbilateralFilter
Dblur
Attempts:
3 left
💡 Hint
Common Mistakes
Mixing up bilateralFilter with medianBlur.
Using blur instead of GaussianBlur.
5fill in blank
hard

Fill all three blanks to apply a bilateral filter with diameter 9, sigmaColor 75, and sigmaSpace 75.

Computer Vision
blurred = cv2.bilateralFilter(image, [1], [2], [3])
Drag options to blanks, or click blank then click option'
A5
B75
C9
D50
Attempts:
3 left
💡 Hint
Common Mistakes
Using diameter 5 instead of 9 changes smoothing area.
Confusing sigmaColor and sigmaSpace values.