james-cole / brainageR

Software for generating a brain-predicted age value, using Gaussian Processes regression, implemented in R
GNU Lesser General Public License v3.0
76 stars 27 forks source link

Error with failed to find grey matter #9

Open QunjunLIANG opened 1 year ago

QunjunLIANG commented 1 year ago

Hi brainageR experts,

I was running brainageR with Docker and an error occurred, as

Item 'Volumes', field 'val': Number of matching files (0) less than required (1). error: No executable modules, but still unresolved dependencies or incomplete module inputs. error: called from spm_jobman>fill_run_job at line 472 column 5 spm_jobman at line 247 column 13 spm_preprocess_brainageR at line 102 column 1 init_octave at line 1 column 41 Processed grey matter file not found: SPM12 pre-processing probably failed

The full log was also uploaded, please check it in attachment. Bug_log.txt

However, this error only occurred when the input T1w image is the preprocessed T1w image using fMRIprep (sub-xxx_desc-preproc_T1w.nii.gz). It would not appear using the raw T1w image. I am not sure if the inputs make the difference.

And I would like to ask a following question. In a previous dataset, I ran brainageR successfully for each subject. The dataset has 91 depression patients with another 91 matched health controls. As a result, the correlation between predicted age and real age is 0.77 for the patients and 0.78 for the controls. Do you have any ideas about why the predicted efficiency shows relatively low comparing with your reports.

Thanks in advance.

james-cole commented 1 year ago

Hi there,

Thanks for getting in touch and your interest in brainageR. The software relies on SPM12 for pre-processing, so any inputs need to be uncompressed Nifti files (.nii). Files ending .nii.gz won't be detected.

Also, it is strongly recommended to use raw 3D T1-weighted MRI scans as input. This is what the model was trained on, so any additional pre-processing could lead to unexpected results.

A lower correlation between age and brain-age in healthy people could be caused by scanner or sites effects. While the model was trained on multiple sites in an attempt to mitigate this, there is still a reasonable amount of residual scanner-related variability possible. Another factor could be sampling bias, in that your sample is not drawn randomly from the same population as the that used to train the model.

Best wishes, James

QunjunLIANG commented 1 year ago

Hi James! Thank you for your timely reply.

What I want to use the preprocessed T1w image as inputs refers to a previous study (Chu et al, 2023), in which they used bias field correction T1w images via ANT's. Thus, I supposed the correction may improve the prediction efficiency... Thanks for your clarification, letting me know that the raw T1w image is sufficient for the prediction.

I appreciate your ideas for the low correlation. We recruited the participants for the health control group without a previous selection. If there is something different between our dataset and the training set, I think it must be the race. All participants in our dataset are Chinese. Would you think that difference matters for the prediction?

We tested the prediction error between groups and found that the prediction error in the health control (mean = 8.85, sd = 7.35) is greater than the patient group (mean = 5.76, sd = 8.40), which is significant (t = 2.64, p = 0.009).

I attached the result csv here, and I hope it would provide more information than my words. Result_brain_predited_age.csv

Best, Qunjun