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

feat: Add DICOM SEG support and MPR, referenceLines and StackSync and more #3015

Merged
merged 117 commits into from
Nov 16, 2022

Conversation

sedghi
Copy link
Member

@sedghi sedghi commented Nov 11, 2022

This PR adds support for DICOM SEG read and various other features. Here is the summary

  1. DICOM SEG read is now added in the longitudinal mode (though you can add it to your own mode as well, just add the extension as dependency and sopClassHandler).
ohif-v3-rc-seg.mp4
  1. MPR support is added via click of a button in the toolbar. If the displaySet is reconstructable it can go MPR (SEG currently load as volume so it is possible to view SEG in MPR)
ohif-v3-rc-mpr.mp4
  1. New Side panels. Previously you had to close a panel to open another one, but the new design adds a better user experience for switching panels

panels

  1. New Reference Line Tools
ohif-v3-rc-reference-lines.mp4
  1. New Stack Synchronization tool across studies

Blocked by dcmjs-org/dicomweb-client#62

Thanks to

@netlify
Copy link

netlify bot commented Nov 11, 2022

Deploy Preview for ohif-platform-viewer ready!

Name Link
🔨 Latest commit c96c01a
🔍 Latest deploy log https://app.netlify.com/sites/ohif-platform-viewer/deploys/6374a5061f551c000c45e646
😎 Deploy Preview https://deploy-preview-3015--ohif-platform-viewer.netlify.app/
📱 Preview on mobile
Toggle QR Code...

QR Code

Use your smartphone camera to open QR code link.

To edit notification comments on pull requests, go to your Netlify site settings.

@netlify
Copy link

netlify bot commented Nov 11, 2022

Deploy Preview for ohif-platform-docs ready!

Name Link
🔨 Latest commit
🔍 Latest deploy log https://app.netlify.com/sites/ohif-platform-docs/deploys/6374c1d6728d5146d627f4a5
😎 Deploy Preview https://deploy-preview-3015--ohif-platform-docs.netlify.app
📱 Preview on mobile
Toggle QR Code...

QR Code

Use your smartphone camera to open QR code link.

To edit notification comments on pull requests, go to your Netlify site settings.

@Georift
Copy link
Contributor

Georift commented Nov 11, 2022

Woah man this is exciting 🙂 I'll definitely be cracking open this branch when I get a spare second.

Copy link
Member

@swederik swederik left a comment

Choose a reason for hiding this comment

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

LGTM with some minor comments

extensions/cornerstone-dicom-seg/LICENSE Outdated Show resolved Hide resolved
extensions/cornerstone-dicom-seg/package.json Outdated Show resolved Hide resolved
extensions/cornerstone/src/utils/transitions.ts Outdated Show resolved Hide resolved
// if the below formula is not correct, on a viewport reset
// it will jump to a different slice than the middle one which
// was the initial slice, and we have some tools such as Crosshairs
// which rely on a relative camera modifications and those will break.
Copy link
Member

Choose a reason for hiding this comment

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

Not sure I see why this should break crosshairs. Lets discuss

extensions/cornerstone/src/commandsModule.ts Outdated Show resolved Hide resolved
},
toggleStackImageSync: ({ toggledState }) => {
if (!toggledState) {
STACK_IMAGE_SYNC_GROUPS_INFO.forEach(syncGroupInfo => {
Copy link
Member

Choose a reason for hiding this comment

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

Commands module is getting pretty big, maybe it should be split into multiple files. Kind of ugly to start putting global variables at the top of the file like STACK_IMAGE_SYNC_GROUPS_INFO

Copy link
Member Author

Choose a reason for hiding this comment

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

Yeah, I don't like the STACK_IMAGE_SYNC_GROUPS_INFO either, but this is a kind of a global thing that we need, where else do you think I should put it?

return viewportData;
}

public async invalidateViewportData(
Copy link
Member

Choose a reason for hiding this comment

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

What is this used for? Not sure I get it

Copy link
Member Author

Choose a reason for hiding this comment

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

When displaySet gets invalidated (patient weight change)

@codecov
Copy link

codecov bot commented Nov 14, 2022

Codecov Report

Merging #3015 (c96c01a) into v3-stable (9f1e813) will increase coverage by 13.11%.
The diff coverage is n/a.

Impacted file tree graph

@@              Coverage Diff               @@
##           v3-stable    #3015       +/-   ##
==============================================
+ Coverage      25.15%   38.27%   +13.11%     
==============================================
  Files            119       98       -21     
  Lines           2862     2098      -764     
  Branches         555      432      -123     
==============================================
+ Hits             720      803       +83     
+ Misses          1856     1060      -796     
+ Partials         286      235       -51     
Impacted Files Coverage Δ
...tform/core/src/services/CineService/CineService.js 12.50% <0.00%> (-6.25%) ⬇️
.../services/MeasurementService/MeasurementService.js 47.23% <0.00%> (-1.96%) ⬇️
platform/core/src/classes/CommandsManager.js 90.69% <0.00%> (-1.14%) ⬇️
platform/core/src/classes/MetadataProvider.js 4.54% <0.00%> (-0.72%) ⬇️
...core/src/services/ToolBarService/ToolBarService.js 1.21% <0.00%> (-0.28%) ⬇️
platform/viewer/src/index.js 0.00% <0.00%> (ø)
platform/viewer/src/appInit.js 0.00% <0.00%> (ø)
platform/core/src/utils/index.js 100.00% <0.00%> (ø)
platform/core/src/utils/isImage.js 100.00% <0.00%> (ø)
platform/core/src/services/ServicesManager.js 100.00% <0.00%> (ø)
... and 48 more

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 08c58b0...c96c01a. Read the comment docs.

@cypress
Copy link

cypress bot commented Nov 14, 2022



Test summary

20 0 0 0


Run details

Project Viewers
Status Passed
Commit c96c01a
Started Nov 16, 2022 9:00 AM
Ended Nov 16, 2022 9:01 AM
Duration 01:46 💡
OS Linux Debian - 11.3
Browser Chrome 103

View run in Cypress Dashboard ➡️


This comment has been generated by cypress-bot as a result of this project's GitHub integration settings. You can manage this integration in this project's settings in the Cypress Dashboard

@sedghi sedghi changed the title Feat/dicom seg feat: Add DICOM SEG support and MPR, referenceLines and StackSync and more Nov 15, 2022
@JamesAPetts
Copy link
Member

Great work!

const segments = {};

dataset.SegmentSequence.forEach(segment => {
const cielab = segment.RecommendedDisplayCIELabValue;
Copy link

Choose a reason for hiding this comment

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

Here can be crashed. RecommendedDisplayCIELabValue is optional in dicom

Copy link
Member Author

Choose a reason for hiding this comment

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

Thanks I will fix it later

@manoocher
Copy link

Hi team,
This PR contains exciting features and improvement, I immediately deployed it all features are the our long waited ones. Though in PT/SR studies the Fusion is not listed in the study browser? I tried the same study with an old version (older then stable) and it works. What could be the cause?

@sedghi sedghi merged commit 83ea228 into v3-stable Nov 16, 2022
@sedghi sedghi deleted the feat/dicom-seg branch January 22, 2025 16:13
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.

6 participants