Skip to content
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

Accept external atlases by searching BIDS-Atlas datasets #1265

Merged
merged 74 commits into from
Oct 4, 2024

Conversation

tsalo
Copy link
Member

@tsalo tsalo commented Sep 16, 2024

Closes #1226.

Allow users to provide paths to BIDS-Atlas datasets via the --datasets (renamed from --derivatives) parameter, as well as names of atlases in those datasets via the --atlases parameter.

Atlases need to be in fsLR-32k space (for CIFTI processing) or MNIInfant/MNI152NLin6Asym/MNI152NLin2009cAsym space (for NIfTI processing). This space/resolution limitation is hopefully only temporary, since I ultimately want to accept almost any input space. See #1076.

Changes to inputs

  • No changes to inputs

Changes to outputs

  • Output atlas sidecar files (i.e., JSONs in the atlases dataset) now share all of the same entities as the image file. Before they only had the atlas entity.

Internal changes

  • Reorganize internal atlases into a BIDS-Atlas dataset. The 4S atlases from AtlasPack are in a BIDS-Atlas dataset now as well (from xcpd_build).

@tsalo tsalo added the enhancement New feature or request label Sep 16, 2024
Copy link

codecov bot commented Sep 17, 2024

Codecov Report

Attention: Patch coverage is 91.42857% with 15 lines in your changes missing coverage. Please review.

Project coverage is 78.80%. Comparing base (68caadf) to head (dc18585).
Report is 42 commits behind head on main.

Files with missing lines Patch % Lines
xcp_d/utils/atlas.py 88.46% 3 Missing and 3 partials ⚠️
xcp_d/utils/utils.py 89.28% 0 Missing and 3 partials ⚠️
xcp_d/interfaces/connectivity.py 66.66% 2 Missing ⚠️
xcp_d/cli/combineqc.py 0.00% 1 Missing ⚠️
xcp_d/cli/parser.py 85.71% 0 Missing and 1 partial ⚠️
xcp_d/workflows/anatomical/parcellation.py 95.65% 0 Missing and 1 partial ⚠️
xcp_d/workflows/bold/cifti.py 50.00% 0 Missing and 1 partial ⚠️
Additional details and impacted files
@@            Coverage Diff             @@
##             main    #1265      +/-   ##
==========================================
+ Coverage   78.63%   78.80%   +0.16%     
==========================================
  Files          59       59              
  Lines        7308     7360      +52     
  Branches     1106     1136      +30     
==========================================
+ Hits         5747     5800      +53     
+ Misses       1273     1267       -6     
- Partials      288      293       +5     

☔ View full report in Codecov by Sentry.
📢 Have feedback on the report? Share it here.

@tsalo tsalo marked this pull request as ready for review October 4, 2024 20:31
@tsalo
Copy link
Member Author

tsalo commented Oct 4, 2024

Tests are passing, coverage is up, and the new behavior is documented, so I think we're good to go!

@tsalo tsalo added the breaking-change PRs that change results or interfaces. label Oct 4, 2024
@tsalo tsalo changed the title Accept BIDS-Atlas datasets as atlases Accept external atlases by search BIDS-Atlas datasets Oct 4, 2024
@tsalo tsalo changed the title Accept external atlases by search BIDS-Atlas datasets Accept external atlases by searching BIDS-Atlas datasets Oct 4, 2024
@tsalo tsalo merged commit 9dea9cb into PennLINC:main Oct 4, 2024
23 checks passed
@tsalo tsalo deleted the bids-atlas branch October 4, 2024 20:47
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
breaking-change PRs that change results or interfaces. enhancement New feature or request
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Allow external atlases organized as BIDS datasets
1 participant