SynthMed LoRAs — Privacy-Preserving Medical Image Generation
Two LoRA adapters for CompVis/stable-diffusion-v1-4 that generate synthetic medical images conditioned on patient metadata.
These models support two generation modes:
Text-to-image (T2I) — generate a novel synthetic image from a prompt alone.
Image-to-image (I2I) — transform a real image into a synthetic counterpart while preserving clinical signals. The strength parameter trades off re-identification risk against biomarker fidelity, enabling tunable de-identification.
Adapter
Domain
Conditioned on
Weight file
hpp-retina
Retinal fundus photography
Age, sex, systolic BP
hpp-retina/lora_weights.safetensors
cxr
Chest X-ray (PA view)
Age, sex, pathology findings
cxr/lora_weights.safetensors
About
Patient privacy constraints limit the sharing of clinical imaging datasets. These LoRAs were developed as part of a study evaluating image-conditioned diffusion as a practical de-identification approach: given a real image, I2I diffusion produces a synthetic counterpart that preserves downstream-relevant clinical signals while reducing re-identification risk.
Key findings from the paper:
I2I outperforms T2I on pixel/perceptual fidelity and biomarker agreement at all conditioning strengths.
Privacy–utility tradeoff (retinal): biomarker agreement (hemoglobin, Pearson r) drops from 0.83 at strength 0.1 to 0.32 at strength 1.0, while top-1 re-identification rate falls from 100% to ~2%.
Cross-cohort transfer: pretraining on I2I synthetic retinal images performs comparably to real-image pretraining when transferring to UK Biobank, and surpasses it in the smallest fine-tuning regimes.
CXR caveat: chest X-rays remain substantially re-identifiable even at high I2I strengths.
Each pair is generated from the same real source image and prompt. T2I generates freely from text; I2I conditions on the real image, preserving anatomical structure.
retina fundoscopy right eye dilated age=42 gender=female bp systolic=104
T2I
I2I
retina fundoscopy right eye dilated age=67 gender=female bp systolic=123
T2I
I2I
retina fundoscopy right eye dilated age=48 gender=male bp systolic=127
T2I
I2I
Chest X-ray — T2I
age=58 female, no finding
age=73 female, cardiomegaly
age=74 male, effusion
age=47 male, fibrosis, infiltration
age=40 male, atelectasis, effusion
age=48 male, atelectasis, nodule
Training Details
Both adapters were fine-tuned from CompVis/stable-diffusion-v1-4 using LoRA on attention layers (to_k, to_q, to_v, to_out.0).
If you use these models in your research, please cite:
bibtex
1@article{synthmed2026,
2 title = {Privacy-Preserving Synthetic Medical Images via Image Conditioned Diffusion Models},
3 author = {Yaya-Stupp, Doron and Lutsker, Guy and Spiegel, Or and Segal, Eran},
4 year = {2026},
5}
License
CC BY 4.0 — free to use, share, and adapt with attribution.