論文<Learning to Promote Saliency Detectors>閱讀

Learning to Promote Saliency Detectors

https://github.com/lartpang/M...

縮寫標註:

  • SD: Saliency Detection
  • ZSL: Zero-Shot Learning

關鍵內容:

  • 沒有訓練直接將圖像映射到標籤中的DNN。相反,將DNN擬合爲一個嵌入函數,以將像素和顯著/背景區域的屬性映射到度量空間。顯着/背景區域的屬性被映射爲度量空間中的錨點。然後,在該空間中構造最近鄰(NN)分類器,將最近的錨點的標籤分配給對應的像素.
  • 保持分辨率的手段:

    1. 移除了最後兩個卷積塊的池化層, 使用擴張卷積來維持卷積濾波器的感受野
    2. 添加亞像素卷積層到每個VGG特徵提取器的卷積塊後, 來上採樣每個卷積塊的特徵圖到輸入圖像大小.
  • 使用了迭代訓練/測試的策略.

    • 這裏沒有提到訓練迭代次數如何確定
    • 測試的迭代次數是人工給定的

一些想法:

類似於R3Net, 最後的添加的結構都是反覆迭代測試後才確定使用多少次, 而且按照相關的測試可以看出來, 一定次數後, 提升的效果就趨於飽和了, 只能說這裏的提到的方法對於現有網絡的提升具有一定的助益.

對於這裏提到的, 這是類似於一種ZSL的方法, 也就是利用現有的SD算法產生的結果("過去的知識"), 添加的新結構, 不斷利用過去的知識迭代, 實現對於最終"後處理"後結果的一個促進("來對現有的SD算法進行推廣").

一些疑惑:

如何將這個方法應用到現有的架構呢? 如何改造現有架構?

改造後的結構, 訓練的時候也要按照文中那樣, 隨機翻轉真值中的像素標籤麼?

img

這裏的第6層是哪裏來的?是前面的5C通道的特徵輸出彙總來的?

Abstract

The categories and appearance of salient objects varyfrom image to image, therefore, saliency detection is animage-specific task. Due to lack of large-scale saliency training data, using deep neural networks (DNNs) with pre-training is difficult to precisely capture the image-specific saliency cues. To solve this issue, we formulate a zero-shot learning problem to promote existing saliency detectors.

Concretely, a DNN is trained as an embedding function to map pixels and the attributes of the salient/background regions of an image into the same metric space, in which an image-specific classifier is learned to classify the pixels.

Since the image-specific task is performed by the classifier, the DNN embedding effectively plays the role of a general feature extractor.

Compared with transferring the learning to a new recognition task using limited data, this formulation makes the DNN learn more effectively from small data.

Extensive experiments on five data sets showthat our method significantly improves accuracy of existing methods and compares favorably against state-of-the-art approaches.

顯着對象的類別和外觀因圖像而異,因此,顯着性檢測是特定於圖像的任務。由於缺乏大規模顯着性訓練數據,使用具有預訓練的深度神經網絡(DNN)難以精確捕獲圖像特定顯着性線索。爲了解決這個問題,我們制定了一個零次學習問題來推廣現有的顯着性檢測器。

具體地,DNN被訓練爲一個嵌入函數,以將像素和圖像的顯着/背景區域的屬性映射到相同的度量空間,其中, 圖像特定的分類器被學習來對像素進行分類。

由於圖像特定任務由分類器執行,因此DNN嵌入有效地扮演一般特徵提取器的角色。

與使用有限數據將學習轉移到新的識別任務相比,該設定使DNN從小數據中更有效地學習。

對五個數據集進行的大量實驗表明,我們的方法顯着提高了現有方法的準確性,並且與最先進的方法相比具有優勢。


這裏提到了一點, 使用 ZSL 問題來推廣現有的SD器. 怎麼推廣?

補充內容 ZSL[零次學習(Zero-Shot Learning)]

