The difference between lossy compression and lossless compression

Both lossy compression and lossless compression belong to compression technology, but no matter what technical model is adopted, the essence of the two is the same, that is, the repetition degree of data information exists through a special coding method. Redundancy is effectively reduced to achieve data compression. The basic principle is that, under the premise of not affecting the basic use of the file, only some "key points" in the original data are retained, and the redundant and redundant information in the data is removed, thereby achieving the purpose of compression.

Definition of lossy compression and lossless compression
The difference between lossy compression and lossless compression

Lossy compression exploits the characteristics of human beings that are insensitive to certain frequency components in images or sound waves, allowing loss of certain information during compression; although the original data cannot be fully recovered, the loss of the portion of the original image is reduced. However, in exchange for a much larger compression ratio, that is, the compressed data is used for reconstruction, and the reconstructed data is different from the original data, but does not affect the misunderstanding of the information expressed by the original data. Lossy compression is used where the reconstructed signal does not have to be identical to the original signal. Image and sound compression (because it contains more data than our visual system and the party system can receive, throwing away some data without misunderstanding the meaning of the sound or image but greatly improving the compression ratio ). Lossy compression is widely used for compression of speech, image and video data.

The lossless compression format uses the statistical redundancy of the data to compress, completely recovering the original data without causing any distortion, but the compression ratio is limited by the theoretical redundancy of the data, generally 2:1 to 5:1. This type of method is widely used for compression of text data, programs, and image data for special applications (such as fingerprint images, medical images, etc.). That is to say, the compressed data is reconstructed (or called reduction, decompression), and the reconstructed data is identical to the original data; lossless compression is used when the reconstructed signal is completely identical to the original signal.

The difference between lossy compression and lossless compression
The difference between lossy compression and lossless compression

1, the difference in reductive

Lossless compression can be completely restored; lossy compression and reduction can not be the same as the original file, there is a certain loss.

2, the difference in compression ratio

Lossless compression compression rate is limited by the theoretical redundancy of data, generally 2:1 to 5:1;

   Lossy compression exploits humans' insensitivity to certain frequency components in images or sound waves, allowing certain information to be lost during compression. Although the original data cannot be fully recovered, the loss of the portion of the original image is less affected. But in exchange for a much larger compression ratio of up to 200:1 or more.

3, the difference in compressed file format

Formats such as mp3, divX, Xvid, jpeg, rm, rmvb, wma, wmv are lossy compression;

   APE, FLAC, TAK, WavPack, TTA, etc. are commonly used in lossless compression formats.

4, the difference in compression principle

The basic mechanism of lossy compression:

One is lossy transform codec, which first samples the image or sound, cuts it into small blocks, transforms it into a new space, quantizes it, and then entropy encodes the quantized value.

The other is predictive codec. The previous data and subsequent decoded data are used to predict the current sound samples or image frames, the error between the predicted data and the actual data, and other information for reproducing the prediction to be quantized and encoded.

The principle of lossless compression is run length coding, Huffman coding, and arithmetic coding.

5, the difference in the field of application

Lossy compression is widely used for compression of voice, image and video data;

Lossless compression is limited by the compression ratio. It is only used for compression of text data, programs and image data of special applications (such as fingerprint images, medical images, etc.), but the prospect of lossless compression formats is undoubtedly bright, over time. Various factors limiting the lossless format will be gradually eliminated. For example, the hard disk capacity is increasing, the mechanical hard disk 1TB has become mainstream, and the solid state hard disk 200GB will also be popularized. The problem of large space loss in the lossless format will no longer be a problem, and the speed will be faster. The decoding chip will also be developed. I believe that more and more hard disk players will support the lossless format. In the near future, even if the capacity of the flash memory player is calculated in TB, in order to pursue higher sound quality, Lossless compression formats will become more and more important.

Modern Physics Experiment Series

Modern physics experiment related equipment for efficient specialized physics laboratory

Modern Physics Experiment Instruments,Optical Instruments,Acousto-Optic Modulator Experimental Device,Optical Spectroscopy Experiment Determinator

Yuheng Optics Co., Ltd.(Changchun) , https://www.yhenoptics.com