We propose a generic feature compression method for Approximate Nearest Neighbor Search (ANNS) problems, which speeds up existing ANNS methods in a plug-and-play manner. Specifically, we propose a new network structure called Compression Network with Transformer (CNT) to compress the feature into a low dimensional space, and an inhomogeneous neighborhood relationship preserving (INRP) loss that aims to maintain high search accuracy. In CNT, we use multiple compression projections to cast the feature into many low dimensional spaces, and then use transformer to globally optimize these projections such that the features are well compressed following the guidance from our loss function. The loss function is designed to assign high weights on point pairs that are close in original feature space, and keep their distances in projected space. Keeping these distances helps maintain the eventual top-k retrieval accuracy, and down weighting others creates room for feature compression. Experimental results show that our CNT can significantly improve the efficiency of popular ANNS methods while preserves or even improves search accuracy, suggesting its broad potential impact on real world applications.
翻译:我们为近距离近邻搜索(ANNS)问题提出了一个通用特征压缩方法,该方法以插接和游戏方式加快了现有的 ANNS 方法。 具体地说,我们提出了一个新的网络结构,名为“ 压缩网络 ”, 用变异器将特性压缩到一个低维空间, 以及一个不相容的邻里关系保护( INRP) 损失, 目的是保持高搜索精确度。 在 CNT 中, 我们使用多重压缩预测将特性投射到许多低维空间, 然后使用变异器在全球优化这些预测, 使这些特性根据我们损失功能的指令被大大压缩。 损失功能旨在给原始功能空间接近的点对配配方分配高重量, 并将它们保持在预测空间的距离。 保持这些距离有助于维持最终的顶端检索精度, 而下限则为其它部分为特性压缩创造了空间。 实验结果表明, 我们的CNT可以大幅提高流行的ANNS 方法的效率, 同时保存甚至提高搜索精度, 表明其对真实世界应用的潜在影响。