Citation: | Hou Zhiqiang, Zhao Mengqi, Yu Wangsheng, et al. Color image segmentation based on SLIC and watershed algorithm[J]. Opto-Electronic Engineering, 2019, 46(6): 180589. doi: 10.12086/oee.2019.180589 |
[1] | 高丽, 杨树元, 夏杰, 等.基于标记的watershed图像分割新算法[J].电子学报, 2006, 34(11): 2018-2023. doi: 10.3321/j.issn:0372-2112.2006.11.019 Gao L, Yang S Y, Xia J, et al. A new marker-based watershed algorithm[J]. Acta Electronica Sinica, 2006, 34(11): 2018-2023. doi: 10.3321/j.issn:0372-2112.2006.11.019 |
[2] | 卢中宁, 强赞霞.基于梯度修正和区域合并的分水岭分割算法[J].计算机工程与设计, 2009, 30(8): 2075-2077. Lu Z N, Qiang Z X. Watershed segmentation based on gradient modification and region merging[J]. Computer Engineering and Design, 2009, 30(8): 2075-2077. |
[3] | 余旺盛, 侯志强, 宋建军.基于标记分水岭和区域合并的彩色图像分割[J].电子学报, 2011, 39(5): 1007-1012. Yu W S, Hou Z Q, Song J J. Color image segmentation based on marked-watershed and region-merger[J]. Acta Electronica Sinica, 2011, 39(5): 1007-1012. |
[4] | Achanta R, Shaji A, Smith K, et al. SLIC superpixels compared to state-of-the-art superpixel methods[J]. IEEE Transactions on Pattern Analysis and Machine Intelligence, 2012, 34(11): 2274-2282. doi: 10.1109/TPAMI.2012.120 |
[5] | Ren X F, Malik J. Learning a classification model for segmentation[C]//Proceedings of the Ninth IEEE International Conference on Computer Vision, 2003: 10. |
[6] | Shi J B, Malik J. Normalized cuts and image segmentation[J]. IEEE Transactions on Pattern Analysis and Machine Intelligence, 2000, 22(8): 888-905. doi: 10.1109/34.868688 |
[7] | Felzenszwalb P F, Huttenlocher D P. Efficient graph-based image segmentation[J]. International Journal of Computer Vision, 2004, 59(2): 167-181. doi: 10.1023/B:VISI.0000022288.19776.77 |
[8] | Levinshtein A, Stere A, Kutulakos K N, et al. Turbopixels: fast superpixels using geometric flows[J]. IEEE Transactions on Pattern Analysis and Machine Intelligence, 2009, 31(12): 2290-2297. doi: 10.1109/TPAMI.2009.96 |
[9] | 赵宏伟, 何劲松.基于贝叶斯框架融合深度信息的显著性检测[J].光电工程, 2018, 45(2): 170341. doi: 10.12086/oee.2018.170341 Zhao H W, He J S. Saliency detection method fused depth information based on Bayesian framework[J]. Opto-Electronic Engineering, 2018, 45(2): 170341. doi: 10.12086/oee.2018.170341 |
[10] | 李旭旭, 李新阳, 王彩霞.哈特曼传感器子孔径光斑的局部自适应阈值分割方法[J].光电工程, 2018, 45(10): 170699. doi: 10.12086/oee.2018.170699 Li X X, Li X Y, Wang C X. Local adaptive threshold segmentation method for subapture spots of Shack-Hartmann sensor[J]. Opto-Electronic Engineering, 2018, 45(10): 170699. doi: 10.12086/oee.2018.170699 |
[11] | 刘辉, 石小龙.结合显著性和超像素改进的GrabCut图像分割[J].红外技术, 2018, 40(1): 55-61. Liu H, Shi X L. Improved GrabCut segmentation based on salience and superpixels[J]. Infrared Technology, 2018, 40(1): 55-61. |
[12] | 冈萨雷斯, 伍兹.数字图像处理[M]. 3版.北京:电子工业出版社, 2010. Gonzalez R C, Woods R E. Digital Image Processing[M]. 3rd ed. Beijing: Publishing House of Electronics Industry, 2010. |
[13] | Digabel H, Lantuéjoul C. Iterative algorithms[C]//Proc. 2nd European Symp. Quantitative Analysis of Microstructures in Material Science, Biology and Medicine. Riederer Verlag, 1978, 19(7): 8. |
[14] | Beucher S, Lantuéjoul C. Use of Watersheds in Contour Detection[C]//International workshop on image processing, real-time edge and motion detection. 1979: 391-396. |
[15] | 冀甜甜, 崔嘉, 董新锋, 等.结合分水岭的纹理梯度各向异性图像分割[J].中国图象图形学报, 2017, 22(7): 926-934. Ji T T, Cui J, Dong X F, et al. Image segmentation by combining the watershed algorithm and anisotropic texture gradients[J]. Journal of Image and Graphics, 2017, 22(7): 926-934. |
[16] | 沈夏炯, 吴晓洋, 韩道军.分水岭分割算法研究综述[J].计算机工程, 2015, 41(10): 26-30. Shen X J, Wu X Y, Han D J. Survey of research on watershed segmentation algorithms[J]. Computer Engineering, 2015, 41(10): 26-30. |
[17] | Bai M, Urtasun R. Deep watershed transform for instance segmentation[C]//Proceedings of 2017 IEEE Conference on Computer Vision and Pattern Recognition, 2017: 2858-2866. |
[18] | 张学文.组成论[M].合肥:中国科学技术大学出版社, 2003. Zhang X W. The Constitution Theory[M]. Hefei: China University of Science and Technology Press, 2003. |
[19] | 吴一全, 张金矿.二维直方图θ划分最大Shannon熵图像阈值分割[J].物理学报, 2010, 59(8): 5487-5495. Wu Y Q, Zhang J K. Image thresholding based on θ-division of 2-D histogram and maximum Shannon entropy[J]. Acta Physica Sinica, 2010, 59(8): 5487-5495. |
[20] | Haralick R M, Shanmugam K, Dinstein I. Textural features for image classification[J]. IEEE Transactions on Systems, Man, and Cybernetics, 1973, SMC-3(6): 610-621. doi: 10.1109/TSMC.1973.4309314 |
[21] | 王崴, 王晓军, 刘晓卫, 等.基于图像复杂度的图像分割算法[J].探测与控制学报, 2015, 37(3): 5-9. Wang W, Wang X J, Liu X W, et al. Image segmentation algorithm based on image complexity[J]. Journal of Detection & Control, 2015, 37(3): 5-9. |
[22] | Martin D, Fowlkes C, Tal D, et al. A database of human segmented natural images and its application to evaluating segmentation algorithms and measuring ecological statistics[C]//Proceedings of the 8th IEEE International Conference on Computer Vision, 2001. |
[23] | 王小鹏, 郝重阳, 樊养余, 等.一种提取图象细节边缘的新方法[J].中国图象图形学报, 2003, 8(11): 1286-1290. Wang X P, Hao C Y, Fan Y Y, et al. New method for image detail edge extraction[J]. Journal of Image and Graphics, 2003, 8(11): 1286-1290. |
[24] | Hodneland E, Tai X C, Kalisch H. PDE based algorithms for smooth watersheds[J]. IEEE Transactions on Medical Imaging, 2016, 35(4): 957-966. doi: 10.1109/TMI.42 |
[25] | Kavzoglu T, Tonbul H. A Comparative study of segmentation quality for multi-resolution segmentation and watershed transform[C]//Proceedings of IEEE 8th International Conference on Recent Advances in Space Technologies, 2017. |
[26] | 王勋, 查宇飞, 毕笃彦. 基于多分辨率分析和分水岭的图像分割方法[J]. 光电工程, 2007, 34(6): 72–76. Wang X, Zha Y F, Bi D Y. Image segmentation based on multi-resolution analysis and watershed algorithm[J]. Opto-Electronic Engineering, 2007, 34(6): 72-76. |
Overview: Image segmentation is the first step in image processing, and plays an important role in image subsequent processing. The quality of feature extraction, target recognition and target detection all depend on the effect of image segmentation. Image segmentation has become a research hotspot and difficulty due to the changes of illumination and scale, the effects of noise and the problems of image itself. At present, image segmentation algorithms mainly include region-based segmentation algorithm, edge-based segmentation algorithm, threshold-based segmentation algorithm, and clustering-based segmentation algorithm. The watershed segmentation algorithm is a typical algorithm based on region segmentation. It has the characteristics of simple implementation, good performance and strong contour extraction ability, but the image over-segmentation problem is more serious. The SLIC algorithm is a super-pixel segmentation algorithm based on gradient rise. It has a faster processing speed, and the super-pixel block can fit the boundary of the target well, and can obtain super-pixel blocks with the same shape and size, but cannot segment the target area, which increases the difficulty for subsequent processing. In order to solve the over-segmentation problem caused by the traditional watershed segmentation algorithm and other existing algorithms(large data processing capacity and low operation efficiency), as well as the problem that the SLIC cannot segment the target region, an image segmentation algorithm based on SLIC algorithm and watershed algorithm is proposed. Firstly, a method of calculating the number of super pixels in the SLIC algorithm is proposed, which used the image complexity and image size to calculate the number of super-pixels pre-segmented, and then used the SLIC segmentation method to pre-process the original image for super-pixel segmentation to reduce redundant information in subsequent processing; Then, a method of adaptively calculating the threshold using mean and variance was proposed to perform threshold processing on the gradient image of the image to effectively remove noise and obtain more complete contour information. Finally, the image was extracted from the minimum value mark to obtain the marked image, and the image was segmented by the watershed segmentation algorithm to obtain the final segmentation image. The algorithm can effectively solve the over-segmentation problem generated by the traditional watershed algorithm. Through the statistical analysis experiment of 500 images in the Berkeley database, and the real local consistency error rate and global consistency error of 100 images and the ground truth are calculated. The fractional rate is eventually found to be better than the traditional algorithms and other marking algorithms, and the ideal segmentation effect is obtained.
Simulated precipitation model
Simulated flooding model
Comparison of segmentation results of the method with different K value.(a0), (b0) Original image; (a1) K=100; (a2) K=320;(a3) K=255;(b1) K=5;(b2) K=120;(b3) K=53
Effect of threshold on image segmentation.(a0), (b0) Original image; (a1), (b1) Manual labeling; (a2), (b2) n=3; (a3), (b3) n=4; (a4), (b4) n=5
Algorithm flowchart
Comparison of segmentation experimental results.(a0)~(d0) Original image; (a1)~(d1) Watershed segmentation algorithm results without SLIC preprocessing segmentation; (a2)~(d2) Ref.[1] algorithm segmentation results; (a3)~(d3) Ref.[3] algorithm segmentation results; (a4)~(d4) Algorithm segmentation results; (a5)~(d5) Berkeley image manual annotation segmentation results provided by the database
Evaluation index of segmentation algorithms
Average evaluation index of segmentation algorithms