I’m trying to extract data from 16-bit grayscale TIFF images. The only documented method I’ve found involves commands like:
…
RawTiffImage = Open( FilePath, tif );
{r, g, b} = RawTiffImage << Get Pixels( "rgb" );But this yields matrices r, g, and b with only 8-bit grayscale values, and I lose the other 8 bits.
Correspondence with the support team informs me that JMP cannot process 16-bit TIFF image files. I would be grateful for the ability to directly import 16-bit images directly into a single matrix.
@RJ_Bailey
Interesting question. Can you share an example file? (might have to zip it to get past the spam filters.) I'm pretty sure this can be done via Python. From what I remember of the TIFF specification, TIFF is a wrapper around many other specifications, and there could be more than one 16-bit format.
Whatever JMP is using to open the TIFF is probably down-converting because JMP's image format only supports 8 bits per channel RGB (24-bit color). By switching to Python, the image could be retrieved in a matrix with the full depth resolution.
https://stackoverflow.com/questions/7247371/python-and-16-bit-tiff
https://stackoverflow.com/questions/6419358/16-bit-grayscale-tiff
edit: posted example Load 16-bit Grayscale Tiff via Python