[ITK] update dynamically images in the registration pipeline
Timothee Evain
tevain at telecom-paristech.fr
Thu Jun 23 07:37:28 EDT 2016
Hello François,
One solution for you could be to create your own cost function to optimize through an itk optimizer.
In your case, the comparison between the two mesh-based images and fixed images seems quite easy so you should be able to have a single-valued cost function.
You can find examples of custom CFs in the optimizers tests, like here : https://github.com/InsightSoftwareConsortium/ITK/blob/master/Modules/Numerics/Optimizers/test/itkRegularStepGradientDescentOptimizerTest.cxx
It basically consist in redefining the GetValue and GetDerivative methods, the later being used in some optimizers which need access to derivatives (like the gradient descent).
Then, you just have to plug this custom function to an ordinary itk optimization pipeline to get your best transformation.
HTH,
Tim
----- Mail original -----
De: "Francois GIRINON" <Francois.GIRINON at ensam.eu>
À: community at itk.org
Envoyé: Jeudi 23 Juin 2016 11:55:36
Objet: [ITK] update dynamically images in the registration pipeline
Hello everyone,
I'd like to suit the registration pipeline to a particular use:
1) I have two fixed target images
2) I have an itk transform which generates an itk mesh, and from this mesh two images are dynamically generated
3) Using the metric methods of ITK I want to optimize the above transform parameters to minimize the metric
As a matter of fact, I don't really need any interpolation method since the generated images already have the same resolution and size. However I can still use a nearest-neighbor interpolation if required.
The real question is where and how to update the dynamically generated images ?
One of my ideas was to create a kind of wrapper like https://itk.org/Doxygen/html/classitk_1_1ObjectToObjectMultiMetricv4.html and starting the GetValue method with an update of my images. The problem is more about the GetValueAndDerivative which I guess tries to evaluate the metric for closest parameters values. I don't know here where should I put my update method.
Thanks!
François.
_______________________________________________
Community mailing list
Community at itk.org
http://public.kitware.com/mailman/listinfo/community
More information about the Community
mailing list