Try   HackMD

圖片濾鏡系統期末線上展覽

因為有些同學在demo時卡到其他時間,因此做了個線上的展覽讓大家可以檢視各組做的狀況。選出一些做得還不錯的結果與一些特別的演算法與大家分享。甚至有同學改良現有的演算法達到更好的結果,非常厲害。

基本功能

Box Filter

將kernel內的所有像素取平均值,因此當kernel越大,輸出圖片會越模糊,會失去越多細節。

  • Author: 廖哲武

    Image Not Showing Possible Reasons
    • The image was uploaded to a note which you don't have access to
    • The note which the image was originally uploaded to has been deleted
    Learn More →

  • Author: 林柏宇 李承洸

    Image Not Showing Possible Reasons
    • The image was uploaded to a note which you don't have access to
    • The note which the image was originally uploaded to has been deleted
    Learn More →

  • Author: 張庭洋

    Image Not Showing Possible Reasons
    • The image was uploaded to a note which you don't have access to
    • The note which the image was originally uploaded to has been deleted
    Learn More →

Median Filter

將kernel內的所有像素取出中位數,因此可以將圖片中的極值濾掉。在圖片中的極值為0與255的黑白像素,亦稱作pepper salt noise,因為胡椒是黑的,鹽是白的,就是胡椒鹽的概念。因此如果使用這種濾鏡,便可以將極大值與極小值濾除。此外,與box filter同理,若使用更大的濾鏡,將會使圖片變得更加模糊,失去更多細節。

  • Author: 廖哲武

    Image Not Showing Possible Reasons
    • The image was uploaded to a note which you don't have access to
    • The note which the image was originally uploaded to has been deleted
    Learn More →

  • Author: 張庭洋

    Image Not Showing Possible Reasons
    • The image was uploaded to a note which you don't have access to
    • The note which the image was originally uploaded to has been deleted
    Learn More →

Image Not Showing Possible Reasons
  • The image file may be corrupted
  • The server hosting the image is unavailable
  • The image path is incorrect
  • The image format is not supported
Learn More →
雀斑消失了!

  • Author: 黃綵誼
    Image Not Showing Possible Reasons
    • The image was uploaded to a note which you don't have access to
    • The note which the image was originally uploaded to has been deleted
    Learn More →

Identity Filter

Skip,基本上輸出圖片與輸入圖片相等。

進階功能

Contrast Stretching(對比拉伸)

Pixelnew=PixelPixelminPixelmaxPmin

  • Author: 張庭洋

    Image Not Showing Possible Reasons
    • The image was uploaded to a note which you don't have access to
    • The note which the image was originally uploaded to has been deleted
    Learn More →

  • Author: 廖偉程 沈昱成

    Image Not Showing Possible Reasons
    • The image was uploaded to a note which you don't have access to
    • The note which the image was originally uploaded to has been deleted
    Learn More →

  • Author: 郭庭維

    Image Not Showing Possible Reasons
    • The image was uploaded to a note which you don't have access to
    • The note which the image was originally uploaded to has been deleted
    Learn More →

如果該圖片本身就具備0及255這種極值的像素值,則拉伸的結果便會非常有限。郭庭維同學因此改良原先的算法,使對比度能夠更加的被拉伸。具體細節如下:

Image Not Showing Possible Reasons
  • The image was uploaded to a note which you don't have access to
  • The note which the image was originally uploaded to has been deleted
Learn More →

  • Author: 郭庭維
    Image Not Showing Possible Reasons
    • The image was uploaded to a note which you don't have access to
    • The note which the image was originally uploaded to has been deleted
    Learn More →

Mosaic Filter(馬賽克濾鏡)

與期末上機考第二題max pooling的做法類似,只不過這次是計算kernel包住的平均值,而非最大值。可以觀察到當kernel size越大,圖片變得更模糊,馬賽克得顆粒越大。

  • Author: 郭庭維
    Image Not Showing Possible Reasons
    • The image was uploaded to a note which you don't have access to
    • The note which the image was originally uploaded to has been deleted
    Learn More →

