ENH: add gradunwarp base workflow for f/smriprep. #819
Conversation
Codecov Report❌ Patch coverage is Additional details and impacted files@@ Coverage Diff @@
## master #819 +/- ##
===========================================
- Coverage 71.46% 46.28% -25.19%
===========================================
Files 89 92 +3
Lines 8622 8686 +64
Branches 1072 1074 +2
===========================================
- Hits 6162 4020 -2142
- Misses 2227 4549 +2322
+ Partials 233 117 -116 ☔ View full report in Codecov by Harness. 🚀 New features to boost your workflow:
|
|
I'm guessing if you want circle / gh to run the test, you'll need to install gradunwarp right? |
| itk_warp_data = fsl_warp.get_fdata().reshape(fsl_warp.shape[:3]+(1,3)) | ||
| itk_warp_data[...,(0,1)] *= -1 | ||
| itk_warp = fsl_warp.__class__(itk_warp_data, fsl_warp.affine) | ||
| itk_warp.header.set_intent("vector") | ||
| out_fname = fname_presuffix(in_warp, suffix="_itk", newpath=os.getcwd()) | ||
| itk_warp.to_filename(out_fname) |
There was a problem hiding this comment.
nitransforms should do all the manipulations for you
There was a problem hiding this comment.
I might have missed something, but from what I understood what needs to be provided to Ants ApplyTransform are ITK warpfields. In nitransforms I cannot see any function to output non-linear warp in ITK format from nitransforms object https://nitransforms.readthedocs.io/en/latest/_api/io.html#nitransforms.io.itk.ITKDisplacementsField, it seems to only deal with inputs. Thus, my attempt to invert that input step.
There was a problem hiding this comment.
Yeah, it looks like you are totally right (and I did the same here a while ago - https://github.com/nipreps/sdcflows/blob/375dd7a024abcd5d4d2b282241a037d76f9719e6/sdcflows/transform.py#L286-L292)
Would you like to become a proud contributor to nitransforms? :D
If not (or either way, actually), may I ask you to file an issue requesting this to be implemented there?
effigies
left a comment
There was a problem hiding this comment.
Mostly comments on the nipype interface.
Co-authored-by: Chris Markiewicz <effigies@gmail.com>
Co-authored-by: Chris Markiewicz <effigies@gmail.com>
Co-authored-by: Chris Markiewicz <effigies@gmail.com>
Co-authored-by: Chris Markiewicz <effigies@gmail.com>
Co-authored-by: Chris Markiewicz <effigies@gmail.com>
Co-authored-by: Chris Markiewicz <effigies@gmail.com>
Co-authored-by: Chris Markiewicz <effigies@gmail.com>
Co-authored-by: Chris Markiewicz <effigies@gmail.com>
Co-authored-by: Chris Markiewicz <effigies@gmail.com>
559c8a1 to
a4d7e3b
Compare
|
I don't understand why I am getting errors on the T1w file when testing the gradunwarp pipeline. How does that ds0000030 differs from the openeuro one? |
Working on nipreps/fmriprep#1550.
Relies on an updated version of the gradunwarp https://github.com/bpinsard/gradunwarp/tree/fix/mem_leaks.