fMRIprep stderr: killed

Dear Neurostars,
I have been trying to run fmriprep on a BIDS converted subject. However, when I apply the function “fmriprep BIDS_DIRECTORY DATA_PREP participant” in my terminal, appears the following message:

bids-validator does not appear to be installed
Traceback (most recent call last):
  File "/Users/joancarrerasdiaz/miniconda3/bin/fmriprep", line 8, in <module>
    sys.exit(main())
             ^^^^^^
  File "/Users/joancarrerasdiaz/miniconda3/lib/python3.11/site-packages/fmriprep/cli/run.py", line 87, in main
    setup_migas(init_ping=True)
  File "/Users/joancarrerasdiaz/miniconda3/lib/python3.11/site-packages/fmriprep/utils/telemetry.py", line 200, in setup_migas
    send_breadcrumb(status='R', status_desc='workflow start')
  File "/Users/joancarrerasdiaz/miniconda3/lib/python3.11/site-packages/fmriprep/utils/telemetry.py", line 207, in send_breadcrumb
    res = migas.add_project("nipreps/fmriprep", __version__, **kwargs)
          ^^^^^^^^^^^^^^^^^
AttributeError: module 'migas' has no attribute 'add_project'
Sentry is attempting to send 2 pending events
Waiting up to 2 seconds
Press Ctrl-C to quit

I have downloaded the bids-validator and reseted the terminal a couple of times and it keeps appearing the same message.

On the other hand, the data generated in the folder DATA_PREP is just a folder named logs, as you can see below.

/Users/joancarrerasdiaz/Desktop/CARPETES/UdG/Pràctiques/DATA_PREP
└── logs

How can I solve this problem?

Note: the structure of the folder

BIDS_DIRECTORY is the following one:
├── README
├── conversion_info
│   └── v0
│       ├── 11CPIB_pet_paths.tsv
│       ├── 18FAV1451_pet_paths.tsv
│       ├── 18FFDG_pet_paths.tsv
│       ├── amyloid_pet_paths.tsv
│       ├── dwi_paths.tsv
│       ├── flair_paths.tsv
│       ├── fmri_paths.tsv
│       └── t1_paths.tsv
├── dataset_description.json
├── participants.tsv
└── sub-ADNI002S0413
    ├── ses-M060
    │   ├── func
    │   │   ├── sub-ADNI002S0413_ses-M060_task-rest_bold.json
    │   │   └── sub-ADNI002S0413_ses-M060_task-rest_bold.nii.gz
    │   ├── pet
    │   │   ├── sub-ADNI002S0413_ses-M060_trc-18FAV45_pet.nii.gz
    │   │   ├── sub-ADNI002S0413_ses-M060_trc-18FFDG_rec-coregavg_pet.nii.gz
    │   │   └── sub-ADNI002S0413_ses-M060_trc-18FFDG_rec-coregiso_pet.nii.gz
    │   └── sub-ADNI002S0413_ses-M060_scans.tsv
    ├── ses-M072
    │   ├── func
    │   │   ├── sub-ADNI002S0413_ses-M072_task-rest_bold.json
    │   │   └── sub-ADNI002S0413_ses-M072_task-rest_bold.nii.gz
    │   └── sub-ADNI002S0413_ses-M072_scans.tsv
    ├── ses-M084
    │   ├── func
    │   │   ├── sub-ADNI002S0413_ses-M084_task-rest_bold.json
    │   │   └── sub-ADNI002S0413_ses-M084_task-rest_bold.nii.gz
    │   ├── pet
    │   │   ├── sub-ADNI002S0413_ses-M084_trc-18FAV45_pet.nii.gz
    │   │   ├── sub-ADNI002S0413_ses-M084_trc-18FFDG_rec-coregavg_pet.nii.gz
    │   │   └── sub-ADNI002S0413_ses-M084_trc-18FFDG_rec-coregiso_pet.nii.gz
    │   └── sub-ADNI002S0413_ses-M084_scans.tsv
    ├── ses-M096
    │   ├── func
    │   │   ├── sub-ADNI002S0413_ses-M096_task-rest_bold.json
    │   │   └── sub-ADNI002S0413_ses-M096_task-rest_bold.nii.gz
    │   └── sub-ADNI002S0413_ses-M096_scans.tsv
    ├── ses-M108
    │   ├── func
    │   ├── pet
    │   │   └── sub-ADNI002S0413_ses-M108_trc-18FAV45_pet.nii.gz
    │   └── sub-ADNI002S0413_ses-M108_scans.tsv
    ├── ses-M132
    │   ├── dwi
    │   │   ├── sub-ADNI002S0413_ses-M132_dwi.bval
    │   │   ├── sub-ADNI002S0413_ses-M132_dwi.bvec
    │   │   ├── sub-ADNI002S0413_ses-M132_dwi.json
    │   │   └── sub-ADNI002S0413_ses-M132_dwi.nii.gz
    │   ├── pet
    │   │   ├── sub-ADNI002S0413_ses-M132_trc-18FAV1451_pet.nii.gz
    │   │   └── sub-ADNI002S0413_ses-M132_trc-18FAV45_pet.nii.gz
    │   └── sub-ADNI002S0413_ses-M132_scans.tsv
    ├── ses-M162
    │   ├── pet
    │   │   └── sub-ADNI002S0413_ses-M162_trc-18FAV45_pet.nii.gz
    │   └── sub-ADNI002S0413_ses-M162_scans.tsv
    └── sub-ADNI002S0413_sessions.tsv

