Design of Adaptive Video Image Dehazing Algorithm and FPGA Accelerated Implementation
-
摘要: 该文提出了一种自适应图像去雾算法,充分考虑不同复杂场景下的图像特征,建立了算法的自适应机制。该机制包含对图像是否有雾、是否为天空区域、滤波器尺寸等的自适应调整,解决了传统图像去雾算法在深度断层处可能产生的光晕效应等问题。该文同时对上述自适应图像去雾算法进行FPGA加速实现,实验结果表明,该文算法在XC7K325T型号FPGA视频处理平台上可以满足对1080P@60Hz视频去雾的实时性要求。对于大多数轻雾或浓雾场景,该文算法去雾后图像色彩自然无过饱和,全局对比度和饱和度提升比率均值为0.309和0.994,相比于本领域其他去雾算法优势明显。Abstract: This paper proposes an adaptive image dehazing algorithm, which fully considers the image features in different complex scenes and establishes an adaptive mechanism of the algorithm. The mechanism includes adaptive adjustments to whether the image is foggy, whether it is a sky area, or filter size, etc., which solves the bad effect that the traditional algorithm may cause when dehazing the depth mutation region. This article also implements FPGA acceleration for the adaptive image dehazing algorithm. Experimental results show that the algorithm can meet the real-time requirements of 1080P@60Hz video dehazing on XC7K325T FPGA video processing platform. For most light fog or heavy fog scenes, the image color of this algorithm is naturally free of oversaturation after dehazing. The average global contrast and saturation enhancement ratio are 0.309 and 0.994, which has obvious advantages compared with other dehazing algorithms in the field.
-
Key words:
- Video dehaze /
- Adaptive mechanism /
- Real-time dehaze /
- Implementation on FPGA
-
表 1 自适应图像去雾算法的有雾与否判定
图片种类 测试数量 判定需要去雾 判定无需去雾 准确率(%) 无雾图 50 1 49 98 薄雾图 50 46 4 92 浓雾图 50 49 1 98 总体 150 ╲ ╲ 96 表 2 原始图像去雾后评价指标统计
表 3 自适应图像去雾算法加速和硬件加速对比
分辨率 He[3](CPU) 本文算法(CPU) 本文算法(FPGA) 800×463 1090 220 (4.9X) 2.85 (382X) 1200×800 2960 500 (5.9X) 7.4 (400X) 1920×1080 6393 1080 (5.9X) 16 (399X) -
[1] ZHU Qingsong, MAI Jiaming, and SHAO Ling. A fast single image haze removal algorithm using color attenuation prior[J]. IEEE Transactions on Image Processing, 2015, 24(11): 3522–3533. doi: 10.1109/TIP.2015.2446191 [2] 汤勇明, 张圣清, 陆佳华. 搭建你的数字积木: 数字电路与逻辑设计(Verilog HDL&Vivado版)[M]. 北京: 清华大学出版社, 2017: 12.TANG Yongming, ZHANG Shengqing, and LU Jiahua. Build Your Digital Blocks: Digital Circuits and Logic Design Using Verilog HDL & Vivado[M]. Beijing: Tsinghua University Press, 2017: 12. [3] HE Kaiming, SUN Jian, and TANG Xiaoou. Single image haze removal using dark channel prior[J]. IEEE Transactions on Pattern Analysis and Machine Intelligence, 2011, 33(12): 2341–2353. doi: 10.1109/TPAMI.2010.168 [4] TAN R T. Visibility in bad weather from a single image[C]. 2008 IEEE Conference on Computer Vision and Pattern Recognition, Anchorage, USA, 2008: 1–8. [5] 杨爱萍, 王南, 庞彦伟, 等. 人工光源条件下夜间雾天图像建模及去雾[J]. 电子与信息学报, 2018, 40(6): 1330–1337. doi: 10.11999/JEIT170704YANG Aiping, WANG Nan, PANG Yanwei, et al. Nighttime haze removal based on new imaging model with artificial light sources[J]. Journal of Electronics &Information Technology, 2018, 40(6): 1330–1337. doi: 10.11999/JEIT170704 [6] SHIAU Y H, CHEN P Y, YANG H Y, et al. Weighted haze removal method with halo prevention[J]. Journal of Visual Communication and Image Representation, 2014, 25(2): 445–453. doi: 10.1016/j.jvcir.2013.12.011 [7] 杨燕, 王志伟. 基于均值不等关系优化的自适应图像去雾算法[J]. 电子与信息学报, 2020, 42(3): 755–763. doi: 10.11999/JEIT190368YANG Yan and WANG Zhiwei. Adaptive image dehazing algorithm based on mean unequal relation optimization[J]. Journal of Electronics &Information Technology, 2020, 42(3): 755–763. doi: 10.11999/JEIT190368 [8] ENGIN D, GENÇ A, and EKENEL H K. Cycle-Dehaze: Enhanced CycleGAN for single image dehazing[C]. Proceedings of the 2018 IEEE/CVF Conference on Computer Vision and Pattern Recognition Workshops, Salt Lake City, USA, 2018: 938–946. [9] ZHU Junyan, PARK T, ISOLA P, et al. Unpaired image-to-image translation using cycle-consistent adversarial networks[C]. 2017 IEEE International Conference on Computer Vision (ICCV), Venice, Italy, 2017: 2242–2251. [10] CAI Bolun, XU Xiangmin, JIA Kui, et al. DehazeNet: An end-to-end system for single image haze removal[J]. IEEE Transactions on Image Processing, 2016, 25(11): 5187–5198. doi: 10.1109/TIP.2016.2598681 [11] LI Boyi, PENG Xiulian, WANG Zhangyang, et al. An all-in-one network for dehazing and beyond[J]. arXiv:1707.06543, 2017. [12] REN Wenqi, MA Lin, ZHANG Jiawei, et al. Gated fusion network for single image dehazing[C]. 2018 IEEE/CVF Conference on Computer Vision and Pattern Recognition, Salt Lake City, USA, 2018: 3253–3261. [13] ZHANG He and PATEL V M. Densely connected pyramid dehazing network[C]. 2018 IEEE/CVF Conference on Computer Vision and Pattern Recognition, Salt Lake City, USA, 2018: 3194–3203. [14] MIDDLETON W E K. Vision Through the Atmosphere[M]. Toronto: University of Toronto Press, 1952. [15] HE Kaiming, SUN Jian, and TANG Xiaoou. Guided image filtering[C]. Proceedings of the 11th European Conference on Computer Vision, Heraklion, Greece, 2010: 1–14. [16] 刘晟. FPGA静态时序约束的策略研究及探讨[J]. 通信技术, 2019, 52(8): 2038–2043. doi: 10.3969/j.issn.1002-0802.2019.08.042LIU Sheng. Strategy research and discussion on FPGA static timing constraints[J]. Communications Technology, 2019, 52(8): 2038–2043. doi: 10.3969/j.issn.1002-0802.2019.08.042