[MINC-users] mincresample -like bug?

Alex Zijdenbos zijdenbos at gmail.com
Mon Mar 30 23:29:33 EDT 2015


I seem to have stumbled into something unusual: a failure of mincresample.

[by the way, according to the GMail spell checker, the correct spelling of
'mincresample' is 'creaminess'. duh.]

Anyways, I have this:

$ mincinfo in.mnc <https://www.dropbox.com/s/dwaz0ftbtefsfz7/in.mnc?dl=0>
model.mnc <https://www.dropbox.com/s/ic41vwursndyonj/model.mnc?dl=0>
file: in.mnc
image: unsigned short 0 to 65535
image dimensions: zspace yspace xspace
    dimension name         length         step        start
    --------------         ------         ----        -----
    zspace                     96            2     -321.707
    yspace                    134            2     -202.414
    xspace                    134            2     -132.414


file: model.mnc
image: signed__ short -32768 to 32767
image dimensions: zspace yspace xspace
    dimension name         length         step        start
    --------------         ------         ----        -----
    zspace                     94            2     -319.707
    yspace                    132            2     -200.414
    xspace                    132            2     -130.414

Now I resample in.mnc like model.mnc:

$ mincresample -like model.mnc in.mnc res.mnc
Transforming
slices:..............................................................................................Done

$ mincinfo res.mnc
file: res.mnc
image: unsigned short 0 to 65535
image dimensions: zspace yspace xspace
    dimension name         length         step        start
    --------------         ------         ----        -----
    zspace                     94            1            0
    yspace                    132            2     -200.414
    xspace                    132            2     -130.414

Clearly, the zspace step and start of the resampled volume (yellow) don't
look at all like those of the -like volume (green). I suspect a numerical
precision issue causing the start/step calculation to go wrong, but I'm not
sure.

In case anybody wants to play, you can get in.mnc and model.mnc from the
URLs in the first mincinfo call.

-- A


More information about the MINC-users mailing list