Segment smooting performance issue using a M1 Apple Silicon Mac

I am using Slicer 5.0.2 on a Mac Studio with a M1 Max chip (10 cores, 64 GB memory) in order to segment the volumes of archaeological finds (in that case a Bronze Age sword hilt). I am working with a 5.84 GB nrrd file with the following dimensions:


Using the segment editor, I created 6 segments for the different components of the hilt and the background using Grow from seeds. The process was quite long, with a long update time for each modification, but that worked eventually. The segment of the blade shows extrusions and holes I would like to smooth. After removing the most obvious mistakes using 3D scissors, I tried to use a median filter with a 1 mm kernel size (I cannot increase it). Slicer then freeze with an endless spinning wheel. The activity monitor shows Sliceer is using around 20 GB of memory, which is fine, but almost all CPU power. I let it run for a couple of days without any change. I also tried the same operation with a smaller volume susing the “Crop Voume” module with a 2.00 spacing scale factor and to apply the smoothing on a small area using the smoothing brush, the result is the same. I always run the smoothing operations with the 3D view deactivated.

The smoothing works fine if I export the segments as stl files and open them on Meshlab, but I’d like to process everything in Slicer. Any idea how I can make it work?

Thank you.

With the resolution of our dataset, 1mm kernel would be 153x153x153 voxels (1mm / 0.0065mm voxel size). That’s a huge kernel size for that filter. Normally you would run a median filter with 3-5 voxels. So try a value that’s like 0.02mm, which should give you a 3x3x3 kernel size.

If the precision displayed in the kernel size field is not enough to enter 0.02, you can increase the number of decimal points by hitting CTRL+ALT+PLUS (+ key) In Mac, I believe it is CMD + ALT + PLUS (+ key)