Thank you,
Joan

I would highly recommend that you use a containerized version of fmriprep (docker or singularity) if you want to use fmriprep.

This way you will be sure that all dependencies (like the bids validator and others) will be installed.

See the nipreps doc for some information to use bids apps with docker: Executing with Docker - NiPreps

This appears to be due to a change in one of our dependencies. I agree that using a container is simplest, but if you want to install fMRIPrep, I would recommend a conda environment.

git clone https://github.com/nipreps/fmriprep.git
git -C fmriprep checkout $VERSION
conda env create -f fmriprep/env.yml  # creates an environment named fmriprep
conda activate fmriprep
pip install -r fmriprep/requirements.txt  # This line can be dropped with 23.2

This ensures that you’re using the exact conda/PyPI dependencies that we tested when the version was released and built into the containers we provide.

Thank you,
However, once I run the fmriprep-docker, as is been indicated in the tutorial Executing with Docker, it appears the following message:

bids-validator@1.13.1
(node:9) Warning: Closing directory handle on garbage collection
(Use `node --trace-warnings ...` to show where the warning was created)
	1: [WARN] You should define 'SliceTiming' for this file. If you don't provide this information slice time correction will not be possible. 'Slice Timing' is the time at which each slice was acquired within each volume (frame) of the acquisition. Slice timing is not slice order -- rather, it is a list of times containing the time (in seconds) of each slice acquisition in relation to the beginning of volume acquisition. (code: 13 - SLICE_TIMING_NOT_DEFINED)
		./sub-ADNI002S0413/ses-M060/func/sub-ADNI002S0413_ses-M060_task-rest_bold.nii.gz
		./sub-ADNI002S0413/ses-M072/func/sub-ADNI002S0413_ses-M072_task-rest_bold.nii.gz
		./sub-ADNI002S0413/ses-M084/func/sub-ADNI002S0413_ses-M084_task-rest_bold.nii.gz
		./sub-ADNI002S0413/ses-M096/func/sub-ADNI002S0413_ses-M096_task-rest_bold.nii.gz

	Please visit https://neurostars.org/search?q=SLICE_TIMING_NOT_DEFINED for existing conversations about this issue.

	2: [WARN] The Authors field of dataset_description.json should contain an array of fields - with one author per field. This was triggered because there are no authors, which will make DOI registration from dataset metadata impossible. (code: 113 - NO_AUTHORS)

	Please visit https://neurostars.org/search?q=NO_AUTHORS for existing conversations about this issue.

        Summary:                  Available Tasks:        Available Modalities: 
        68 Files, 524.32MB                                MRI                   
        1 - Subject                                       PET                   
        13 - Sessions                                                           


	If you have any questions, please post on https://neurostars.org/tags/bids.
