harmonic_interpolation — 对图像区域执行谐波插值。
harmonic_interpolation(Image, Region : InpaintedImage : Precision : )
算子 harmonic_interpolation reconstructs the
destroyed image data of Image inside the region
Region by solving the discrete Laplace equation
for the corresponding
gray value function u. The unique solution, which exists under
Dirichlet boundary conditions given by Image outside of
Region, is returned in InpaintedImage。
This technique is called harmonic interpolation since in function theory the solutions of the Laplace equation are referred to as harmonic functions.
If Region touches the border of the gray value matrix of
Image and thus some Dirichlet boundary values do not exist,
von Neumann boundary conditions are used instead. This means that
the gray values are mirrored at the border of Image. If no
Dirichlet boundary values exist at all, a constant image with gray
value 0 is returned.
The spatial derivatives are discretized as
and
.
The equation is solved by an
iterative conjugate gradient solver, which iteratively improves the
computational error until the maximum norm of its update step
becomes a smaller fraction than Precision of the norm of
the input data or a maximum of 1000 iterations is
reached. Precision = 0.01 thus means a relative
computational accuracy of 1%.
请注意,若使用域缩减后的图像作为输入,滤波器算子可能会返回意外结果。请参阅 滤波器 一章
Image (输入对象) (multichannel-)image(-array) → object (byte / uint2 / real)
输入图像。
Region (输入对象) region → object
Inpainting region.
InpaintedImage (输出对象) image(-array) → object (byte / uint2 / real)
输出图像。
Precision (输入控制) real → (real)
Computational accuracy.
默认值: 0.001
建议值: 0.0, 0.0001, 0.001, 0.01
限制:
Precision >= 0.0
inpainting_ct,
inpainting_aniso,
inpainting_mcf,
inpainting_texture,
inpainting_ced
L.C. Evans; “Partial Differential Equations”; AMS, Providence;
1998.
W. Hackbusch; “Iterative Lösung großer schwachbesetzter
Gleichungssysteme”; Teubner, Stuttgart;1991.
基础