Cross Modification Attention Based Deliberation Model for Image Captioning

Zheng Lian, Yanan Zhang, Haichang Li, Rui Wang, Xiaohui Hu · DOI

Abstract

The conventional encoder-decoder framework for image captioning generally adopts a single-pass decoding process, which predicts the target descriptive sentence word by word in temporal order. Despite the success of this framework, it suffers from error accumulation and a lack of global planning on linguistic information. To overcome these limitations, we explore a universal two-pass decoding framework. A single-pass Drafting Model first generates a draft caption, and a Deliberation Model then performs a polishing process to refine the draft. We propose a novel Cross Modification Attention (CMA) module to enhance semantic expression and filter out error information. Our Cross Modification Attention based Deliberation Model (CMA-DM) achieves significant improvements over single-pass baselines on the MS COCO dataset.

Introduction

Most image captioning models utilize a single-pass decoding process, predicting the next word based on the image and previously generated words. This approach faces two primary challenges:

  1. Error Accumulation: Early mistakes (e.g., miscounting objects) can mislead subsequent predictions, leading to nonsensical final sentences.
  2. Lack of Global Planning: Because models only look backward, they cannot optimize sentence structure for overall flow or clarity, often resulting in repetitive or awkward phrasing.

Methodology

The proposed framework introduces a universal two-pass "Draft-and-Polish" architecture:

  • The Drafting Model: A standard encoder-decoder that generates an initial "rough draft" caption from an input image.
  • The Deliberation Model (CMA-DM): This component acts as an editor, taking both the image features and the draft caption to produce a refined final version.

Cross Modification Attention (CMA)

The core innovation is the Cross Modification Attention (CMA) module. Unlike standard attention mechanisms, CMA performs mutual correction by generating visual and textual context vectors simultaneously.

The Cross Modification Attention (CMA) module architecture, featuring Multi-Head Attention and Gated Linear Units (GLU).

As shown in the architecture above, CMA uses Gated Linear Units (GLU) to filter out noise or errors in the draft. A residual connection on the visual side ensures that the original image information remains accessible, preventing a poor draft from "poisoning" the model's understanding. The system is trained using a two-stage joint optimization, first with Cross-Entropy loss and then refined using Self-Critical Sequence Training (SCST) to optimize for the CIDEr metric.

Key Results

The CMA-DM was evaluated on the MS COCO dataset using the Karpathy split, demonstrating consistent improvements over strong single-pass baselines like Up-Down and AoANet.

  • Quantitative Performance: On the MS COCO test split, the model achieved a CIDEr score of 129.0 (using AoANet as a drafter), outperforming the baseline AoANet score of 128.3. For simpler models like Att2in, the score jumped from 114.3 to 121.9.
  • Qualitative Refinement: The deliberation process successfully corrects common errors found in initial drafts.
Qualitative examples showing how the deliberation model refines draft captions into more accurate and coherent descriptions.

As illustrated in the examples, the model can correct object counts (e.g., changing "two polar bears" to "a polar bear") and replace generic terms with more specific attributes (e.g., identifying "chips" instead of generic "potatoes"). Human evaluations confirmed that CMA-DM captions are preferred for both relevance and linguistic coherence.

Conclusion

The CMA-DM framework effectively addresses the limitations of single-pass decoding by introducing a robust deliberation phase. While the model's performance is partially dependent on the quality of the initial draft, the CMA module's residual connections provide a necessary safety net. Future work may explore multi-pass deliberation or the application of this framework to other multimodal tasks such as Video Captioning and Visual Question Answering.

Summary updated

BibTeX
@misc{lian2021cross,
  author = {Zheng Lian and Yanan Zhang and Haichang Li and Rui Wang and Xiaohui Hu},
  title = {{Cross Modification Attention Based Deliberation Model for Image Captioning}},
  year = {2021},
  eprint = {2109.08411},
  archivePrefix = {arXiv},
  url = {https://arxiv.org/abs/2109.08411},
}
Figure