231215-12:15:01,695 nipype.workflow IMPORTANT:
	 Running fMRIPrep version 23.2.0a2

         License NOTICE ##################################################
         fMRIPrep 23.2.0a2
         Copyright 2023 The NiPreps Developers.
         
         This product includes software developed by
         the NiPreps Community (https://nipreps.org/).
         
         Portions of this software were developed at the Department of
         Psychology at Stanford University, Stanford, CA, US.
         
         This software is also distributed as a Docker container image.
         The bootstrapping file for the image ("Dockerfile") is licensed
         under the MIT License.
         
         This software may be distributed through an add-on package called
         "Docker Wrapper" that is under the BSD 3-clause License.
         #################################################################
231215-12:15:01,754 nipype.workflow IMPORTANT:
	 Building fMRIPrep's workflow:
           * BIDS dataset path: /data.
           * Participant list: ['ADNI002S0413'].
           * Run identifier: 20231215-121447_689a1c94-c55c-4fb5-b4f2-6b52fdfdab55.
           * Output spaces: MNI152NLin2009cAsym:res-native.
           * Pre-run FreeSurfer's SUBJECTS_DIR: /out/fmriprep/sourcedata/freesurfer.
231215-12:15:03,69 nipype.workflow INFO:
	 ANAT Stage 1: Adding template workflow
231215-12:15:03,483 nipype.workflow INFO:
	 ANAT Stage 2: Preparing brain extraction workflow
231215-12:15:03,611 nipype.workflow INFO:
	 ANAT Stage 3: Preparing segmentation workflow
231215-12:15:03,619 nipype.workflow INFO:
	 ANAT Stage 4: Preparing normalization workflow for ['MNI152NLin2009cAsym']
231215-12:15:03,633 nipype.workflow INFO:
	 ANAT Stage 5: Preparing surface reconstruction workflow
231215-12:15:03,661 nipype.workflow INFO:
	 ANAT Stage 6: Preparing mask refinement workflow
231215-12:15:03,665 nipype.workflow INFO:
	 ANAT No T2w images provided - skipping Stage 7
231215-12:15:03,665 nipype.workflow INFO:
	 ANAT Stage 8: Creating GIFTI surfaces for ['white', 'pial', 'midthickness', 'sphere_reg', 'sphere']
231215-12:15:03,692 nipype.workflow INFO:
	 ANAT Stage 8: Creating GIFTI metrics for ['thickness', 'sulc']
231215-12:15:03,704 nipype.workflow INFO:
	 ANAT Stage 8a: Creating cortical ribbon mask
231215-12:15:03,710 nipype.workflow INFO:
	 ANAT Stage 9: Creating fsLR registration sphere
231215-12:15:03,717 nipype.workflow INFO:
	 ANAT Stage 10: Creating MSM-Sulc registration sphere
231215-12:15:04,887 nipype.workflow INFO:
	 Stage 1: Adding HMC boldref workflow
231215-12:15:04,899 nipype.workflow INFO:
	 Stage 2: Adding motion correction workflow
231215-12:15:04,912 nipype.workflow INFO:
	 Stage 3: Adding coregistration boldref workflow
231215-12:15:05,256 nipype.workflow INFO:
	 Stage 1: Adding HMC boldref workflow
231215-12:15:05,265 nipype.workflow INFO:
	 Stage 2: Adding motion correction workflow
231215-12:15:05,272 nipype.workflow INFO:
	 Stage 3: Adding coregistration boldref workflow
231215-12:15:05,529 nipype.workflow INFO:
	 Stage 1: Adding HMC boldref workflow
231215-12:15:05,537 nipype.workflow INFO:
	 Stage 2: Adding motion correction workflow
231215-12:15:05,545 nipype.workflow INFO:
	 Stage 3: Adding coregistration boldref workflow
231215-12:15:05,797 nipype.workflow INFO:
	 Stage 1: Adding HMC boldref workflow
231215-12:15:05,806 nipype.workflow INFO:
	 Stage 2: Adding motion correction workflow
231215-12:15:05,813 nipype.workflow INFO:
	 Stage 3: Adding coregistration boldref workflow
231215-12:15:06,75 nipype.workflow INFO:
	 Stage 1: Adding HMC boldref workflow
231215-12:15:06,84 nipype.workflow INFO:
	 Stage 2: Adding motion correction workflow
231215-12:15:06,91 nipype.workflow INFO:
	 Stage 3: Adding coregistration boldref workflow
231215-12:15:06,139 nipype.workflow IMPORTANT:
	 BOLD series will be slice-timing corrected to an offset of 1.46s.
231215-12:15:09,16 nipype.workflow CRITICAL:
	 ERROR: a valid license file is required for FreeSurfer to run. fMRIPrep looked for an existing license file at several paths, in this order: 1) command line argument ``--fs-license-file``; 2) ``$FS_LICENSE`` environment variable; and 3) the ``$FREESURFER_HOME/license.txt`` path. Get it (for free) by registering at https://surfer.nmr.mgh.harvard.edu/registration.html

