Login  Register

Re: Spatial and density calibration from TIFF files to ImageJ

Posted by Davide Guarisco on Oct 20, 2015; 10:01pm
URL: http://imagej.273.s1.nabble.com/Spatial-and-density-calibration-from-TIFF-files-to-ImageJ-tp5014677p5014690.html

Oli, thank you for your answer.

Unfortunately, this does not seem to work. Here's the code I am using:

from PIL import Image
stepsize =  params['scanX']/params['nrows']
opts2 = 'ImageJ=1.50b unit=nm cf=0 c0=0 c1=0.33 vunit=nm'
ar = Image.fromarray(img_data)
ar.save('AFM3.tiff',description=opts2,x_resolution=1/stepsize, y_resolution=1/stepsize)

The Image Description received by ImageJ, as shown using the Debug mode, is:

Image Description: ImageJ=1.50b unit=nm cf=0 c0=0 c1=0.33 vunit=nm

The image has the correct X and Y scaling, but the unit is still "pixel".
The Z values calibration does not take effect.

It seems I am missing something obvious, but what?

--
ImageJ mailing list: http://imagej.nih.gov/ij/list.html