Skip to content

Commit

Permalink
Merge pull request #669 from arnaudbore/bf_bids
Browse files Browse the repository at this point in the history
[BF] bids_validate
  • Loading branch information
arnaudbore authored Jan 26, 2023
2 parents a172eef + 593e348 commit 858371b
Showing 1 changed file with 4 additions and 3 deletions.
7 changes: 4 additions & 3 deletions scripts/scil_validate_bids.py
Original file line number Diff line number Diff line change
Expand Up @@ -246,6 +246,7 @@ def get_data(layout, nSub, dwis, t1s, fs, default_readout, clean):
BIDS structure unkown.Please send an issue:
https://github.com/scilus/scilpy/issues
""")
return {}

# T1 setup
t1_path = 'todo'
Expand Down Expand Up @@ -325,15 +326,15 @@ def associate_dwis(layout, nSub):
phaseEncodingDirection = layout.get_PhaseEncodingDirection(**base_dict)
if len(phaseEncodingDirection) == 1:
logging.info("Found one phaseEncodingDirection.")
return [layout.get(part=Query.NONE, **base_dict) +
return [[el] for el in layout.get(part=Query.NONE, **base_dict) +\
layout.get(part='mag', **base_dict)]
elif len(directions) == 1:
logging.info("Found one direction.")
return [layout.get(part=Query.NONE, **base_dict) +
return [[el] for el in layout.get(part=Query.NONE, **base_dict) +\
layout.get(part='mag', **base_dict)]
elif not directions:
logging.info("Found no directions or PhaseEncodingDirections.")
return [layout.get(part=Query.NONE, **base_dict) +
return [[el] for el in layout.get(part=Query.NONE, **base_dict) +\
layout.get(part='mag', **base_dict)]

if len(phaseEncodingDirection) > 2 or len(directions) > 2:
Expand Down

0 comments on commit 858371b

Please sign in to comment.