I have an SPM12 nipype pipeline for fmri preprocessing. The pipeline executes spm.Realign(), with realign.inputs.register_to_mean = True, but I don’t want to reslice until the normalization step, after slice correction. I have tried two methods:
you can take a look at this example. this has an extra coregistration step in between, but you will notice that it only estimates rather than estimates and writes. the same options are available to realign.
Thanks @satra, for offering the example. I have tried to use realign with only ‘estimate’ as a jobtype. Under that condition, it seems that if I input ‘realigned_files’ directly into the normalize node, then the warped file will be motion-corrected.
However, if I input ‘realigned_files’ into the slice-time correction node, and then connect to the normalize node, the warped file in not motion-corrected.
Also, using ‘estimate’ only as the jobtype for realignment, the mean image is no longer written out, which was previously used to estimate the alignment parameters in the normalization run.
Is there any other way to pass modified headers, without reslicing after realignment, to subsequent nodes successfully?