フィルターのクリア

Convolution in Fourier domain

2 ビュー (過去 30 日間)
Radmilka
Radmilka 2015 年 5 月 16 日
回答済み: Star Strider 2015 年 5 月 16 日
Hello! I wanna implement 2D convolution using fft2 in such way:
F=fft2(im2double(imread('cameraman.tif')));
H=fft2(fspecial('motion',15,5));
G=F.*H;
But F and H are not the same size.. How to do this correctly?

採用された回答

Star Strider
Star Strider 2015 年 5 月 16 日
One possibility would be to zero-pad the smaller image so it is the same size as the larger one.
From the documentation:
  • Y = fft2(X,m,n) truncates X, or pads X with zeros to create an m-by-n array before doing the transform. The result is m-by-n.

その他の回答 (0 件)

カテゴリ

Help Center および File ExchangeFourier Analysis and Filtering についてさらに検索

タグ

Community Treasure Hunt

Find the treasures in MATLAB Central and discover how the community can help you!

Start Hunting!

Translated by