Open jbwexler opened 1 year ago
@effigies any idea what might cause this?
Not off the top of my head. The source file has 8 volumes:
sub-13/func/sub-13_task-rest_acq-MB3PA_bold.nii.gz int16 [104, 104, 72, 8] 2.00x2.00x2.00x1.91 #exts: 1
I guess it's possible that with only 8 volumes you only get one component, so melodic_IC.nii.gz
ends up being 3D. We could update plot_melodic_components
to ensure that we get promote a 3D image to a 4D image to pass to iter_img()
. It's pretty simple with slicing:
In [1]: import nibabel as nb
In [2]: img = nb.load('/home/chris/Downloads/sample_image.nii.gz')
In [3]: img.shape
Out[3]: (256, 256, 25)
In [4]: img.slicer[..., None]
Out[4]: <nibabel.nifti1.Nifti1Image at 0x7f6d0c0a6eb0>
In [5]: img.slicer[..., None].shape
Out[5]: (256, 256, 25, 1)
Is there a way to get MRIQC to use the newest version of niworkflows once the above fix is released? Or would we need a new release of MRIQC for that?
Easiest would be a new MRIQC release, as then you get a coherent docker image.
After rerunning with mriqc 23.0.1 I ran into this issue: https://github.com/poldracklab/tacc-openneuro/issues/72
Happened for every subject. As far as I can tell, the input images are fine and 4-D.