fMRIPREP - Not able to run the code

Hello everyone,

I am new here and I have a beginner’s problem :slight_smile:

I have installed docker and the required packages and everything went well until the moment that I had to run the code (the from the tutorial). I have tried many things but nothings seems to work, it either does nothing (when for example I try bash or a couple of times it gave me a permission denied error when I used ./ to run it. I have tried to run it form the windows command prompt, from the ubuntu, from the power shell, I tried as an administrator, I checked that it has the permissions required and nothing has worked so far so I 'd appreciate any leads

Thank you very much in advance,

What tutorial are you referring to? Have you tried using the example code on the fMRIPrep website?

docker run -ti --rm \
    -v /PATH/TO/DATA:/data:ro \
    -v /PATH/TO/DATA/derivatives:/out \
    -v /PATH/TO/license.txt:/opt/freesurfer/license.txt \
    nipreps/fmriprep:latest \
    /data /out \
    participant \

Thank you very much for your answer!

I am referring to this tutorial BIDS App Tutorial #2: fMRIPrep — Andy's Brain Book 1.0 documentation
When I save the code as a .sh file, there is no way to run it.

To fix permission errors, you can usually allow something to run as a program by right clicking the file and going to properties menu (but exact method depends on your OS). In general, you should try to use a Linux shell if possible (ubuntu or install cygwin if you want to use Windows). Did the code I posted worked (after changing it to match your needs)?

I did all the things you mentioned but nothing seems to work. As far as I understand the problem is not the code but the fact that I cannot run the .sh file at all. It’s not that it runs and it gives me an error or something, it doesn’t run at all.

Is it still only saying permission denied? Also, you can run the code I posted right from your terminal without putting it in an .sh file first.

Either it says permission denied or it just does nothing (!). I will try your code now directly and let you know thanks a lot!