研究生: |
游士和 Shi-He You |
---|---|
論文名稱: |
以FPGA實現即時白平衡系統 A Real-Time White Balance System Implemented on FPGA |
指導教授: |
王乃堅
Nai-Jian Wang |
口試委員: |
王乃堅
Nai-Jian Wang 鍾順平 Shun-Ping Chung 蘇順豐 Shun-Feng Su 姚嘉瑜 Chia-Yu Yao 呂學坤 Shyue-Kung Lu |
學位類別: |
碩士 Master |
系所名稱: |
電資學院 - 電機工程系 Department of Electrical Engineering |
論文出版年: | 2023 |
畢業學年度: | 111 |
語文別: | 中文 |
論文頁數: | 57 |
中文關鍵詞: | 影像白平衡 、透射率 、暗通道先驗 、FPGA 、即時 |
外文關鍵詞: | White Balance, Transmission, Dark Channel Prior, FPGA, Real-Time |
相關次數: | 點閱:209 下載:3 |
分享至: |
查詢本校圖書館目錄 查詢臺灣博碩士論文知識加值系統 勘誤回報 |
當光源不同時,影像的顏色會隨著光源發生變化。人眼可以適應不同的光源,具有自動校正顏色的能力,而數位相機則沒有這種機制,導致拍攝出來的影像無法呈現物體真實的色彩,而造成色偏問題。
現有各種白平衡方法有基於統計假設、白點估計以及樣本學習。基於統計假設的方法,通常假設影像中的顏色分布符合某種統計模型,但在現實世界中的影像不一定符合這些假設特性;白點估計的方法,需要找到影像中的估測白點進行校正,但有時因為周遭因素導致找到不準確的估測白點,而樣本學習的方法,需要大量樣本進行學習,耗費許多時間。
本篇論文會以白點估計即尋找影像估測白點的白平衡方法為基礎,去改良此方法所遇到的各種問題,最後將改良後的白平衡演算法實現在FPGA(Field Programmable Gate Array)上。當硬體接收到影像序列的輸入,首先將影像進行預處理,並從預處理後的影像計算大氣光的值,並藉由大氣散射模型算出影像透射率,針對透射率以及白點特性去尋找影像估測白點,透過這些估測白點計算校正增益,將一幅色偏影像進行白平衡。
實驗結果顯示此方法可成功從攝影鏡頭輸入並將白平衡後的影像顯示輸出至螢幕上,且最後的結果顯示本系統使用了17,503個邏輯元件和107,456 bits內部記憶體,功耗為818.66mW,且處理速度達到每秒70張影像(NTSC Input)。
When the light source varies, the colors in an image change accordingly. While the human eye can adapt to different light sources and automatically correct colors, digital cameras lack this mechanism, resulting in color cast issues and an inability to accurately represent the true colors of objects. Existing white balance methods include statistical assumptions, white point estimation, and sample learning. However, statistical assumption-based methods often fail to accommodate real-world image characteristics that may deviate from the assumed distributions. White point estimation methods require accurate identification of the reference white point in an image, which can be challenging due to external factors. Sample learning methods demand significant time and a large number of samples for training.
This thesis focuses on white balance improvement based on white point estimation. The proposed algorithm is implemented on Field Programmable Gate Array (FPGA). When the hardware receives an input image sequence, it undergoes preprocessing, and the atmospheric light value is calculated from the preprocessed image. By utilizing an atmospheric scattering model, the image's transmission rate is determined. Subsequently, the estimation of the white point is performed based on the transmission rate and white point characteristics. With the calculated white point, correction gains are computed to achieve white balance for a color-cast image.
Experimental results show that this method effectively produces white-balanced images on the screen. The findings reveal that the system uses 17,503 logic elements and 107,456 bits of internal memory, with a power consumption of 818.66mW. Additionally, the processing speed achieves 70 images per second (NTSC Input).
[1] E. Y. Lam, "Combining Gray world and retinex theory for automatic white balance in digital photography," Proceedings of the Ninth International Symposium on Consumer Electronics, 2005. (ISCE 2005), Macau, China, 2005, pp. 134-139, doi: 10.1109/ISCE.2005.1502356.
[2] J. Jiang, M. Yang, X. Wang and Z. Wu, "Auto white balance algorithm based on digital camera," International Conference on Internet Technology and Applications, 2011, pp. 1-4, doi: 10.1109/ITAP.2011.6006238.
[3] T. Jiang, D. Nguyen and K. -D. Kuhnert, "Auto white balance using the coincidence of chromaticity histograms," Eighth International Conference on Signal Image Technology and Internet Based Systems, 2012, pp. 201-208, doi: 10.1109/SITIS.2012.68.
[4] J. Im, D. Kim, J. Jung, T. -C. Kim and J. Paik, "Dark channel prior-based white point estimation for automatic white balance," IEEE International Conference on Consumer Electronics (ICCE), 2014, pp. 123-124, doi: 10.1109/ICCE.2014.6775936.
[5] M. Afifi, B. Price, S. Cohen and M. S. Brown, "When color constancy goes wrong: correcting improperly white-balanced images," IEEE/CVF Conference on Computer Vision and Pattern Recognition (CVPR), Long Beach, CA, USA, 2019, pp. 1535-1544, doi: 10.1109/CVPR.2019.00163.
[6] M. Afifi and M. S. Brown, "Deep white-balance editing," IEEE/CVF Conference on Computer Vision and Pattern Recognition (CVPR), Seattle, WA, USA, 2020, pp. 1394-1403, doi: 10.1109/CVPR42600.2020.00147.
[7] F. Wang, W. Wang, "An automatic white balance method via dark channel prior," Opto-Electronic Engineering, 2018, 45(1): 170549. doi: 10.12086/oee.2018.170549.
[8] C. C. Weng, H. Chen and C. S. Fuh, "A novel automatic white balance method for digital still cameras," IEEE International Symposium on Circuits and Systems (ISCAS), 2005, pp. 3801-3804 Vol. 4, doi: 10.1109/ISCAS.2005.1465458.
[9] Y. Cheng, Z. Jia, H. Lai, J. Yang and N. K. Kasabov, "A fast sand-dust image enhancement algorithm by blue channel compensation and guided image filtering," IEEE Access, 2020, vol. 8, pp. 196690-196699, doi: 10.1109/ACCESS.2020.3034151.
[10] K. He, J. Sun, and X. Tang, “Single image haze removal using dark channel prior,” IEEE transactions on pattern analysis and machine intelligence, 2010, vol. 33, no. 12, pp. 2341–2353.
[11] C. Li and X. Zhang, “Underwater image restoration based on improved background light estimation and automatic white balance,” 11th International Congress on Image and Signal Processing, BioMedical Engineering and Informatics (CISP-BMEI), 2018, pp. 1-5, doi: 10.1109/CISP-BMEI.2018.8633271.
[12] E. J. McCartney, “Optics of the atmosphere: scattering by molecules and particles,” New York, John Wiley and Sons, Inc., 1976, vol. 1, pp. 421.
[13] L. Shi and B. Funt, “Re-processed version of the gehler color constancy dataset of 568 images, ” accessed from http://www.cs.sfu.ca/~colour/data/
[14] “DE2 development and education board user manual,” [Online]. Available: https://www.terasic.com.tw/attachment/archive/226/DE2_70_User_manual_v105.pdf.
[15] “Sony EVI-D70 technical manual,” [Online]. Available: http://pro.sony/en_GR/products/ptz-network-cameras/evi-d70-d70p-pal-