Central Similarity Quantization for Efficient Image and Video Retrieval

Li Yuan, Tao Wang, Xiaopeng Zhang, Francis E. H. Tay, Zequn Jie, Wei Liu, Jiashi Feng · DOI

Introduction

Central Similarity Quantization (CSQ) represents a paradigm shift in deep learning-to-hash methods. By moving beyond traditional "local" perspectives—which rely on comparing pairs or triplets of data—CSQ introduces a global "hash center" for each category. This approach encourages similar items to collapse toward a shared center in Hamming space, resulting in a 3–20% improvement in retrieval accuracy (mAP) and training speeds up to 5.5x faster than previous state-of-the-art techniques.

The Challenge of Local Similarity

Image and video retrieval systems frequently utilize hashing to transform high-dimensional data into compact binary codes. Conventional deep hashing methods typically employ pairwise or triplet losses to ensure that similar images have close hash codes while dissimilar ones are distant. However, this local approach suffers from three primary drawbacks:

  1. Computational Inefficiency: Comparing every possible pair or triplet scales poorly ($O(n^2)$ or $O(n^3)$).
  2. Limited Global Context: Local comparisons fail to capture the broader data distribution.
  3. Data Imbalance: The overwhelming number of dissimilar pairs in real-world datasets makes it difficult for models to learn effective similarity relationships.

Central Similarity Quantization (CSQ)

The proposed CSQ method shifts the focus to a global metric. Instead of comparing points to each other, hash codes are trained to approach a pre-defined hash center that represents their specific class.

Conceptual comparison of local similarity (Doublet, Triplet) vs. Central Similarity.

Hash Center Generation

Hash centers are sets of points in Hamming space designed with large mutual distances. The authors utilize two primary generation strategies:

  • Hadamard Matrices: Mutually orthogonal vectors ensure a Hamming distance of exactly $K/2$ (where $K$ is the bit length) between any two centers.
  • Bernoulli Distributions: Randomly sampling bits ($P=0.5$) statistically ensures well-separated centers.

Optimization Objectives

The model is optimized using two core loss functions:

  • Central Similarity Loss ($L_C$): Minimizes the Hamming distance between a generated hash code and its assigned class center using Binary Cross Entropy.
  • Quantization Loss ($L_Q$): Employs a smooth log cosh function to push continuous neural network outputs toward binary extremes (0 or 1) while maintaining differentiability.

Experimental Results and Insights

CSQ was evaluated across major image (ImageNet, MS COCO, NUS-WIDE) and video (UCF101, HMDB51) retrieval benchmarks.

t-SNE visualizations of hash codes generated by different methods on ImageNet, showing the superior clustering of Central Similarity.

Key Findings

  • Superior Accuracy: CSQ significantly outperformed baselines like HashNet and DCH. On ImageNet (16 bits), it achieved an mAP of 0.851, a substantial leap from DCH’s 0.652.
  • Enhanced Training Efficiency: By reducing complexity from $O(n^2)$ to $O(nm)$ (where $m$ is the number of centers), CSQ trains 3 to 5.5 times faster than previous methods.
  • The "Collapse" Effect: Unlike pairwise methods that merely push points apart, CSQ pulls similar points toward a central "star." This creates highly cohesive clusters, as evidenced by t-SNE visualizations.
  • Robustness to Imbalance: CSQ's most significant gains occurred on ImageNet, which features a severe 100:1 ratio of dissimilar to similar pairs, proving the stability of global learning signals.

Conclusion and Future Directions

CSQ demonstrates that global centers provide a more effective and efficient learning signal for hashing than local comparisons. While highly successful, the authors note that future iterations could incorporate semantic hierarchies into center generation—ensuring, for example, that the center for "Husky" is closer to "Labrador" than to "Toaster." Additionally, exploring adaptive centers that reflect the natural data manifold while maintaining distance constraints remains a promising area for future research.

Summary updated

BibTeX
@inproceedings{yuan2020central,
  author = {Li Yuan and Tao Wang and Xiaopeng Zhang and Francis E. H. Tay and Zequn Jie and Wei Liu and Jiashi Feng},
  title = {{Central Similarity Quantization for Efficient Image and Video Retrieval}},
  booktitle = {IEEE/CVF Conference on Computer Vision and Pattern Recognition},
  year = {2020},
  doi = {10.1109/cvpr42600.2020.00315},
}
Figure