Skip to main content
QUICK REVIEW

[Paper Review] High-Dimensional Approximate Nearest Neighbor Search: with Reliable and Efficient Distance Comparison Operations

Jianyang Gao, Cheng Long|arXiv (Cornell University)|Mar 17, 2023
Advanced Image and Video Retrieval TechniquesComputer Science6 citations
TL;DR

This paper proposes ADSampling, a randomized algorithm that accelerates distance comparison operations (DCOs) in high-dimensional approximate K-nearest neighbor (AKNN) search by sampling dimensions logarithmically instead of scanning all dimensions. It achieves near-zero accuracy loss while reducing DCO time from O(D) to O(log D) in most cases, significantly boosting efficiency across multiple AKNN algorithms with theoretical guarantees and empirical validation.

ABSTRACT

Approximate K nearest neighbor (AKNN) search is a fundamental and challenging problem. We observe that in high-dimensional space, the time consumption of nearly all AKNN algorithms is dominated by that of the distance comparison operations (DCOs). For each operation, it scans full dimensions of an object and thus, runs in linear time wrt the dimensionality. To speed it up, we propose a randomized algorithm named ADSampling which runs in logarithmic time wrt to the dimensionality for the majority of DCOs and succeeds with high probability. In addition, based on ADSampling we develop one general and two algorithm-specific techniques as plugins to enhance existing AKNN algorithms. Both theoretical and empirical studies confirm that: (1) our techniques introduce nearly no accuracy loss and (2) they consistently improve the efficiency.

Motivation & Objective

  • To address the performance bottleneck in AKNN search caused by expensive distance comparison operations (DCOs) in high-dimensional spaces.
  • To reduce the time complexity of DCOs from O(D) to O(log D) for the majority of operations while maintaining high accuracy.
  • To develop generic and algorithm-specific techniques based on ADSampling that enhance existing AKNN algorithms without compromising accuracy.
  • To provide theoretical guarantees and empirical validation for the efficiency and reliability of the proposed DCO acceleration method.

Proposed method

  • ADSampling uses random projection and sequential hypothesis testing to estimate distances via sampled dimensions, avoiding full-dimensional computation.
  • It applies concentration inequalities to bound approximation error, ensuring high-probability correctness with minimal sampling.
  • The method distinguishes between positive and negative objects by stopping early if a sample indicates the distance exceeds the threshold.
  • A generic plugin technique integrates ADSampling into any AKNN algorithm by replacing standard DCOs with the accelerated version.
  • Two algorithm-specific techniques are designed: one for graph-based methods (e.g., HNSW) and another for vector quantization (e.g., IVF), optimizing for their unique candidate generation patterns.
  • The approach supports extension to cosine similarity and inner product comparisons via vector normalization and transformation.

Experimental results

Research questions

  • RQ1Can distance comparison operations in high-dimensional AKNN search be accelerated without significant accuracy loss?
  • RQ2Can a sampling-based method achieve O(log D) time complexity for DCOs while maintaining high success probability?
  • RQ3How can ADSampling be integrated as a generic plugin to enhance diverse AKNN algorithms?
  • RQ4What is the theoretical and empirical impact of using ADSampling on the overall efficiency of AKNN search?
  • RQ5Can the proposed method be extended to other similarity metrics such as cosine similarity and inner product?

Key findings

  • ADSampling reduces the time complexity of DCOs from O(D) to O(log D) for the majority of operations, achieving logarithmic performance in practice.
  • On the DEEP dataset (256 dimensions), DCOs accounted for 77.2% of total runtime in HNSW, which was significantly reduced using ADSampling.
  • The proposed techniques introduce negligible accuracy loss, with no measurable drop in KNN quality across all evaluated datasets and algorithms.
  • Empirical results show consistent speedups across multiple AKNN algorithms, including HNSW, IVF, and graph-based methods.
  • Theoretical analysis confirms that ADSampling succeeds with high probability and maintains bounded error under no data assumptions.
  • The method is extendable to cosine similarity and inner product comparisons via simple vector transformations, broadening its applicability.

Read this paper

Open the full text in the Nubint reader and ask about any passage as you read.

Read this paper on Nubint

This review was generated by AI from the original paper. Please check the paper before citing it.