Improving Zero-Shot Image Captioning Efficiency with Metropolis-Hastings
摘要
Image captioning, a crucial aspect of natural language processing, aims to convert visual content into textual representations through technological advancements. Zero-shot learning, a technique that has gained widespread attention in recent research, performs tasks without relying on domain-specific training datasets. However, current zero-shot image captioning methods mainly depend on non-autoregressive language models, which often suffer from operational inefficiencies, resulting in prolonged captioning times and limiting their practical applications. To address this limitation, this study introduces an efficient zero-shot image captioning method, MHIC, leveraging the Metropolis-Hastings sampling algorithm. MHIC significantly improves computational speed while maintaining caption quality. Specifically, we optimize the caption generation process using the Metropolis-Hastings algorithm, effectively reducing the number of iterations required for word generation while preserving caption quality by minimizing the number of generated words. This approach markedly enhances the speed of image captioning. To validate the effectiveness of MHIC, we conducted rigorous experiments on two publicly available datasets. The results demonstrate that our proposed algorithm achieves an average speedup of 2 times compared to state-of-the-art methods, highlighting its significant potential in improving computational efficiency.