arXivDaily arXiv每日学术速递 周一至周五更新
arXiv 2002.06504cs.LGstat.ML
收藏

具有最优迁移的可微Top-k算子

Differentiable Top-k Operator with Optimal Transport

Georgia Institute of Technology(佐治亚理工学院);Google Inc.(谷歌公司)

Yujia Xie, Hanjun Dai, Minshuo Chen, Bo Dai, Tuo Zhao, Hongyuan Zha, Wei Wei, Tomas Pfister

摘要:

top-k操作,即,从分数集合中找到k个最大或最小元素是一个重要的模型组件,其广泛用于信息检索、机器学习和数据采掘。然而,如果top-k操作以算法方式实现,例如,使用气泡算法,不能使用流行的梯度下降算法以端到端的方式训练所得到的模型。这是因为这些实现通常涉及交换索引,其梯度无法计算。此外,从输入分数到该元素是否属于前k集合的指示符向量的对应映射本质上是不连续的。为了解决这个问题,我们提出了一个平滑的近似,即SOFT(可扩展的最佳运输为基础的diFferentiable)top-k运营商。具体来说,我们的SOFT top-k算子近似的top-k操作的输出作为熵最优运输(EOT)问题的解决方案。基于EOT问题的最优性条件,可以有效地近似SOFT算子的梯度。我们提出的运营商的k-近邻和束搜索算法,并证明了改进的性能。

英文摘要:

The top-k operation, i.e., finding the k largest or smallest elements from a collection of scores, is an important model component, which is widely used in information retrieval, machine learning, and data mining. However, if the top-k operation is implemented in an algorithmic way, e.g., using bubble algorithm, the resulting model cannot be trained in an end-to-end way using prevalent gradient descent algorithms. This is because these implementations typically involve swapping indices, whose gradient cannot be computed. Moreover, the corresponding mapping from the input scores to the indicator vector of whether this element belongs to the top-k set is essentially discontinuous. To address the issue, we propose a smoothed approximation, namely the SOFT (Scalable Optimal transport-based diFferenTiable) top-k operator. Specifically, our SOFT top-k operator approximates the output of the top-k operation as the solution of an Entropic Optimal Transport (EOT) problem. The gradient of the SOFT operator can then be efficiently approximated based on the optimality conditions of EOT problem. We apply the proposed operator to the k-nearest neighbors and beam search algorithms, and demonstrate improved performance.

机构、总结、中文摘要均由AI分析而来,可能存在错误,请以论文正文为准。

↑