Visual Data Diagnosis and Debiasing with Concept Graphs

Rwiddhi Chakraborty, Yinong Oliver Wang, Jialu Gao, Runkai Zheng, Cheng Zhang, Fernando De la Torre

Deep learning models are notorious for taking the "path of least resistance." If every picture of a cow in a training dataset features a grassy field, the model might incorrectly learn that "grass" is the defining feature of a cow. When it eventually encounters a cow on a beach, it fails. This phenomenon, known as the spurious correlation problem, leads to brittle performance in real-world, out-of-distribution scenarios.

To address this, researchers have introduced ConBias, a novel framework designed to systematically diagnose and mitigate these logical shortcuts by representing visual datasets as concept graphs.

ConBias Overview

The Challenge of Inherent Bias

Most large-scale datasets are inherently biased. Humans tend to photograph objects in their typical environments—boats on water, cars on roads, or specific demographics in certain professional settings. Models trained on this data inevitably pick up these co-occurrence biases.

While previous attempts to fix this have relied on traditional data augmentation (like flipping or cropping) or using Large Language Models (LLMs) to generate diverse image descriptions, two major gaps have persisted:

  1. Diagnosis: Most methods attempt to "debias" without first understanding the specific nature of the bias within the dataset.
  2. Control: Relying solely on generative models to create "unbiased" data can inadvertently introduce the model's own internal biases or distort the target objects.

The ConBias Methodology

ConBias is an end-to-end pipeline that identifies under-represented combinations of objects and contexts (e.g., a waterbird in a forest) and uses generative AI to fill the gaps. The framework operates in three distinct stages:

The ConBias Framework

1. Concept Graph Construction

The dataset is first represented as a knowledge graph. Nodes represent target classes (e.g., "Landbird") and background concepts (e.g., "Tree," "Man," "Beach"). Edges connect nodes that appear together in the same image, with the edge weight representing the frequency of their co-occurrence.

2. Concept Diagnosis via Cliques

To uncover complex biases, the system analyzes the graph for cliques—subsets of nodes where every node is connected to every other node. By comparing the frequency of these cliques across different classes, ConBias spots imbalances. For instance, if the clique {Beach, Ocean, Waterbird} is highly frequent but {Beach, Ocean, Landbird} is virtually non-existent, a specific bias is diagnosed.

3. Concept Debiasing via Inpainting

Once a "missing" combination is identified, ConBias employs a text-to-image model (like Stable Diffusion) to generate a background containing those specific concepts. Crucially, it uses inpainting: the system extracts a real object from the original dataset and pastes it into the synthetic background. This ensures the actual object features remain authentic, preserving label integrity while diversifying the context.

Key Insights and Results

The researchers evaluated ConBias on several benchmark datasets known for specific biases, including Waterbirds (background bias), UrbanCars (background and co-occurring object bias), and COCO-GB (gender bias).

  • Graphs over Statistics: Simple frequency tables often miss higher-order relationships. By utilizing graph cliques, ConBias can identify nuanced biases—recognizing, for example, that a model isn't just biased against "water," but against the specific combination of "water + boat + person."
  • Significant Performance Gains: ConBias consistently outperformed state-of-the-art methods and standard augmentations. On the Waterbirds dataset, Out-of-Distribution (OOD) accuracy jumped to 69.3%, a massive improvement over the baseline's 44.9%. Similarly, UrbanCars OOD accuracy improved from 40.5% to 52.9%.
  • The "Goldilocks" Zone: The study noted that adding synthetic data improves performance up to a certain threshold (e.g., around 1,000 images in COCO-GB tests). Beyond this point, performance can degrade as the model begins overfitting to the artifacts of the generative engine.

Limitations and Future Directions

While highly effective, the authors note a few computational and structural hurdles. Finding all cliques in a graph is an NP-complete problem; while limiting cliques to a size of 4 works well for current vision tasks, scaling to massively complex datasets could become a bottleneck. Additionally, ConBias currently relies on existing concept metadata (like captions or tags). Applying it to entirely unlabelled raw data would require an automated tagging precursor.

By transforming the messy reality of visual data into a structured, diagnosable graph, ConBias provides a powerful "X-ray" for AI datasets, allowing developers to systematically uncover and heal the biases that lead to model failure.

Summary updated

BibTeX
@inproceedings{chakraborty2024visual,
  author = {Rwiddhi Chakraborty and Yinong Oliver Wang and Jialu Gao and Runkai Zheng and Cheng Zhang and Fernando De la Torre},
  title = {{Visual Data Diagnosis and Debiasing with Concept Graphs}},
  booktitle = {Advances in Neural Information Processing Systems},
  year = {2024},
  url = {https://openreview.net/forum?id=XNGsx3WCU9},
}
Figure