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

[Bug] Rectangle ROI Threshold Tool in TMTV is not working #4773

Open
abhijith-trenser opened this issue Feb 7, 2025 · 1 comment
Open

[Bug] Rectangle ROI Threshold Tool in TMTV is not working #4773

abhijith-trenser opened this issue Feb 7, 2025 · 1 comment
Assignees
Labels
Bugs Bug reported, reproducible, and verified.

Comments

@abhijith-trenser
Copy link
Contributor

abhijith-trenser commented Feb 7, 2025

Describe the Bug

The Rectangle ROI Threshold tool in TMTV mode is not functioning properly. Additionally, when attempting to fix this issue, several subsequent errors arise. It appears that in Cornerstone, the segmentationId and volumeId are now treated as separate entities, but in OHIF Viewer, we still attempt to fetch the segmentation using the volumeId (e.g., see: extensions/tmtv/src/utils/handleROIThresholding.ts#5). Here in v3.9 we got the volumeID instead of segmentationID.

Furthermore, the "Run" button required to execute the command is missing from the TMTV Segmentation Panel, preventing the tool from being fully functional.

threshold-tool.mp4

Steps to Reproduce

  1. Launch a PT/CT data in TMTV Viewer.
  2. Select PT Axial Viewport.
  3. Select Rectangle ROI Threshold Tool from the segmentation panel.
  4. Draw a rectangle in Viewport.
  5. Click the run button
  6. Observe the console errors.

The current behavior

The "Run" button is missing from the options in the Rectangle ROI Threshold tool. Even if the "Run" button is displayed, clicking it does not trigger the thresholding action on the slices. Additionally, console errors are being logged, which indicate underlying issues.

The expected behavior

The user should be able to segment using the Rectangle ROI Threshold tool without errors.
The Run button should display while select Rectangle ROI Threshold tool

OS

Windows 10

Node version

18.19.0

Browser

132.0.6834.160

@abhijith-trenser abhijith-trenser added the Awaiting Reproduction Can we reproduce the reported bug? label Feb 7, 2025
@abhijith-trenser
Copy link
Contributor Author

@sedghi Upon investigating the issue, it was observed that the "Run" button is not appearing due to the handling of the state (selectedSegmentationId) in RectangleROIOptions.tsx. The current implementation collects the segmentationId from the viewports; however, in the setState method, an id property is being assigned based on the format ${segmentationId}-${type}-${viewportId}, rather than directly using the segmentationId. Modifying the selectedSegmentationId to use the segmentationId directly resolved this issue.

Following this fix, a new error related to an undefined volumeId was encountered. Please refer to the attached screenshot for further details.

Image

@sedghi sedghi added the Bugs Bug reported, reproducible, and verified. label Feb 7, 2025 — with Linear
@sedghi sedghi removed the Awaiting Reproduction Can we reproduce the reported bug? label Feb 7, 2025
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Bugs Bug reported, reproducible, and verified.
Projects
None yet
Development

No branches or pull requests

3 participants