Accepted at MICCAI 2025. Official code for the paper "Conformal Prediction for Image Segmentation Using Morphological Prediction Sets".
Luca Mossina,¹ Corentin Friedrich¹
¹ IRT Saint Exupéry. Toulouse, France
- Research Lab: DEEL, Dependable, Explainable & Embeddable Learning for trustworthy AI
- DEEL's open-source software
- DEEL's publications
Visual example of our conformal margin: we build a morphological margin (via dilation) that covers all missed pixels (false negatives). Dataset: WBC

The animation shows a sequence of four dilations by a
In the following image, we have a ground truth mask (in red) and a predicted mask (in blue). In purple, we have the pixels that were correctly predicted. The remaining red ones, are false negatives, i.e. pixels that belong to the ground truth but were not predicted.
We use morphological operations (dilation, sequences of dilations, etc.) to add a margin
To make this statistically rigorous, we use conformal prediction: using calibration data, we find the minimal number of dilations
This gives us a prediction set
This is a nonparametric method, which does not require any training or hyperparameter tuning, and is model-agnostic: it can be applied to any segmentation model, including deep learning models, classical methods, or even human annotators.
-
requirement: having a set of (previously unseen) annotated calibration pairs
$(X_i, Y_i)_{i=1}^n$ , that are i.i.d. samples from the same distribution as the test data.
$ make install
The directory notebooks contains complete examples for the datasets:
- WBC and OASIS, using the UniverSeg segmentation model
- polyps tumors dataset, using PraNet (we use precomputed predictions as distributed by A. Angelopoulos.
Starting points for datasets:
- WBC, via universeg repo
- OASIS, via universeg repo
- polyps tumor data, via aangelopoulos/conformal-prediction repo
Models used:
- UniverSeg: code, paper
- PraNet: paper, via aangelopoulos/conformal-prediction repo
For full bibliographic references, see the Experiments section in our paper.
MIT License © 2025 IRT Saint Exupéry.
Part of the DEEL project on trustworthy AI (deel.ai).
@InProceedings{Mossina_2025_conformal_morpho,
title={Conformal Prediction for Image Segmentation Using Morphological Prediction Sets},
author={Mossina, Luca and Friedrich, Corentin},
booktitle={Medical Image Computing and Computer Assisted Intervention -- MICCAI 2025},
year={2026},
publisher={Springer Nature Switzerland},
address={Cham},
pages={78--88},
}

