-
Notifications
You must be signed in to change notification settings - Fork 161
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
[SCHEMA] Add MEG, func, and fmap metadata tables #1054
Merged
tsalo
merged 5 commits into
bids-standard:schema/sidecar_validation
from
tsalo:other-sections
Apr 8, 2022
Merged
Changes from 3 commits
Commits
File filter
Filter by extension
Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
There are no files selected for viewing
This file contains 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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,87 @@ | ||
# | ||
# Groups of related metadata fields | ||
# | ||
# Assumptions: never need disjunction of selectors | ||
# Assumptions: top-to-bottom overrides is sufficient logic | ||
|
||
|
||
--- | ||
# Fieldmap data | ||
MRIFieldmapB0FieldIdentifier: | ||
selectors: | ||
- modality == "MRI" | ||
- datatype == "fmap" | ||
fields: | ||
B0FieldIdentifier: RECOMMENDED | ||
|
||
MRIFieldmapIntendedFor: | ||
selectors: | ||
- modality == "MRI" | ||
- datatype == "fmap" | ||
fields: | ||
IntendedFor: | ||
level: OPTIONAL | ||
addendum: | | ||
This field is OPTIONAL, and in case the fieldmaps do not correspond | ||
to any particular scans, it does not have to be filled. | ||
|
||
# Case 1: Phase-difference map and at least one magnitude image | ||
MRIFieldmapPhaseDifferencePhasediff: | ||
selectors: | ||
- modality == "MRI" | ||
- datatype == "fmap" | ||
- suffix == "phasediff" | ||
fields: | ||
EchoTime1: REQUIRED | ||
EchoTime2: REQUIRED | ||
|
||
MRIFieldmapPhaseDifferenceMagnitude1: | ||
selectors: | ||
- modality == "MRI" | ||
- datatype == "fmap" | ||
- suffix == "magnitude1" | ||
fields: | ||
EchoTime1: REQUIRED | ||
|
||
MRIFieldmapPhaseDifferenceMagnitude2: | ||
selectors: | ||
- modality == "MRI" | ||
- datatype == "fmap" | ||
- suffix == "magnitude2" | ||
fields: | ||
EchoTime2: REQUIRED | ||
|
||
# Case 2: Two phase maps and two magnitude images | ||
# NOTE: Need to check for presence of related files. | ||
# For example, magnitude1 needs EchoTime__fmap only if phase1 file exists, | ||
# but EchoTime1 if phasediff exists. | ||
MRIFieldmapTwoPhase: | ||
selectors: | ||
- modality == "MRI" | ||
- datatype == "fmap" | ||
- suffix in ["phase1", "phase2", "magnitude1", "magnitude2"] | ||
fields: | ||
EchoTime__fmap: REQUIRED | ||
|
||
# Case 3: Direct field mapping | ||
MRIFieldmapDirectFieldMapping: | ||
selectors: | ||
- modality == "MRI" | ||
- datatype == "fmap" | ||
- suffix in ["phase", "fieldmap"] | ||
fields: | ||
Units: | ||
level: REQUIRED | ||
addendum: | | ||
Fieldmaps must be in units of Hertz (`"Hz"`), | ||
radians per second (`"rad/s"`), or Tesla (`"T"`). | ||
|
||
# Case 4: Multiple phase encoded directions ("pepolar") | ||
MRIFieldmapPepolar: | ||
selectors: | ||
- modality == "MRI" | ||
- datatype == "fmap" | ||
- suffix == "epi" | ||
fields: | ||
PhaseEncodingDirection: REQUIRED | ||
TotalReadoutTime: REQUIRED |
This file contains 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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,105 @@ | ||
# | ||
# Groups of related metadata fields | ||
# | ||
# Assumptions: never need disjunction of selectors | ||
# Assumptions: top-to-bottom overrides is sufficient logic | ||
|
||
|
||
--- | ||
# Task imaging data | ||
|
||
# Required fields | ||
MRIFuncRequired: | ||
selectors: | ||
- modality == "MRI" | ||
- datatype == "func" | ||
fields: | ||
RepetitionTime: REQUIRED | ||
VolumeTiming: REQUIRED | ||
TaskName: | ||
level: REQUIRED | ||
addendum: | | ||
A RECOMMENDED convention is to name resting state task using labels | ||
beginning with `rest`. | ||
|
||
# Timing Parameters | ||
MRIFuncTimingParameters: | ||
selectors: | ||
- modality == "MRI" | ||
- datatype == "func" | ||
fields: | ||
NumberOfVolumesDiscardedByScanner: RECOMMENDED | ||
NumberOfVolumesDiscardedByUser: RECOMMENDED | ||
DelayTime: RECOMMENDED | ||
AcquisitionDuration: | ||
level: RECOMMENDED | ||
level_addendum: | | ||
REQUIRED for sequences that are described with the `VolumeTiming` | ||
field and that do not have the `SliceTiming` field set to allow for | ||
accurate calculation of "acquisition time" | ||
DelayAfterTrigger: RECOMMENDED | ||
|
||
# The mutual exclusion table, spread across 5 definitions | ||
MRIFuncTimingParametersMutualExclusion1: | ||
selectors: | ||
- modality == "MRI" | ||
- datatype == "func" | ||
- sidecar contains "RepetitionTime" | ||
fields: | ||
AcquisitionDuration: PROHIBITED | ||
VolumeTiming: PROHIBITED | ||
|
||
MRIFuncTimingParametersMutualExclusion2: | ||
selectors: | ||
- modality == "MRI" | ||
- datatype == "func" | ||
- sidecar contains "SliceTiming" | ||
- sidecar contains "VolumeTiming" | ||
fields: | ||
RepetitionTime: PROHIBITED | ||
DelayTime: PROHIBITED | ||
|
||
MRIFuncTimingParametersMutualExclusion3: | ||
selectors: | ||
- modality == "MRI" | ||
- datatype == "func" | ||
- sidecar contains "AcquisitionDuration" | ||
- sidecar contains "VolumeTiming" | ||
fields: | ||
RepetitionTime: PROHIBITED | ||
DelayTime: PROHIBITED | ||
|
||
MRIFuncTimingParametersMutualExclusion4: | ||
selectors: | ||
- modality == "MRI" | ||
- datatype == "func" | ||
- sidecar contains "RepetitionTime" | ||
- sidecar contains "SliceTiming" | ||
fields: | ||
AcquisitionDuration: PROHIBITED | ||
VolumeTiming: PROHIBITED | ||
|
||
MRIFuncTimingParametersMutualExclusion5: | ||
selectors: | ||
- modality == "MRI" | ||
- datatype == "func" | ||
- sidecar contains "RepetitionTime" | ||
- sidecar contains "DelayTime" | ||
fields: | ||
AcquisitionDuration: PROHIBITED | ||
VolumeTiming: PROHIBITED | ||
|
||
# fMRI task information | ||
MRIFuncTaskInformation: | ||
selectors: | ||
- modality == "MRI" | ||
- datatype == "func" | ||
fields: | ||
Instructions: | ||
level: RECOMMENDED | ||
addendum: | | ||
This is especially important in context of resting state recordings and | ||
distinguishing between eyes open and eyes closed paradigms. | ||
TaskDescription: RECOMMENDED | ||
CogAtlasID: RECOMMENDED | ||
CogPOID: RECOMMENDED |
Oops, something went wrong.
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.
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.
This is probably worth discussing. New PROHIBITED level.
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.
Actually I'll just add a note to the HackMD.