[MINC-users] how to pad prior to distance computation with mincmorph

Andrew Janke a.janke at gmail.com
Wed May 25 18:47:54 EDT 2011


Hi Michel,

On Thu, May 26, 2011 at 08:17, Michel Audette
<michel.audette at kitware.com> wrote:
> I'm trying to use mincmorph to compute a distance transform from a binary
> image, and finding that the algorithm also seems to initialize distance at 0
> at the boundary of the image. I assume that the answer lies in padding the
> volume prior to the distance transform, and I can see that there is an
> option for that, but I can't seem to get that part of the computation
> working properly. Can anyone show an example of this use?

I am guessing that you will want something like this:

   $ mincmorph -successive 'B[0:100]PF' <in.mnc> <out.mnc>

This will first binarise the image between 0 and 100, then pad it
(using the size of the kernel currently in use) and then do the
distance transformation.


a


More information about the MINC-users mailing list