1: Faster-rcnn代碼
2:把實驗數據跑完
-
if name == 'main' 如何正確理解?
http://blog.konghy.cn/2017/04/24/python-entry-program/
1.運行read_data.py 分別修改param為oxford和paris
create the lists of query and database images
data_reader.png
-
在/data/imagelists中分別保存文件
- oxford
Saving text file: data/imagelists/oxford.txt
Saving text file: data/imagelists/query_oxford.txt
- paris
Saving text file: data/imagelists/paris.txt
Saving text file: data/imagelists/query_paris.txt
Filtering Stag. The Image-wise pooling (IPA) strategy is used to build image descriptors for both query and database images. At test time, the descriptor of the query image is compared to all the elements in the database, which are then ranked based on the cosine similarity. At this stage, the whole image is considered as the query.
- 先提取所有圖片的特征以及數據庫里面的特征,再把圖片特征與數據庫中的特征進行對比,用cosine大小來進行比較,形成第一步的query。
- 這一步使用的是圖像的特征(IPA)與圖像的區域特征(RPA)無關。
- 提取特征features.py,第一步比較ranking.py
2.運行features.py
extract Fast R-CNN features for all images in a dataset and store them to disk
先提取paris的參數,fast-rcnn里面的輸入圖片的參數設置為500.
結束時候的截圖:
一開始的截圖:
開始提取Oxford的特征:
生成的特征保存在data/features里面:
3.運行ranker.py
generate and store the rankings for the queries of the chosen dataset
先排Oxford的:
排Paris的:
結果保存在data/ranking里面:
Spatial Reranking. After the Filtering Stage, the top N elements are locally analyzed and reranked.
再次排列:
4.運行rerank.py文件
Rerank based on region features
先rerank Oxford數據集
image.png
再rerank Paris數據集
image.png
生成文件存在data/reranking里面
Query Expasion (QE). The image descriptors of the top
M elements of the ranking are averaged together with the
query descriptor to perform a new search。
ranking 里面的top5平均后進行一個新的search