[MINC-users] minctoraw

Andrew Janke minc-users@bic.mni.mcgill.ca
Thu, 5 Sep 2002 16:23:13 +1000


On Thu, 29 Aug 2002, Stephen Smith wrote:

> Hi - thanks for the reply, though I couldn't quite follow what the range
> options are really doing. I have tried that and sadly it gives junk output
> - most values being set to 32767...
>
> The intensity range parts of mincheader are below - does that tell you
> anything useful about what the options should be to mincextract?

Time for me to add my 2c + 15% GST worth.

>  image-min = 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
>  image-max = 5896592.46886447, 6089528.00976801, 5860417.05494506,

What peter is elluding to is that your images have probably been rescaled (per
slice) along the way. This can be viewed as either an unfortunate or fortunate
thing... :)

Peter also is taking a stab at your input and output data range being 12-bit.
(something that we all know is very common of certain unnamed manufacturers).

The problem as you describe it sounds like you are writing out data that is
scaled per slice and getting "zippering" between slices. Unfortunately minctoraw
and mincextract don't appear to have an option to "normalize" just between
slices although peter will correct me here if I am wrong.

As such what you need to do is make sure a MINC image has only one max and min
value before doing a minctoraw/mincextract.  Most programs that use volume_io
and set_volume_real_range have the side-effect of doing this.. :)

On this note, I have been meaning to write a quick volume_io proggie to do this.
Stay tuned (or email me again in a week) and I'll have a fix for you.


andrew