[ITK] [ITK-users] adding a global hierarchical watershed segmentation mode to itksnap
Dr. Roman Grothausmann
grothausmann.roman at mh-hannover.de
Thu Aug 14 06:42:10 EDT 2014
Hi Paul,
Many thanks for Your reply. The main problem that I often face with samples from
material science is, that around 1000 labels are needed per tomogram, e.g.
individual particles, regions, domains. So setting markers by hand is already
very timeconsuming. Expanding each of these one after another is way to
cumbersum. I'm not sure if I have tried clustering. At least it was not
available as preprocessing mode (possibly because I only have a greyscale
tomogram) as described in the ReleaseNotes (is there any other new docu?). I did
not try supervised classification because dev32 does not run on our system and
the self-compiled binary crashes at start up with a segmentation fault (see below).
Anyway it seems not possible to have the snake-tool make multiple labels compete
against each other, as e.g. in a global watershed approach.
I'd be very happy if there was already a tool in order to achieve what I need
but it seems there isn't, so I guess I've to start creating my own.
With Andras hint about using Slicer, I'm now wondering whether I should
implement it for itksnap or slicer. None of both seem to have a tool to
join/remove labels from a base map to a result map by just LMB/RMB clicking,
which I would find very helpful.
Adding a hierarchical watershed to generate the base map and using the mouse
wheel to change the level/granularity on the fly would then just be an extension.
A tile view (e.g. both maps side by side) for all three axes as in itksnap would
be handy for this join/remove tool. Does Slicer offer something like that as well?
Is it possible to get also the overlay id together with the click position? That
would even allow to choose an already existing label in the result map for
modification by just a click.
Any further recommendations for the start are very welcome.
Thanks,
Roman
______________________
LD_LIBRARY_PATH=/opt/itk-4.5.1/lib/:/opt/qt-5.3.1/5.3/gcc_64/lib/ vglrun
./ITK-SNAP
QXcbConnection: Failed to initialize XRandr
Qt: XKEYBOARD extension not present on the X server.
*************************************
ITK-SNAP: Segmentation fault
BACKTRACE:
./ITK-SNAP(_Z24SegmentationFaultHandleri+0x133)[0x7af9c3]
/lib/x86_64-linux-gnu/libc.so.6(+0x324f0)[0x7f6e977224f0]
/lib/x86_64-linux-gnu/libc.so.6(+0x11aedf)[0x7f6e9780aedf]
/opt/qt-5.3.1/5.3/gcc_64/lib/libQt5Core.so.5(_ZN16QCoreApplication9argumentsEv+0x8c)[0x7f6ea8dbf6bc]
/opt/qt-5.3.1/5.3/gcc_64/plugins/platforms/libqxcb.so(+0x4b213)[0x7f6e907df213]
/opt/qt-5.3.1/5.3/gcc_64/plugins/platforms/libqxcb.so(+0x4b5f9)[0x7f6e907df5f9]
/opt/qt-5.3.1/5.3/gcc_64/plugins/platforms/libqxcb.so(+0x58127)[0x7f6e907ec127]
/opt/qt-5.3.1/5.3/gcc_64/plugins/platforms/libqxcb.so(+0x4b009)[0x7f6e907df009]
/opt/qt-5.3.1/5.3/gcc_64/lib/libQt5Gui.so.5(_ZN7QWindow6createEv+0x33)[0x7f6ea9e89e03]
/opt/qt-5.3.1/5.3/gcc_64/lib/libQt5OpenGL.so.5(_ZN10QGLContext13chooseContextEPKS_+0x121)[0x7f6eaad4bf51]
/opt/qt-5.3.1/5.3/gcc_64/lib/libQt5OpenGL.so.5(_ZN10QGLContext6createEPKS_+0x39)[0x7f6eaad23609]
/opt/qt-5.3.1/5.3/gcc_64/lib/libQt5OpenGL.so.5(_ZN9QGLWidget10setContextEP10QGLContextPKS0_b+0xa7)[0x7f6eaad4b8b7]
/opt/qt-5.3.1/5.3/gcc_64/lib/libQt5OpenGL.so.5(_ZN16QGLWidgetPrivate11initContextEP10QGLContextPK9QGLWidget+0x7a)[0x7f6eaad28c2a]
/opt/qt-5.3.1/5.3/gcc_64/lib/libQt5OpenGL.so.5(_ZN9QGLWidgetC2EP7QWidgetPKS_6QFlagsIN2Qt10WindowTypeEE+0x111)[0x7f6eaad29031]
./ITK-SNAP(_ZN19QtAbstractOpenGLBoxC1EP7QWidget+0xd)[0x849e3d]
./ITK-SNAP(_ZN16GenericSliceViewC2EP7QWidget+0x10)[0x848310]
./ITK-SNAP(_ZN17Ui_SliceViewPanel7setupUiEP7QWidget+0x235f)[0x840fbf]
./ITK-SNAP(_ZN14SliceViewPanelC1EP7QWidget+0x53)[0x839fc3]
./ITK-SNAP(_ZN18Ui_MainImageWindow7setupUiEP11QMainWindow+0x336b)[0x7d77bb]
./ITK-SNAP(_ZN15MainImageWindowC2EP7QWidget+0x64)[0x7c47b4]
./ITK-SNAP(main+0x1b3)[0x7aa8c3]
/lib/x86_64-linux-gnu/libc.so.6(__libc_start_main+0xfd)[0x7f6e9770eead]
./ITK-SNAP[0x7af6f9]
*************************************
On 13/08/14 22:15, Paul Yushkevich wrote:
> Hi Roman,
>
> I am not sure, have you experimented with some of the newer segmentation modes
> in ITK-SNAP (clustering, available in the 3.0 release, and supervised
> classification, available in the dev32 branch). These still operate using active
> contours, but can generate per-label probability maps that could then be easily
> converted into multilabel segmentations. I guess my main question is whether
> heirarchical watershed segmentation offers advantages over these modes, and if
> so, whether it may possibly be integrated as another segmentation mode in the
> snake pipeline...
>
> Paul.
>
>
> On Tue, Aug 12, 2014 at 4:14 AM, Dr. Roman Grothausmann
> <grothausmann.roman at mh-hannover.de <mailto:grothausmann.roman at mh-hannover.de>>
> wrote:
>
> Hi Andras,
>
>
> Many thanks for Your hints. We'll test them on our data. However, our data
> is not as standardized in quality as CT or MRT data and from our experience
> many of the "magic" segmentations demonstrated on CT or MRT data does not
> work on our data.
> However, of all the segmentation modules I could find in Slicer or elsewhere
> none was based on a hierarchical watershed algorithm like the
> SegmentationEditor of the InsightApplications. Is there any other that I've
> missed?
> Concerning my idea to implement this if no tool currently already exists:
> Would such an extension be of more use in Slicer or itksnap?
> For which of the both would it likely be easier to integrate the extension?
>
> Best wishes
> Roman
>
> On 11/08/14 16:20, Andras Lasso wrote:
>
> Have you tried segmentation tools in 3D Slicer? There is a multi-label
> watershed
> segmentation tool that works in 3d
> (http://www.slicer.org/__slicerWiki/index.php/__Documentation/Nightly/Modules/__Editor#WatershedFromMarkers
> <http://www.slicer.org/slicerWiki/index.php/Documentation/Nightly/Modules/Editor#WatershedFromMarkers>),
> there are also a number of other generic semi-automatic segmentation
> tools (such
> as GrowCut) and a few fully-automatic specialized tools (for brain,
> airways, etc). Download the nightly build and also checkout the Segmentation
> category in the Extension Manager.
>
> Andras
>
> *From:* Dr. Roman Grothausmann
> <mailto:grothausmann.roman at mh-__hannover.de
> <mailto:grothausmann.roman at mh-hannover.de>>
> *Sent:* Monday, August 11, 2014 1:15 AM
> *To:* itksnap-users at googlegroups.com
> <mailto:itksnap-users at googlegroups.com>
> <mailto:itksnap-users at __googlegroups.com
> <mailto:itksnap-users at googlegroups.com>>
> *Cc:* ITK Mailing List <mailto:insight-users at itk.org
> <mailto:insight-users at itk.org>>
>
>
> Dear mailing list members,
>
>
> For a long time now I've been searching for a replacement of the old
> SegmentationEditor (part of the InsightApplications) which I could not
> get to
> work even with older ITK-3.x. Somewhere I was told that it was
> integrated and
> maintained within itksnap. However the only tool in itksnap based on
> watershed
> segmentation seems to be the adaptive brush. It is very handy, but
> time-consuming in 3D and only for local segmentations. In contrast the
> SegmentationEditor used a global hierarchical watershed segmentation to pick
> labels from, see e.g. the video linked here:
> http://www.insight-journal.__org/browse/publication/70
> <http://www.insight-journal.org/browse/publication/70>
> Quite often now I've stumbled over data, that would likely have profited
> a lot
> of such a tool for segmentation.
>
> If such a tool working with ITK-4.x does not exist any more, I thought of
> implementing it as a global WS segmentation mode in itksnap. That way
> making the
> tool easier to find, to use and to ensure maintenance (should it be
> integrated
> into the itksnap code base in the end) and also avoiding recoding a GUI with
> mouse interaction and such.
>
> My current idea is to start, similar to the snake-tool, with
> pre-filtering like
> smoothing and optional edge-detection.
> Then the main edit mode to consist of the usual 4 subwindows showing an
> overlay
> of the grey-image and the watershed segmentation of the hierarchical
> WS-filter
> (hWS), side-by-side to another label-dataset (loaded like a tiled
> overlay) which
> consist of the actually chosen labels from the hWS as the final data (FD).
> The interaction I'm considering would be to LMB click on a label in the hWS
> which is then added to the FD as the current fg label, or removed with a
> RMB.
> The hierachrchy level of the hWS could be controlled by a slider or the
> mouse
> wheel + Shift in nearly real time if some region demands higher or lower
> detailed segmentation. When the fg label is changed, the segmentation
> added or
> removed with further mouse interactions would modify the new fg label.
> When all is done and the global WS mode is left, the FD label-dataset is
> added
> to the main segmentation of itksnap.
>
> Would that be possible to implement in itksnap 3.x?
> What source files of the itksnap code base should I look at for:
> - the pre-filtering mode of the snake (for the smoothing and edge detection)
> - the mouse interactions (for e.g. adding the whell + Shift interaction)
> - possible examples for the dual layout
>
> Thanks for any comments, help or hints.
> Roman
>
> --
> Dr. Roman Grothausmann
>
> Tomographie und Digitale Bildverarbeitung
> Tomography and Digital Image Analysis
>
> Institut für Funktionelle und Angewandte Anatomie, OE 4120
> Medizinische Hochschule Hannover
> Carl-Neuberg-Str. 1
> D-30625 Hannover
>
> Tel. +49 511 532-9574 <tel:%2B49%20511%20532-9574>
> _______________________________________
> Powered by www.kitware.com <http://www.kitware.com>
>
> Visit other Kitware open-source projects at
> http://www.kitware.com/__opensource/opensource.html
> <http://www.kitware.com/opensource/opensource.html>
>
> Kitware offers ITK Training Courses, for more information visit:
> http://www.kitware.com/__products/protraining.php
> <http://www.kitware.com/products/protraining.php>
>
> Please keep messages on-topic and check the ITK FAQ at:
> http://www.itk.org/Wiki/ITK___FAQ <http://www.itk.org/Wiki/ITK_FAQ>
>
> Follow this link to subscribe/unsubscribe:
> http://public.kitware.com/__mailman/listinfo/insight-users
> <http://public.kitware.com/mailman/listinfo/insight-users>
> _________________________________________________
> Community mailing list
> Community at itk.org <mailto:Community at itk.org>
> http://public.kitware.com/__mailman/listinfo/community
> <http://public.kitware.com/mailman/listinfo/community>
>
>
> --
> Dr. Roman Grothausmann
>
> Tomographie und Digitale Bildverarbeitung
> Tomography and Digital Image Analysis
>
> Institut für Funktionelle und Angewandte Anatomie, OE 4120
> Medizinische Hochschule Hannover
> Carl-Neuberg-Str. 1
> D-30625 Hannover
>
> Tel. +49 511 532-9574 <tel:%2B49%20511%20532-9574>
>
> --
> You received this message because you are subscribed to the Google Groups
> "itksnap-users" group.
> To unsubscribe from this group and stop receiving emails from it, send an
> email to itksnap-users+unsubscribe at __googlegroups.com
> <mailto:itksnap-users%2Bunsubscribe at googlegroups.com>.
> To post to this group, send email to itksnap-users at googlegroups.com
> <mailto:itksnap-users at googlegroups.com>__.
> Visit this group at http://groups.google.com/__group/itksnap-users
> <http://groups.google.com/group/itksnap-users>.
> For more options, visit https://groups.google.com/d/__optout
> <https://groups.google.com/d/optout>.
>
>
>
>
> --
> Paul A. Yushkevich, Ph.D.
> Associate Professor
> Penn Image Computing and Science Laboratory
> Department of Radiology
> University of Pennsylvania
>
> --
> You received this message because you are subscribed to the Google Groups
> "itksnap-users" group.
> To unsubscribe from this group and stop receiving emails from it, send an email
> to itksnap-users+unsubscribe at googlegroups.com
> <mailto:itksnap-users+unsubscribe at googlegroups.com>.
> To post to this group, send email to itksnap-users at googlegroups.com
> <mailto:itksnap-users at googlegroups.com>.
> Visit this group at http://groups.google.com/group/itksnap-users.
> For more options, visit https://groups.google.com/d/optout.
--
Dr. Roman Grothausmann
Tomographie und Digitale Bildverarbeitung
Tomography and Digital Image Analysis
Institut für Funktionelle und Angewandte Anatomie, OE 4120
Medizinische Hochschule Hannover
Carl-Neuberg-Str. 1
D-30625 Hannover
Tel. +49 511 532-9574
_____________________________________
Powered by www.kitware.com
Visit other Kitware open-source projects at
http://www.kitware.com/opensource/opensource.html
Kitware offers ITK Training Courses, for more information visit:
http://www.kitware.com/products/protraining.php
Please keep messages on-topic and check the ITK FAQ at:
http://www.itk.org/Wiki/ITK_FAQ
Follow this link to subscribe/unsubscribe:
http://public.kitware.com/mailman/listinfo/insight-users
More information about the Community
mailing list