lossy compression

Uses your system voice; voice and rate in settings.

Q55564Snapshot

≈ 13 min read

Names in other languages

  • Españolalgoritmo de compresión con pérdida
  • ItalianoCompressione dati lossy
  • Magyarveszteséges tömörítés
  • עבריתדחיסה מאבדת נתונים
  • Češtinaztrátová komprese
  • Englishlossy compression
  • EnglishLossy compression
  • Englishlossy compression

Article bodies are English and are not machine-translated. A name in another language is not a translation of the article.

In information technology, lossy compression, or irreversible compression, is the class of data compression methods that uses inexact approximations and partial data discarding to represent the content. These techniques are used to reduce data size for storing, handling, and transmitting content. Higher degrees of approximation create coarser images as more details are removed. This is opposed to lossless data compression (reversible data compression) which does not degrade the data.

The amount of data reduction possible using lossy compression is much higher than using lossless techniques. Well-designed lossy compression technology often reduces file sizes significantly before degradation is noticed by the end-user. Even when noticeable by the user, further data reduction may be desirable (e.g., for real-time communication or to reduce transmission times or storage needs). The most widely used lossy compression algorithm is the discrete cosine transform (DCT), first published by Nasir Ahmed, T. Natarajan and K. R. Rao in 1974.

Lossy compression is most commonly used to compress multimedia data (audio, video, and images), especially in applications such as streaming media and internet telephony. By contrast, lossless compression is typically required for text and data files, such as bank records and text articles.…

In information technology, lossy compression, or irreversible compression, is the class of data compression methods that uses inexact approximations and partial data discarding to represent the content. These techniques are used to reduce data size for storing, handling, and transmitting content. Higher degrees of approximation create coarser images as more details are removed. This is opposed to lossless data compression (reversible data compression) which does not degrade the data.

The amount of data reduction possible using lossy compression is much higher than using lossless techniques. Well-designed lossy compression technology often reduces file sizes significantly before degradation is noticed by the end-user. Even when noticeable by the user, further data reduction may be desirable (e.g., for real-time communication or to reduce transmission times or storage needs). The most widely used lossy compression algorithm is the discrete cosine transform (DCT), first published by Nasir Ahmed, T. Natarajan and K. R. Rao in 1974.

Lossy compression is most commonly used to compress multimedia data (audio, video, and images), especially in applications such as streaming media and internet telephony. By contrast, lossless compression is typically required for text and data files, such as bank records and text articles. It can be advantageous to make a master lossless file which can then be used to produce additional copies from.

This allows one to avoid basing new compressed copies on a lossy source file, which would yield additional artifacts and further unnecessary information loss.

Types

It is possible to compress many types of digital data in a way that reduces the size of a computer file needed to store it, or the bandwidth needed to transmit it, with no loss of the full information contained in the original file. A picture, for example, is converted to a digital file by considering it to be an array of dots and specifying the color and brightness of each dot.

If the picture contains an area of the same color, it can be compressed without loss by saying "200 red dots" instead of "red dot, red dot, ...(197 more times)..., red dot." The original data contains a certain amount of information, and there is a lower bound to the size of a file that can still carry all the information. Basic information theory says that there is an absolute limit in reducing the size of this data. When data is compressed, its entropy increases, and it cannot increase indefinitely.

For example, a compressed ZIP file is smaller than its original, but repeatedly compressing the same file will not reduce the size to nothing. Most compression algorithms can recognize when further compression would be pointless and would in fact increase the size of the data. In many cases, files or data streams contain more information than is needed.

For example, a picture may have more detail than the eye can distinguish when reproduced at the largest size intended; likewise, an audio file does not need a lot of fine detail during a very loud passage. Developing lossy compression techniques as closely matched to human perception as possible is a complex task. Sometimes the ideal is a file that provides exactly the same perception as the original, with as much digital information as possible removed; other times, perceptible loss of quality is considered a valid tradeoff.

The terms "irreversible" and "reversible" are preferred over "lossy" and "lossless" respectively for some applications, such as medical image compression, to circumvent the negative implications of "loss". The type and amount of loss can affect the utility of the images. Artifacts or undesirable effects of compression may be clearly discernible yet the result still useful for the intended purpose.

Or lossy compressed images may be 'visually lossless', or in the case of medical images, so-called diagnostically acceptable irreversible compression (DAIC) may have been applied.

