Hi
I used the following to calculate the mean pixel value from a series of 16bit input images (ImageMagick 6.9.1-2 Q16) as per
convert t00.tif t01.tif t02.tif -evaluate-sequence mean t_mean.tif
for the first pixel (for example) this gives values in the original images of 2312, 1276 and 4305, with a computed value of 2631 (makes sense).
These images were converted to 32bit and pixel values show as 151521544, 83625212 and 282136785. I then re-computed the mean (ImageMagick 6.9.1-2 Q32 hdri enabled) and got 000.040.
The histograms all look the same so the image values are being scaled. However all precision is lost in the final mean calculation. Two queries:
1. why is 32bit mean calculation not an integer?
2. can I increase the number of significant figures for it?
thanks
mike
32bit mean pixel calculation
-
- Posts: 12159
- Joined: 2010-01-23T23:01:33-07:00
- Authentication code: 1151
- Location: England, UK
Re: 32bit mean pixel calculation
Use "-precision" to control the number of output significant digits. See http://www.imagemagick.org/script/comma ... #precision
Please show us the command(s) you are using. Is your IM Q32? HDRI?1. why is 32bit mean calculation not an integer?
snibgo's IM pages: im.snibgo.com
Re: 32bit mean pixel calculation
ImageMagick 6.9.3-7 Q32 x86_64 2016-04-04
Apologies, my fault. I did put this in the message, but it was hidden somewhat
I used
..\convert t00.tif t01.tif t02.tif -evaluate-sequence mean t_mean.tif
and was expecting an integer result given the pixel values were integers
Apologies, my fault. I did put this in the message, but it was hidden somewhat
I used
..\convert t00.tif t01.tif t02.tif -evaluate-sequence mean t_mean.tif
and was expecting an integer result given the pixel values were integers
-
- Posts: 12159
- Joined: 2010-01-23T23:01:33-07:00
- Authentication code: 1151
- Location: England, UK
Re: 32bit mean pixel calculation
No, that command didn't do this:
What commands showed those results?mikjsmith wrote:These images were converted to 32bit and pixel values show as 151521544, 83625212 and 282136785. I then re-computed the mean (ImageMagick 6.9.1-2 Q32 hdri enabled) and got 000.040.
snibgo's IM pages: im.snibgo.com