GPU加速的SIFT在视觉任务中比深度学习特征更准更快,还能保证结果一致。
PySIFT: GPU-Resident Deterministic SIFT for Deep Learning Vision Pipelines

- 用CUDA实现全GPU运行的SIFT,支持快速可复现的特征提取
- 在多个数据集上优于深度学习特征,且速度提升2-18倍
- 适合需要确定性输出和高精度匹配的科研与工程场景
局部特征研究普遍认为传统手工描述子已过时,应被学习型替代。我们通过覆盖四个基准(HPatches、ROxford5K、IMC Phototourism、MegaDepth)的8种配置消融实验表明:带有DSP多尺度池化的经典SIFT,在所有精度指标上均优于HardNet、OriNet等学习型描述子和方向估计器,同时运行速度提升2–18倍;而学习型匹配器(LightGlue)更适合作为补充而非替代。这一发现揭示了过去十年的误区:不应“替换SIFT”,而应“组合使用SIFT”——仅在几何上下文复杂时搭配学习型匹配。此前研究无法发现此结论,因缺乏全程驻留GPU显存且支持可控对比的工具。本文提出PySIFT,首个完全基于GPU的SIFT实现,采用CuPy/Numba CUDA内核与DLPack零拷贝接口,实现亚毫秒级的O(1)元数据切换,不依赖关键点数量。在配备4GB显存的RTX 3050笔记本上,PySIFT在HPatches上比OpenCV SIFT取得更高平均匹配准确率,每对图像处理速度比MegaDepth快383毫秒,跨数据集测试中几何精度显著提升(MegaDepth上AUC@10°提高5.6个百分点),且在多轮运行及不同GPU架构间保持比特级确定性输出,这是学习型提取器无法实现的。
原文摘要 · Abstract (English)
A widespread assumption in local feature research holds that classical handcrafted descriptors are accuracy-limited relics best replaced by learned alternatives. We show this is wrong. Through an 8-configuration ablation spanning four benchmarks (HPatches, ROxford5K, IMC Phototourism, MegaDepth), we demonstrate that classical SIFT with DSP multi-scale pooling outperforms neural descriptor and orientation replacements (HardNet, OriNet) on every accuracy metric--while running 2--18$\times$ faster--and that learned matchers (LightGlue) complement rather than supersede classical features. The conclusion reframes a decade of work: not "replace SIFT" but "compose with SIFT," classical extraction paired with learned matching only where geometric context demands it. This finding was invisible because no prior GPU SIFT kept the complete pipeline in VRAM or offered modularity for controlled classical-vs-learned ablations. We present PySIFT, the first fully GPU-resident SIFT, implemented in CuPy/Numba CUDA kernels with DLPack zero-copy handoff to downstream DL frameworks--submillisecond O(1) metadata swap regardless of keypoint count. On a laptop-grade NVIDIA RTX 3050 (4 GB VRAM), PySIFT achieves: (i) higher Mean Matching Accuracy (MMA) than OpenCV SIFT on HPatches, (ii) 383 ms faster per pair on high-resolution MegaDepth, (iii) higher geometric accuracy on cross-dataset benchmarks (+5.6 pp AUC@10${}^\circ$ on MegaDepth, more inliers on IMC Phototourism), and (iv) bitwise deterministic output--identical keypoints and descriptors across runs, with detection reproducing identically even across GPU architectures: a guarantee that learned extractors cannot match without significant performance sacrifice, and cannot achieve at all across GPU architectures due to cuDNN's architecture-dependent algorithm selection. PySIFT is open-source, requiring no C++ compilation.
Thank you to arXiv for use of its open access interoperability. PaperDance 不是 arXiv 官方产品;中文卡片由大模型生成,请以原文为准。