鄧衛(wèi)軍 楊勝
摘要:圖像拼接是是一種重要而實(shí)用的計(jì)算機(jī)技術(shù),好的拼接算法離不開魯棒的參數(shù)估計(jì)方法。尺度總體最小二乘方法作為一種新的線性模型參數(shù)估計(jì)方法,它是最小二乘,數(shù)據(jù)最小二乘與總體最小二乘方法的直接推廣與統(tǒng)一體,具有良好的估計(jì)性能??紤]到觀測數(shù)據(jù)中外點(diǎn)的存在將可能導(dǎo)致參數(shù)估計(jì)失效,我們首次將RANSAC方法與尺度總體最小二乘結(jié)合起來用于圖像拼接問題,實(shí)驗(yàn)表明,該方法具有優(yōu)良的性能,值得推薦。
關(guān)鍵詞:圖像拼接;尺度總體最小二乘
中圖分類號:TP18文獻(xiàn)標(biāo)識碼:A文章編號:1009-3044(2012)18-4503-04
Scaled Total Least Squares and Its Application in Image Mosaicing
DENG Wei-jun1,2,YANG Sheng2
(1. Hunan Normal University, College of Polytechnic, Changsha 410081,China; 2.Yueyang County Vocational School, Yueyang 414100, China)
Abstract:Image mosaicing is an important and useful technology in computer science and it requires robust parameter estimation methods. Scaled total least squares (STLS) is novel parameter estimation approach for linear model which unifies the least square (LS), data least squares (DLS) and total least squares (TLS) and shows better performance. However, the outliers or gross errors may destroy the estimation performance of the LS, DLS, TLS and STLS approaches. We combined the RANSAC method with the STLS algorithm and adopted it in the image mosaicing. Experiments show that the RANSAC-STLS method behaves excellent and it is recommendable for practical workers in computer vision.
Key words:image mosaicing; scaled total least squaers
圖像拼接(image mosaicing)是一項(xiàng)重要技術(shù),在醫(yī)學(xué)影像處理,航空遙感,地理信息系統(tǒng),虛擬現(xiàn)實(shí)技術(shù),計(jì)算機(jī)視覺等領(lǐng)域有著廣泛的應(yīng)用背景[1-2]。一方面,由于攝像機(jī)的視角范圍遠(yuǎn)比人小,如果要對較大的區(qū)域獲取全景信息,就不等不把圖片系列包含的場景拼接成全景;另一方面,對于人眼也無法縱覽的場景,例如大地尺度下的遙感遙測與地理信息系統(tǒng),也迫使人們尋求準(zhǔn)確高效的圖像拼接方法。較早的獲取全景圖像的方法是使用像機(jī)繞定軸搖轉(zhuǎn)(panning),而拼接過程則類似于按母線展開圓柱面。對于以平移運(yùn)動為主的運(yùn)動攝像機(jī)拍攝的圖片系列,與搖轉(zhuǎn)情形類似,都可以用一個(gè)公共的參考平面來構(gòu)建全景,其中包含各個(gè)局部拍攝的圖片所包含的局部場景信息。對于場景而言,最簡單的是靜態(tài)的場景,當(dāng)前的各種圖像算法都是針對這類問題,對于運(yùn)動場景的拼接問題,則要復(fù)雜得多,Peleg等人[3]在這方面做出了開創(chuàng)性的貢獻(xiàn)。
圖像拼接技術(shù)包括兩個(gè)基本步驟:圖像配準(zhǔn)(image alignment, image registration)與區(qū)域粘帖(pasting)。對于圖像配準(zhǔn)而言,有兩大類方法,第一類方法是間接法,即利用特征抽取與匹配過程獲得的匹配點(diǎn)計(jì)算兩圖像間的單應(yīng)矩陣(射影變換或放射變換矩陣);第二類是直接法,采用所有像素點(diǎn)求得圖像點(diǎn)的平面運(yùn)動模型(單應(yīng)矩陣)。對于區(qū)域粘貼,也有兩大類方法,一類是使用全部像素的常規(guī)方法,另一類是流形拼接方法[4-8],這類方法的特點(diǎn)是從每張圖片中選取一個(gè)條帶,先進(jìn)性形變將光流平行化,然后按順序(不重疊地的)拼接。
然而無論何種拼接問題與方法,圖像配準(zhǔn)過程都離不開平面單應(yīng)矩陣的參數(shù)估計(jì)過程,因此好的線性模型參數(shù)方法總能在圖像拼接中得到應(yīng)用。在實(shí)際問題中,從圖像中提取任何信息都會受到噪聲干擾,各類方法都存在一個(gè)魯棒性(也叫穩(wěn)健性)問題,當(dāng)觀測數(shù)據(jù)中存在外點(diǎn)時(shí),參數(shù)估計(jì)方法很可能會失效。此外,在不存在外點(diǎn)時(shí),不同的參數(shù)估計(jì)方法也有不同的性能,尋找好的估計(jì)方法在理論上與應(yīng)用上都非常重要。
在該文中,我們考慮基于特征抽取與匹配的圖像拼接方法,采用RANSAC方法[9]剔除外點(diǎn),而用尺度總體最小二乘(scaled total least squares, STLS)方法[10]估計(jì)平面單應(yīng)矩陣,用距離加權(quán)融合圖像間公共區(qū)域以獲取無縫拼接的全景圖像。
圖3RANSAC-STLS方法得到的全景圖(γ=1.0)
容易發(fā)現(xiàn),拼接想效果非常只好,沒有任何“鬼影”(ghost)現(xiàn)象,連圖中的電線也已經(jīng)光滑連接了。實(shí)驗(yàn)還發(fā)現(xiàn),當(dāng)把圖1作為參考圖像時(shí),在γ<0.85時(shí),單應(yīng)模型參數(shù)估計(jì)失效,兩幀圖像無法正確配準(zhǔn),從而得不到正確的全景圖像。而如果不采用RANSAC方法剔除錯(cuò)誤匹配點(diǎn),則無論γ取什么值,都無法配準(zhǔn),從而不可能得到全景圖像。
[1]趙向陽,杜利民.一種全自動穩(wěn)健的圖像拼接融合算法[J].中國圖像圖像學(xué)報(bào),2004,9(4):417-422.
[2] M.Brown, D.G.Lowe, Recongizing Panoramas.Procedings of IEEE International Conference on Computer Vision ,2003(2):1218-1225.
[3] A. Rav-Acha, Y. Pritch, D. Lischinski,et,al. Dynamosaicing: Mosaicing of Dynamic Scenes, IEEE Trans. PAMI, Oct. 2007:1789-1801.
[4] S. Peleg, B. Rousso, A. Rav-Acha, and A. Zomet, Mosaicing on Adaptive Manifolds, IEEE Trans. on PAMI, Oct. 2000:1144-1154.
[5] B. Rousso, S. Peleg, I. Finci, and A. Rav-Acha, Universal Mosaicing using Pipe Projection , ICCV98, Bombay, January 1998:945-952.
[6] B. Rousso, S. Peleg, and I. Finci, Video Mosaicing using Manifold Projection , British Machine Vision Conference BMVC97, Univ. of Es? sex, UK, Sept. 1997. HTML version.
[7] S. Peleg and J. Herman, Panoramic Mosaics by Manifold Projection ,, CVPR97, June 1997:338-343.
[8] B. Rousso, S. Peleg, and I. Finci, Mosaicing with Generalized Strips, DARPA Image Understanding Workshop, May 1997:255-260
[9] M.A. Fishler and R.C. Boles. "Random sample consensus: A paradigm for model fitting with applications to image analysis and automat? ed cartography". Comm. Assoc. Comp, Mach., 1981, 24(6): 381-395.
[10]張鴻燕,耿征.Levenberg-Marquardt算法的一種新解釋[J].計(jì)算機(jī)工程與應(yīng)用, 2009, 45(19): 5-8.
[11] C.C. Paige & Z. Strakos, Unifying least squares, total least squares and data least squares , In S. van Huffel and P. Lemmerling, editors, Total Least Squares and Errors-in-Variables Modeling, Dordrecht: Kluwer Academic Publishers, 2002:25-34.
[12]張賢達(dá).矩陣分析與應(yīng)用[M].北京:清華大學(xué)出版社,2004.
[13] Lowe,DavidG.(2004)."DistinctiveImageFeaturesfromScale-InvariantKeypoints".InternationalJournalofComputerVision60(2):91-110.
[14] Cui, Y,Hasler N. Thormaehlen, T.; Seidel, H.-P. (July 2009). "Scale Invariant Feature Transform with Irregular Orientation Histogram Binning". Proceedings of the International Conference on Image Analysis and Recognition (ICIAR 2009), Halifax, Canada: Springer .
[15] R. Hartley, A. Zisserman, Multiple View Geometry in Computer Vision, 2nd ed., Cambridge Press, 2004.