Fmriprep-docker error

I tried to use fMRIPrep, however, it was impossible to start the docker.

First, I installed fMRIPrep as written in the tutorial.
“pip3 install --user --upgrade fmriprep-docker”
Therefore, I got the message at last, “Successfully installed fmriprep-docker-1.5.0”.

Second, I typed on the command line “sudo docker pull poldracklab/fmriprep:1.5.0”.

Lastly, I tried to preprocess my neuroimaging data.



Hi, thanks for reaching out. I see a few things in here.

  1. When you install fmriprep-docker via pip3 install --user, you’re installing it specifically for your user. When you then try to call it with sudo, you’re acting as the root user, so it doesn’t have your user’s environment to know where to look. Have you tried running just fmriprep-docker ...?

  2. If you’re running sudo fmriprep-docker and sudo docker, I suspect that this means that your user doesn’t have permissions. You should probably check out Docker’s Post-installation steps for Linux to give your user access, which will help you avoid running things as root.

  3. If your user still can’t run fmriprep-docker, then chances are your path doesn’t include ~/.local/bin. You can add it to your PATH, or just run python3 -m fmriprep_docker instead of fmriprep-docker, which will let Python find the module for you. Note that when using -m, you need to use an underscore (_), not a hyphen (-).

  4. Your docker run commands never reference an image, and don’t mount volumes. I would recommend using fmriprep-docker to add these things for you, but please see the Docker container section of our installation documents for examples, if you continue writing your commands manually.

Hope this helps,
Chris

1 Like

@effigies
Thank you so much for replying.
Based on you advice, I could handle the issue and successfully ran fMRIPrep.
However, it is time consuming than I expected.

Compare to SPM, what makes fMRIPrep takes long time to preprocess the image?
Is there any way to improve it?

Additionally…Is it possible to use Freesurfer berfore fMRIPrep? Would it be helpful for improving the speed?

fMRIPrep is definitely time-consuming, and the majority of that is FreeSurfer. If you pre-run FreeSurfer, you can reuse those results by including the subjects directory in your output directory under the name freesurfer/. See the note in Surface preprocessing.

The other primary slowdown relative to SPM is likely to be ANTs skull stripping and normalization. This is a cost-quality tradeoff we’ve settled on.

1 Like

Thank you so much! I really appreciate for your reply!