張 毅 雷 杰 李云松
?
一種新的基于先驗(yàn)數(shù)據(jù)表的JPEG-LS動(dòng)態(tài)碼率控制算法
張 毅 雷 杰*李云松
(西安電子科技大學(xué)綜合業(yè)務(wù)網(wǎng)國家重點(diǎn)實(shí)驗(yàn)室 西安 710071)
JPEG-LS算法簡單,壓縮性能出眾,特別適合應(yīng)用在圖像的無損/近無損壓縮領(lǐng)域。但是,無法精確控制碼率的缺點(diǎn)使得JPEG-LS難以應(yīng)用在帶寬受限的衛(wèi)星圖像編碼領(lǐng)域。為了解決這個(gè)問題,該文基于對JPEG-LS編碼特性的分析,通過理論推導(dǎo)得出輸出碼率與失真量化參數(shù)的數(shù)學(xué)關(guān)系,提出一種以查表算法為核心的新型JPEG-LS動(dòng)態(tài)碼率控制算法。相對于現(xiàn)有的動(dòng)態(tài)碼率控制算法,該算法具有碼率精確度高,收斂速度快等優(yōu)點(diǎn)。
圖像壓縮;碼率控制;近無損;JPEG-LS
壓縮編碼技術(shù)是圖像處理和傳輸過程中的一項(xiàng)關(guān)鍵技術(shù),JPEG-LS圖像壓縮標(biāo)準(zhǔn)在無損/近無損壓縮時(shí)性能優(yōu)異,算法復(fù)雜度低,成為空間通信和醫(yī)療等領(lǐng)域圖像壓縮技術(shù)的首選方案[1]。但是JPEG-LS有一個(gè)缺陷,編碼器輸出碼率波動(dòng)較大而且不可控,這種缺陷極大限制了JPEG-LS的應(yīng)用。特別是在遙感衛(wèi)星應(yīng)用中,信道帶寬受到嚴(yán)格的限制,編碼器的輸出碼率必須與信道帶寬相匹配[2]。
本文通過對JPEG-LS圖像壓縮標(biāo)準(zhǔn)的編碼特性進(jìn)行分析,提出了一種基于先驗(yàn)數(shù)據(jù)表的JPEG- LS動(dòng)態(tài)碼率控制算法。實(shí)驗(yàn)結(jié)果表明該方法可以更好地實(shí)現(xiàn)碼率的精確控制,在碼率精確度、碼率收斂速度方面都明顯優(yōu)于現(xiàn)有的一階線性碼率控制算法,且保留了JPEG-LS復(fù)雜度低、運(yùn)算消耗小的優(yōu)點(diǎn)。
在JPEG-LS的核心算法LOCO-I[10]中,采用一種估計(jì)的方法來得出合適的值,使得Golomb- Rice的編碼長度最短[13]。估算式如式(3)所示。
將式(3)代入式(2)中,得到具體的碼長為
分別對式(5)和式(6)等號兩邊取絕對值,并取數(shù)學(xué)期望,得
將式(7),式(9)和式(8),式(10)分別代入式(11),式(12)中,并求差值得
圖1 不同復(fù)雜度圖像的碼率特性曲線的關(guān)系
統(tǒng)計(jì)得到的先驗(yàn)數(shù)據(jù)如表1所示,由第3節(jié)的分析結(jié)論可知:該表內(nèi)容適用于各類圖像的壓縮,具有通用性,且在壓縮過程中不需要更新。這種特點(diǎn)使得本文算法不僅精確度高,而且復(fù)雜度低,易于實(shí)現(xiàn)。
表1實(shí)驗(yàn)統(tǒng)計(jì)得到的經(jīng)驗(yàn)數(shù)組
失真控制參數(shù)碼率調(diào)整(bpp)失真控制參數(shù)碼率調(diào)整(bpp) 01.56896100.07480 10.69552110.06464 20.42024120.05856 30.29728130.05288 40.22088140.04664 50.17384150.04264 60.14080160.03976 70.11896170.03680 80.10176180.03472 90.08776190.03232
(4)結(jié)束調(diào)整。
圖2 情況下的值調(diào)整算法流程圖
步驟1 初始化:
(4)計(jì)算前個(gè)碼塊的碼率偏差
步驟4 結(jié)束編碼。
(1)碼率精確度 圖4反映的是兩種算法在碼率精確度上的性能對比。分別使用一階線性碼率控制算法和本文算法對測試圖像進(jìn)行壓縮編碼和碼率控制,記錄在不同算法控制下,測試圖像的輸出碼率和目標(biāo)碼率的差。獲得的實(shí)驗(yàn)結(jié)果如圖4所示,橫軸為圖像序號,縱軸代表圖像實(shí)際輸出碼率和目標(biāo)碼率的偏差的絕對值。從圖4可以直觀地看到,本文提出的碼率控制算法的碼率偏差明顯小于一階線性碼率控制算法。
圖3 基于JPEG-LS編碼特性的碼率控制算法框圖
本文通過深入分析JPEG-LS的編碼特性,提出了一種以失真量化參數(shù)的查表算法為核心的新型JPEG-LS動(dòng)態(tài)碼率控制算法,實(shí)驗(yàn)結(jié)果表明:該算法在碼率控制精度以及碼率收斂速度等主要性能指標(biāo)上都明顯超過現(xiàn)有的一階動(dòng)態(tài)碼率控制算法,并且復(fù)雜度低,易于實(shí)現(xiàn),能將JPEG-LS更好地應(yīng)用于帶寬受限的場合中。
圖4 兩種算法的碼率精確度對比
圖5 兩種算法的碼率收斂速度對比圖
[1] Cai Q, Song L, Li G,.. Lossy and lossless intra coding performance evaluation: HEVC, H.264/AVC, JPEG 2000 and JPEG LS[C]. Signal & Information Processing Association Annual Summit and Conference, Hollywood, California, USA, 2012: 1-9.
[2] 陳曉, 徐曉慶. 衛(wèi)星圖像碼率控制方法的改進(jìn)[J]. 光電工程, 2012, 39(9): 7-11.
[3] Jiang J and Yang S Y. A rate-controlled near lossless image CODEC based on visual perception and content adaptability [C]. Proceedings of International Society for Optics and Photonics, the International Society for Optical Engineering, Boston, USA, 2001, 4209: 262-272.
[4] Tsai T H, Kao S C, and Lee Y X. The segment-based rate control algorithm in JPEG-LS for bandwidth-efficiency applications[C]. IEEE International Conference on Multimedia and Exposition, Hannover, Germany, 2008: 793-796.
[5] Jiang J and Reddy M. Open-loop rate control for JPEG-LS near lossless image compression[J]., 1999, 35(6): 465-466.
[6] Zhang J, Li Y, Liu K,.. The rate control scheme for JPEG-LS with high bitrate[C]. Proceedings of International Society for Optics and Photonics, Satellite Data Compression, Communications, and Processing VIII, San Diego, USA, 2012: 1-8.
[7] 侯舒維, 孫文方, 等. 一種JPEG-LS圖像壓縮的碼率控制方法[P]. 中國, 201010617932.2, 2010.
[8] 崔倩. JPEG-LS碼率控制算法研究[D]. [碩士論文], 西安電子科技大學(xué), 2010.
[9] 徐燕凌, 劉蓓. JPEG-LS圖像壓縮動(dòng)態(tài)碼率控制策略[J]. 計(jì)算機(jī)工程, 2008, 34(7): 238-271.
[10] Weinberger Marcelo J, Seroussi G, and Sapiro G. LOCO-I: a low complexity, context-based, lossless image compression algorithm[C]. Proceedings of IEEE, Data Compression Conference, Snowbird, Utah, USA, 1996: 140-149.
[11] Weinberger Marcelo J, Seroussi G, and Sapiro G. The LOCO-I lossless image compression algorithm: principles and Standardization into JPEG-LS[J]., 2000, 9(8): 1309-1324.
[12] Ding J J, Wei W Y, and Pan G C. Modified Golomb coding algorithm for asymmetric two-sided geometric distribution data[C]. 20th European Signal Processing Conference, Bucharest, Romania, 2012: 1548-1552.
[13] Ding J and Wei W. Adaptive golomb code for joint geometrically distributed data and its application in image coding[J]., 2012, 23(4): 661-670.
[14] Wahl S, Tantawy H A, Wang Z,. Exploitation of context classification for parallel pixel coding in JPEG-LS[C]. Image Processing (ICIP), 2011 18th IEEE International Conference on, Brussels, Belgium, 2011: 2001-2004.
[15] Gera Y, Wang Z, Simon S,.. Fast and context-free lossless image compression algorithm based on JPEG-LS[C]. Data Compression Conference (DCC), Snowbird, Utah, USA, 2012: 396.
張 毅: 男,1989年生,碩士生,研究方向?yàn)閳D像編碼算法及其硬件實(shí)現(xiàn).
雷 杰: 男,1981年生,副教授,研究方向?yàn)閳D像/視頻傳輸與處理.
李云松: 男,1974年生,教授,研究方向?yàn)閳D像/視頻傳輸與處理.
A Novel Dynamic Rate Control Algorithm for JPEG-LS Based on Empirical Data Table
Zhang Yi Lei Jie Li Yun-song
(,,’710071,)
JPEG-LS is suitable for the field of lossless/near-lossless image compression because of its simple algorithm and high performance. However, it is difficult for JPEG-LS to control precisely the bit rate, which makes it hard to be applied to bandwidth-constrained occasions such as the satellite image coding. To solve this issue, the mathematic relation between bit rate and the quantization parameter is obtained by analyzing the coding characteristics of JPEG-LS, with which a novel dynamic bit-rate control algorithm is proposed based on the look-up table algorithm. Experimental results show that the proposed new bit-rate control algorithm is superior to the current JPEG-LS rate control scheme on the accuracy of bit-rate and the speed of bit-rate convergence.
Image compression; Bit-rate control; Near-lossless; JPEG-LS
TN919.81
A
1009-5896(2014)04-0823-05
10.3724/SP.J.1146.2013.00759
2013-05-27收到,2013-12-20改回
國家優(yōu)秀青年基金(61222101),國家自然科學(xué)基金(61301287, 61301291), 111基地項(xiàng)目(B08038)和中央高校基本科研業(yè)務(wù)費(fèi)專項(xiàng)資金(K5051301043, K5051201043)資助課題
雷杰 jielei@mail.xidian.edu.cn