I've discovered that the registration doesn't work if the images are preliminarily normalized by mean-std. MSE loss immediately falls to nan, NCC - to 0, and they do not ever change.
I'm not sure how you see the intended use of the library, but I'd say that working with mean-std normalized images is quite common.
Hi,
thank you very much for your report.
The problem here is in the center of mass calculation, with negative intensity values.
This should not affect other registration methods.
We will try to fix this issue.
Hi,
I've discovered that the registration doesn't work if the images are preliminarily normalized by mean-std. MSE loss immediately falls to nan, NCC - to 0, and they do not ever change.
I'm not sure how you see the intended use of the library, but I'd say that working with mean-std normalized images is quite common.
To reproduce, in https://github.com/airlab-unibas/airlab/blob/master/examples/affine_registration_3d.py change https://github.com/airlab-unibas/airlab/blob/master/examples/affine_registration_3d.py#L41-L43 to
and https://github.com/airlab-unibas/airlab/blob/master/examples/affine_registration_3d.py#L45-L48 to