Page MenuHomePhabricator

[MITK Diffusion] Fix tract envelope as DICOM seg
Closed, ResolvedPublic

Event Timeline

neher triaged this task as Normal priority.Sep 6 2018, 8:17 AM
neher created this task.

Croshes on savin multi-label image as DICOM Seg.

Test data: Fibers & DICOM T1 image.

Create multi-label:

  1. Open "Fiber quantification view"
  2. Select Fibers and DICOM T1 data nodes in input data checkboxes.
  3. Slect "Binary Envelope" in "Fiber-derived images" box
  4. Click "Generate Image" to create multi label segmentation
  5. Save segmentation as DICOM Seg --> crash

Location in code:
https://phabricator.mitk.org/source/mitk/browse/master/Plugins/org.mitk.gui.qt.diffusionimaging.fiberprocessing/src/internal/QmitkFiberQuantificationView.cpp$376

The crash is caused by the duplicate creation of the layers:

multilabelImage->Initialize(m_SelectedImage);
multilabelImage->InitializeByLabeledImage(img);

The first initialization could be removed.

To get the referenced DICOM tag information (source image) xou have to add:
DICOMQIPropertyHandler::DeriveDICOMSourceProperties(m_SelectedImage, multilabelImage);