Then, my folder named DATA_PREP (the data output) gets the following structure:

/Users/joancarrerasdiaz/Desktop/CARPETES/UdG/Pràctiques/DATA_PREP
└── fmriprep
    ├── logs
    └── sub-ADNI002S0413
        └── log
            └── 20231215-121447_689a1c94-c55c-4fb5-b4f2-6b52fdfdab55
                └── fmriprep.toml

Hi @Joan_Carreras_Diaz did you include the —fs-license-file argument when you ran fmriprep (and have it point to a valid file)?

I have just included the -fs-license-file but it does not seem to work neither.

I run the following lines:


docker run -ti --rm \
-v /Users/joancarrerasdiaz/Desktop/CARPETES/UdG/Pràctiques/Dades_ADNI/BIDS_DIRECTORY:/data:ro \
-v /Users/joancarrerasdiaz/Desktop/CARPETES/UdG/Pràctiques/DATA_PREP:/out \
nipreps/fmriprep \
/data /out/fmriprep \
participant \
-w /work \
--fs-license-file /Applications/freesurfer/7.1.1 \            
--fs-subjects-dir /Applications/freesurfer/7.1.1/subjects

But the message given is the following one:


usage: fmriprep [-h] [--skip_bids_validation] [--participant-label PARTICIPANT_LABEL [PARTICIPANT_LABEL ...]]
                [-t TASK_ID] [--echo-idx ECHO_IDX] [--bids-filter-file FILE] [-d [PATH ...]]
                [--bids-database-dir PATH] [--nprocs NPROCS] [--omp-nthreads OMP_NTHREADS] [--mem MEMORY_MB]
                [--low-mem] [--use-plugin FILE] [--sloppy] [--anat-only] [--level {minimal,resampling,full}]
                [--boilerplate-only] [--reports-only]
                [--ignore {fieldmaps,slicetiming,sbref,t2w,flair} [{fieldmaps,slicetiming,sbref,t2w,flair} ...]]
                [--output-spaces [OUTPUT_SPACES ...]] [--longitudinal] [--bold2t1w-init {register,header}]
                [--bold2t1w-dof {6,9,12}] [--force-bbr] [--force-no-bbr] [--slice-time-ref SLICE_TIME_REF]
                [--dummy-scans DUMMY_SCANS] [--random-seed _RANDOM_SEED] [--me-t2s-fit-method {curvefit,loglin}]
                [--output-layout {bids,legacy}] [--me-output-echos] [--medial-surface-nan] [--project-goodvoxels]
                [--md-only-boilerplate] [--cifti-output [{91k,170k}]] [--no-msm] [--use-aroma]
                [--aroma-melodic-dimensionality AROMA_MELODIC_DIM] [--error-on-aroma-warnings]
                [--return-all-components] [--fd-spike-threshold REGRESSORS_FD_TH]
                [--dvars-spike-threshold REGRESSORS_DVARS_TH] [--skull-strip-template SKULL_STRIP_TEMPLATE]
                [--skull-strip-fixed-seed] [--skull-strip-t1w {auto,skip,force}] [--fmap-bspline]
                [--fmap-no-demean] [--use-syn-sdc [{warn,error}]] [--force-syn] [--fs-license-file FILE]
                [--fs-subjects-dir PATH] [--no-submm-recon] [--fs-no-reconall] [--track-carbon]
                [--country-code COUNTRY_CODE] [--version] [-v] [-w WORK_DIR] [--clean-workdir] [--resource-monitor]
                [--config-file FILE] [--write-graph] [--stop-on-first-crash] [--notrack]
                [--debug {compcor,fieldmaps,pdb,all} [{compcor,fieldmaps,pdb,all} ...]]
                bids_dir output_dir {participant}
