Help wanted: implementation of 3D medial axis skeletonization

968 views
Skip to first unread message

Stefan van der Walt

unread,
Nov 2, 2015, 5:27:00 PM11/2/15
to scikit...@googlegroups.com
Hi all,

I have been approached by a group that is interested in sponsoring the
development of 3D skeletonization in scikit-image. One potential
starting place would be:

http://www.insight-journal.org/browse/publication/181

Is anyone interested in working on this? Please get in touch.

Thanks!
Stéfan

Emmanuelle Gouillart

unread,
Nov 2, 2015, 5:39:28 PM11/2/15
to scikit...@googlegroups.com
Hi Stéfan

3D skeletonization would be a great idea. I wonder if the algorithm you
mention is the same as the one used in http://fiji.sc/Skeletonize3D
(which is quite popular in the X-ray tomography community). There are so
many 3D skeletonization algorithms that understanding which specs are
required might be an important first step.

Can you explain which kind of sponsoring it would be? Is it only
available for people living in the US, or in other countries? For
students only?

Cheers
Emma

Stefan van der Walt

unread,
Nov 2, 2015, 8:26:49 PM11/2/15
to scikit...@googlegroups.com
Hi Emma

On 2015-11-02 14:39:26, Emmanuelle Gouillart <emmanuelle...@nsup.org> wrote:
> Can you explain which kind of sponsoring it would be? Is it only
> available for people living in the US, or in other countries? For
> students only?

I think there is a small amount of money available for anyone who is
interested.

And I agree, starting with a quick assessment of existing algorithms
would be good!

Stéfan

Josh Warner

unread,
Nov 2, 2015, 8:55:41 PM11/2/15
to scikit-image
Should we use/apply this to a particular volumetric dataset while prototyping different methods, to ensure accurate comparisons?

Should anisotropic, regularly sampled voxels be supported?

Juan Nunez-Iglesias

unread,
Nov 2, 2015, 9:20:49 PM11/2/15
to scikit...@googlegroups.com, scikit-image
I can't work on this right now but I am very excited to see it happen... And it's the first example of a sponsored scikit-image project, right??? (Not counting GSoC.) Support for anisotropic voxels would be a definite plus, too.

Don't forget that Fiji's code is mostly GPL, so don't try to copy it, at least not without first discussing dual licensing with the author(s).

Juan.




On Tue, Nov 3, 2015 at 12:55 PM, Josh Warner <silvertr...@gmail.com> wrote:

Should we use/apply this to a particular volumetric dataset while prototyping different methods, to ensure accurate comparisons?

Should anisotropic, regularly sampled voxels be supported?

--
You received this message because you are subscribed to the Google Groups "scikit-image" group.
To unsubscribe from this group and stop receiving emails from it, send an email to scikit-image...@googlegroups.com.
For more options, visit https://groups.google.com/d/optout.


Josh Warner

unread,
Nov 2, 2015, 11:16:41 PM11/2/15
to scikit-image
I suggest the lobster, one of the bonsai, or the XMas tree datasets located here as excellent 'torture tests' for 3d skeletonization.

http://www9.informatik.uni-erlangen.de/External/vollib/

Emmanuelle Gouillart

unread,
Nov 3, 2015, 4:18:11 PM11/3/15
to scikit...@googlegroups.com

> Don't forget that Fiji's code is mostly GPL, so don't try to copy it, at least
> not without first discussing dual licensing with the author(s).

Excellent point. Actually I'm only using the Fiji page as a way to find
the paper by Lee et al. again :-).

Kevin Keraudren

unread,
Nov 7, 2015, 12:46:23 PM11/7/15
to scikit...@googlegroups.com
Hi,

I don’t want to volunteer for this project, but I just wanted to mention that the 3D skeletonization from ITK is easily accessible to Python through SimpleITK, see example below for the lobster dataset. SimpleITK could be used for comparison or validation of the proposed scikit-image algorithm.

Kind Regards,

Kevin

PS: is there another way to load those *.pvm datasets in Python without converting them to raw and hardcoding the image dimension and pixel type? An skimage.io.imread() plugin?


SimpleITK_skeletonize_lobster.py
lobster_mask.png
lobster_skeleton.png

Stefan van der Walt

unread,
Nov 9, 2015, 8:42:26 PM11/9/15
to scikit...@googlegroups.com
Hi Kevin

On 2015-11-07 09:46:17, 'Kevin Keraudren' via scikit-image <scikit...@googlegroups.com> wrote:
> I don’t want to volunteer for this project, but I just wanted to
> mention that the 3D skeletonization from ITK is easily accessible to
> Python through SimpleITK, see example below for the lobster
> dataset. SimpleITK could be used for comparison or validation of the
> proposed scikit-image algorithm.

Thanks for the pointer. In this case, one of the purposes of the
exercise is to stay away from a heavy dependency such as ITK.

> PS: is there another way to load those *.pvm datasets in Python
> without converting them to raw and hardcoding the image dimension and
> pixel type? An skimage.io.imread() plugin?

I have no idea about .pvm files, but perhaps we should start a set of
plugin gists on the wiki somewhere?

Stéfan

Josh Warner

unread,
Nov 20, 2015, 12:23:50 AM11/20/15
to scikit-image

It looks like the lobster and bonsai can be downloaded directly as raw volumes (8 bit only, but will serve these purposes perfectly well) here:
http://www.volvis.org/

This simple wrapper for np.fromfile will load them

import numpy as np


def loadraw(rawfile, shape=None, dtype=np.uint8):
    """
    Load RAW volume to a NumPy array.

    Parameters
    ----------
    rawfile : string
        Path to *.raw volume.
    shape : tuple
        Shape of the volume. If not provided, output will be a rank-1 stream
        which can be reshaped as desired.
    dtype : NumPy dtype
        Dtype of the raw image volume.
    """        
    vol = np.fromfile(rawfile, dtype=dtype)

    if shape is not None:
        vol = vol.reshape(shape)

    return vol

For the lobster, use shape=(56, 324, 301) and recall the voxel spacing has a ratio of 1.4:1:1
For the bonsai, use shape=(256, 256, 256) and the volume is isotropic (1:1:1 spacing)

Reply all
Reply to author
Forward
0 new messages