Comparison

The advantage of lossy methods over lossless methods is that in some cases a lossy method can produce a much smaller compressed file than any lossless method, while still meeting the requirements of the application. Lossy methods are most often used for compressing sound, images or videos. This is because these types of data are intended for human interpretation where the mind can easily "fill in the blanks" or see past very minor errors or inconsistencies – ideally lossy compression is transparent (imperceptible), which can be verified via an ABX test. Data files using lossy compression are smaller in size and thus cost less to store and to transmit over the Internet, a crucial consideration for streaming video services such as Netflix and streaming audio services such as Spotify.

Transparency

When a user acquires a lossily compressed file, (for example, to reduce download time) the retrieved file can be quite different from the original at the bit level while being indistinguishable to the human ear or eye for most practical purposes. Many compression methods focus on the idiosyncrasies of human physiology, taking into account, for instance, that the human eye can see only certain wavelengths of light. The psychoacoustic model describes how sound can be highly compressed without degrading perceived quality. Flaws caused by lossy compression that are noticeable to the human eye or ear are known as compression artifacts.

Compression ratio

The compression ratio (that is, the size of the compressed file compared to that of the uncompressed file) of lossy video codecs is nearly always far superior to that of the audio and still-image equivalents. Video can be compressed immensely (e.g., 100:1) with little visible quality loss Audio can often be compressed at 10:1 with almost imperceptible loss of quality Still images are often lossily compressed at 10:1, as with audio, but the quality loss is more noticeable, especially on closer inspection.

Transcoding and editing

An important caveat about lossy compression (formally transcoding), is that editing lossily compressed files causes digital generation loss from the re-encoding. This can be avoided by only producing lossy files from (lossless) originals and only editing (copies of) original files, such as images in raw image format instead of JPEG. If data which has been compressed lossily is decoded and compressed losslessly, the size of the result can be comparable with the size of the data before lossy compression, but the data already lost cannot be recovered. When deciding to use lossy conversion without keeping the original, format conversion may be needed in the future to achieve compatibility with software or devices (format shifting), or to avoid paying patent royalties for decoding or distribution of compressed files.

Editing of lossy files

By modifying the compressed data directly without decoding and re-encoding, some editing of lossily compressed files without degradation of quality is possible. Editing which reduces the file size as if it had been compressed to a greater degree, but without more loss than this, is sometimes also possible.

JPEG

The primary programs for lossless editing of JPEGs are jpegtran , and the derived exiftran (which also preserves Exif information), and Jpegcrop (which provides a Windows interface). These allow the image to be cropped, rotated, flipped, and flopped, or even converted to grayscale (by dropping the chrominance channel). While unwanted information is destroyed, the quality of the remaining portion is unchanged.

Some other transforms are possible to some extent, such as joining images with the same encoding (composing side by side, as on a grid) or pasting images such as logos onto existing images (both via Jpegjoin), or scaling. Some changes can be made to the compression without re-encoding: Optimizing the compression (to reduce size without change to the decoded image) Converting between progressive and non-progressive encoding. The freeware Windows-only IrfanView has some lossless JPEG operations in its JPG_TRANSFORM plugin.

Metadata

Metadata, such as ID3 tags, Vorbis comments, or Exif information, can usually be modified or removed without modifying the underlying data.

Downsampling/compressed representation scalability

One may wish to downsample or otherwise decrease the resolution of the represented source signal and the quantity of data used for its compressed representation without re-encoding, as in bitrate peeling, but this functionality is not supported in all designs, as not all codecs encode data in a form that allows less important detail to simply be dropped. Some well-known designs that have this capability include JPEG 2000 for still images and H.264/MPEG-4 AVC based Scalable Video Coding for video.

Such schemes have also been standardized for older designs as well, such as JPEG images with progressive encoding, and MPEG-2 and MPEG-4 Part 2 video, although those prior schemes had limited success in terms of adoption into real-world common usage.

Without this capacity, which is often the case in practice, to produce a representation with lower resolution or lower fidelity than a given one, one needs to start with the original source signal and encode, or start with a compressed representation and then decompress and re-encode it (transcoding), though the latter tends to cause digital generation loss.

