Model-Agnostic Gender Debiased Image Captioning

Yusuke Hirota, Yuta Nakashima, Noa Garcia

TL;DR

This paper introduces LIBRA, a novel framework for mitigating gender bias in image captioning models. LIBRA effectively addresses two types of gender bias – context-to-gender and gender-to-context – by synthesizing biased captions and then training a debiasing generator. This approach leads to more neutral and accurate image descriptions without requiring modifications to the original captioning models.

What Problem Does This Paper Address?

Image captioning models, while impressive in their ability to describe visual content, often perpetuate and even amplify societal biases present in their training data. This paper focuses on gender bias, a prevalent issue where models might incorrectly infer gender based on image context (e.g., associating a skateboard with a boy) or generate gender-stereotypical descriptions (e.g., describing a woman in a kitchen). Prior work has attempted to address this by forcing models to focus on people, but this can lead to a trade-off where gender accuracy is improved at the expense of generating correct, non-stereotypical descriptions. The authors identify two key types of gender bias:

  1. Context → Gender Bias: The model uses image context to predict gender, potentially leading to misclassifications.
  2. Gender → Context Bias: The model generates gender-stereotypical words that are not necessarily relevant to the image content, simply because of the predicted gender.

The paper aims to tackle both these biases simultaneously to achieve truly debiased image captions.

Methods

LIBRA is a two-module framework:

  1. Biased Caption Synthesis (BCS): This module generates synthetic captions that exhibit gender bias. It employs two strategies:
  2. Gender-Swapping: Swaps gendered words in original captions to create inconsistencies between the text and the implied gender, thus creating context → gender bias.
  3. T5-generation: Leverages a pre-trained T5 language model to generate modified captions. By filtering these generated captions, the module amplifies gender → context bias, creating captions with gender-stereotypical word choices.
  4. These two strategies can be combined to create captions with both types of biases.
  5. Debiasing Caption Generator (DCG): This module is an encoder-decoder architecture (Transformer-based) trained on the synthetic biased captions and their corresponding images. The goal is to learn to "un-bias" the input captions. During training, the input caption is masked to encourage the model to rely on both the image and the (biased) text to generate a neutral, accurate caption. Crucially, DCG is model-agnostic, meaning it can be applied on top of any existing image captioning model during inference without retraining the original model.

Datasets

  • MSCOCO captions [9]: Used for training captioning models and for synthesizing biased captions with BCS.
  • MSCOCO validation set: Used for evaluating the performance of the debiased models. This subset is noted to have binary gender annotations from [65].

Key Insights and Ideas

  • Two distinct types of gender bias: The paper clearly delineates "context → gender" and "gender → context" biases, providing a more nuanced understanding of the problem than previous work.
  • Trade-off in existing methods: The authors highlight that methods focusing solely on improving gender classification accuracy can inadvertently worsen gender-stereotypical language generation.
  • Synthetic data as a powerful proxy: The success of LIBRA demonstrates that carefully synthesized biased data can effectively train a debiasing model, acting as a good proxy for real-world biases found in large datasets.
  • Model-agnosticism is key: The ability to apply LIBRA as a post-processing step to any captioning model makes it highly practical and broadly applicable.
  • CLIPScore as a better metric for bias mitigation: The paper suggests that CLIPScore, a reference-free metric, is more robust to changes made by debiasing methods (like replacing stereotypical words with neutral ones) compared to traditional reference-based metrics (BLEU, CIDEr, etc.), which may favor human-annotated, potentially biased, language.

Key Results

  • Consistent bias reduction: LIBRA consistently reduced gender → context bias (measured by LIC) across various captioning models, often achieving negative LIC scores, indicating less bias than human annotators.
  • Mitigation of context → gender bias: The "Error" metric showed that LIBRA significantly reduced gender misclassification in most models.
  • Improved caption quality (with caveats): While reference-based captioning metrics sometimes dropped slightly (e.g., BLEU-4), LIBRA maintained or improved scores on CLIPScore, suggesting that the generated captions were still semantically relevant and visually grounded, even if they used less stereotypical language.
  • Outperforms image caption editing models: LIBRA demonstrated superior performance in mitigating gender bias compared to a general image caption editing model (ENT [40]), underscoring the need for specialized bias mitigation frameworks.
  • Effectiveness of synthetic data: DCG trained on BCS-generated data consistently outperformed DCG trained on randomly perturbed captions, validating the approach of intentionally creating biased samples.

Limitations and Future Work

  • Subtle biases: LIBRA's effectiveness might be limited for more subtle societal biases beyond gender, which may not be as explicitly captured by word choices.
  • Context → Gender bias evaluation: The "Error" metric for context → gender bias is acknowledged as not directly evaluating the bias itself, but rather its consequence (misclassification). A more direct metric is desired.
  • Insufficient gender clues: In cases with very few visual clues, LIBRA's gender misclassification might still occur due to the lack of definitive information. The authors suggest exploring predicting gender-neutral terms like "person" in such scenarios.
  • Potential for over-confidence: Users might become overly confident that LIBRA has eliminated all gender bias, potentially overlooking other subtle biases or the inherent biases that might still exist in the underlying captioning models.
  • Future work: The authors suggest extending LIBRA to mitigate other types of biases (e.g., age, skin-tone) and exploring mechanisms for predicting gender-neutral words when gender is ambiguous.

Summary updated

Abstract

Image captioning models are known to perpetuate and amplify harmful societal bias in the training set. In this work, we aim to mitigate such gender bias in image captioning models. While prior work has addressed this problem by forcing models to focus on people to reduce gender misclassification, it conversely generates gender-stereotypical words at the expense of predicting the correct gender. From this observation, we hypothesize that there are two types of gender bias affecting image captioning models: 1) bias that exploits context to predict gender, and 2) bias in the probability of generating certain (often stereotypical) words because of gender. To mitigate both types of gender biases, we propose a framework, called LIBRA, that learns from synthetically biased samples to decrease both types of biases, correcting gender misclassification and changing gender-stereotypical words to more neutral ones. Code is available at https://github.com/rebnej/LIBRA.
BibTeX
@inproceedings{hirota2023model,
  author = {Yusuke Hirota and Yuta Nakashima and Noa Garcia},
  title = {{Model-Agnostic Gender Debiased Image Captioning}},
  booktitle = {IEEE/CVF Conference on Computer Vision and Pattern Recognition},
  year = {2023},
}
Figure