
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) On Monday, November 9, 2015 at 8:42:26 PM UTC-5, stefanv wrote: Hi Kevin
On 2015-11-07 09:46:17, 'Kevin Keraudren' via scikit-image < scikit-image@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