上一節主要是介紹LSD算法理論,這節主要是介紹LBD算法。
參考文章:An efficient and robust line segment matching approach based on LBD descriptor and pairwise geometric consistency ----Lilian Zhang , Reinhard Koch
第二部分:Line detection and description
1.尺度空間中提取線段
為了克服在線檢測碎片問題和提高大尺度變化的性能,我們的檢測框架采用由對原始圖像進行高斯下采樣( with a set of 尺度因子and 高斯模糊 )的尺度空間金字塔組成(N層圖像)。我們首先用Edline算法每層的尺度空間產生一組線。每條直線都有一個方向,它是由從直線左側到右側的大部分邊緣像素點的梯度構成的。然后通過在尺度空間中找到對應的直線來組織它們。在尺度空間中所有的線,他們被分配一個唯一的ID,如果在圖像中他們相關相同的事件,將其存儲在一個稱為LineVecs的向量中(即圖像的同一區域具有相同的方向)。線檢測方法 不同於Wang et al.[5] ,通過重新組織從尺度空間提取的所有的線段形成LineVecs,從而降低了圖匹配問題的維數。最終提取的結果是一組LineVecs如下圖:
如圖1所示,每個Linevec可能包括尺度空間的多條線。為描述一個LineVec局部外觀,對於其中的每條線,我們會在被提取的線段的每層圖中產生一種線描述符。
2.條帶(Band)來表示線的支持域
在octave image給出了線段,描述符將從線段支持域(LSR)計算。該支持區域被划分為一組條帶{B1;B2;...;Bm},每個條帶都是LSR的子區域並且他們之間的平行的,條代數m的和每個條帶的寬度w,條帶的長度等於線段的長度,如下圖當m =5 ,w=3的LSR例子。
類似於 MSLD[11],引入兩個方向構成a local 2D coordinate frame(局部二維坐標系),用於區分具有相反梯度方向的平行線並使描述符旋轉不變。根據線的方向為 ,正交方向(垂直方向)
被定義為
順時針垂直的方向。該線的中點被選為這個局部坐標系的原點。LSR中的每個像素的梯度投影到這個局部框架
,其中的
:image frame中的像素梯度,
:local frame中的像素梯度。
對於SIFT[23] and MSLD,兩個高斯函數應用在每一行沿着的方向。首先,全局權重系數
是在LSR的第i行,其中
是第i行到LSR中心行的距離,
第二,考慮一個條帶Bj,以及他在相鄰的條帶Bj-1,Bj+1 ,局部權重系數
在Bj第k行,其中
第k行到Bj中心行的距離,
全球的高斯窗的目的是給予在LSR中沿
方向遠離線的微小變化梯度很小的關注度(敏感性)。局部高斯窗的目的是減少邊界效應,它避免了像素從一個條帶移動到下一個的描述符突然改變。
此方法描述子區域的優點:首先,它對方向的小的位置變化更有魯棒性,因為在這種情況下,帶內圖像的大部分內容保持不變,只有帶邊界略有變化。注意,這個特性很重要,因為一般來說,由於線路端點不穩定,線的位置精度在方向
中要比方向
低。第二,它的計算效率更高,因為每個條帶之間在
方向沒有重疊,高斯權重直接應用於每一行,而不是每個像素。
3.構造條帶描述符
(the Line Band Descriptor) LBD:
每條條帶的描述子BDj:通過其最近的兩相鄰行的條帶Bj-1 ; Bj+1來計算 。特別是,對於在頂部和底部的條帶帶B1和Bm,在計算B1和Bm的描述子時行在LSR之外不會被考慮在內。(所以下面n的取值會把j=1||m單獨出來)
BDj的計算(其實就是描述的上下左右四個方向):
k:表示在條帶Bj的第k行,我們累積的像素的梯度在這行;:高斯權重。
條帶描述矩陣the band description matrix (BDM):
BDj由BDMj矩陣的均值向量Mj and標准方差 Sj 得到:
LBD的均值部分和標准方差部分由於其大小不同,分別進行規范化處理。此外,為減少非線性光照變化的影響,對LBD每個維度的進行抑制,使它小於一個閾值(經驗:0.4的是一個很好的值)。最后,我們重新規范約束向量得到單元的LBD。
二.描述符性能評價
在檢測我們提出的圖像匹配算法之前,我們線分析一下LSR參數的影響,例如條帶的數量m和條帶的寬度w,評價LBD的性能與MSLD描述子做比較。
Mikolajczyk and Schmid [33]建立一個基准,評價局部描述符的性能。我們使用這個框架來比較線描述符的性能。實驗數據集包括八組圖像:光照變化、面內旋轉、jpeg壓縮、圖像模糊、圖像遮擋、低紋理場景中視點變化和紋理場景,以及尺度變化。
針對這一部分所描述的描述符的匹配性能,我們選擇了最近鄰匹配准則,根據描述符的距離對線進行匹配,避免了由於不同描述符偏愛不同閾值而造成距離閾值的偏差。這種匹配准則的另一個優點是,召回率(正確匹配的數量除以地面對應的數目)和匹配精度(正確匹配的數量除以總數量的匹配)是唯一的決定正確匹配的數量由於不同的描述符的分母是相等的。
描述子維數
下圖顯示了所有的圖像正確匹配的數量是由這兩個參數(m和w)影響的。It is clear that LBD and MSLD share similar rules: the performance increases fast at the beginning with the increment of m or w, then reaches the best performance when m=9 and w is about 7 or 9, after that there is a steady performance decrease.
The results are well explained by the fact that larger values of m and w (i.e. larger LSR) make the descriptor more distinctive(獨特的) while they also reduce the repeatability(可重復性) of the LSR.
We also evaluate the time performances of these two descriptors which are given in Table 1.
Although the time performances may change from image to image, their relative relationship will keep the same. We only show the results which are generated from an example image with the size of 900×600 and 573 extracted lines. Basically, the larger m and w are, the more computational time is consumed.
LBD is less sensitivity(敏感) to the increase of m and w than that of MSLD, especially for the increase of w.Based on the aforementioned evaluation, through the rest of the paper, the descriptor will be computed from a LSR with m= 9 and w= 7, resulting in a 72-dimensional descriptor. Then the computing times of LBD and MSLD for the example image are 28 ms, and 137 ms, respectively.
2.MSLD and LBD更多比較
比較每組照片的,MSLD and LBD recall ratios如下圖:
(a) shows the performances of MSLD and LBD for the image illumination changes. From image 1 to image 5, the lighting condition gets worse. The recall ratios decrease with the increment(增長) of the lighting distortion(照明畸變).
(b) shows the results for images which are generated by a set of in-plane rotation varying from15° to75° .It is interesting that when the rotation angle is 45 (between image 3 and the reference image), LBD and MSLD perform worst because of the aliasing of discrete lines(離散線的混疊).
(c) and (d) show the descriptor performance against the image compression(壓縮) and the image blurring(模糊), respectively. Not surprisingly, the performances decrease with the increment of the image compression ratio(壓縮比) or the image blurring.
(e) shows the descriptor performance against image occlusion(遮擋). To evaluate the occlusion effect, we first artificially(人工地) add some vertical line(垂直線) features in a background image, then shift the region of interest along the vertical direction of the artificial image to generate a set of smaller images as shown in Fig. 5(e). This process makes sure that for the most of the lines, their LSR in the image sequence(圖像序列) will change gradually (some part of the LSR moves out or in). The results show that the descriptor performance decreases with the increment of the image occlusion.
(f) shows the descriptor performance in the lowtexture scene(低紋理場景). Images in this sequence are captured in front of the window with small view point changes. The results do not show drastic change(巨大的變化) in performance because of the small baseline between images.
(g) shows the descriptor performance against large view point change. The view angles between the query images and the reference image range approximately from
-70° to 60° . No doubt, the descriptors perform better when the absolute value of the view angle is smaller (image3 and image4).
(h) shows the most challenging case for the descriptors, i.e, the large scale change. The scale ratio(比率) between the query images and the reference image range from 0.9 to 0.3. The performance decreases fast with the scale change.