作者投稿和查稿 主编审稿 专家审稿 编委审稿 远程编辑

计算机工程 ›› 2006, Vol. 32 ›› Issue (24): 186-188. doi: 10.3969/j.issn.1000-3428.2006.24.067

• 人工智能及识别技术 • 上一篇    下一篇

基于递归的二值图像连通域像素标记算法

徐正光,鲍东来,张利欣   

  1. (北京科技大学信息工程学院,北京100083)
  • 收稿日期:1900-01-01 修回日期:1900-01-01 出版日期:2006-12-20 发布日期:2006-12-20

Pixel Labeled Algorithm Based on Recursive Method of Connecting Area in Binary Images

XU Zhengguang, BAO Donglai, ZHANG Lixin   

  1. (School of Information Engineering, University of Science and Technology Beijing, Beijing 100083)
  • Received:1900-01-01 Revised:1900-01-01 Online:2006-12-20 Published:2006-12-20

摘要:

在研究以前二值图像连通算法的基础上,提出了一种基于递归方法的二值图像连通域像素标记算法。通过对二值图像的扫描和分析可得到二值图像中的连通域划分和连通域的数目。算法主要包括两个步骤:对输入的二值图像进行一次扫描,得到所有目标像素的连通域划分和标记的等价对表;利用递归对等价对表进行分析,得到正确的连通标记划分和连通区域数目。实验结果表明,该算法对于任意复杂形状、任意数目(小于1 000)的连通区域都能正确检测。

关键词: 二值图像, 像素标记, 递归

Abstract:

On the foundation of studying former connecting area algorithms, the paper presents a pixel labeled algorithm based on recursive method of connecting area in binary images. The algorithm determines the distribution and count of connecting areas through once scanning of image. It mainly includes two steps in the algorithm. Firstly, scanning the input binary image is used to get the whole connecting labeled area and the equal marks list. The second step is to analyze the equal marks list by recursive method to ascertain the right distribution and count of connecting areas. Experiments show that it can exactly detect any connecting areas in binary images, which contains complicated shapes and random number (less than 1 000).

Key words: Binary image, Pixel labeling, Recursion