ANTs icon indicating copy to clipboard operation
ANTs copied to clipboard

Feature Request: Generalize masking option into a weighting option for registration

Open gdevenyi opened this issue 3 years ago • 7 comments

Hard edge masks require the masks to be as-near-to-possible to perfect to perform optimally for guiding registrations.

If instead the masks were considered as a weight option (if say the masks contain a distribution of values 0-1) then one could do something like blur the mask so the edges are now a gradient which relaxes the perfection requirement some.

There are likely option useful things I can't think of that would benefit from weights.

gdevenyi avatar Oct 21 '22 16:10 gdevenyi

I had asked about this sometime ago (can't find the issue, maybe an email), but was told it was not easy to implement. I agree, would be great to have weighted masks, it would open the way to all sorts of masks derived from various scenarios. It would also need some heavy testing of how they can be used (i.e., would fading the bran edge impair gyral registration compared to a binary mask).

dorianps avatar Oct 21 '22 17:10 dorianps

This would require significant changes to the ITK image metrics. As they are currently written, the masks dictate which voxels are used for computation---a binary proposition, hence the hard masks as input. As such, this feature request should be made over on the ITK side. I would recommend closing this issue here and opening it over there.

ntustison avatar Oct 21 '22 18:10 ntustison

@gdevenyi are you using binary masks as fixed and moving images? Or you're saying binary masks with -x causes the registration to align mask boundaries?

cookpa avatar Oct 21 '22 18:10 cookpa

What I'm proposing is the -x option generalize to floating point numbers to weight the registration rather than an include/exclude

gdevenyi avatar Oct 21 '22 20:10 gdevenyi

We understand the proposal and indeed we designed the system to allow this however we would have to introduce new standards and as Nick said this would go back to ITK

On Fri, Oct 21, 2022 at 4:42 PM Gabriel A. Devenyi @.***> wrote:

What I'm proposing is the -x option generalize to floating point numbers to weight the registration rather than an include/exclude

— Reply to this email directly, view it on GitHub https://github.com/ANTsX/ANTs/issues/1437#issuecomment-1287418037, or unsubscribe https://github.com/notifications/unsubscribe-auth/AACPE7XGNX6LMPF44BOGZWDWEL5ZZANCNFSM6AAAAAARLKCSE4 . You are receiving this because you are subscribed to this thread.Message ID: @.***>

--

brian

stnava avatar Oct 21 '22 21:10 stnava

Got it @stnava I missed your earlier comment. I'll move this up to ITK

gdevenyi avatar Oct 21 '22 22:10 gdevenyi

Upstreamed, https://github.com/InsightSoftwareConsortium/ITK/issues/3704

gdevenyi avatar Oct 22 '22 18:10 gdevenyi