Running fMRIPrep in Neurodesk

Can you share the code that causes this error? It is most likely related to a limitation in memory.

And I just rerun the code and it all runs perfectly for me: Google Colab

It’s the same code. I went back to it, but I’m still looking for a solution because of the loss of volumes for nuisance regression.
The same code worked before, even after I upgraded the memory.
I’m lost!

u got the same, i mean this one

Hi @stebo85
Yes, you’re right. I tried it with the GPU A100 and it works; however, unfortunately, there aren’t enough resources for the rest of the data. :smiling_face_with_tear:

You shouldn’t need a GPU for this! You should only need enough RAM. Can you run this analysis locally on your computer using Neurodesk instead of in Google Colab?

1 Like

I can reproduce the memory error now as well. Maybe google colab changed something:
image

they kill it after it has consumed more memory than allowed:
image

One workaround would be to upgrade your colab to a paid version where they give you more RAM.

Another workaround could be to trade of speed vs RAM by doing the command per volume :slight_smile: …

!fslsplit "{rest_output_dir}/fMRI_realigned.nii.gz" temp_vol_ -t
!for vol in temp_vol_*.nii.gz; do flirt -in "$vol" -ref "/content/drive/MyDrive/Processed_Data/0050683/session_1/anat_1/T1w_brain.nii.gz" -applyxfm -init func2anat.mat -out "reg_$vol"; done
!fslmerge -t "{rest_output_dir}/fMRI_coreg.nii.gz" reg_temp_vol_*.nii.gz
!rm temp_vol_*.nii.gz reg_temp_vol_*.nii.gz 

works:

1 Like

YUP
It works again
thank soo much

Hi @stebo85
could you please explain and guide me within this error? still using neurodesk , colab

Processing sub-1S0225...
FATAL:   container creation failed: mount hook function failure: hook function for tag sessiondir returns error: while mounting /var/lib/apptainer/mnt/session/mountinfo to /proc/self/mountinfo: permission denied

Thank u !

Dear @Oumayma - Google colab made an update and it’s currently not possible to execute containers inside google colab. We are working on a workaround and hopefully have a solution soon.

1 Like

Dear @Oumayma - it doesn’t look like there is an easy way to get this to work at the moment. Can you run Neurodesk locally on your own computer or use our Neurodesk Play cloud (https://play.neurodesk.org) in the meantime?