Image convolution kernel inverse filter output

Does anyone have an idea how to calculate the inversion of a two-dimensional filter?

Let's say I have a 3x3 filter:
0 1 0
1 1 1
0 1 0
I want to find it inverse. This is easy to do using DFT. But let me say that I want to make it a convolution. Now, what a problem, Matlab symbolism is not my specialty. Assuming there a 3X3 inverse filter, this means that the convolution of the two will lead to: 0 0 0
0 1 0
0 0 0
The task is to create the correct system of equations for it and solve it. It’s easy to think with symbols, but I couldn’t do it.

Any ideas? Thank.

PS I'm not sure if there is an inverse filter for this, since it has zeros in DTFT.

In addition, someone should enable Latex in this forum, like MathOverflow.

+3
source share
5 answers

The output of the inverse kernel of this two-dimensional convolution kernel

This is basically a generalization of the issue - obtaining an inverse filter for the convolution kernel of an image .

Formulation of the problem

For a given convolution kernel $ f \ in \ mathbb {R} ^ {m \ times n} $, find your inverse kernel, $ g \ in \ mathbb {R} ^ {p \ times q} $ for which $ f \ ast g = h = \ delta $.

Decision i

You can build the matrix form of the convolution operator.
The Matrix form can duplicate various image filtering modes (exclusive):

  • ( ).
    • .

    • / . .

    • ( ).
      .

    • .
    • - $\left (m + p - 1\right)\times\left (n + q - 1\right) $.

    • ("").

    • - .

, .
Convolution Matrix ( "Same"), .

, , - .
, ( ), .
, , , ( ).

II

:

$$\arg\min_ {g}\frac {1} {2} {\ left\| f\ast g - h\right\|} _ {2} ^ {2} $$

:

$$\frac {\ part\frac {1} {2} {\ left\| f\ast g - h\right\|} _ {2} ^ {2}} {\ g} = f\star\left (f\ast g - h\right) $$

$\star $ - .

full ( MATLAB).
:

hObjFun     = @(mG) 0.5 * sum((conv2(mF, mG, 'full') - mH) .^ 2, 'all');
mObjFunGrad = conv2(conv2(mF, mG, 'full') - mH, mF(end:-1:1, end:-1:1), 'valid');

, mF Correaltion valid ( Adjoint/Transpose β†’ output ).

:

for ii = 1:numIteraions
    mObjFunGrad = conv2(conv2(mF, mG, 'full') - mH, mF(end:-1:1, end:-1:1), 'valid');
    mG          = mG - (stepSize * mObjFunGrad);
end

StackOverflow Q2080835 GitHub Repository.

0

h [n] - 1D-. ? FIR.

. H (omega) G (omega) = 1 omega, H - DTFT h [n], G - DTFT g [n]. h [n] FIR, g [n] IIR.

, IIR -. , (LMS). IIR. .

, , . , , , , FIR FIR. , , , .

EDIT: y [n] = b0 x [n-0] + b1 x [n-1] +... + bN x [n-N]. , y - , x - . , : h [n] = b0 d [n-0] + b1 d [n-1] +... + bN d [n-N]. N + 1.

, x - , y - . d [n] = b0 h [n] + b1 h [n-1] +... + bN h [n-N]. , b0 h [n] = d [n] - b1 h [n-1] -... - bN h [n-N].

, b0 bN . m, h [m] , h [m + N] . , . .

. - , . , . ; .

2: "". , - .

+4

http://en.wikipedia.org/wiki/Wiener_deconvolution, , fudge: 1/H (w) H (w)/(abs (H (w)) ^ 2 + c), H (w) - h (x) ( 2- , ), "w" - . .

+3

( , , , ), .

H (w) G (w) = 1/H (w), - (h [n] ) -DFT . , ( ), , . . Widrow and Stearn Adaptive Signal Processing.

+1

- , () .

, 1D [1, -1], , .

1 -1 .

. - 1 . , .

+1

Source: https://habr.com/ru/post/1728810/


All Articles