Algorithmic encoding of protected characteristics in image-based models\n for disease detection

Ben Glocker, Charles Jones, M. Brooke Bernhardt, Stefan Winzeck · DOI

Abstract

It has been rightfully emphasized that the use of AI for clinical decision making could amplify health disparities. An algorithm may encode protected characteristics, and then use this information for making predictions due to undesirable correlations in the (historical) training data. It remains unclear how we can establish whether such information is actually used. Besides the scarcity of data from underserved populations, very little is known about how dataset biases manifest in predictive models and how this may result in disparate performance. This article aims to shed some light on these issues by exploring new methodology for subgroup analysis in image-based disease detection models. We utilize two publicly available chest X-ray datasets, CheXpert and MIMIC-CXR, to study performance disparities across race and biological sex in deep learning models. We explore test set resampling, transfer learning, multitask learning, and model inspection to assess the relationship between the encoding of protected characteristics and disease detection performance across subgroups. We confirm subgroup disparities in terms of shifted true and false positive rates which are partially removed after correcting for population and prevalence shifts in the test sets. We further find a previously used transfer learning method to be insufficient for establishing whether specific patient information is used for making predictions. The proposed combination of test-set resampling, multitask learning, and model inspection reveals valuable new insights about the way protected characteristics are encoded in the feature representations of deep neural networks.

Introduction

The integration of deep learning into clinical workflows offers significant potential for improving diagnostic accuracy. However, a growing body of research suggests that these models may inadvertently amplify existing health disparities. A particularly startling discovery in recent years is the ability of neural networks to accurately predict a patient’s self-reported race from medical images—such as chest X-rays—even when those images contain no obvious demographic markers visible to human experts. This raises a critical question: if a model "knows" a patient's race or sex, is it using that information as a "shortcut" for disease detection?

This research investigates the mechanisms by which protected characteristics are encoded in medical imaging models. By evaluating two large-scale datasets, CheXpert and MIMIC-CXR, the authors challenge existing methodologies for auditing algorithmic bias and propose a more rigorous framework for understanding how demographic information interacts with clinical predictions.

The Fallacy of the Supervised Prediction Layer Information Test (SPLIT)

A common method for detecting bias, known as the Supervised Prediction Layer Information Test (SPLIT), involves taking a pre-trained disease detection model, freezing its feature-extracting "backbone," and training a new classification head to predict demographic traits. If the head succeeds, researchers often conclude that the model has implicitly learned to encode demographic features to aid its primary task.

The authors demonstrate that this conclusion is fundamentally flawed. They applied the SPLIT method to backbones that had never seen a medical image (pre-trained on ImageNet) and even to backbones with completely random weights. Surprisingly, these models could still predict race and sex with high accuracy (AUCs of 0.78 and 0.70, respectively). This suggests that demographic signals are inherently present in the raw pixel data and are preserved through even random transformations. Consequently, the mere ability to extract demographic information from a model's latent space does not prove that the model is utilizing that information for clinical decision-making.

Disentangling Algorithmic Bias from Statistical Shifts

To better understand performance disparities, the authors utilized test-set resampling. Standard datasets are often skewed; for instance, in the datasets studied, Black patients were systematically younger than White patients. When evaluated on these skewed sets, models appeared to underdiagnose Black patients, showing a higher false-positive rate for "no finding."

However, when the authors created balanced test sets—controlling for age, race, and disease prevalence—this specific disparity vanished. This indicates that what was previously interpreted as "algorithmic bias" was actually a reflection of statistical population shifts within the test data. By isolating these variables, the study highlights the importance of rigorous data auditing before attributing performance gaps to the model's internal logic.

Multitask Learning and Feature Orthogonality

To further probe the relationship between disease features and demographic features, the authors employed multitask learning, training models to simultaneously predict disease, race, and sex. Using Principal Component Analysis (PCA) and t-SNE to visualize the resulting feature representations, they found that the model often encodes these characteristics in distinct, orthogonal directions within the latent space.

For example, while the first principal component might strongly correlate with biological sex, the features used for disease prediction (such as identifying pleural effusion) occupied a different "mode" of the feature space. This suggests that a model can simultaneously "know" a patient's demographic identity while keeping that information separate from its diagnostic output.

Results and Persistent Disparities

While resampling resolved some disparities, others remained. Specifically, the model showed persistent performance gaps in detecting pleural effusion in Black patients, characterized by lower True Positive and False Positive rates. This suggests that while some "biases" are artifacts of data distribution, others represent genuine differences in how the model processes images from different subgroups.

Quantitatively, the baseline models achieved strong performance (AUCs 0.85–0.90), but the study proves that high performance does not preclude the existence of subtle subgroup disparities that require specialized auditing techniques to uncover.

Conclusion

This research provides a necessary correction to the methodology of AI auditing in healthcare. It demonstrates that the encoding of protected characteristics is often an unavoidable consequence of the high-dimensional nature of medical images rather than a deliberate shortcut taken by the model. To build truly equitable AI, researchers must move beyond simple information extraction tests and focus on how features are integrated into final clinical predictions, while remaining vigilant about the statistical composition of their evaluation datasets.

Summary updated

BibTeX
@misc{glocker2021algorithmic,
  author = {Ben Glocker and Charles Jones and M. Brooke Bernhardt and Stefan Winzeck},
  title = {{Algorithmic encoding of protected characteristics in image-based models\textbackslash\{\}n for disease detection}},
  year = {2021},
  eprint = {2110.14755},
  archivePrefix = {arXiv},
  url = {https://arxiv.org/abs/2110.14755},
}
Figure