ANTs icon indicating copy to clipboard operation
ANTs copied to clipboard

per metric mask

Open sdika opened this issue 9 years ago • 4 comments

Hi,

unless I missed something, it is not possible now to use one mask per metric (only one mask per stage is possible). Right know it seems I can specify a single mask that will be applied to all metric and a metric-wise (but global) weight.

I work on multimodality registration and I know that some of the modalities are better in some known region than other. So I would like to specify a different "weight image" for each metric.

For the command line syntax, the weight parameter that is already present in the metric specification could accept either a scalar or a weight image.

is it possible, to add this feature ?

Michaël

sdika avatar Sep 20 '16 07:09 sdika

I agree that the proposed modification would be useful for certain cases. And it's definitely possible. We can certainly leave this as a 'to-do' item but, honestly, the code overhaul would be quite extensive and so I don't foresee it getting done anytime soon.

ntustison avatar Sep 20 '16 14:09 ntustison

I completely understand thanks

sdika avatar Sep 20 '16 20:09 sdika

you can do a work around via the following observation :

if the metric is roughly linear then you can apply weights to the images directly.

e.g. w * < i - j, i -j > = < w * i - w * j, i - j >

would recommend working out the math but that's the basic idea

brian

On Tue, Sep 20, 2016 at 4:20 PM, sdika [email protected] wrote:

I completely understand thanks

— You are receiving this because you are subscribed to this thread. Reply to this email directly, view it on GitHub https://github.com/stnava/ANTs/issues/360#issuecomment-248421927, or mute the thread https://github.com/notifications/unsubscribe-auth/AATyfqBvZ42qYvtexoqJuEzK_0s6XR0Nks5qsEAcgaJpZM4KBUqF .

stnava avatar Sep 20 '16 20:09 stnava

that indeed works to incorporate the weight in the metric. However, the nonlinear deformation makes it problematic: w^2(x) || I(T(x)) - J(x) ||^2 = || w(x)I(T(x)) - w(x)J(x) ||^2

multiplication by w would approximate w(x)I(T(x)) by w(T(x))I(T(x)) for strong deformations, I don't think the approximation would be valid,

thanks anyway

sdika avatar Sep 20 '16 20:09 sdika