Closed vinferrer closed 6 years ago
That example shows the necessary steps to do what you want. Just repeat with another mapping passed via -t.
On Thu, Jul 26, 2018, 06:12 sento4000 notifications@github.com wrote:
Hi,
I was following the example for fMRI data in https://stnava.github.io/fMRIANTs/ and I was wondering how to combine the last transform (${nm}_diffCollapsedWarp.nii.gz) that combines all the motion corrections with my transformations to the MNI space. I use an intermediate step passsing throught the anatomical space. So I wan't to combine ${nm}_diffCollapsedWarp.nii.gz, func2anatGenericaffine.mat, anat2MNIGenericAffine.mat ,MNIwrapping.nii.gz
— 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/615, or mute the thread https://github.com/notifications/unsubscribe-auth/AATyfu1-HBnHFI3IxET31tUwVG6Gh1MMks5uKZX3gaJpZM4Vhi8w .
now I get it, however there is something i don't understand. you apply motioncorrection with this command: tx=SyN[0.1,3,0.0] # critical parameters (though others matter too) antsRegistration --dimensionality 4 -f 1 -r ${nm}Warp.nii.gz \ --output [${nm}_,${nm}Warped.nii.gz] \ --interpolation Linear --use-histogram-matching 1 \ --winsorize-image-intensities [0.005,0.995] --transform $tx \ --metric meansquares[${fxd},$fmri,1] \ --convergence [15x2,1e-6,4] --shrink-factors 2x1 \ --smoothing-sigmas 1x0vox --restrict-deformation 1x1x1x0
and after computing and combining the other transformations you use this command to apply them to the original bold data: antsApplyTransforms -d 4 -o ${nm}_bold2template.nii.gz \ -t ${nm}_diff4DCollapsedWarp.nii.gz -t ${nm}_0Warp.nii.gz \ -r data/template_replicated.nii.gz -i ${nm}Warped.nii.gz
but ${nm}Warped.nii.gz isn't the original data, is the output of the first command (the replicated templated, warped to the non corrected motion image?). Isn't the original data fmri=data/bold.nii.gz, why isn't this the input?
sry that command maps the the time series to the fixed space but anyway i still not get why ${nm}Warped.nii.gz is the input when you apply the transformation to the original bold data.
You can probably figure out another way to do it and feel free to modify the example and share with us
On Sun, Jul 29, 2018, 12:31 sento4000 notifications@github.com wrote:
sry that command maps the the time series to the fixed space but anyway i still not get why ${nm}Warped.nii.gz is the input when you apply the transformation to the original bold data.
— You are receiving this because you commented. Reply to this email directly, view it on GitHub https://github.com/ANTsX/ANTs/issues/615#issuecomment-408689244, or mute the thread https://github.com/notifications/unsubscribe-auth/AATyfkMudP5igAZi-_CISZb-NR9mxaxuks5uLeNTgaJpZM4Vhi8w .
I made a PR
https://github.com/stnava/fMRIANTs/pull/4
This applies the warp to the original bold data.
Hi,
I was following the example for fMRI data in https://stnava.github.io/fMRIANTs/ and I was wondering how to combine the last transform (${nm}_diffCollapsedWarp.nii.gz) that combines all the motion corrections with my transformations to the MNI space. I use an intermediate step passsing throught the anatomical space. So I wan't to combine ${nm}_diffCollapsedWarp.nii.gz, func2anatGenericaffine.mat, anat2MNIGenericAffine.mat ,MNIwrapping.nii.gz