arXivDaily arXiv每日学术速递 周一至周五更新
arXiv 2308.15136cs.DScs.CVcs.DBcs.DCcs.IR
收藏

CAGRA:面向GPU的高并行图构建与近似最近邻搜索

CAGRA: Highly Parallel Graph Construction and Approximate Nearest Neighbor Search for GPUs

NVIDIA(英伟达)

Hiroyuki Ootomo, Akira Naruse, Corey Nolet, Ray Wang, Tamas Feher, Yong Wang

AI总结:

针对现有近似最近邻搜索算法对GPU等并行硬件利用不足的问题,提出CAGRA并行近邻图构建与搜索算法,在图构建速度、大小批量查询吞吐量上均显著优于现有CPU及GPU最优方法,同时保持精度相当。

摘要:

近似最近邻搜索(ANNS)在数据挖掘、人工智能的众多领域中发挥着关键作用,涵盖信息检索、计算机视觉、自然语言处理以及推荐系统等方向。近年来数据量激增,穷尽式精确最近邻搜索的计算成本往往高得令人难以承受,因此亟需采用近似技术。基于图的方法凭借均衡的性能与召回率,近期在ANNS算法领域受到了广泛关注;然而,尽管大规模并行通用计算已得到普及,但仅有少数研究探索了如何利用GPU与多核处理器的算力。为填补这一空白,我们提出了一种基于并行计算硬件的新型近邻图与搜索算法。借助现代硬件的高性能特性,我们的方法实现了显著的效率提升。具体而言,该方法在近邻图构建方面优于现有的CPU与GPU基方法,在大小批量搜索中均展现出更高的吞吐量,同时保持了相当的精度。在图构建耗时上,我们的方法CAGRA比CPU端最优实现之一的HNSW快2.2~27倍。在召回率90%至95%区间的大批量查询吞吐量方面,我们的方法比HNSW快33~77倍,比GPU端的最优实现快3.8~8.8倍。针对单查询场景,在95%召回率下我们的方法比HNSW快3.4~53倍。

英文摘要:

Approximate Nearest Neighbor Search (ANNS) plays a critical role in various disciplines spanning data mining and artificial intelligence, from information retrieval and computer vision to natural language processing and recommender systems. Data volumes have soared in recent years and the computational cost of an exhaustive exact nearest neighbor search is often prohibitive, necessitating the adoption of approximate techniques. The balanced performance and recall of graph-based approaches have more recently garnered significant attention in ANNS algorithms, however, only a few studies have explored harnessing the power of GPUs and multi-core processors despite the widespread use of massively parallel and general-purpose computing. To bridge this gap, we introduce a novel parallel computing hardware-based proximity graph and search algorithm. By leveraging the high-performance capabilities of modern hardware, our approach achieves remarkable efficiency gains. In particular, our method surpasses existing CPU and GPU-based methods in constructing the proximity graph, demonstrating higher throughput in both large- and small-batch searches while maintaining compatible accuracy. In graph construction time, our method, CAGRA, is 2.2~27x faster than HNSW, which is one of the CPU SOTA implementations. In large-batch query throughput in the 90% to 95% recall range, our method is 33~77x faster than HNSW, and is 3.8~8.8x faster than the SOTA implementations for GPU. For a single query, our method is 3.4~53x faster than HNSW at 95% recall.

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

↑