ANTs icon indicating copy to clipboard operation
ANTs copied to clipboard

Update field smoothing in SyN

Open m-albert opened this issue 5 years ago • 9 comments

Hi,

generally SyN is working great for me. I have a quick question related to its fine tuning:

How is the update field convolution kernel size determined? Should (and can) I optimise it depending on my desired regularisation behavior?

Thanks a lot in advance! Cheers, Marvin

m-albert avatar Mar 21 '19 13:03 m-albert

How is the update field convolution kernel size determined?

The options for SyN are

SyN[gradientStep,<updateFieldVarianceInVoxelSpace=3>,<totalFieldVarianceInVoxelSpace=0>]

The convolution kernel for both the update and total field variance are specified in terms of the radius in voxel space.

Should (and can) I optimise it depending on my desired regularisation behavior?

Yes.

ntustison avatar Mar 21 '19 14:03 ntustison

Thanks for the quick answer @ntustison !

Sorry, I knew about this setting and should have been more precise in my question. Here's the longer version: I'm wondering whether it makes sense to customise how the update field varies depending on the resolution level.

Namely, using a python implementation of SyN (nipy.org/dipy) I found that I get better results for low target variances when starting out with higher variances (higher than the scaling coming from units given in voxels). So far so good. However, in some cases I get seemingly inconsistent behaviour when changing the variance within the same registration call (the metric can increase its value dramatically).

Therefore I was wondering whether anything in the SyN formulation would disallow me to freely play with the update field variance?

Thanks a lot again!

m-albert avatar Mar 21 '19 14:03 m-albert

I'm wondering whether it makes sense to customise how the update field varies depending on the resolution level. Therefore I was wondering whether anything in the SyN formulation would disallow me to freely play with the update field variance?

Sure, you can do that.

Namely, using a python implementation of SyN (nipy.org/dipy)...

Just one word of caution---implementing SyN is not straightforward so I wouldn't necessarily attribute differences in performance strictly to visible parameter choices. In fact, I would get guidance on usage directly from the authors of that implementation.

ntustison avatar Mar 21 '19 14:03 ntustison

yea and you can also use: https://github.com/ANTsX/ANTsPy

brian

On Thu, Mar 21, 2019 at 10:44 AM Nick Tustison [email protected] wrote:

I'm wondering whether it makes sense to customise how the update field varies depending on the resolution level. Therefore I was wondering whether anything in the SyN formulation would disallow me to freely play with the update field variance?

Sure, you can do that.

Namely, using a python implementation of SyN (nipy.org/dipy)...

Just one word of caution---implementing SyN is not straightforward so I wouldn't necessarily attribute differences in performance strictly to visible parameter choices. In fact, I would get guidance on usage directly from the authors of that implementation.

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

stnava avatar Mar 21 '19 14:03 stnava

Just one word of caution...

You're right, thanks!

yea and you can also use: https://github.com/ANTsX/ANTsPy

Wow, will check it out. Thanks!

m-albert avatar Mar 22 '19 09:03 m-albert

A followup regarding this discussion:

Does updateFieldVarianceInVoxelSpace and totalFieldVarianceInVoxelSpace refer to the voxels of the currently subsampled space? i.e. If I am at shrink 8, and updateFieldVarianceInVoxelSpace=3 is that 3*8 voxels of the original resolution?

gdevenyi avatar Mar 22 '19 12:03 gdevenyi

If I am at shrink 8, and updateFieldVarianceInVoxelSpace=3 is that 3*8 voxels of the original resolution?

No, that value maintains for every resolution level.

ntustison avatar Mar 22 '19 14:03 ntustison

Okay to be really super clear :)

If I have a 1mm iso fixed-space, and I set updateFieldVarianceInVoxelSpace=3 what is the updateFieldVarianceInVoxelSpace in mm if my shrink factor is 8?

gdevenyi avatar Mar 22 '19 14:03 gdevenyi

ntustison avatar Mar 22 '19 14:03 ntustison