[fitsbits] Output array type when BZERO is an integer {External}
Seaman, Robert Lewis - (rseaman)
rseaman at arizona.edu
Sun Mar 10 12:17:52 EDT 2024
Hi Paul,
I'm writing a FITS package for the Julia programming language. I have a question about the output type of the image when BZERO is an integer value. The documentation implies that the output image should be a floating point type because the BSCALE value is a float. Is this correct? If yes, then I recommend stating this explicitly in the FITS standard documentation. I also recommend suggesting the appropriate output type depending on the input type, e.g., UInt8 => Float32, Int16 => Float32, etc.
Yes, that is the ancient implication of BSCALE. This carries over to lossy tile compression, too, which is a very fancy BSCALE operation if you look at it sideways.
Undoubtedly there are other pending tweaks to the docs. This is hard to avoid with esoteric standards, especially perhaps if they survive through multiple generations of other contingent computer technologies.
I’m not sure I understand your last sentence. Could you provide a table of the mappings you think should apply?
To first order, other languages and libraries should start with the CFITSIO source for appropriate usage (or to suggest differently). One recommendation is that all FITS packages support tile compression.
Rob Seaman
Lunar and Planetary Laboratory
University of Arizona
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://listmgr.nrao.edu/pipermail/fitsbits/attachments/20240310/636a7e6e/attachment.html>
More information about the fitsbits
mailing list