Single-loss hash image retrieval method based on improved visual transformer
Abstract
Deep hashing methods have gained popularity in image retrieval due to their advantages such as low storage requirements and high efficiency. However, existing deep hashing methods for large-scale image retrieval tasks suffer from issues including low discriminative power of binary hash codes, difficult optimization of losses, and low retrieval accuracy. This paper proposes a single-loss hash image retrieval method based on an improved visual transformer to address these issues. The proposed method utilizes a pre-trained Vision Transformer (ViT) on ImageNet as the backbone network, augmented with a hash coding layer to extract image features more comprehensively. Additionally, we design a single learning objective loss function that addresses the discriminative power of hash codes and quantization errors, thereby eliminating the complexity of adjusting various loss weights. Experimental evaluations on ImageNet100, NUS-WIDE, CIFAR10, and MS-COCO datasets demonstrate the superior performance of the proposed method compared to contemporary methods, indicating its adaptability to diverse data.
References
- Bengio Y, Nicholas Léonard, Courville A C. Estimating or Propagating Gradients Through Stochastic Neurons for Conditional Computation: arXiv 2013.
- Hanjiang Lai, Yan Pan, Ye Liu, and Shuicheng Yan. Simultaneous feature learning and hash coding withdeep neural networks. In Proceedings of the IEEE conference on computer vision and pattern recognition,pages 3270–3278, 2015.
- Yair Weiss, Antonio Torralba, and Rob Fergus. Spectral hashing. In D. Koller, D. Schuurmans, Y. Bengio,and L. Bottou, editors, Advances in Neural Information Processing Systems, volume 21. Curran Associates,Inc., 2009.
- Yunchao Gong, Svetlana Lazebnik, Albert Gordo, and Florent Perronnin. Iterative quantization: A procrustean approach to learning binary codes for large-scale image retrieval. IEEE transactions on pattern analysis and machine intelligence, 35(12):2916–2929, 2012.
- Piotr Indyk and Rajeev Motwani. Approximate nearest neighbors: Towards removing the curse of dimensionality. In Proceedings of the Thirtieth Annual ACM Symposium on Theory of Computing, STOC ’98, page 604–613, New Y ork, NY, USA, 1998. Association for Computing Machinery.
- Brian Kulis and Kristen Grauman. Kernelized locality-sensitive hashing for scalable image search. In 2009 IEEE 12th international conference on computer vision, pages 2130–2137. IEEE, 2009.
- BL Lu, L Zhang, J Kwok. Proceedings of the 18th international conference on Neural Information Processing - Volume Part II[C]// International Conference on Neural Information Processing. Springer-Verlag, 2011.
- Cao Z, Long M , Wang J , et al. HashNet: Deep Learning to Hash by Continuation[J]. IEEE Computer Society, 2017.
- Su S, Tian Y . Greedy Hash: Towards Fast Optimization for Accurate Hash Coding in CNN[C]// Neural Information Processing Systems. 2018.
- Zheng X, Zhang Y, Lu X. Deep Balanced Discrete Hashing for Image Retrieval[J]. Neurocomputing, 2020, 403(3).
- Dubey S R, Singh S K, Chu W T. Vision Transformer Hashing for Image Retrieval[J]. arXiv e-prints, 2021.
- Dosovitskiy A, Beyer L, Kolesnikov A, et al. An Image is Worth 16x16 Words: Transformers for Image Recognition at Scale[C]// International Conference on Learning Representations. 2021.
- Chen X, Yan B, Zhu J, et al. High-Performance Transformer Tracking[J]. 2022.
- Zhang T, Zhu L, Zhao Q, et al. Neural Networks Weights Quantization: Target None-retraining Ternary (TNT)[J]. 2019.
- Kulis B, Darrell T. Learning to Hash with Binary Reconstructive Embeddings[C]// International Conference on Neural Information Processing Systems. Curran Associates Inc. 2009.