fmriprep: error: Path does not exist: </Applications/freesurfer/7.1.1>.

However, the distribution of my freesurfer folder is like the one below:


/Applications/freesurfer
└── 7.1.1
    ├── ASegStatsLUT.txt
    ├── DefectLUT.txt
    ├── FreeSurferColorLUT.txt
    ├── FreeSurferEnv.csh
    ├── FreeSurferEnv.sh
    ├── Freeview.app
    ├── SegmentNoLUT.txt
    ├── SetUpFreeSurfer.csh
    ├── SetUpFreeSurfer.sh
    ├── Simple_surface_labels2009.txt
    ├── WMParcStatsLUT.txt
    ├── average
    ├── bin
    ├── build-stamp.txt
    ├── diffusion
    ├── docs
    ├── etc
    ├── fsafd
    ├── fsfast
    ├── lib
    ├── license.txt
    ├── matlab
    ├── mni
    ├── python
    ├── sessions
    ├── sources.csh
    ├── sources.sh
    ├── subjects
    ├── tkmeditParcColorsCMA
    ├── trctrain
    └── uninstall.sh

Hi @Joan_Carreras_Diaz,

You should put the full path to (and including) license.txt. You will also need to mount /Applications/freesurfer with the -v Docker argument. Also, you have not defined or mounted /work anywhere, as far as I can tell.

Best,
Steven

Hello, I had some problems and I had to reset the computer and download all again. However, once I have done it all, I’m stuck again in that part. After running these lines, it appears the following error message:

joancarrerasdz@MacBook-Pro-de-Joan ~ % docker run -ti --rm \
  -v /Users/joancarrerasdz/Desktop/CARPETES/UdG/Pràctiques/Dades_ADNI/BIDS_DIRECTORY:/data:ro \
  -v /Users/joancarrerasdz/Desktop/CARPETES/UdG/Pràctiques/DATA_PREP:/out \
  -v /Users/joancarrerasdz/Desktop/CARPETES/UdG/Pràctiques/freesurfer_license.txt:/LICENSE:ro \
  nipreps/fmriprep \
  /data /out/fmriprep participant \
  -w /work \
  --fs-license-file /Applications/freesurfer/license.txt \  
  --fs-subjects-dir /Applications/freesurfer/subjects

However, it seems that I have the license.txt file as you can see below.

Thank you,
Joan

Hi @Joan_Carreras_Diaz,

These statements conflict with each other. You mount /Users/joancarrerasdz/Desktop/CARPETES/UdG/Pràctiques/freesurfer_license.txt:/LICENSE, but then you tell fMRIPrep that your --fs-license-file /Applications/freesurfer/license.txt. If your license is indeed at /Users/joancarrerasdz/Desktop/CARPETES/UdG/Pràctiques/freesurfer_license.txt, then your fMRIPrep argument should be --fs-license-file /LICENSE, since that is where your mount it in the container.

fMRIPrep will not be able to find this, since you have not mounted /Applications/freesurfer to the container. You can add -v /Applications/freesurfer to do this mounting.

