The digging for existing functions and implementations regarding the non-linear volumetric morph, might turn out shorter than expected.
The basic functionality has already been implemented in DIPY, which is using the Symmetric Normalization (SyN) algorithm proposed by Avants et al. (2009).
Based on the provided example I tested the algorithm on two T1 weighted anatomical MRIs. Furthermore I tested how well the algorithm performs on arbitrarily distributed cubes in a larger otherwise empty cuboid. The volume that was needed to be morphed was (in this case) created by randomly shifting each cube’s location of the initial random volume slightly.
And here are the results:
While the red color indicates the moving volume, the green color represents the static. Hence the more areas are yellow the better (higher overlap). Each frame of the respective GIF represents a slice through the corresponding volume.
For both simulations it turns out, that the amount of overlap after morphing the “moving” volume towards the “static” volume increased. Hence a (non-linear) transformation to morph image landmarks towards each other was achieved.
Structural differences in my testing examples were quite significant (human head vs. random cubes), however the algorithm performed well in both scenarios.
I think that’s quite a good starter!
Let’s see what else is out there!
Avants, B. B., Epstein, C. L., Grossman, M., & Gee, J. C. (2009). Symmetric Diffeomorphic Image Registration with Cross- Correlation: Evaluating Automated Labeling of Elderly and Neurodegenerative Brain, 12(1), 26-41.