Multiple metrics and regularization

222 views
Skip to first unread message

Pablo A. Alvarez

unread,
Apr 7, 2021, 8:58:21 AM4/7/21
to elastix-imageregistration
Hello all,

I would like to use a combination of two image-based metrics and a regularization term for the elastic registration of CT lung images. This is defined in the elastix parameter file as follows:

(Registration "MultiMetricMultiResolutionRegistration")
(Metric "AdvancedNormalizedCorrelation" "AdvancedNormalizedCorrelation" "TransformBendingEnergyPenalty")

(FixedImagePyramid "FixedRecursiveImagePyramid" "FixedRecursiveImagePyramid")
(MovingImagePyramid "MovingRecursiveImagePyramid" "MovingRecursiveImagePyramid")
(ImageSampler "Random" "Random")
(Interpolator "BSplineInterpolator" "BSplineInterpolator")

I provide elastix with two moving images (-m0 -m1) and two fixed images (-f0 -f1) as well as the typical input/output parameters, but I obtain an error at execution:

Description: itk::ERROR: itk::ERROR: MultiMetricMultiResolutionRegistration(0000025A5C22BED0): The NumberOfInterpolators should equal 1 or equal the NumberOfMetrics

If I try to add interpolator, image sampler and image pyramid descriptions for the penalty term it gives me another error:

Description: itk::ERROR: itk::ERROR: FixedRecursivePyramid(000002A2B81755C0): Input Primary is required but not set.

After giving a quick glance at the code, I suspect that the combination of penalty terms and more than one image-based metric is not supported, but I didn't find this information in the manual.  

Can someone confirm if penalty terms can be used along more than one image-based metric in Elastix ?  

Best,

Pablo A. Alvarez

unread,
Apr 13, 2021, 8:57:54 AM4/13/21
to elastix-imageregistration
Hello all,

I have modified the source code (Elastix 5.0.1) to implement this multi metric with penalization feature. I just added some logic to count separately the "image based", "transformation based" and "point set based" metrics. This allows to check for the number of image pyramids and interpolators according to the specified metrics, since such components are needed only for the "image based" metrics. 

I am not sure if this has already been done in the develop branch. How should I proceed to share this code ? Should I create an issue or something in the git repository ?

Best,

M.St...@lumc.nl

unread,
Apr 19, 2021, 4:36:32 AM4/19/21
to elastix-imag...@googlegroups.com
Dear Pablo,

The best way would be to send a pull request on GitHub against the development branch. In case you have trouble doing so, perhaps Niels Dekker can be of assistance.

Best, Marius



From: elastix-imag...@googlegroups.com <elastix-imag...@googlegroups.com> on behalf of Pablo A. Alvarez <paba...@gmail.com>
Sent: 13 April 2021 2:57 PM
To: elastix-imageregistration
Subject: [elastix-imageregistration] Re: Multiple metrics and regularization
 
--
You received this message because you are subscribed to the Google Groups "elastix-imageregistration" group.
To unsubscribe from this group and stop receiving emails from it, send an email to elastix-imageregis...@googlegroups.com.
To view this discussion on the web visit https://groups.google.com/d/msgid/elastix-imageregistration/3dd51b00-1a12-4885-9e72-b1a783d10035n%40googlegroups.com.
Reply all
Reply to author
Forward
0 new messages