You have not defined /work anywhere, as far as I can tell. You should define this as somewhere outside the BIDS directory, ideally.

In summary, your command can look like the following:

docker run -ti --rm \
  -v /Users/joancarrerasdz/Desktop/CARPETES/UdG/Pràctiques/Dades_ADNI/BIDS_DIRECTORY:/data \
  -v /Users/joancarrerasdz/Desktop/CARPETES/UdG/Pràctiques/freesurfer_license.txt:/LICENSE:ro \
  -v /PATH/TO/WORKINGDIR:/work \ # CHANGE THIS TO WHERE YOU WANT IT TO BE
  -v /Applications/freesurfer/ \
  nipreps/fmriprep:23.2.0 \
  /data /data/derivatives/fmriprep participant \
  -w /work \
  --fs-license-file /LICENSE \  
  --fs-subjects-dir /Applications/freesurfer/subjects

Best,
Steven

Dear Steven,

Once I compiled the lines you have provided, I have obtained the following warnings. How can I solve it?

Afterwards, I’ve looked if the data has been created but it only appeared one folder with a large name and the file named layout_index-sqlite as you can see below.

Hi @Joan_Carreras_Diaz,

My bad. As you can see, the data is mounted as a read only file system (the :ro at the end). Simply remove the :ro and you will be able to write.

Regarding the BIDS validation warnings, they will not preclude you from running fMRIPrep. The lack of SliceTiming will preclude you from doing slice timing correction, however.

Best,
Steven

Great, I have modified the line and now it seems to work. However, at the end of the preprocessing it has appeared this message.

Meanwhile, the folder where I wanted to send the data has filled as you can see below.


Has the process worked well? Or has happened something that it shouldn’t have?

Thank you,
Joan

Hi @Joan_Carreras_Diaz,

In the future, please share code and terminal outputs as text here, formatted with tick marks by using the </> button in the text editor so it looks nice

Like this.

It is easier for us to read than screenshots.

The error indicates that a process has been killed which means you likely did not have enough memory devoted to the job. What kind of resources do you have available? How much data does each subject have? You might have better luck processing subjects one at a time.

Best,
Steven

Right, actually I am working with the BIDS data generated from the whole data downloaded in ADNI of just one subject.

The exact error shown in the .html file is the following one:
Errors.txt (25.6 KB)

Dear Neurostars team,
I have been trying to preprocess the fMRI data from fMRIPREP following the tutorial given in this page: Functional Neuroimaging Analysis in Python . However, once I try to execute the command preproc_T1 = layout.get(datatype='anat', desc='preproc', extension=".nii.gz") it does not seem to happen anything.

On the other hand, I don’t have exactly the same results as in the tutorial, obtaining different files and results in the fmriprep folder. Even I get one Error in the fMRIPREP conversion, as it can be seen in here.
Errors.txt (25.6 KB)

I am unaware if this error is significative and it is the main cause of my problems. If not, how could I obtain the desired results as in the tutorial with my data?

The tree of the fmriprep folder is the following one:

/Users/joancarrerasdz/Desktop/CARPETES/UdG/Pràctiques/Dades_ADNI/BIDS_DIRECTORY/derivatives/fmriprep
├── dataset_description.json
├── logs
├── sub-ADNI002S0413
└── sub-ADNI002S0413.html

