[MINC-users] default slice min/max in mincreshape?

Alex Zijdenbos zijdenbos at gmail.com
Thu May 31 23:51:55 EDT 2012


Hi all,

I just ran into something that had me stumped for a while: a
mincreshape call that set all values in the reshaped volume to 0. In
the end, turned out that this was due to slice scaling again (sigh).

My source volume is a PET volume, byte 0-255, that comes out of
dcm2mnc with slice maxima like so:

image-max = 0.000246520439341603, 0.000163440197211826,
    0.000214308078508676, 0.000180133543411815, 0.000249790729781494,
    ...

however when I call mincreshape on that volume to pad it, i.e., add
empty slices, the added slices receive a max value of 1; so the
resulting image shows, after adding 5 slices:

image-max = 1, 1, 1, 1, 1, 0.000246520439341603, 0.000163440197211826,
    0.000214308078508676, 0.000180133543411815, 0.000249790729781494,
    ...

(all image-mins values are 0).

Given that the this is a byte volume, setting a [0,1] range while the
actual image data has a range of [0,2e-4], well, squashes that data
into oblivion :-)

It's easy to fix by adding -normalize to the mincreshape call; but the
question I have is: why is the image-max for added, empty slices set
to 1 (instead of 0 for example)? It seems to me that this may cause
trouble for all volumes with real values much smaller than 1.

Thanks,

-- Alex


More information about the MINC-users mailing list