Jump to content
Main menu
Main menu
move to sidebar
hide
Navigation
Main page
Recent changes
Random page
Help about MediaWiki
Special pages
Niidae Wiki
Search
Search
Appearance
Create account
Log in
Personal tools
Create account
Log in
Pages for logged out editors
learn more
Contributions
Talk
Editing
Image compression
(section)
Page
Discussion
English
Read
Edit
View history
Tools
Tools
move to sidebar
hide
Actions
Read
Edit
View history
General
What links here
Related changes
Page information
Appearance
move to sidebar
hide
Warning:
You are not logged in. Your IP address will be publicly visible if you make any edits. If you
log in
or
create an account
, your edits will be attributed to your username, along with other benefits.
Anti-spam check. Do
not
fill this in!
== Lossy and lossless image compression == Image compression may be [[lossy compression|lossy]] or [[lossless compression|lossless]]. Lossless compression is preferred for archival purposes and often for medical imaging, technical drawings, [[clip art]], or comics. Lossy compression methods, especially when used at low [[bit rate]]s, introduce [[compression artifact]]s. Lossy methods are especially suitable for natural images such as photographs in applications where minor (sometimes imperceptible) loss of fidelity is acceptable to achieve a substantial reduction in bit rate. Lossy compression that produces negligible differences may be called visually lossless. Methods for [[lossy compression]]: * [[Transform coding]] β This is the most commonly used method. ** [[Discrete Cosine Transform]] (DCT) β The most widely used form of lossy compression. It is a type of [[List of Fourier-related transforms|Fourier-related transform]], and was originally developed by [[N. Ahmed|Nasir Ahmed]], T. Natarajan and [[K. R. Rao]] in 1974.<ref>{{cite journal|doi=10.1109/T-C.1974.223784|url=http://dasan.sejong.ac.kr/~dihan/dip/p5_DCT.pdf | title=Discrete Cosine Transform|date=1974 |archive-url=https://web.archive.org/web/20111125071212/http://dasan.sejong.ac.kr/~dihan/dip/p5_DCT.pdf |archive-date=2011-11-25 |last1=Ahmed |first1=N. |last2=Natarajan |first2=T. |last3=Rao |first3=K.R. |journal=IEEE Transactions on Computers |pages=90β93 |s2cid=149806273 }}</ref> The DCT is sometimes referred to as "DCT-II" in the context of a family of discrete cosine transforms (see [[discrete cosine transform]]). It is generally the most efficient form of image compression. *** DCT is used in [[JPEG]], the most popular lossy format, and the more recent [[HEIF]]. ** The more recently developed [[wavelet transform]] is also used extensively, followed by [[Quantization (image processing)|quantization]] and [[entropy coding]]. * [[Color quantization]] - Reducing the [[color space encoding|color space]] to a few "representative" colors in the image. The selected colors are specified in the color [[palette (computing)|palette]] in the header of the compressed image. Each pixel just references the index of a color in the color palette. This method can be combined with [[dithering]] to avoid [[posterization]]. ** Whole-image palette, typically 256 colors, used in GIF and PNG file formats. ** block palette, typically 2 or 4 colors for each block of 4x4 pixels, used in [[Block Truncation Coding|BTC]], [[Color Cell Compression|CCC]], [[S2TC]], and [[S3 Texture Compression|S3TC]]. * [[Chroma subsampling]]. This takes advantage of the fact that the human eye perceives spatial changes of brightness more sharply than those of color, by averaging or dropping some of the chrominance information in the image. * [[Fractal compression]]. * More recently, methods based on [[Machine Learning]] were applied, using [[Multilayer perceptron]]s, [[Convolutional neural network]]s, [[Generative adversarial network]]s<ref>{{cite web |author1=Gilad David Maayan |title=AI-Based Image Compression: The State of the Art |url=https://towardsdatascience.com/ai-based-image-compression-the-state-of-the-art-fb5aa6042bfa |website=Towards Data Science |access-date=6 April 2023 |date=Nov 24, 2021}}</ref> and [[Diffusion model]]s.<ref>{{Cite web |last=BΓΌhlmann |first=Matthias |date=2022-09-28 |title=Stable Diffusion Based Image Compression |url=https://pub.towardsai.net/stable-diffusion-based-image-compresssion-6f1f0a399202 |access-date=2022-11-02 |website=Medium |language=en}}</ref> Implementations are available in [[OpenCV]], [[TensorFlow]], [[MATLAB]]'s Image Processing Toolbox (IPT), and the [[High-Fidelity Generative Image Compression]] (HiFiC) open source project.<ref>{{cite web |title=High-Fidelity Generative Image Compression |url=https://hific.github.io/ |access-date=6 April 2023}}</ref> Methods for [[lossless compression]]: * [[Run-length encoding]] β used in default method in [[PCX]] and as one of possible in [[BMP file format|BMP]], [[.tga|TGA]], [[TIFF]] * Predictive coding β used in [[DPCM]] * [[Entropy encoding]] β the two most common entropy encoding techniques are [[arithmetic coding]] and [[Huffman coding]] * Adaptive dictionary algorithms such as [[LZW]] β used in [[Graphics Interchange Format|GIF]] and [[TIFF]] * [[DEFLATE]] β used in [[Portable Network Graphics|PNG]], [[Multiple-image Network Graphics|MNG]], and [[TIFF]] * [[Chain code]]s
Summary:
Please note that all contributions to Niidae Wiki may be edited, altered, or removed by other contributors. If you do not want your writing to be edited mercilessly, then do not submit it here.
You are also promising us that you wrote this yourself, or copied it from a public domain or similar free resource (see
Encyclopedia:Copyrights
for details).
Do not submit copyrighted work without permission!
Cancel
Editing help
(opens in new window)
Search
Search
Editing
Image compression
(section)
Add topic