/Users/joancarrerasdz/Desktop/CARPETES/UdG/Pràctiques/Dades_ADNI/BIDS_DIRECTORY/derivatives/fmriprep/sub-ADNI002S0413
├── figures
│   ├── sub-ADNI002S0413_desc-conform_T1w.html
│   ├── sub-ADNI002S0413_ses-M000_desc-about_T1w.html
│   ├── sub-ADNI002S0413_ses-M000_desc-summary_T1w.html
│   ├── sub-ADNI002S0413_ses-M060_task-rest_desc-validation_bold.html
│   ├── sub-ADNI002S0413_ses-M072_task-rest_desc-validation_bold.html
│   ├── sub-ADNI002S0413_ses-M084_task-rest_desc-validation_bold.html
│   ├── sub-ADNI002S0413_ses-M096_task-rest_desc-validation_bold.html
│   └── sub-ADNI002S0413_ses-M132_task-rest_desc-validation_bold.html
├── log
│   └── 20240117-185138_35bcf3be-da65-485c-a6b4-fb456cf9e865
│       ├── crash-20240117-201746-root-anat_merge-b67922a0-fe47-4606-bd80-2ff14f427aa1.txt
│       └── fmriprep.toml
├── ses-M060
│   └── func
│       ├── sub-ADNI002S0413_ses-M060_task-rest_desc-coreg_boldref.json
│       ├── sub-ADNI002S0413_ses-M060_task-rest_desc-coreg_boldref.nii.gz
│       ├── sub-ADNI002S0413_ses-M060_task-rest_desc-hmc_boldref.json
│       ├── sub-ADNI002S0413_ses-M060_task-rest_desc-hmc_boldref.nii.gz
│       ├── sub-ADNI002S0413_ses-M060_task-rest_from-orig_to-boldref_mode-image_desc-hmc_xfm.json
│       └── sub-ADNI002S0413_ses-M060_task-rest_from-orig_to-boldref_mode-image_desc-hmc_xfm.txt
├── ses-M072
│   └── func
│       ├── sub-ADNI002S0413_ses-M072_task-rest_desc-coreg_boldref.json
│       ├── sub-ADNI002S0413_ses-M072_task-rest_desc-coreg_boldref.nii.gz
│       ├── sub-ADNI002S0413_ses-M072_task-rest_desc-hmc_boldref.json
│       ├── sub-ADNI002S0413_ses-M072_task-rest_desc-hmc_boldref.nii.gz
│       ├── sub-ADNI002S0413_ses-M072_task-rest_from-orig_to-boldref_mode-image_desc-hmc_xfm.json
│       └── sub-ADNI002S0413_ses-M072_task-rest_from-orig_to-boldref_mode-image_desc-hmc_xfm.txt
├── ses-M084
│   └── func
│       ├── sub-ADNI002S0413_ses-M084_task-rest_desc-coreg_boldref.json
│       ├── sub-ADNI002S0413_ses-M084_task-rest_desc-coreg_boldref.nii.gz
│       ├── sub-ADNI002S0413_ses-M084_task-rest_desc-hmc_boldref.json
│       ├── sub-ADNI002S0413_ses-M084_task-rest_desc-hmc_boldref.nii.gz
│       ├── sub-ADNI002S0413_ses-M084_task-rest_from-orig_to-boldref_mode-image_desc-hmc_xfm.json
│       └── sub-ADNI002S0413_ses-M084_task-rest_from-orig_to-boldref_mode-image_desc-hmc_xfm.txt
├── ses-M096
│   └── func
│       ├── sub-ADNI002S0413_ses-M096_task-rest_desc-coreg_boldref.json
│       ├── sub-ADNI002S0413_ses-M096_task-rest_desc-coreg_boldref.nii.gz
│       ├── sub-ADNI002S0413_ses-M096_task-rest_desc-hmc_boldref.json
│       ├── sub-ADNI002S0413_ses-M096_task-rest_desc-hmc_boldref.nii.gz
│       ├── sub-ADNI002S0413_ses-M096_task-rest_from-orig_to-boldref_mode-image_desc-hmc_xfm.json
│       └── sub-ADNI002S0413_ses-M096_task-rest_from-orig_to-boldref_mode-image_desc-hmc_xfm.txt
└── ses-M132
    └── func
        ├── sub-ADNI002S0413_ses-M132_task-rest_desc-coreg_boldref.json
        ├── sub-ADNI002S0413_ses-M132_task-rest_desc-coreg_boldref.nii.gz
        ├── sub-ADNI002S0413_ses-M132_task-rest_desc-hmc_boldref.json
        ├── sub-ADNI002S0413_ses-M132_task-rest_desc-hmc_boldref.nii.gz
        ├── sub-ADNI002S0413_ses-M132_task-rest_from-orig_to-boldref_mode-image_desc-hmc_xfm.json
        └── sub-ADNI002S0413_ses-M132_task-rest_from-orig_to-boldref_mode-image_desc-hmc_xfm.txt

