Package nom.tam.fits.compression.algorithm.quant


package nom.tam.fits.compression.algorithm.quant

Quantization support for representing floating-point values with integers corresponding to discrete levels. While not a compression alorithm in itself (hence you might also wonder why it's in a package on its own under compression algorithms) quantization is nevertheless commonly used as a pre-sompression (or post-decompression step) with actual algorithms, especially if the algorithms are designed for integer-only data.

Quantization is an inherently lossy process, so it will result in a lossy compression even when paired with a lossless compression algorithm. However, it can significantly improve compression ratios when images have limited dynamic range. For example a 2-byte integer quantization of double-precision values will provide 64k discrete levels at 1/4th of the required storage space -- even before compression is applied.

The only class in here that users would typically interact with is QuantizeOption or CompressedImageHDU.getCompressOption(Class) to set options after a quantization algorithm was selected for compressing an image HDU.

  • Classes
    Class
    Description
    Quantization options when they are part of the compression scheme.
    A standard fixed random sequence to use for portable and reversible dither implementations.