Page MenuHomePhabricator

[Segmentation] 3-d picking tool crashes with dynamic segmentations
Closed, ResolvedPublic

Description

Both the 3-d region growing and 3-d picking tools were mentioned in the known issues section of the last release notes, because they do not yet support dynamic images/segmentations. The 3-d region growing tool is still deactivated for dynamic images (see T28499: Refactor/rewrite RegionGrowing3D tool) but the 3-d picking tool is not and crashes with an "image dimension (4) is not in (2)(3)" message.

Revisions and Commits

rMITK MITK
Restricted Differential Revision
Restricted Differential Revision

Event Timeline

kislinsk triaged this task as Unbreak Now! priority.Oct 20 2021, 7:48 AM
kislinsk created this task.
kislinsk moved this task from Backlog to Cycle on the MITK (v2021.10) board.

Found the problem. It is not a error in the picking tool.

It is in

void mitk::LabelSetImage::ClearBuffer()

Because AccessByItk (which is used there) by default only supports 2D and 3D. -> Exception when trying to reset dynamic LabelSetImages.

So far I see the following solutions:

  1. Add 4D as a CMake default (but would impact a lot of code...)
  2. Add in clear buffer a check if instance is 4D and if so explizitly call it for 4D (in other cases use AccessByItk as we did so far.

@kislinsk Do you see an other option? Which one would you choose?

Found the problem. It is not a error in the picking tool.

It is in

void mitk::LabelSetImage::ClearBuffer()

Because AccessByItk (which is used there) by default only supports 2D and 3D. -> Exception when trying to reset dynamic LabelSetImages.

So far I see the following solutions:

  1. Add 4D as a CMake default (but would impact a lot of code...)
  2. Add in clear buffer a check if instance is 4D and if so explizitly call it for 4D (in other cases use AccessByItk as we did so far.

@kislinsk Do you see an other option? Which one would you choose?

(1) is not a reasonable option, so (2) it is in my opinion. I didn't check the code but an alternative could be the typical iteration through time steps in case of dynamic data and call the templated function with 3 dimensions.

floca added a revision: Restricted Differential Revision.Oct 21 2021, 4:57 PM