Thank you.

Hi @Joan_Carreras_Diaz,

From your tree output, you can see you have no preprocessed full BOLD timeseries (e.g., any desc-preproc_bold.nii.gz, which explains why the layout finder command is not returning anything.

├── ses-M060
│   └── func
│       ├── sub-ADNI002S0413_ses-M060_task-rest_desc-coreg_boldref.json
│       ├── sub-ADNI002S0413_ses-M060_task-rest_desc-coreg_boldref.nii.gz
│       ├── sub-ADNI002S0413_ses-M060_task-rest_desc-hmc_boldref.json
│       ├── sub-ADNI002S0413_ses-M060_task-rest_desc-hmc_boldref.nii.gz
│       ├── sub-ADNI002S0413_ses-M060_task-rest_from-orig_to-boldref_mode-image_desc-hmc_xfm.json
│       └── sub-ADNI002S0413_ses-M060_task-rest_from-orig_to-boldref_mode-image_desc-hmc_xfm.txt

From your error file:

Stderr:
	Killed
Traceback:
	Traceback (most recent call last):
	  File "/opt/conda/envs/fmriprep/lib/python3.10/site-packages/nipype/interfaces/base/core.py", line 453, in aggregate_outputs
	    setattr(outputs, key, val)
	  File "/opt/conda/envs/fmriprep/lib/python3.10/site-packages/nipype/interfaces/base/traits_extension.py", line 330, in validate
	    value = super(File, self).validate(objekt, name, value, return_pathlike=True)
	  File "/opt/conda/envs/fmriprep/lib/python3.10/site-packages/nipype/interfaces/base/traits_extension.py", line 135, in validate
	    self.error(objekt, name, str(value))
	  File "/opt/conda/envs/fmriprep/lib/python3.10/site-packages/traits/base_trait_handler.py", line 74, in error
	    raise TraitError(
	traits.trait_errors.TraitError: The 'out_file' trait of a RobustTemplateOutputSpec instance must be a pathlike object or string representing an existing file, but a value of '/work/fmriprep_23_2_wf/sub_ADNI002S0413_wf/anat_fit_wf/anat_template_wf/anat_merge/sub-ADNI002S0413_ses-M000_T1w_noise_corrected_ras_template.nii.gz'  was specified.

	During handling of the above exception, another exception occurred:

	Traceback (most recent call last):
	  File "/opt/conda/envs/fmriprep/lib/python3.10/site-packages/nipype/interfaces/base/core.py", line 400, in run
	    outputs = self.aggregate_outputs(runtime)
	  File "/opt/conda/envs/fmriprep/lib/python3.10/site-packages/nipype/interfaces/base/core.py", line 460, in aggregate_outputs
	    raise FileNotFoundError(msg)
	FileNotFoundError: No such file or directory '/work/fmriprep_23_2_wf/sub_ADNI002S0413_wf/anat_fit_wf/anat_template_wf/anat_merge/sub-ADNI002S0413_ses-M000_T1w_noise_corrected_ras_template.nii.gz' for output 'out_file' of a StructuralReference interface

As we mentioned to you in earlier posts (such as one below), the Stderr: Killed means you are likely running into out of memory issues.

Best,
Steven

Hi,
I have tried to do the fMRIPREP again with the sample data downloaded in openneuro. However, once I try to do the fimri-prep docker function I obtain the following error message:
ErrorfMRIPREP.txt (4.0 KB)

Whether I compile using the code $ fmriprep-docker /path/to/data/dir /path/to/output/dir participant or the one you gave me previously, I obtain the same result.

On the other hand, I have tried to follow the YouTube tutorial fMRIPrep Tutorial #2: Creating the Script by Andrew Jahn, but once I try to run the fmriprep_singleSubj.sh file, it does not happen anything.

Thank you,
Joan