Description
All Key Points and supplements would be attached FOR CONSIDERATION
Part I: Filter basics
Sharpen rain.jpeg
and eliminate rain drops in it by median filter.
Task 1: Implement your sharpening filter and perform it on rain.jpeg
. Save your results as sharpened.jpg
. To get an obvious result, you may chose a relatively large
Task 2: Implement your own median filter and perform it on rain.jpeg
to eliminate rain drops. Save results to derained.jpg
. To get a good deraining result, the filter size should be as small as possible but large enough to eliminate rain drops. (2 points)
Part II: Canny edge detector
Implement Canny edge detector to detect edges in road.jpeg
. Your program should contain following steps:
- Convert colour image into grayscale image, and save as
gray.jpg
. (1 point) - Choose a proper
sigma
to perform Gaussian smoothing, save the result asgauss.jpg
. Discuss howsigma
affects final edge detection results. (2 points) - Apply sobel operator, save the x-gradient
Gx , y-gradientGy and magnitudeG asG_x.jpg
,G_y.jpg
andG.jpg
. (3 points) - Non-maximum value suppression. Save suppression result as
supress.jpg
. (3 points) - Hysteresis thresholding. Choose two proper threshold low and high, then binarize your suppression result via Hysteresis thresholding. Save binarization result by lower threshold as
edgemap_low.jpg
, result by high threshold asedgemap_high.jpg
. Save the final result by Hysteresis thresholding asedgemap.jpg
. Discuss how different thresholds affect final edgemap. (2 points, one point foredgemap_low.jpg
andedgemap_high.jpg
, one foredgemap.jpg
)
Bonus: Hough transform
This part follows part II Canny edge detector to recognize straight lines in edgemap.jpg
.
- Hough Transform. Save the voting result as
hough.jpg
. (2 points) - Find out several most possible straight lines. Draw them on original image, then save as
detection_result.jpg
. To draw lines on image, see this example. (1 points)