朱德利, 陈兵旗, 杨雨浓, 梁习卉子, 杨明, 乔妍. 苹果采摘机器人视觉系统的暗通道先验去雾方法[J]. 农业工程学报, 2016, 32(16): 151-158. DOI: 10.11975/j.issn.1002-6819.2016.16.021
    引用本文: 朱德利, 陈兵旗, 杨雨浓, 梁习卉子, 杨明, 乔妍. 苹果采摘机器人视觉系统的暗通道先验去雾方法[J]. 农业工程学报, 2016, 32(16): 151-158. DOI: 10.11975/j.issn.1002-6819.2016.16.021
    Zhu Deli, Chen Bingqi, Yang Yunong, Lianxi Huizi, Yang Ming, Qiao Yan. Method of haze-removal based on dark channel prior in visual system of apple harvest robot[J]. Transactions of the Chinese Society of Agricultural Engineering (Transactions of the CSAE), 2016, 32(16): 151-158. DOI: 10.11975/j.issn.1002-6819.2016.16.021
    Citation: Zhu Deli, Chen Bingqi, Yang Yunong, Lianxi Huizi, Yang Ming, Qiao Yan. Method of haze-removal based on dark channel prior in visual system of apple harvest robot[J]. Transactions of the Chinese Society of Agricultural Engineering (Transactions of the CSAE), 2016, 32(16): 151-158. DOI: 10.11975/j.issn.1002-6819.2016.16.021

    苹果采摘机器人视觉系统的暗通道先验去雾方法

    Method of haze-removal based on dark channel prior in visual system of apple harvest robot

    • 摘要: 针对雾霾严重气候条件下苹果采摘机器人视觉定位困难的问题,提出一种把暗通道先验(dark channel prior,DCP)原理应用于苹果图像去雾的调参和改进方法。给出了一种获取大气光系数A的方法,首先把计算得到的暗通道图结果存入矩阵,求暗通道图中的前1/1 000个最大元素所在位置,并存储在与暗通道矩阵相同大小的新矩阵中;根据新矩阵中的位置信息获得R通道矩阵相应位置的值,最后求取这些值的平均值作为A的取值。根据工程需要,该研究取去雾强度ω恒为1。通过与多尺度Retinex(multiscale retinex,MSR)方法、自适应直方图均衡化(adaptive histogram equalization,AHE)等常规方法以及其他文献的暗通道去雾使用方法进行对比试验,结论是该文的方法能获得更好的主观视觉效果。在结果图像的对比度方面,该研究使用的方法能得到平均对比度64.04,与计算速度较快的直方图均衡化方法的35.46相比,提升了81%;R通道对比度为68.525,与直方图均衡化方法得到的R通道对比度36.425相比提升了88%;该方法得到的图像直方图整体上呈现中间高两边低的形状特点,表明相对其他去雾方法,该文的方法能得到较好的去雾图像质量。时间复杂度方面,改进后的DCP方法计算640?480的图像耗时在33~37 ms之间,基本能满足实时要求。分割定位精确度方面,该文方法的综合定位精度为94.8%,高于其他方法。试验证明使用该文方法能在去雾的效率和性能方面得到较好的平衡,是一种可以用于实际采摘作业的可行方法。

       

      Abstract: Abstract: It is difficult to locate the apple in fog and haze environment for apple harvest robot. This paper proposed a new method to apply the principle of DCP (dark channel prior) to remove fog and haze on images which were collected from apple orchard. We adopted a new route to achieve the value of atmospheric light coefficient. Scan the hazed image with a 15×15 window, and get the smallest value of the 225 pixels from every window. All the smallest values constituted a dark channel image. The values of dark channel were stored in a matrix at the first step, and then the 1/1000 largest elements and their locations were calculated and stored in a new matrix which had the same shape with the dark channel matrix. Extract the matrix of red (R) channel of the hazed image at the next step. At the third step, the corresponding values in the matrix of R channel were obtained according to the position information in the new matrix. Finally, the average value of these values was calculated as the value of atmospheric light coefficient. According to the requirement of apple harvest robot, we took the haze-removal strength parameter of DCP algorithm as 1. In order to speed up the running of the algorithm, we calculated the transmission radio with guided filter. Image segmentation method used in the study had 3 stages: binaryzation, de-noising and dilation. Firstly, the grey image was obtained by calculating a special linear combination with red (R) channel, green (G) channel and blue (B) channel. This method emphasized the value of red channel in color images, which was conducive to separate the apple better at the next step. Secondly, binary image was obtained by Otsu method based on the grey image. Finally, after the process of de-noising and dilation, a better segmentation results could be obtained. We developed an experimental software with Microsoft Vision Studio 2010 and OpenCV (Open Source Computer Vision Library) to test the haze-removal effects in apple harvest robot vision system. The graphical user interface of the program was developed based on MFC (Microsoft Foundation Classes) library. The software had achieved the following functions: reading the image, calculating the dark channel value, calculating the value of atmospheric light coefficient based on the R channel, calculating the transmission radio, and so on. Based on this software we compared some haze-removal methods including MSR (multiscale retinex), AHE (adaptive histogram equalization) and DCP with different parameters. Hardware platform of the experiment was X230, which is a notebook computer produced by Lenovo Inc. We took Nikon D7100 camera as the image acquisition equipment and fixed it with tripod when it worked. Experimental images were collected at the apple base in Changping District of Beijing. Image acquisition dates were some days with heavy fog and haze in November 2015. Twelve images were selected as the experimental materials. After the analysis of the experimental data, this paper got the following results: 1) The average contrast value of the images was 64.04 with our method; the AHE method was faster, but the contrast value was 35.46 with the AHE; the histogram obtained by our method had the characteristics of Gaussian distribution, which showed that our method could get better image quality; 2) Testing the 640×480 images pixels, our method required 36.46 ms computing time, the MSR method required 126.43 ms, and the AHE required 28.58 ms. The time performance of our method was not as good as the AHE, but it was better than the MSR; 3) The average location accuracy was 94.8% with our method, which was higher than other methods. The experiments show that our method can get better balance between efficiency and performance. It is a feasible method for the actual apple harvest operation.

       

    /

    返回文章
    返回