Skip to content

[ENH] add option to include derivatives in BIDSDataGrabber #2815

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

Closed
wants to merge 4 commits into from

Conversation

jdkent
Copy link
Contributor

@jdkent jdkent commented Dec 8, 2018

Summary

The behavior of pybids changed from 0.5.* to 0.6.* such that the derivatives domain is not included in the default search pattern.
Fixes #2814

This pull request is partially overlapping with #2737

List of changes proposed in this PR (pull-request)

  • add domains option in BIDSDataGrabber for user to select what domains should be used for indexing files
  • add checks to modify behavior depending on which version of pybids is being used.

Acknowledgment

  • (Mandatory) I acknowledge that this contribution will be available under the Apache 2 license.

@codecov-io
Copy link

codecov-io commented Dec 8, 2018

Codecov Report

Merging #2815 into master will increase coverage by 0.01%.
The diff coverage is 58.33%.

Impacted file tree graph

@@            Coverage Diff             @@
##           master    #2815      +/-   ##
==========================================
+ Coverage   67.46%   67.48%   +0.01%     
==========================================
  Files         341      341              
  Lines       43331    43342      +11     
  Branches     5371     5374       +3     
==========================================
+ Hits        29235    29250      +15     
+ Misses      13396    13390       -6     
- Partials      700      702       +2
Flag Coverage Δ
#smoketests 50.54% <16.66%> (-0.02%) ⬇️
#unittests 64.9% <58.33%> (+0.03%) ⬆️
Impacted Files Coverage Δ
nipype/interfaces/io.py 53.99% <58.33%> (ø) ⬆️
nipype/pipeline/plugins/legacymultiproc.py 66% <0%> (+4.5%) ⬆️

Continue to review full report at Codecov.

Legend - Click here to learn more
Δ = absolute <relative> (impact), ø = not affected, ? = missing data
Powered by Codecov. Last update 1eeabd3...90e2952. Read the comment docs.

@effigies
Copy link
Member

@jdkent Sorry, I haven't had time to really think this through. Especially given that it may conflict with (I haven't checked) @adelavega's #2737 (which also needs to merge master), I think we should put this off to next release.

@effigies effigies added this to the 1.1.8 milestone Dec 14, 2018
exclude = None
if self.inputs.strict:
exclude = ['derivatives/', 'code/', 'sourcedata/']
layout = BIDSLayout(self.inputs.base_dir, exclude=exclude)

if pybids_ver < version.parse('0.5'):
Copy link
Contributor

@adelavega adelavega Dec 14, 2018

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Maybe you can include something like this in my PR? My PR is more general update to 0.7, and includes some extra functionality / updates, in addition to allowing for derivatives. I just hadn't merged because I'm waiting for pybids 0.7 release.

Copy link
Contributor

@adelavega adelavega Dec 14, 2018

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Although now that I think about it, I wouldn't worry too much about backwards compatibility. I would make 0.7 the hard requirement. The default behavior of my PR is to only look in the core BIDS folder, but you can optionally ask it to look in /derivatives or add extra paths.

@effigies effigies self-assigned this Jan 16, 2019
@effigies
Copy link
Member

Closing in favor of #2737. If further changes are needed, please open a new PR. (I think trying to merge and salvage a usable commit history from this one is probably not worth it.)

@effigies effigies closed this Jan 23, 2019
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

BIDSDataGrabber does not support derivatives domain
4 participants