registration of two images i done but it required more execution time, please provide another code?

2 vues (au cours des 30 derniers jours)
% Image Registration
clc;
clear all;
close all;
fixed = imread('high.jpg');
% figure(),imshow(fixed);
moving = imread('low.jpg');
figure, imshowpair(moving, fixed, 'montage')
title('Unregistered');
[optimizer,metric] = imregconfig('multimodal');
movingRegisteredDefault = imregister(moving, fixed, 'affine', optimizer, metric);
% % figure, imshowpair(movingRegisteredDefault, fixed);
% title('A: Default registration');
% disp(optimizer);
% disp(metric);
optimizer.InitialRadius = optimizer.InitialRadius/3.5;
movingRegisteredAdjustedInitialRadius = imregister(moving, fixed, 'affine', optimizer, metric);
% figure, imshowpair(movingRegisteredAdjustedInitialRadius, fixed);
% title('Adjusted InitialRadius');
optimizer.MaximumIterations = 300;
movingRegisteredAdjustedInitialRadius300 = imregister(moving, fixed, 'affine', optimizer, metric);
% figure, imshowpair(movingRegisteredAdjustedInitialRadius300, fixed)
% title('B: Adjusted InitialRadius, MaximumIterations = 300, Adjusted InitialRadius.');
tformSimilarity = imregtform(moving,fixed,'similarity',optimizer,metric);
Rfixed = imref2d(size(fixed));
movingRegisteredRigid = imwarp(moving,tformSimilarity,'OutputView',Rfixed);
% figure, imshowpair(movingRegisteredRigid, fixed);
tformSimilarity.T
movingRegisteredAffineWithIC = imregister(moving,fixed,'affine',optimizer,metric,...
'InitialTransformation',tformSimilarity);
figure(),
imshowpair(movingRegisteredAffineWithIC, fixed)
imwrite(movingRegisteredAffineWithIC,'Regi.jpg');

Réponse acceptée

Matt J
Matt J le 7 Avr 2015
There are lots of registration routines offered on the File Exchange that you could browse,

Plus de réponses (0)

Catégories

En savoir plus sur Geometric Transformation and Image Registration dans Help Center et File Exchange

Community Treasure Hunt

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

Start Hunting!

Translated by