Borrar filtros
Borrar filtros

How to use "imregister" with "InitialTransformation"?

5 visualizaciones (últimos 30 días)
Wei Zheng
Wei Zheng el 17 de Mzo. de 2022
Respondida: Steve Eddins el 24 de Mzo. de 2022
Hi everyone,
I try to use imregister with intialization:
% im: 3D image to be registered
% fixed: 3D Reference image
% [optimizer, metric] = imregconfig('monomodal');
% R_reg_old: an imreg3d object
[movingRegistered, R_reg] = imregister(im,fixed,'rigid',optimizer, metric,'InitialTransformation',R_reg_old);
But I get this error:
Error using imregtform>preparseSpatialRefObjects (line 492)
Expected spatial referencing arguments to be 2nd and 4th input arguments.
Error in imregtform>parseInputs (line 243)
[R_moving,R_fixed,varargin] = preparseSpatialRefObjects(varargin{:});
Error in imregtform (line 124)
parsedInputs = parseInputs(varargin{:});
Error in imregister (line 119)
tform = imregtform(varargin{:});
I checked the document of imregister: https://www.mathworks.com/help/images/ref/imregister.html
But I still don't understand why I got this error. Can anyone help me with this?
Thank you so much!

Respuesta aceptada

Steve Eddins
Steve Eddins el 24 de Mzo. de 2022
The value of InitialTransformation is supposed to be an affine3d object, not an imref3d object. See the doc description for the InitialTransformation input.

Más respuestas (0)

Productos


Versión

R2020b

Community Treasure Hunt

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

Start Hunting!

Translated by