In this paper, we propose a k-reciprocal encoding method to re-rank the re-ID results. Our hypothesis is that if a gallery image is similar to the probe in the k-reciprocal nearest neighbors, it is more likely to be a true match.Specifically, given an image, a k-reciprocal feature is calculated by encoding its k-reciprocal nearest neighbors into a single vector, which is used for re-ranking under the Jaccard distance. The final distance is computed as the combination of the original distance and the Jaccard distance.算法
这篇论文提出了k-reciprocal 编码方法去重排re-ID结果。论文假定底库图片和查询图片在 k-reciprocal近邻是类似的,则它们最有多是匹配的。论文主要利用原始距离和杰卡德距离完成re-ranking。app
上图是使用KNN(k=10)聚类的结果,其中Probe为查询图片,P1~P4为正样本,N1~N6为负样本。P1~P4在类似排名上并不靠前,而N1~N6却比较靠前,这说明使用KNN算法获得初始排序结果具备很大噪声。ide
上图是使用KRNN(k-reciprocal nearest neighbor)算法的重排结果。首先咱们须要求出一张图片的表征特征(appearance feature)和k-r特征(k-reciprocal feature)而后分别计算原始距离和杰卡德距离,最后计算最终距离,得出re-ranking列表。性能
这篇文章的主要工做:测试
Mahalanobis distance:
this
M为半正定矩阵 ,\(d(p,{g_i})\) 为文中提到的原始距离。编码
KNN:
KNN算法简介:给定测试实例,基于某种距离度量找出训练集中与其最靠近的k个实例点,而后基于这k个最近邻的信息来进行预测。spa
KRNN:
rest
∧为合取联结词,叫作合取,好比r=q∧p,那么当且仅当p与q同时为真(或者说同时为1)时r为真(或1),也就是说\({g_i}\)是p的近邻,p也是\({g_i}\)的近邻。排序
有时候正样本不在K近邻中,也不在k-r近邻中。为了解决这个问题,本文增长了\(\frac{1}{2}\)k-r近邻,来得到更为鲁棒性的\({R^*}(p,k)\)。
\(\left| \right|\)表明这个数据集的数量。若是\({g_i}\)和p是类似的,则\({R^*}(p,k)\)和\({R^*}(g_i,k)\)重合部分较多,则杰卡德距离\({d_J}(p,{g_i})\)就越小。
这步操做有3个缺点:
由于同一类别的图片具备类似的特征,咱们使用KNN方法完成本地查询操做。
假设底库图片集大小为N,通常状况下距离测量和从新排序的时间复杂度分别为\(O({N^2})\),\(O({N^2}\log N)\)。可是,咱们提早在本地上计算距离和进行排序,故时间复杂度分别为\(O({N})\),\(O({N}\log N)\)。