ENH: Support combined surface-volume reference spaces#883
Draft
tsalo wants to merge 11 commits into
Draft
Conversation
Codecov ReportAttention: Patch coverage is
Additional details and impacted files@@ Coverage Diff @@
## master #883 +/- ##
==========================================
- Coverage 69.40% 69.32% -0.09%
==========================================
Files 86 86
Lines 8483 8526 +43
Branches 1059 1079 +20
==========================================
+ Hits 5888 5911 +23
- Misses 2373 2387 +14
- Partials 222 228 +6 ☔ View full report in Codecov by Sentry. |
tsalo
commented
Jul 23, 2024
| if self.space.startswith("fs"): | ||
| object.__setattr__(self, "dim", 2) | ||
|
|
||
| if "volspace" in self.spec: |
Contributor
Author
There was a problem hiding this comment.
This check would hopefully only be necessary in the short-term, since mixed standard/non-standard CIFTIs should be allowed.
tsalo
commented
Aug 5, 2024
Comment on lines
+151
to
+152
| cifti = attr.ib(default=False, repr=False, type=bool) | ||
| """Whether this space is a CIFTI space or not.""" |
Contributor
Author
There was a problem hiding this comment.
Alternatively, I could use a new dim value, like 2.5, instead of adding this attribute.
This was referenced Sep 20, 2024
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Closes #881. This is a ways away from being usable, but it might be good to get folks' thoughts on it before I put too much effort into it.
The basic idea is that users can request any combination of surface and volume that they might want as output CIFTIs.
For example, the common
fsLRspace withden-91kcorresponds to CIFTIs with the left and right hemisphere surface components in fsLR space with 32k vertices in each hemisphere and the subcortical volumetric component in MNI152NLin6Asym space with 2 mm voxels. In my proposal, users would define that as--output-spaces fsLR:den-32k::MNI152NLin6Asym:res-02. This could also be extended to other combinations, such as:To discuss:
<source_entities>_space-dhcpAsym_cohort-42_volspace-MNIInfant_volcohort-2_den-32k_res-1_bold.dtseries.nii, maybe<source_entities>_space-dhcpAsym42+MNIInfant2_den-32k_res-1_bold.dtseries.nii.cohort,volspace, andvolcohortare not part of BIDS at the moment, so this approach would require fewer changes to BIDS (though we'd still need to allow+symbols in entity values).Changes proposed:
::) to allow combinations of surfaces and volumes for CIFTIs.specdictionary.ciftiattribute to the Reference object to denote if a space is CIFTI or not.