I have a script that is part of my analysis and it expects aparc+aseg.nii.gz because it passes it to AFNI for resampling. The freesurfer output from fmriprep is in .mgz format(i.e. aparc+aseg.mgz). Is there a way to have fmriprep output this file as .nii.gz or does it need to be converted using a different software?
you can also use AFNI’s “@SUMA_Make_Spec_FS” which runs mri_convert under the hood and does other things to prep FS voxel and surface outputs for AFNI analyses
mri_convert has .nii files implemented, meaning you just have to specify an output filename that has the file ending .nii.
E.g. if you have a file T1.mgz and want to convert it to .nii, you can run mri_convert T1.mgz T1.nii