假設小暗(純粹因爲不想用小明)和爸爸,到了動物園,看到了馬,然後爸爸告訴他,這就是馬;之後,又看到了老虎,告訴他:“看,這種身上有條紋的動物就是老虎。”;最後,又帶他去看了熊貓,對他說:“你看這熊貓是黑白色的。”然後,爸爸給小暗安排了一個任務,讓他在動物園裏找一種他從沒見過的動物,叫斑馬,並告訴了小暗有關於斑馬的信息:“斑馬有着馬的輪廓,身上有像老虎一樣的條紋,而且它像熊貓一樣是黑白色的。”最後,小暗根據爸爸的提示,在動物園裏找到了斑馬(意料之中的結局。。。)。

上述例子中包含了一個人類的推理過程,就是利用過去的知識(馬,老虎,熊貓和斑馬的描述),在腦海中推理出新對象的具體形態,從而能對新對象進行辨認

ZSL就是希望能夠模仿人類的這個推理過程,使得計算機具有識別新事物的能力。

結合起來看, 也就是說可以利用過去的知識, 來對現有的SD器進行推廣.

這個過程是什麼樣的呢?

Introduction

傳統的顯着性檢測方法通常是利用低級別的特徵和啓發式先驗,它們不能在複雜的場景中發現顯着的對象,也就不能夠捕獲語義對象。隨着DNN的流行, 可以學習來自訓練樣本的更爲高層的語義特徵, 因此對於定位語義顯著性區域更爲有效, 在複雜場景下也會更爲有效.

使用DNN就要考慮一個問題, 數據. DNN通常在大量數據的基礎上來訓練, 而SD的數據是比較有限的, 這個問題通常用在其他任務的大數據集(如分類任務)上預訓練的手段來解決, 然而這很容易導致其他問題:

img

從圖上可以看出來, 分類任務訓練出來的模型, 最後的特徵圖中關注的重點對於SD任務而言, 在兩列的特徵圖中不加區分地突出顯示符號和人的區域。

哪個圖"不加區分地突出顯示符號和人的區域"?
  1. 預訓練任務與SD的差異: 由預先訓練的特徵提取器產生的特徵假定用於所有圖像。例如,標誌和人是圖1第一列中的顯着對象,而它們屬於第二列中的背景。然而,在兩列的特徵圖中不加區分地突出了標誌和人的區域。使用這種特徵提取器,可以強制預測模型學習將相似特徵映射到相反標籤,這對於小訓練數據集來說是困難的。
  2. 顯着對象的類別和外觀因圖像而異,而小的訓練數據不足以捕捉多樣性. 例如,圖1中所示的六個顯着對象來自六個不同的類別,並且它們的外觀差別很大。因此,可能很難學習統一的檢測器來處理各種顯着對象。

考慮到顯着對象的多樣性,我們沒有訓練直接將圖像映射到標籤中的深度神經網絡(DNN)。相反,我們將DNN訓練爲一個嵌入函數,以將像素和顯著/背景區域的屬性映射到度量空間。顯着/背景區域的屬性被映射爲度量空間中的錨點。然後,在該空間中構造最近鄰(NN)分類器,將最近的錨點的標籤分配給對應的像素。

作爲非參數模型,NN分類器可以很好地適應新數據並處理顯着對象的多樣性。另外,由於分類任務是由NN分類器執行的,因此DNN的目標轉向學習從顯着/背景區域的屬性到嵌入空間中的錨點的一般映射。與直接學習檢測不同的顯着對象相比,網絡更容易學習有限的數據.

補充內容: 嵌入(Embedding)

嵌入意味着將數據轉換爲特徵表示,其中某些屬性可以用距離的概念表示。

例如,針對用於說話者識別的語音信號訓練的模型可以允許您將語音片段轉換爲數字向量,使得來自相同說話者的另一片段與原始向量具有小的距離(例如,歐幾里德距離)。或者,不同的嵌入函數可能允許您根據信號中所說的單詞轉換語音信號。因此,如果在這些片段中使用相同的單詞,則在兩個語音信號的編碼表示之間將獲得小的歐幾里德距離。另外, 你可能只想學習一種嵌入,它代表語音信號的“情緒”,例如:“快樂”與“悲傷”與“憤怒”等。兩個語音信號的編碼表示之間的小距離將意味着相似的情緒,反之亦然。

