Journal of Computer Applications ›› 2018, Vol. 38 ›› Issue (4): 1111-1116.DOI: 10.11772/j.issn.1001-9081.2017082033

Previous Articles     Next Articles

Image inpainting algorithm based on pruning samples referring to four-neighborhood

MENG Hongyue1, ZHAI Donghai1,2, LI Mengxue1, CAO Daming1   

  1. 1. College of Information Science and Technology, Southwest Jiaotong University, Chengdu Sichuan 610097, China;
    2. College of Engineering, Tibet University, Lhasa Tibet 850000, China
  • Received:2017-08-21 Revised:2017-11-01 Online:2018-04-10 Published:2018-04-09
  • Supported by:
    This work is partially supported by the National Natural Science Foundation of China (61461048).


孟红月1, 翟东海1,2, 李梦雪1, 曹大命1   

  1. 1. 西南交通大学 信息科学与技术学院, 成都 610097;
    2. 西藏大学 工学院, 拉萨 850000
  • 通讯作者: 孟红月
  • 作者简介:孟红月(1993-),女,河南永城人,硕士研究生,主要研究方向:数字图像处理;翟东海(1974-),男,山西芮城人,副教授,博士,主要研究方向:数字图像处理、海量数据挖掘;李梦雪(1992-),女,重庆潼南人,硕士研究生,主要研究方向:数字图像处理;曹大命(1990-),男,河北沧州人,硕士研究生,主要研究方向:数字图像处理。
  • 基金资助:

Abstract: To inpaint the image with large damaged region and complex structure texture, a new method based on neighborhood reference priority which can not only maintain image character but also improve inpainting speed was proposed, by which the problem of image inpainting was translated into the best sample searching process. Firstly,the structure information of target image was extracted, and the sample region was divided into several sub-regions to reduce the sample size and the search scope. Secondly, in order to solve the problem that Sum of Squares of Deviations (SSD) method ignores the matching of structure information, structure symmetry matching constraint was introduced into matching method, which effectively avoided wrong matches and improves sample matching precision and searching efficiency. Then, priority formulas which highlights the effect of structure was obtained by introducing structure weight and confidence and combining the traditional priority calculation. Finally,the priority of four-neighborhood was got by computing overlapping information between target block and neighborhood blocks patches, according to the reliable reference information provided by four-neighborhood and the improved block matching method, the samples were pruned and the optimal sample was retrieved. The inpainting was completed until all the the optimal samples for all the target blocks were retrieved. The experimental results demonstrate that the proposed method can overcome the problems like texture blurring and structure dislocations and so on, the Peak Signal-to-Noise Ratio (PSNR) of the improved algorithm is increased by 0.5 dB to 1 dB compared with the contrast methods with speeding up inpainting process, the recovered image is much continuous for human vision. Meanwhile, it can effectively recover common damaged images and is more pervasive.

Key words: image inpainting, structure symmetry matching constraint, structure factor, four-neighborhood reference priority, pruning sample

摘要: 针对结构纹理信息较复杂、破损尺度较大的图像修复问题,提出一种既能保持图像特征又能提高修复速度的参照四邻域裁剪样本的修复算法,将图像修复问题转化为最佳样本的检索过程。首先,提取图像结构信息,并对图像进行区域划分以缩小样本的裁剪与检索范围;其次,为了改进离差平方和(SSD)方法对块的结构信息匹配的忽视,在像素块匹配计算中引入结构对称匹配约束,有效避免了误匹配,提高了图像块匹配精度及样本搜索效率;然后,通过引入结构因子和置信度,结合传统的优先权计算,得到突出结构作用的优先级公式;最后,利用目标块与四邻域块间的重叠区域计算四邻域参照优先级,并根据四邻域提供的可靠参照信息,依据改进的块匹配方法裁剪样本集并检索最佳样本块,直至所有目标块都检索匹配到最佳样本,完成修复。实验结果表明,该算法可以很好地解决纹理模糊和结构错位等问题,在提高图像修复速度的同时,所提算法修复效果的峰值信噪比(PSNR)比其他对比算法平均提高了0.5~1 dB,使得修复后的图像更好地满足视觉连通性,同时能高效地修复一般区域,具有更好的普适性。

关键词: 图像修复, 结构对称匹配约束, 结构因子, 四邻域参照优先级, 裁剪样本

CLC Number: