数字图像处理与应用 Class 3. 20200504
Lecture 3 Image Enhancement(Spatial Filtering)
Lecture 3 Image Enhancement(Spatial Filtering)
Basic of spatial filtering
Smoothing spatial filters 平滑
Smoothing linear filters 平滑线性滤波器
Order-statistics filters 统计排序滤波器
Sharpening spatial filters 锐化
1st derivative filters 一阶导
2nd derivative filters 二阶导
Basic
Any size rectangle and any shape filter are possible.
一般选择奇数(保证滤波器有中心点)/偶数需额外控制
Spatial Linear filters
a=(m-1)/2 and b=(n-1)/2
m x n (odd numbers)
-
一般化-->
-
Strange Things at the Edges
At the edges of an image we are missing pixels to form a neighbourhood
- Solutions
-Omit missing pixels
Can add extra code and slow down processing
-Pad the image 增补图片
Typically with either all white or all black pixels
-Replicate border pixels 复制边界像素
-Truncate the image 截断图像
Spatial smoothing filtering 空间平滑滤波
Used for blurring (removal of small details prior to large object extraction, bridging small ga