Hi,
Sorry for the delay, I just noticed your question regarding steps at the end....
1) 3dAllineate to perform eddy current correction. I created an average B0 as a reference frame. I also aligned my T2 to my B0 reference scan rigidly.
For subjects with lots of motion you can use -twopass...its robust but takes a while to run.
2) 3dQwarp for B0 to pseudo-T2 distortion correction but with a slightly lower penalty (1 instead of 5). I also limited number of iterations so that it doesn't get weird results from over warping since they are close to begin with.
It seemed to give me reasonable results for the corrections. Plus I could use wsinc5 to write out files for improved interpolation.
QUESTIONS:
1) The part that is a bit more difficult is how to rotate the bvecs. I used MRtrix3 to import the nifti and output the bval/bvec in "FSL format" which I assume is just the row vector and has nothing to do with sign of values. I want to apply my 3dAllineate matrix but I only want to apply motion related 6dof from the 12dof matrix for the rotation of bvecs, which I DO NOT THINK the following afni blogs perform. It seems that I would want to keep rotation and translation and throw out scaling and shear to accomplish this goal, but the scripts below throw out translation (not sure why).
2) Another question is regarding afni implementations I found:
[
blog.cogneurostats.com]
Vecwarp -matvec tmp.transform.final.${aRow} -input tmp.bvecs.${aRow}
-forward >> bvec_rotated.1D
When comparing the post above to one of Daniel's old post, there was a conflict in the following line:
[
afni.nimh.nih.gov]
Vecwarp -matvec tempmatvec0.1D
-backward -input tempvector.1D -force -output temprotgrad.1D > & /dev/null
The difference between these two afni suggestions could be due to the way 3dAllineate and WarpDrive function differently , or there is a mistake in one of these two versions. Is the -forward option correct for applying 3dAllineate matrix?
3) For Afni's DTI Fit is the reweight/nonlinear option the same as Restore/iRestore algorithm or different?
Any suggestions would be much appreciated.
Thanks,
Ajay