The Joint Photographic Experts Group, in addition to their well-known lossy image compression techniques, JPEG and JPEG 2000, also have three standards for lossless compression (of which JPEG-LS has a lossy mode):
Lossless JPEG was developed as a late addition to JPEG in 1993, using a completely different technique from the lossy JPEG standard. It uses a predictive scheme based on the three nearest (causal) neighbors (upper, left, and upper-left), and entropy coding is used on the prediction error. It was never widely adopted.
JPEG-LS was developed with the aim of providing a low complexity lossless image compression standard that could be able to offer better compression efficiency than lossless JPEG. Part 1 of this standard was finalized in 1999. The core of JPEG-LS is based on the LOCO-I algorithm, that relies on prediction, residual modeling and context-based coding of the residuals. Most of the low complexity of this technique comes from the assumption that prediction residuals follow a two-sided geometric distribution (also called a discrete Laplace distribution) and from the use of Golomb-like codes, which are known to be near-optimal for geometric distributions. Besides lossless compression, JPEG-LS also provides a lossy mode where the maximum absolute error can be controlled by the encoder. Compression for JPEG-LS is generally much faster than JPEG 2000 and much better than the original lossless JPEG standard.
JPEG 2000 includes a lossless mode based on a special integer wavelet filter (biorthogonal 3/5). JPEG 2000's lossless mode runs more slowly and usually has worse compression ratios than JPEG-LS. However, it is scalable and progressive, and, because its algorithm is more similar to JPEG 2000, it is more widely supported.
Graphics file formats | Lossless compression algorithms | Lossy compression algorithms | JPEG-LS