Pixel Perfect MegaMed: A Megapixel-Scale Vision-Language Foundation Model for Generating High Resolution Medical Images
Zahra TehraniNasab, Amar Kumar, Tal Arbel · 2025
Read Pixel Perfect MegaMed: A Megapixel-Scale Vision-Language Foundation Model for Generating High Resolution Medical Images by Zahra TehraniNasab, Amar Kumar, Tal Arbel (2025) in the Tower of Babel, a free online library of public-domain works preserved in clean, searchable text. No sign-up. The full text is served as a plain-text file at a predictable URL, where text is present: https://antarctic-labs.com/tower-of-babel/arxiv-2507-12698.txt.
Introduction
Zahra TehraniNasab and co-authors present a vision language model that generates high resolution medical images in a 2025 paper, based on the head byline. Medical image synthesis is hard because clinical use demands fine detail at high resolution. Standard generative models often blur the small features that diagnosis depends on. Their model is the first of its kind to synthesize images at megapixel scale.
A multi scale transformer keeps both global anatomy and local detail, while vision language alignment ties text prompts to medical terms and imaging types. Applied to a chest X ray data set, the model produced clinically faithful images from text. The synthetic images also helped downstream classification tasks.
Catalog record
| CREATOR | Zahra TehraniNasab, Amar Kumar, Tal Arbel |
|---|---|
| YEAR | 2025 |
| COLLECTION | PAPERS |
| FORMAT | TXT |
| FILE SIZE | 19 KB |
| VERSION | 1.0 |
| LICENSE | http://creativecommons.org/licenses/by/4.0/ |
| RIGHTS | CC BY |
| SOURCE | arXiv |
Source: https://arxiv.org/abs/2507-12698
Browse the full library · About the Tower of Babel
Full text
The opening of the work, from the library's hosted text:
Pixel Perfect MegaMed: A Megapixel-Scale Vision-Language Foundation Model for Generating High Resolution Medical Images Zahra TehraniNasab, Amar Kumar, Tal Arbel Abstract Medical image synthesis presents unique challenges due to the inherent complexity and high-resolution details required in clinical contexts. Traditional generative architectures such as Generative Adversarial Networks (GANs) or Variational Auto Encoder (VAEs) have shown great promise for high-resolution image generation but struggle with preserving fine-grained details that are key for accurate diagnosis. To address this issue, we introduce Pixel Perfect MegaMed , the first vision-language foundation model to synthesize images at resolutions of 1024 × 1024 1024\times 1024 . Our method deploys a multi-scale transformer architecture designed specifically for ultra-high resolution medical image generation, enabling the preservation of both global anatomical context and local image-level details. By leveraging vision-language alignment techniques tailored to medical terminology and imaging modalities, Pixel Perfect MegaMed bridges the gap between textual descriptions and visual representations at unprecedented resolution levels. We apply our model to the CheXpert dataset and demonstrate its ability to generate clinically faithful chest X-rays from text prompts. Beyond visual quality, these high-resolution synthetic images prove valuable for downstream tasks such as classification, showing measurable performance gains when used for data augmentation, particularly in low-data regimes. Our code is accessible through the project website 1 1 1 https://tehraninasab.github.io/pixelperfect-megamed/ . 1 Introduction High-resolution medical images are needed for many clinical decision support systems that depend on the ability to resolve fine-grained anatomical and pathological features. Consider its importance in the context of chest X-rays, where subtle abnormalities—such as small pulmonary nodules, fine patterns, or early pleural changes—are more easily identified at higher resolutions Haque et al. 2023 ; Jiang et al. 2025 . AI-driven diagnostic systems should maintain images at high resolution, if available, in order to preserve essential texture and edge information that might otherwise be lost at lower resolutions Miyata et al. 2020 ; Schuijf et al. 2022 ; Yanagawa et al. 2018 . For instance, in detecting pleural effusion, the separation of the pleural line—a key diagnostic indicator—may remain undetectable at lower resolutions but becomes visible when sufficient spatial detail is present (see Figure 1 & 2 ). Given their importance, high-resolution image generators can synthesize detailed medical images in contexts where real, high-quality data is scarce, thereby supporting the development of robust diagnostic models in data-limited settings. Image-based generative models have made significant advances in medical imaging, holding substantial potential for advancing analysis and enabling data augmentation for improved classification Fathi et al. 2024 ; Kumar et al. 2023 and segmentation Chlap et al. 2021 ; Chen et al. 2022 . Conditional generative models have led to huge advances in explainability through counterfactual image generation Fathi et al. 2024 ; Mertes et al. 2022 , leading to advances in understanding personalized markers of disease Kumar et al. 2022 . Furthermore, recent advances in VLM foundation models (e.g. Stable Diffusion) have permitted significant performance improvements for many tasks when fine-tuned on medical images. However, most existing work in medical image synthesis has been constrained to low or moderate resolutions, typically around 128\times 128 Iklima et al. 2022 ; Madani et al. 2018 or 256\times 256 pixels Atad et al. 2022 ; Fathi et al. 2024 . These resolutions are inadequate for clinical use, as they fail to capture the detailed anatomical structures and subtle pathological cues necessary for accurate diagnosis (see Figure 2 ). Although recent methods have started to push resolution boundaries—reaching 512\times 512 pixels Kumar et al. 2025 ; Pérez-García et al. 2025 —generating high-quality, high-resolution medical images that retain clinical utility remains a significant challenge. Achieving ultra-high resolution synthesis (e.g., 1024\times 1024 and beyond) is crucial for capturing the full complexity of medical imagery, including tiny anatomical variations and rare pathological signatures that are vital for robust diagnostic and research applications. Figure 1: Grad-CAM visualization of activation maps in the EfficientNet classifier for pleural effusion (PE) classification of a patient’s Chest X-ray image Irvin et al. 2019 . The heatmaps highlight that the model fails to focus on relevant regions in low-resolution images, leading to incorrect classifications. At the higher resolution, the model focuses on the exact location of interest. In this work, we present Pixel Perfect MegaMed , the first VLM foundation model capable of synthesizing ultra-high-resolution medical images at 1024\times 1024 pixels, setting a new benchmark (4 times larger than existing VLM) for fidelity and clinical relevance in generative medical imaging. Our approach builds upon a multi-scale transformer-based backbone architecture based on Stable-Diffusion XL (SDXL) Podell et al. 2023 , a VLM for synthesizing ultra-high resolution images, fine-tuned on a medical imaging dataset, CheXpert Irvin et al. 2019 . Furthermore, we extend our framework to progressively upscale the generated images to a resolution of 2048\times 2048 , further pushing the boundaries of photorealism and clinical relevance. We validate our model’s performance using rigorous image quality metrics, including Fréchet Inception Distance (FID) and Vendi Score, demonstrating synthesis fidelity and perceptual quality of our method. Additionally, we demonstrate that images generated by Pixel Perfect MegaMed can be used for data augmentation, yielding measurable gains in downstream classification performance under limited data regimes. The code and model weights of our new VLM models will be released to permit widespread adoption in the medical imaging community. Figure 2: The effect of image resolution on multi-class disease classification performance (Left: AUROC, Right: F1). The same samples across different resolutions are used to train all the EfficientNet classifiers. 2 Methodology In this work, we propose building a VLM foundation model for high-resolution medical images by fine-tuning SDXL using Low-Rank Adaptation (LoRA) Hu et al. 2022 . Our framework includes: (i) generation of a 1024\times 1024 image conditioned on embeddings from OpenCLIP ViT-bigG Ilharco et al. and CLIP ViT-L Radford et al. 2021 ; (ii) refinement via a denoising module to improve anatomical realism; (iii) [ optional ] a progressive upscaling module increases the resolution to 2048\times 2048 , see Figure 3 . 2.1 MultiDiffusion: Adapted Latent Diffusion Latent Diffusion Models (LDMs) Rombach et al. 2022 perform diffusion in a learned latent space rather than directly in the high-dimensional pixel space, thus reducing the computational costs while preserving the quality of generated samples. Given a pre-trained autoencoder with an encoder \mathcal{E} and decoder \mathcal{D} , images \mathbf{x}\in\mathbb{R}^{H\times W\times C} are first mapped into a lower-dimensional latent space as \mathbf{z}=\mathcal{E}(\mathbf{x}) , \mathbf{z}\in\mathbb{R}^{h\times w\times c} . A standard diffusion process is then applied in the latent space to model the data distribution. The forward diffusion process gradually adds Gaussian noise to the latent variable \mathbf{z}_{0} over T steps: q(\mathbf{z}_{t}\mid\mathbf{z}_{t-1})=\mathcal{N}(\mathbf{z}_{t};\sqrt{1-\beta_{t}}\mathbf{z}_{t-1},\beta_{t}\mathbf{I}), where \beta_{t} is a fixed variance schedule. The model learns a denoising function \epsilon_{\theta}(\mathbf{z}_{t},t) to approximate the added noise, enabling the reverse process to recover \mathbf{z}_{0} iteratively. The final image is reconstructed via \hat{\mathbf{x}}=\mathcal{D}(\mathbf{z}_{0}) . MultiDiffusion Bar-Tal et al. 2023 enhances latent diffusion models (LDMs) by enabling the image generation at resolutions higher than those originally trained on. Rather than synthesizing the entire image in a single step, the method breaks the target canvas into several overlapping tiles. Each tile is processed independently in the latent space, guided by a shared prompt or contextual information. Once individual tiles are denoised, they are combined using a