5ttgen fsl error - registration?

Dear MRtrix experts,

Hi! I’ve encountered an error while running the 5ttgen command on my data.
I’ve ran this line of commands:

5ttgen fsl anat.mif 5tt_nocoreg.mif

which, in the log file, contains the following:

mrconvert /Users/server/Desktop/sub-032302/ses-01/dwi/anat.mif /Users/server/Desktop/sub-032302/ses-01/dwi/5ttgen-tmp-5Z3S8K/input.mif
mrconvert input.mif T1.nii -strides -1,+2,+3
maskfilter /usr/local/fsl/data/standard/MNI152_T1_1mm_brain_mask_dil.nii.gz dilate mni_mask.nii -npass 4
standard_space_roi T1.nii T1_preBET.nii.gz -maskMASK mni_mask.nii -roiFOV
bet T1_preBET.nii.gz T1_BET.nii.gz -f 0.15 -R
fast T1_BET.nii.gz
run_first_all -m none -s L_Accu,R_Accu,L_Caud,R_Caud,L_Pall,R_Pall,L_Puta,R_Puta,L_Thal,R_Thal -i T1.nii -o first

and got an error message.

[ERROR] FSL FIRST has failed; 0 of 10 structures were segmented successfully (check /Users/server/Desktop/sub-032302/ses-01/dwi/5ttgen-tmp-RA22G8/first.logs)

We’ve tried the -debug option to find out the problem, but we still got the exact same message, nothing else.
We checked on our T1.nii image and confirmed that it is okay, but then we found out that our T1_preBET image was completely cropped out like the following:

so we are suspecting that something went wrong while executing the standard_space_roi command, possibly aligning the mni mask and the T1 image.

We’ve also checked our mni_mask.nii file to be sure, and it was okay too.

What might be the problem? If the problem is as we suspect, would there be any way to fix it?
Thank you in advance!

It looks like you are using an MP2RAGE image (or something similar). Most tools will not play nicely with MP2RAGE data it of the box. Any reason you are not using an MPRAGE (or similar)?

Hi!

I am using a public dataset, and unfortunately it only contains MP2RAGE T-1 images for all subjects.
I didn’t expect that to be an issue… is there any suggestion that might make it work?

Thank you!

Hello
mp2rage volumes have some advantage (better contrast, less biais, and a quantitative T1 map !) compare to mprage but it comes with a non negligible drawback : the background

indeed it makes standard process fail because of the background that is not black. I can not run freesurfer directly, and so I am not surprise that also fsl tools fails too.

If you also have the 2 original series (INV1 and INV2) that were acquired to produced the mp2rage volume (mp2rage = INV1/INV2 (or INV2/IN1 …?), then there is a matlab program

that will allow you to produce (from inv1 and inv2) the T1 image, with a normal background (at the cost of less debias result)

Alternatively, (if you only have the mp2rage image) you can try the cat12 (matlab SPM toolbox) to produce the brain mask. Just run the segmentation, and then add p1 p2 and p3 mask (gray / white / csf)
to build the brain mask.

Once you have the brain mask, you can do you preferred process (freesurfer fsl …)

Problem solved!! 5ttgen worked perfectly with the fixed image.
Thank you so much!

In the absence of the original series being available in order to reconstruct an image with noise suppression, you could also derive a more appropriate brain mask (using any method of your choice), and provide that to 5ttgen fsl using the -mask option. In the absence of such, 5ttgen fsl will internally run FSL’s bet, which is simply not designed to handle such data.