Skip to content

Commit

Permalink
FIX: Ignore sourcedata and derivatives when fetching data
Browse files Browse the repository at this point in the history
  • Loading branch information
effigies committed Sep 25, 2019
1 parent c7c428c commit 7081a7c
Showing 1 changed file with 4 additions and 1 deletion.
5 changes: 4 additions & 1 deletion fmriprep/cli/run.py
Original file line number Diff line number Diff line change
Expand Up @@ -7,6 +7,7 @@
"""

import os
import re
from pathlib import Path
import logging
import sys
Expand Down Expand Up @@ -544,7 +545,9 @@ def build_workflow(opts, retval):
retval['run_uuid'] = run_uuid

# First check that bids_dir looks like a BIDS folder
layout = BIDSLayout(str(bids_dir), validate=False)
layout = BIDSLayout(str(bids_dir), validate=False,

This comment has been minimized.

Copy link
@bpinsard

bpinsard Oct 3, 2019

Collaborator

Why is validate=False here?
The main difference I found is that with validate=False, bold niftis without task defined will be taken into account. Took me some time to figure out why is wasn't behaving the same as pybids default or the niworkflow.util.bids.collect_participants https://github.com/poldracklab/niworkflows/blob/master/niworkflows/utils/bids.py#L45

This comment has been minimized.

ignore=("code", "stimuli", "sourcedata", "models",
"derivatives", re.compile(r'^\.')))
subject_list = collect_participants(
layout, participant_label=opts.participant_label)
retval['subject_list'] = subject_list
Expand Down

0 comments on commit 7081a7c

Please sign in to comment.