unravel.register.affine_initializer_check module#
Use reg_affine_initializer_check
(raic
) from UNRAVEL to check if the initially aligned template is fully within the padded region of the fixed image.
- Prerequisites:
affine_initializer
orreg
must have been run to generate the initially aligned template image.
Notes
Registration is less accurate if the initially aligned template is not fully within the padded region of the fixed image.
This script checks the number of surface voxels in the initially aligned template that are above a specified threshold.
If this number is greater than the threshold, it indicates that the initially aligned template may not be fully within the padded region of the fixed image.
This can be fixed by increasing the padding percentage (-pad) when running reg.
Usage:#
reg_affine_initializer_check -i <template__initial_alignment_to_fixed_img.nii.gz> [-t <threshold>] [-d list of paths] [-p sample??] [-v]
- unravel.register.affine_initializer_check.affine_initializer_check(nii_path, thres=0)[source]#
Check if the initially aligned template is fully within the padded region of the fixed image.
Parameters:#
- nii_pathstr or Path
Path to the NIfTI file containing the initially aligned template image.
- thresfloat, optional
Voxel intensity threshold for checking if the initially aligned template is within the padded region of the fixed image. Default is 0.
Returns:#
- int
The number of surface voxels in the initially aligned template that are above the specified threshold.