FFT - based Technique Simulation

2 ビュー (過去 30 日間)
software
software 2014 年 9 月 22 日
コメント済み: Roger 2016 年 4 月 23 日
i want to simulation of 'An FFT-Based Technique for Translation,Rotation, and Scale-Invariant Image Registration'. First of all, i tried to A(without Scale Change)for find out theta & translation (x0,y0), but i failed.
This is my code. plz advise me.
close all; clc; clear all;
im1 = imread('IU.jpg');
%making image
im01 = im1(1:400,1:400);
im02 = im1(50:449,30:429);
im02 = imrotate(im02,30);
im02 = imresize(im02,[400,400]);
imshow(im01)
figure,imshow(im02)
%Fourier transform
F1 = fft2(im01);
F2 = fft2(im02);
%magnitude
M1 = abs(F1);
M2 = abs(F2);
f1 = fft2(M1);
f2 = fft2(M2);
%cross power spectrum
cp = f1.*conj(f2)/abs(f1.*conj(f2));
mag = ifft(cp);
[x, y] = find(mag ==max(max(mag)))
  1 件のコメント
Roger
Roger 2016 年 4 月 23 日
did u figure out it now ?

サインインしてコメントする。

回答 (0 件)

Community Treasure Hunt

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

Start Hunting!

Translated by