Another approach is to encode the original signal at several different bitrates, and then either choose which to use (as when streaming over the internet – as in RealNetworks' "SureStream" – or offering varying downloads, as at Apple's iTunes Store), or broadcast several, where the best that is successfully received is used, as in various implementations of hierarchical modulation. Similar techniques are used in mipmaps, pyramid representations, and more sophisticated scale space methods.

Some audio formats feature a combination of a lossy format and a lossless correction which when combined reproduce the original signal; the correction can be stripped, leaving a smaller, lossily compressed, file. Such formats include MPEG-4 SLS (Scalable to Lossless), WavPack, OptimFROG DualStream, and DTS-HD Master Audio in lossless (XLL) mode).

Methods

Graphics

Image

Discrete cosine transform (DCT) JPEG WebP (high-density lossless or lossy compression of RGB and RGBA images) High Efficiency Image Format (HEIF) Better Portable Graphics (BPG) (lossless or lossy compression) JPEG XR, a successor of JPEG with support for high-dynamic range, wide gamut pixel formats (lossless or lossy compression) Wavelet compression JPEG 2000, JPEG's successor format that uses wavelets (lossless or lossy compression) DjVu ICER, used by the Mars Rovers, related to JPEG 2000 in its use of wavelets PGF, Progressive Graphics File (lossless or lossy compression) Cartesian Perceptual Compression, also known as CPC Fractal compression JBIG2 (lossless or lossy compression) S3TC texture compression for 3D computer graphics hardware

3D computer graphics

glTF

Video

Discrete cosine transform (DCT) H.261 Motion JPEG MPEG-1 Part 2 MPEG-2 Part 2 (H.262) MPEG-4 Part 2 (H.263) Advanced Video Coding (AVC / H.264 / MPEG-4 AVC) (may also be lossless, even in certain video sections) High Efficiency Video Coding (HEVC / H.265) Ogg Theora (noted for its lack of patent restrictions) VC-1 Wavelet compression Motion JPEG 2000 Dirac Sorenson video codec

Audio

General

Modified discrete cosine transform (MDCT) Dolby Digital (AC-3) Adaptive Transform Acoustic Coding (ATRAC) MPEG Layer III (MP3) Advanced Audio Coding (AAC / MP4 Audio) Vorbis Windows Media Audio (WMA) (Standard and Pro profiles are lossy. WMA Lossless is also available.) LDAC Opus (Notable for lack of patent restrictions, low delay, and high quality speech and general audio.) Adaptive differential pulse-code modulation (ADPCM) Master Quality Authenticated (MQA) MPEG-1 Audio Layer II (MP2) Musepack (based on Musicam) aptX/ aptX-HD

Speech

Linear predictive coding (LPC) Adaptive predictive coding (APC) Code-excited linear prediction (CELP) Algebraic code-excited linear prediction (ACELP) Relaxed code-excited linear prediction (RCELP) Low-delay CELP (LD-CELP) Adaptive Multi-Rate (used in GSM and 3GPP) Codec2 (noted for its lack of patent restrictions) Speex (noted for its lack of patent restrictions) Modified discrete cosine transform (MDCT) AAC-LD Constrained Energy Lapped Transform (CELT) Opus (mostly for real-time applications)

Text and other data

Researchers have performed lossy compression on text by either using a thesaurus to substitute short words for long ones, or generative text techniques, although these sometimes fall into the related category of lossy data conversion.

See also

Compression artifact Data compression Image scaling Lenna List of codecs Lossless compression Rate–distortion theory Seam carving Transcoding

Notes

External links

Lossy audio formats, comparing the speed and compression strength of five lossy audio formats. Data compression basics, including chapters on lossy compression of images, audio and video. Using lossy GIF/PNG compression for the web (article) JPG for Archiving, comparing the suitability of JPG and lossless compression for image archives fr:Compression de données#Compression avec pertes

Text derived from https://en.wikipedia.org/w/index.php?oldid=1375368234 under CC BY-SA 4.0; modifications have been made.

Provenance

snapshot lossy-compression-006561-581a1b7cbea03d55 · hash 581a1b7cbea03d5593fe6158159a081f680fbc6ef611d569456fd6fa8cccb98b · captured 1789637267.0 · version history

Cite this page as: encyclopegia.org, “lossy compression”, snapshot lossy-compression-006561-581a1b7cbea03d55. https://encyclopegia.org/a/lossy-compression

Sources cited in this revision

No external citation was extracted for this revision. That is a statement about the source, not a claim that none exists.