或者例如,word2vec embeddings, 在一個空間中“映射”一個單詞,其中這些單詞之間的歐幾里德距離代表語義相似性(同樣, embedding ~ 爲您提供給定單詞的數字向量)。因此,如果你使用“德國”的word2vec表示,從中減去“柏林”,並將結果添加到“法國”,你會得到一個矢量, 在歐幾里德空間非常接近“巴黎”的嵌入(the embedding for “Paris”)!

同樣,在需要分類成數十萬或數百萬個類的應用程序中,例如面部識別,一種常見的方法是使用“度量學習”技術(通常是具有所謂的對比或三重丟失的連體CNN(Siamese CNNs with so-called contrastive or triplet loss)),這在測試時允許您在面部的矢量表示上使用最近鄰技術!

另一個介紹:

Embedding在數學上表示一個maping, f: X -> Y, 也就是一個function,其中該函數是injective(就是我們所說的單射函數,每個Y只有唯一的X對應,反之亦然)和structure-preserving (結構保存,比如在X所屬的空間上X1 < X2,那麼映射後在Y所屬空間上同理 Y1 < Y2)。那麼對於word embedding,就是將單詞word映射到另外一個空間,其中這個映射具有injective和structure-preserving的特點。

clipboard.png

具體地說,我們在圖2中顯示了我們提出的方法的流程。

在訓練期間,DNN具有真實的顯着區域和背景區域,其中幾個隨機選擇的像素的標籤被翻轉,以產生錨點。NN分類器的輸出構成了saliency map。DNN可以通過此顯着性圖和真值之間的損失進行端到端的監督訓練。

當在圖像上進行測試時,每個圖像的顯着性圖像按照訓練的流程來獲得,使用的是現有方法來檢測的近似的顯著性/背景區域。儘管近似顯着/背景區域不完全正確,但是它通常與真實的顯著性/背景區域有着相似的屬性。因此,對應的嵌入向量(即錨點)將接近真實的顯着/背景區域的向量。

此外,爲了產生更好的結果,我們提出了一個迭代測試的方案。NN分類器的結果用於修改錨點,從而產生越來越精確的結果。

迭代測試的想法, 如何實現? 在測試的時候, 你的迭代只能使用測試集的圖片數據和你預測出來的結果, 不可以在真實值上進行迭代, 那這裏的迭代如何片定效果, 如何學習? 這裏的進一步迭代測試的操作就是一種後處理手段, 但是如何迭代那? 何時終止迭代?

這裏的方法可以看作是一個ZSL問題,其中由現有方法檢測到的近似顯着/背景區域爲未看到的顯著性對象提供屬性,並且模型從訓練數據中學習去從屬性中學習一個特定於圖像的分類器來分類此圖像的像素

對五個數據集的大量實驗表明,該方法可以顯着提高現有方法的準確性,並且與現有技術方法相比具有優勢。

Related works

Generally, saliency detection methods can be categorized into two streams: top-down and bottom-up saliency. Since our work addresses bottom-up saliency, here we mainly review recent works on bottom-up saliency, meanwhile shortly mention top-down saliency. We also explore the relation between our proposed method and top-down saliency.

BU

Bottom-up (BU) saliency is stimuli-driven(刺激驅動), where saliency is derived from contrast among visual stimuli(視覺刺激).

