图像修复Criminisi算法我要分享

Image restoration Criminisi algorithm

matlab 算法 修复 图像 criminisi

关注次数: 328

下载次数: 2

文件大小: 9.74 kB

代码分类: 其他

开发平台: matlab

下载需要积分: 2积分

版权声明:如果侵犯了您的权益请与我们联系,我们将在24小时内删除。

代码描述

中文说明:应用背景基于样本块的纹理合成图像修复算法,经典算法Criminisi算法,能够修复灰度图像也能修复彩色图像,结合了C语言编程提高了代码的运行速度,附带测试图像,代码绝对没有问题,直接运行就可以用。关键技术 Criminisi算法的核心是一种等照度线驱动的图像采样过程。 首先,给定一幅输入图像,用户选定一个目标区域Ω,Ω将被移除并且填充。定义源区域Φ为整幅图像I减去目标区域,即Φ=I-Ω,源区域用来提供匹配块。接着,设置模板窗口的大小,默认大小为9*9,但在实际操作中需要比图像的最大纹理元稍大。一旦这些参数确定了,区域填充就可以自动进行了。在Criminisi算法中,每一个像素点都有一个颜色值(如果某处没有像素则为空)和一个置信度值。置信度反映了像素值的可信度,一旦某个像素被填充其置信度值就不能再改变。在算法进行的过程中,位于填充前沿的样本块会被赋予一个临时的优先权值。优先权决定了填充顺序。


English Description:

Application backgroundSample block texture synthesis and image inpainting algorithm based on, classical algorithm criminisi algorithm to gray-scale image inpainting can also repair color image, combined with the C language programming code running speed is improved, attached to the test image, the code does not have a problem absolutely, direct operation can be used to.Key TechnologyThe core of the Criminisi algorithm is a sample process of the image sampling process driven by equal illumination line..First, a given input image is selected for a target area, and the user will be removed and filled. The definition of the source area for the whole image with I minus the target area, namely Omega phi =I-, the source region to provide matching block. Next, the size of the template window is set, and the default size is 9*9, but the maximum texture element in the actual operation is slightly larger than the maximum texture element of the image. Onc


代码预览