压缩分为无损压缩(lossless compression)和有损压缩(lossy compression)
无损压缩:Lossless compression is a class of data compression that allows the original data to be perfectly reconstructed from the compressed data with no loss of information。
允许从压缩数据中完美地重建原始数据,而不丢失信息
有损压缩:Lossy compression or irreversible compression is the class of data compression methods that uses inexact approximations and partial data discarding to represent the conten
数据经过压缩、解压后与原数据不完全相同但非常接近的压缩方式;
有损压缩应用场景:用在非高精确度要求数据中,如图片、视频、声纹等流媒体数据信息
有损压缩常见算法:(1)在图像领域中有基于离散余弦变换DCT (DiscreteCosine Transform)的JPEG、JPEG2000,小波压缩;
(2)视频领域中的Flash、MNG;
(3)音乐领域中的AAC、MP2、MP3;
(4)语音领域的CELP、HILN
无损压缩应用场景:H.264/265, OpenCTM
无损压缩常见算法:(1)基于字典编码的算法:RLE, LZ77, LZMA
(2)基于熵编码的算法: Huffman, FSE, Arithmetic