ANTSSLICEREGU...DREGISTRATION(1)
π ANTSSLICEREGU...DREGISTRATION(1) π
User Commands manual page, bestie. Let's get into it π
β¨ NAME β¨
antsSliceRegularizedRegistration - part of ANTS registration suite π¦
β¨ DESCRIPTION β¨
π£ COMMAND:
antsSliceRegularizedRegistration
okay so this one is a user-level application for slice-by-slice translation registration π It's giving precision. The results get regularized in z using polynomial regression, and it's built for spinal cord MRI π§
Only one stage is supported, and a stage is made of a transform, an image metric, and iterations, shrink factors, and smoothing sigmas for each level. It's specialized for 3D data, so the fixed image is 3D and the moving image is 3D too. Registration happens slice-by-slice first, then gets regularized in z. The -p flag controls the polynomial degree, and -p 0 means no regularization β¨
Shoutout to B. Avants for implementing it and Julien Cohen-Adad for conceiving it π«Ά
π€ Outputs:
OutputPrefixTxTy_poly.csv: the polynomial fit to Tx & Ty πOutputPrefix.nii.gz: the transformed image πΌοΈ
π§ͺ Example call:
antsSliceRegularizedRegistration -p 4 --output [OutputPrefix,OutputPrefix.nii.gz] --transform Translation[0.1] --metric MI[ fixed.nii.gz, moving.nii.gz , 1 , 16 , Regular , 0.2 ] --iterations 20 --shrinkFactors 1 --smoothingSigmas 0
β¨ OPTIONS β¨
-m,--metricβ pick your image metric, there's a whole menu here π The forms look like this:
CC[fixedImage,movingImage,metricWeight,radius,<samplingStrategy={Regular,Random,None}>,<samplingPercentage=[0,1]>]
MI[fixedImage,movingImage,metricWeight,numberOfBins,<samplingStrategy={Regular,Random,None}>,<samplingPercentage=[0,1]>]
MeanSquares[fixedImage,movingImage,metricWeight,radius,<samplingStrategy={Regular,Random,None}>,<samplingPercentage=[0,1]>]
GC[fixedImage,movingImage,metricWeight,radius,<samplingStrategy={Regular,Random,None}>,<samplingPercentage=[0,1]>]
There are four image metrics available: GC (global correlation), CC (ANTS neighborhood cross correlation), MI (mutual information), and MeanSquares (mean-squares intensity difference) π₯
β οΈ Heads up: the metricWeight is currently not used. It's just a temporary placeholder until multivariate metrics are available for a single stage.
-x,--maskmask-in-fixed-image-space.nii.gzβ a fixed image mask that limits which voxels the metric considers π―-n,--interpolationβ choose your interpolation vibe. Options:
Linear
NearestNeighbor
MultiLabel[<sigma=imageSpacing>,<alpha=4.0>]
Gaussian[<sigma=imageSpacing>,<alpha=1.0>]
BSpline[<order=3>]
CosineWindowedSinc
WelchWindowedSinc
HammingWindowedSinc
LanczosWindowedSinc
GenericLabel[<interpolator=Linear>]
ITK has a whole buffet of interpolation options, and we've made all of them available π°
-t,--transformβ pick your transform π§ Options:
Translation[gradientStep]
Rigid[gradientStep]
Similarity[gradientStep]
There are several transform options. The gradientStep (or learningRate) characterizes the gradient descent optimization, and it gets scaled appropriately for each transform using the shift scales estimator. Subsequent parameters are transform-specific and can be figured out from the usage π
-i,--iterationsMxNx0...β specify the number of iterations at each level π-s,--smoothingSigmasMxNx0...β specify the amount of smoothing at each level π«οΈ-f,--shrinkFactorsMxNx0...β specify the shrink factor for the virtual domain (typically the fixed image) at each level π-o,--outputβ set your output vibes π¦ The format is:
[outputTransformPrefix,<outputWarpedImage>,<outputAverageImage>]
Specify the output transform prefix (the output format is .nii.gz). Optionally, you can warp the moving image to the fixed space and, if the inverse transform exists, you can also output the warped fixed image β¨
-h,--helpβ print the help menu (short version).<VALUES>: 1, 0-v,--verboseβ verbose option.<VALUES>: 0-p,--polydegreeβ the degree of polynomial, up tozDimension-2. This is the main polynomial degree control, and0means no regularization π It can also be a vector, written like2x2x1for a 3-parameter transform (e.g. rigid). That would regularize the translation with a 2nd degree polynomial and the rotation with a linear function π
πΈ And that's the whole tea, bestie! Source: antsSliceRegularizedRegistrat..., dated December 2025 π
β¨
π¦ where this page comes from
- ubuntu resolute: ants 2.6.4+dfsg-1 Β· BSD-3-Clause
- π girlified by claude-haiku-5-5 on : a language model's rewrite of the original, under its terms