Conventional bottom-up saliency detection methods often utilize low-level features and heuristic priors(啓發式).

  • Jiang et al. [12] formulate saliency detection via an absorbing Markov chain(吸收馬爾可夫鏈http://www.vartang.com/2013/0...) on an image graph model, where saliency of each region is defined as its absorbed time from boundary nodes.
  • Yang et al. [32] rank the similarity of the image regions with foreground cues or background cues via graph-based manifold ranking(通過基於圖的流形排序對圖像區域與前景線索或背景線索的相似性進行排序).

Since the conventional methods are not robust in complex scenes neither capable of capturing semantic objects, deep neural networks (DNNs) are introduced to overcome these drawbacks.

  • Li et al. [16] train CNNs with fully connected layers to predict saliency value of each superpixel, and to enhance the spatial coherence(空間連貫性) of their saliency results using a refinement method.
  • Li et al. [18] propose a FCN trained under the multi-task learning framework for saliency detection.
  • Zhang et al. [34] present a generic framework to aggregate multi-level convolutional features for saliency detection.

Although the proposed method is also based on DNNs, the main difference between ours and these methods is that they learn a general model that directly maps images to labels, while our method learns a general embedding function as well as an image-specific NN classifier.

TD

Top-down (TD) saliency aims at finding salient regions specified by a task, and is usually formulated as a supervised learning problem.

  • Yang and Yang [33] propose a supervised top-down saliency model that jointly learns a Conditional Random Field (CRF) and a discriminative dictionary.
  • Gao et al. [9] introduced a top-down saliency algorithm by selecting discriminant features from a pre-defined filter bank(預定義的過濾器庫).

TD+BU

Integration of TD and BU saliency has been exploited by some methods.

  • Borji [3] combines low-level features and saliency maps of previous bottom-up models with top-down cognitive visual features to predict fixations.
  • Tong et al. [26] proposed a top-down learning approach where the algorithm is bootstrapped with training samples generated using a bottom-up model(該算法使用自下而上模型生成的訓練樣本進行引導) to exploit the strengths of both bottom-up contrast-based saliency models and top-down learning methods.

Our method also can be viewed as an integration of TD and BU saliency. Although both our method and the method of Tonget al. [26] formulate the problem as top-down saliency detection specified by initial saliency maps, there are certain difference between the two.

  1. First, Tong’s method trains a strong model via boostrap learning(引導學習) with training samples generated by a weak model. In contrast, our method maps pixels and the approximate salient/background regions into a learned metric space, which is related to zero-shot learning.
  2. Second, thanks to deep learning, our method is capable of capturing semantically salient regions and does well on complex scenes, while Tong’s method uses hand-crafted features and heuristic priors, which are less robust.
  3. Third, our method produces pixel-level results, while Tong’s method computes saliency value of each image region to assemble a saliency map, which tends to be coarser.

The Proposed Method

clipboard.png

Our method consists of three components:

  1. a DNN as an embedding function i.e. the anchor network, that maps pixels and regions of the input image into a learned metric space
  2. a nearest neighbor (NN) classifier in the embedding space learned specifically for this image to classify its pixels
  3. an iterative testing scheme that utilizes the result of the NN classifier to revise anchors(修改錨點), yielding increasingly more accurate results.

The anchor network

這部分主要是進行了一個映射的操作. 一個是映射圖像中的像素點, 一個是映射圖像中的顯著性/背景區域.

像素點通過一個DNN建模的嵌入函數, 來映射到一個D維度量空間的向量上.

clipboard.png

圖像中的顯著性/背景區域也同樣被DNN映射到了D維度量空間中的向量上, 也就是這裏提到的錨點(anchors).

clipboard.png

We assume that in the embedding space, all pixels of an image cluster around the corresponding anchors of this image. Then a nearest neighbor classifier can be built specifically for this image by classifying each pixel according to its nearest anchor.
我們假設在嵌入空間中,圖像的所有像素都聚集在這個圖像的相應錨點周圍。然後,通過根據最近的錨對每個像素進行分類,可以爲該圖像特定地構建最近鄰分類器.

感覺可以這樣理解: 因爲並不知道哪個維度上可以看作是所謂的"embedding space", 所以目的就是去近似逼近這樣一個空間的表示. 這也算是深度網絡的一個擬合作用的體現, 告訴他應該存在這樣一個維度的空間, 是可以滿足這樣的要求, 給它限制, 讓它訓練學習, 逐步逼近擬合到這樣一個結果上.

爲了做出這樣的約束, 給定一個概率, 也就是對應的像素x屬於顯著性/背景區域C的條件概率, 由該測度空間上兩個向量的距離d對應的softmax函數表示得到:

clipboard.png

這裏的目的是要不斷的提升屬於對應區域的像素被判定歸屬於該區域的概率, 這裏使用梯度上升法:

clipboard.png

這裏的t是一個指示變量, 類似與指示函數的作用, 等於1的時候, 表示該像素屬於實際屬於區域1, 也就是顯著性區域, 等於0表示屬於區域2, 也就是背景區域.

但是這裏要注意, 對於錨點而言, 是使用真實標註來轉化生成的, 所以在測試的時候, 就得考慮如何處理了. 這裏使用的是利用生成的顯著性圖來進行生成anchors, 這是不準確的.

爲了匹配訓練和測試條件, 但是又不能改動測試的真值, 只能對訓練的流程進行改進. 在訓練期間, 當生成anchors時, 以概率p隨機翻轉每一個像素的標籤. 這種處理額外帶來的一個好處是, 一定程度上增加了訓練樣本的多樣性, 有一定的抗過擬合的作用.

下面是算法的流程

clipboard.png

訓練需要迭代, 迭代的過程, 就是不斷的隨機翻轉標籤, 計算像素和區域錨點的映射向量, 最大化對數似然, 更新參數. 注意上圖中真值使用的方法.

Iterative testing scheme

測試期間生成錨點是個需要注意的問題, 因爲真值認爲是未知的, 這裏就嘗試根據 現有方法生成的顯著性圖(先驗) 選擇的近似的顯著性/背景區域來生成錨點(要注意, 本文提出的實際上是一個後處理的方法, 目標是對於現有架構的進一步提升). 這裏使用了一個迭代的測試方案使用NN分類器, 來逐漸調整錨點,.

在這個迭代的過程中, 會使用到一個隨之不斷迭代的先驗顯著性圖(初始的先驗顯著性圖$Y^{(0)}_m$是由現有的方法生成的), 流程中使用的先驗顯著性圖, 是通過這個公式迭代計算的:

img

這裏的Y就是迭代中使用的先驗顯著性圖, 被用來選擇下一次迭代中的顯著性和背景區域. 而且隨着迭代不斷地開始, 新的結果所佔的比例越來越低, 這將確保迭代過程的穩定性.

img

img

上圖展示了提出的方法對於顯著性圖的不斷的優化提升的過程.

這個過程實際上就是先對像素映射向量, 然後開始迭代, 最開始的先驗使用的是現有方法生成的顯著性圖, 也就是$Y^{0}$, 利用先驗圖選擇前景背景, 也就是下圖中的位置, 進而生成近似的錨點(利用先驗圖作爲類似訓練時的真值, 與從網絡中提取出來的特徵層相乘(實際上是選擇了前景與背景區域之後)在送入區域嵌入結構生成錨點).

img

根據公式3, 對每個像素計算其顯著性值(也就是屬於顯著性區域的概率值), 來構建另一個新的顯著性圖, 利用迭代公式進行迭代計算(相當於是d位置與i位置顯著圖的合併). 之後按照上圖那樣送入結構中.

要注意, 這裏的迭代次數T是給定的.(這就有點不智能了)

儘管初始的顯著性圖沒能準確的區分出來前景和背景, 但是它通常能部分的區分它們, 因此可以提供關於圖像中顯著性目標的類別和外觀的信息.

例如,在圖3的第一張圖片中,儘管只有一小部分前景被突出顯示,但初始顯著性圖可以告訴我們前景可能是一隻大猩猩,而背景則包含一片綠色。(這應該算是合理推測)

然後,其選定的前景/背景區域應該與真實的前景/背景區域相似,從而導致相應的錨點與學習到的度量空間中的真實區域相關聯

因此,方程3給出的最近鄰分類可以產生良好的結果。隨着迭代的進展,近似錨點逐漸接近真實錨點,這將導致更好的結果。這反過來可以提供對錨點的越來越精確的近似,並且產生更準確的結果。

如圖3所示,初始顯著性圖並不吸引人,而迭代修改後的圖看起來要好得多。

對於數據較爲有限的SD任務, 選擇在嘗試調整在分類數據集預訓練的模型(這裏使用ImageNet上預訓練過的VGG16), 來擬合爲像素嵌入函數和區域嵌入函數, 以實現數據的映射. 由於不再是分類器, 去掉全連接, 只保留特徵提取組件, 包含五個卷積塊. 並且實際中也使用了BN和ReLU操作.

Pixel embedding

由於VGG特徵提取器本身會導致特徵圖不斷地縮小, 這並不是想要的結果, 因爲這裏提出的方法是要實現對於輸入圖像的每個像素來映射一個向量, 需要這個嵌入CNN產生一個具有與輸入圖像相同分辨率的特徵圖.

這裏採用了兩個策略來獲取更大的特徵圖.

  1. 移除了最後兩個卷積塊的池化層, 使用擴張卷積來維持卷積濾波器的感受野
  2. 添加亞像素卷積層到每個VGG特徵提取器的卷積塊後, 來上採樣每個卷積塊的特徵圖到輸入圖像大小.
要注意, 這裏實際上最後剩下來的只有兩個最大池化, 可見代碼:
self.proc_feats_list = nn.ModuleList([
    # convtranspose2d=>out_size=(in_size-1)xstride-2xpadding+kernel_size
    nn.Sequential(
        # x4 512卷積塊對應的輸出
        nn.ConvTranspose2d(dims[0], dims[0], 8, 4, 2),
        nn.Conv2d(dims[0], odims[0], kernel_size=3, padding=1)),
    nn.Sequential(
        # x4 512對應的輸出
        nn.ConvTranspose2d(dims[1], dims[1], 8, 4, 2),
        nn.Conv2d(dims[1], odims[1], kernel_size=3, padding=1)),
    nn.Sequential(
        # x4 256對應的輸出
        nn.ConvTranspose2d(dims[2], dims[2], 8, 4, 2),
        nn.Conv2d(dims[2], odims[2], kernel_size=3, padding=1)),
    nn.Sequential(
        # x2 128對應的輸出
        nn.ConvTranspose2d(dims[3], dims[3], 4, 2, 1),
        nn.Conv2d(dims[3], odims[3], kernel_size=3, padding=1)),

    # 使用亞像素卷積實現上採樣 #############################################
    # 不清楚這裏爲什麼放棄了使用亞像素卷積的手段
    # 這裏的nn.PixelShuffle(up_scale)便是可以用來實現亞像素卷積的一個類
    # nn.Sequential(
    #     nn.Conv2d(dims[0], odims[0], kernel_size=3, padding=1),
    #     nn.PixelShuffle(4)),
    # nn.Sequential(
    #     nn.Conv2d(dims[1], odims[1], kernel_size=3, padding=1),
    #     nn.PixelShuffle(4)),
    # nn.Sequential(
    #     nn.Conv2d(dims[2], odims[2], kernel_size=3, padding=1),
    #     nn.PixelShuffle(4)),
    # nn.Sequential(
    #     nn.Conv2d(dims[3], odims[3], kernel_size=3, padding=1),
    #     nn.PixelShuffle(2)),

    # x1 64 對應的輸出
    nn.Conv2d(dims[4], dims[4], kernel_size=3, padding=1),
])
Subpixel convolution is an upsampling strategy originally proposed in [Real-time single im-age and video super-resolution using an efficient sub-pixelconvolutional neural network] for image super-resolution.

這裏也提示了一點, 對於深度學習實現的顯著性檢測手段, 裏面會涉及到分辨率的恢復操作, 也就是所謂的上採樣, 由於網絡的深層事實上需要更大的感受野, 所以說, 對於往常的池化層不能輕易去除, 而要找到合適的替代, 這裏提供了幾個思路, 一個是使用擴張卷積替代池化操作, 一個是使用超分辨率重建(本質都是低分辨率重建爲高分辨率)的思想.

爲了生成C通道的N倍輸入大小的tensor, 亞像素卷積首先通過一般的卷積得到一個 $N^2 \times C$ 通道的與原輸入一致大小的tensor. 然後這個tensor被重新調整爲C通道的N倍於輸入大小的tensor.


本小節補充內容:

超分辨率技術(Super-Resolution)是指從觀測到的低分辨率圖像重建出相應的高分辨率圖像,在監控設備、衛星圖像和醫學影像等領域都有重要的應用價值。SR可分爲兩類:從多張低分辨率圖像重建出高分辨率圖像和從單張低分辨率圖像重建出高分辨率圖像。基於深度學習的SR,主要是基於單張低分辨率的重建方法,即Single Image Super-Resolution (SISR)。

如果做SR(超分辨率)的話,需要將一張低分辨率圖像轉換成一張高分辨率圖像。如果直接用deconvolution作爲upscale手段的話,通常會帶入過多人工因素進來(有不少論文提到這個)。而sub-pixel conv會大大降低這個風險。Subpixel convolution是一種巧妙的圖像及特徵圖upscale的方法,又叫做pixel shuffle(像素洗牌), 亞像素卷積操作就是通過生成更多的特徵層, 然後利用它們數據的週期性組合, 來實現分辨率的提升.

clipboard.png

上圖很直觀得表達了sub-pixel convolution的做法,前面就是一個普通的CNN網絡,到後面彩色部分就是sub-pixel conv的操作了。首先,如果我想對原圖放大3倍,那麼我需要生成出3^2=9個same size的特徵圖。將九個same size的特徵圖拼成一個X3的大圖,這就是sub-pixel convolution的操作了。這是一種抽樣的反思想,如果把一張x3的大圖,每隔三個點抽樣一個,那就會得到9張低分辨率的圖像。於是,如果我們可以通過CNN來獲得9張符合分佈的低分辨率圖像,那麼就可以組成一張高分辨率的大圖。

img

通過在五個卷積塊後添加一個亞像素卷積層, 這裏會獲取5個C通道的特徵圖, 5個特徵圖級聯, 想成一個5C通道的特徵圖. 但是直接使用和這個級聯的特徵圖不是最好的選擇, 因爲不同的卷積塊之間有着不同的感受野(區域不同), 爲了解決這個問題, 額外添加了兩個卷積層來轉化這個級聯特徵圖爲一個D通道的特徵圖(特徵融合), 其中的每個D維向量就被認爲是每個像素所對應的的D維表示.

文中的實現裏, 設定C爲64, D爲512.

Region embedding

img

爲了簡單, 對於兩個嵌入操作(像素和區域), 共享相同的特徵提取器和亞像素上採樣層.

新的層被添加在亞像素卷積層後, 來匹配圖片區域的5C通道特徵圖到一個D維向量.

這裏考慮了兩種結構:

  1. 基於卷積的區域嵌入結構: 5C-channel->Convs->D-channel->channel-wise-average->D-vector
  2. 基於全連接的區域嵌入結構 5C-channel->channel-wise-average->5C-vevtor->FC->D-vector

Experiments

評價標準

  • PR曲線
  • F測度曲線
  • F測度得分
  • MAE得分

The precision of a binary map is defined as the ratio of the number of salient pixels it correctly labels, to all salient pixels in this binary map. 預測的二值圖像中的預測的顯著性目標區域標註正確的比例. 就是預測爲真值(預測爲顯著性區域)中的實際真值(實際的顯著性區域)的比例.

The recall value is the ratio ofthe number of correctly labeled salient pixels to all salient pixels in the ground-truth map. 實際真值中被正確標出的比例.

img

in which TS denotes true salient pixels, DS denotes detected salient pixels by the binary map, and $|·|$ denotes cardinality of a set.

F測度使用下式計算.

img

曲線的計算按照動態閾值來計算.

Given a saliency map whose intensities are in the rangeof 0 and 1, a series of binary maps can be produced by thresholding the saliency map with different values in [0,1].

Precision and recall values of these binary maps can becomputed according to Eqn. 6. F-measure can be computed according to Eqn. 7.

Plotting the (precision, recall) pairs of all the binary maps results in the precision-recall curve, and plotting the (F-measure, threshold) pairs results in theF-measure curve.

Also as suggested in [1], we use twice the mean valueof the saliency maps as the threshold to generate binary maps for computing the F-measure.

Notice that some works have reported slightly different F-measures using different thresholds. But as far as we know, twice the mean value isthe most commonly used threshold.

As complementary to PR curves, mean absolute error(MAE) is used to quantitatively measure the average difference between the saliency map S and the ground truth map G.

img

MAE indicates how similar a saliency map is compared to the ground truth. It is widely used in different pixel-level prediction tasks such as semantic segmentation and image cropping [22].

Implementation details

  • We train our model on the training set of DUTS dataset.
  • As in [20], we augment the training data by horizontal flipping and cropping the images to reduce overfitting.
  • The probability $p$ of randomly flipping ground truth when producing anchors during training is set to 0.05.
  • We comparetwo type of region embedding in Sec.4.4, and adopt theConv-based one in other experiments.
  • Adam [14] optimization method is used for training our model.
  • Learning rateis set to 1e-3.
  • We do not use a validation set, and train our model until its training loss converges.
  • The training process takes almost 16 hours and converges after around 300 kiterations with mini-batch of size 1.

img

From this comparison we can see that the performance of FC-based and Conv-based region embedding is comparable.

  • The FC-based region embedding yields relatively larger F-measure
  • Conv-based region embedding is more superior in terms of MAE

img

We show the effect of the proposed iterative approximation scheme in Figure 5. As shown in Figure 5, the first iteration improve the F-measure and decrease MAE most significantly. The improvement slows down with iterations, and saturates(飽和) gradually.

Performance

We apply our method to promote the performance of each baseline method, by using its predicted saliency maps to generate initial anchors in Eqn.3.

img

img

img

  • Figure 6 shows the PR curves of the baseline methods and the one promoted by our method.
  • Table 2 shows the F-measure and MAE scores of 8 deep learning based methods and the corresponding promoted results.
  • The quantified improvements in F-measure and MAE of applying our method to conventional methods are shown in Table 3.
  • As shown in Figure 6, Table 2, and Table 3, our method drastically(大幅) promotes all the baseline methods.

img

img

觀察數據可知

  • 論文提出的方法, 對於已有的深度方法和傳統的方法都有提升.
  • Notice that the results shown here are obtained by iterating Alg. 2 only once for fast testing speed.
  • As shown in Sec.4.4, better results can be achieved through iterating Alg. 2 more times.

Figure 7 shows a visual comparison of saliency maps produced by some state-of-the-art methods and the promoted ones by our method.

img

It can be seen that the saliency maps produced by our methods highlight salient regions that are missed by the baselines.

Further, our method can suppress the background regions that are wrongly labeled as salient by the baseline methods(我們的方法可以抑制基線方法錯誤標記爲顯着的背景區域。).

總結

In this paper, we propose a novel learning method to promote existing salient object detection methods. Extensive experiments on five benchmark datasets show that our method can significantly improve accuracy of existing methods and compares favorably against state-of-the-arts(我們的方法可以顯着提高現有方法的準確性,並且與現有最優技術相比具有優勢).

參考鏈接

發表評論
所有評論
還沒有人評論,想成為第一個評論的人麼? 請在上方評論欄輸入並且點擊發布.
相關文章