How to understand SegmentMesher with Image spacing and Image Dimensions

Hello everyone,

I am using SegmentMesher for meshing, and so far things are going well. However, I am still trying to understand how image dimensions and voxel spacing influence the element size and the total number of elements.

For instance, I worked with a 3D image of a cube that I downscaled to 155 × 155 × 155 pixels with a spacing of 1 mm. Using the parameters shown in the attached screenshot, SegmentMesher generated about 2.6 million elements.

In contrast, the original dataset had 310 × 310 × 310 pixels, and the actual physical size of the cube was only 0.2 mm. After I applied the same parameters on SegmentMesher to this dataset, I received over 10 million elements.

In general, 2x increase of resolution on an axis results in 8x more elements.

However, Cleaver can dynamically adjust the element size - creating larger elements inside a segment, while creating smaller elements on the surface to preserve small details. This dynamic adjustment is controlled by rate of change (how much size difference is allowed between neighbor elements) and feature scaling parameters (overall responsiveness of element size to mesh details).

I would recommend to experiment with features scaling and sampling rate parameters. I think adjustment of sampling rate is equivalent with resampling your input segmentation/labelmap.