Intensity Transformation(強度轉換)

基本上就是找各種函數將input的像素值map到ouptut的像素值。

  • Author: 江旭宸 周志鎧

    Image Not Showing Possible Reasons
    • The image was uploaded to a note which you don't have access to
    • The note which the image was originally uploaded to has been deleted
    Learn More →

  • Authot: 黃綵誼

    Image Not Showing Possible Reasons
    • The image was uploaded to a note which you don't have access to
    • The note which the image was originally uploaded to has been deleted
    Learn More →

Histogram Equalization(直方圖均化)

ref: [https://jason-chen-1992.weebly.com/home/-histogram-equalization]
為使用統計的手法將像素值盡可能的分散到不同的像素值,以增強圖片對比度。

  • Author: 黃綵誼
    Image Not Showing Possible Reasons
    • The image was uploaded to a note which you don't have access to
    • The note which the image was originally uploaded to has been deleted
    Learn More →

Alpha-Trimmed Mean Filter(Alpha-修整平均濾波器)

結合了box filter與median filter的點子,將kernel內的像素值排序後,去掉部分的極大極小值,將剩餘的值平均。為一個對抗胡椒鹽雜訊的好工具。

  • Author: 江旭宸 周志鎧
    Image Not Showing Possible Reasons
    • The image was uploaded to a note which you don't have access to
    • The note which the image was originally uploaded to has been deleted
    Learn More →

Sobel Gradient Filter(索伯梯度濾鏡)

Horizontal Kernel:

Gx=(+101+202+101)

Vertical Kernel:

Gy=(+1+2+1000121)

將兩個kernel與原圖作convolution之後作幾何平均:

I(x,y)=(GxI)2+(GyI)2

  • Author: 楊捷茗

    Image Not Showing Possible Reasons
    • The image was uploaded to a note which you don't have access to
    • The note which the image was originally uploaded to has been deleted
    Learn More →

  • Author: 張庭洋

    Image Not Showing Possible Reasons
    • The image was uploaded to a note which you don't have access to
    • The note which the image was originally uploaded to has been deleted
    Learn More →

Linear Motion Blurring(線性運動模糊)

這個濾鏡的結果很像在拍照的時候手抖了一下,因此會有一個速度感。實作原理如下:

B(x,y)=I(xtcos(θ),ytsin(θ))dt

其中

I(x,y)為原始圖像中的像素值,
B(x,y)
為模糊後的像素值。透過將上式離散化所得到的kernel與原圖作convolution之後,便可以得到圖片朝特定方向產生線性模糊的結果圖。

  • Author: 江旭宸 周志鎧
    Image Not Showing Possible Reasons
    • The image was uploaded to a note which you don't have access to
    • The note which the image was originally uploaded to has been deleted
    Learn More →

特殊現象

Moire Pattern(摩爾紋)

當ASCII ART使用過高解析度,且原始圖片解析度較高時,在液晶螢幕上顯示只有黑字的ASCII ART時會因為大量細紋的光學干涉產生摩爾紋效應。

  • Author: 廖哲武
    Image Not Showing Possible Reasons
    • The image was uploaded to a note which you don't have access to
    • The note which the image was originally uploaded to has been deleted
    Learn More →

    Image Not Showing Possible Reasons
    • The image was uploaded to a note which you don't have access to
    • The note which the image was originally uploaded to has been deleted
    Learn More →

在日常生活中也會出現類似的現象:

Image Not Showing Possible Reasons
  • The image was uploaded to a note which you don't have access to
  • The note which the image was originally uploaded to has been deleted
Learn More →

ref: [https://www.fuji.com.tw/shownews.asp?RecordNo=880]

希望你們學到的事情

Image Not Showing Possible Reasons
  • The image file may be corrupted
  • The server hosting the image is unavailable
  • The image path is incorrect
  • The image format is not supported
Learn More →
Programming + Domain Knowledge = Potential

現在學會寫程式後,再加上你們來自各個領域的專業知識,便有無限的潛能。