-
Notifications
You must be signed in to change notification settings - Fork 52
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
ENH: Add optional session filter when collecting data #678
Conversation
@effigies looks like using
|
Actually, I think this is expected
Perhaps there needs to be another value for Query that mimics ANY, but allows undefined entities as well. |
Oh damn.
I guess we don't currently have a query enum that would do what I was thinking. I guess we need to revert to what you had, but let's open an issue on PyBIDS to allow a query that means it can be present or absent (maybe |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
As per the new docstring, session_id
can be None
. If so, it would be better to make the value replacement the latest possible, rather than the default parameter.
niworkflows/utils/bids.py
Outdated
@@ -145,6 +146,7 @@ def collect_participants( | |||
def collect_data( | |||
bids_dir, | |||
participant_label, | |||
session_id=Query.ANY, |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
session_id=Query.ANY, | |
session_id=None, |
Perhaps |
OMG you guys are fast :) |
Co-authored-by: Chris Markiewicz <markiewicz@stanford.edu>
ff3899a
to
61a1df9
Compare
Codecov Report
@@ Coverage Diff @@
## master #678 +/- ##
==========================================
- Coverage 49.14% 47.38% -1.77%
==========================================
Files 49 45 -4
Lines 5858 5605 -253
Branches 834 808 -26
==========================================
- Hits 2879 2656 -223
+ Misses 2871 2854 -17
+ Partials 108 95 -13
Flags with carried forward coverage won't be shown. Click here to find out more.
Continue to review full report at Codecov.
|
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Looks good.
A slight alteration to provide session level control.