-
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
[FIX] PET Spec; added known DICOM tags, fixed tag error, updated citation, clarified scale factor. #1021
Conversation
src/04-modality-specific-files/09-positron-emission-tomography.md
Outdated
Show resolved
Hide resolved
Added dicom tag description for `InjectionStart`
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.
good to merge IMO assuming i did not forget brackets or commas :-)
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.
There are some minor formatting issues with the macro calls, and I have one question about the updated definition for ScaleFactor. Thanks!
src/04-modality-specific-files/09-positron-emission-tomography.md
Outdated
Show resolved
Hide resolved
src/04-modality-specific-files/09-positron-emission-tomography.md
Outdated
Show resolved
Hide resolved
src/04-modality-specific-files/09-positron-emission-tomography.md
Outdated
Show resolved
Hide resolved
src/04-modality-specific-files/09-positron-emission-tomography.md
Outdated
Show resolved
Hide resolved
src/04-modality-specific-files/09-positron-emission-tomography.md
Outdated
Show resolved
Hide resolved
src/04-modality-specific-files/09-positron-emission-tomography.md
Outdated
Show resolved
Hide resolved
src/04-modality-specific-files/09-positron-emission-tomography.md
Outdated
Show resolved
Hide resolved
src/schema/objects/metadata.yaml
Outdated
@@ -2293,7 +2293,7 @@ SamplingFrequency: | |||
ScaleFactor: | |||
name: ScaleFactor | |||
description: | | |||
Scale factor for each frame. | |||
Scale factor for each frame. Values must be set if the imaging data (.nii) are unscaled, otherwise set to 1. |
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.
Could you explain this a bit for me? I don't do PET, so I'm a little confused. It sounds like you're saying that this field is REQUIRED if the data are unscaled, but also required if they aren't.
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.
I'm going to have to refresh my memory on this as well, but I seem to recall that we ran into some double scaling occurring as a result of converting to nifti (this smells of ECAT). And we wanted to preserve that scaling history in some way in the spec.
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.
I can see how you would need the scaling factor in that case, but I'm still confused about what the update to the description is meant to convey.
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.
it makes explicit something that was implicit - some conversion wrote the scaling values in the json and applied to the data then what should a user do then? with that change we know
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.
I'm still confused. Perhaps the source of my confusion will be clearer if I break the added sentence down.
Part 1: "Values must be set if the imaging data (.nii) are unscaled"
My interpretation: If the data are unscaled, ScaleFactor
is required.
Part 2: "otherwise set to 1."
My interpretation: If the data are scaled, ScaleFactor
is required.
The combined interpretation would thus be, regardless of whether the data are scaled or not, ScaleFactor
is required. But then, in the table, ScaleFactor
isn't required, it's recommended.
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.
I think the concern is that by updating ScaleFactor
to required will break the few currently passing datasets that are out there. @mnoergaard had some concerns regarding this so I will let him weigh in on this.
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.
You're right, that would break backwards compatibility. How about something like this?
This field MUST be defined if the imaging data (.nii[.gz]) are scaled. If this field is not defined, then it is assumed that the scaling factor is 1. Defining this field when the scaling factor is 1 is recommended, for the sake of clarity.
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.
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.
yep perfect thx @tsalo
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.
Updated here, should be gtg.
Co-authored-by: Taylor Salo <[email protected]>
Co-authored-by: Taylor Salo <[email protected]>
Co-authored-by: Taylor Salo <[email protected]>
Co-authored-by: Taylor Salo <[email protected]>
Co-authored-by: Taylor Salo <[email protected]>
Co-authored-by: Taylor Salo <[email protected]>
Co-authored-by: Taylor Salo <[email protected]>
- Fixed markdown formatting in src/01-introduction.md - Removed dicom tag description for InjectionTimeStart in src/04-modality-specific-files/09-positron-emission-tomography.md as there is some disagreement on whether dicom tag Radiopharmaceutical Start Time (0018, 1072) should be referenced.
@@ -154,8 +154,8 @@ which we divide into several categories: | |||
|
|||
{{ MACROS___make_metadata_table( | |||
{ | |||
"TracerName": "REQUIRED", | |||
"TracerRadionuclide": "REQUIRED", | |||
"TracerName": ("REQUIRED", "Corresponds to DICOM Tags (0008,0105) `Mapping Resource` and (0008,0122) `Mapping Resource Name`."), |
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.
Why aren't we putting these in the metadata.yaml directly?
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.
well some were in yaml some were in spec, and there is no rule to decide --so being lazy i pushed all new ones there
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.
The rule I would use is whether the BIDS term unambiguously corresponds to a DICOM tag (so would be sensible to render any time the term is rendered), or if it corresponds to a DICOM tag in the specific context of a particular table.
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.
I'm not confident enough to say that these tags should belong in the metadata.yml
as many of these terms are often more explicitly defined (or known....) by the experiment designer/performer or simply not present in the dicom headers. Adding them to the tables provides a bread crumb for a user to extract this info if they're not omnipotent concerning the experiment or the metadata.
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.
"Corresponds to DICOM Tag" doesn't say to me "MUST be derived from DICOM Tag". I think linking the concepts in the term definition helps clarify.
That said, I won't die on this hill. We can move these into metadata.yaml
in the future as well.
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.
"Corresponds to DICOM Tag" doesn't say to me "MUST be derived from DICOM Tag". I think linking the concepts in the term definition helps clarify.
That said, I won't die on this hill. We can move these into
metadata.yaml
in the future as well.
Agreed. Have already noticed in this PR that it's very easy 🙄 to add something into these tables and duplicate what's in the metadata.yaml
or vice versa.
Update Scale Factor description to consensus
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.
+1 to merge once my minor suggestions have been incorporated.
@tsalo you still have a "changes requested" blocking review. Could you please confirm that your concerns have been addressed (seems like it) and re-review? |
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.
LGTM!
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.
LGTM! thanks!
Co-authored-by: Stefan Appelhoff <[email protected]>
Thanks @bendhouseart and @CPernet and all reviewers :-) |
Codecov ReportAll modified and coverable lines are covered by tests ✅
Additional details and impacted files@@ Coverage Diff @@
## master #1021 +/- ##
===========================================
+ Coverage 34.05% 71.50% +37.45%
===========================================
Files 8 9 +1
Lines 834 930 +96
===========================================
+ Hits 284 665 +381
+ Misses 550 265 -285 ☔ View full report in Codecov by Sentry. |
very funny to receive a codecov report here, more than two years after the last push 🤔 |
Small updates to the PET spec: