DOI: 10.5061/dryad.6djh9w174
title: Generation of synthetic whole-slide image tiles of tumours from RNA-sequencing data via cascaded diffusion models

description: Data scarcity presents a significant obstacle in the field of biomedicine,
 where acquiring diverse and sufficient datasets can be costly and
 challenging. Synthetic data generation offers a potential solution to this
 problem by expanding dataset sizes, thereby enabling the training of more
 robust and generalizable machine learning models. Although previous
 studies have explored synthetic data generation for cancer diagnosis, they
 have predominantly focused on single-modality settings, such as
 whole-slide image tiles or RNA-Seq data. To bridge this gap, we propose a
 novel approach, RNA-Cascaded-Diffusion-Model or RNA-CDM, for performing
 RNA-to-image synthesis in a multi-cancer context, drawing inspiration from
 successful text-to-image synthesis models used in natural images. In our
 approach, we employ a variational auto-encoder to reduce the
 dimensionality of a patient’s gene expression profile, effectively
 distinguishing between different types of cancer. Subsequently, we employ
 a cascaded diffusion model to synthesize realistic whole-slide image tiles
 using the latent representation derived from the patient’s RNA-Seq data.
 Our results demonstrate that the generated tiles accurately preserve the
 distribution of cell types observed in real-world data, with
 state-of-the-art cell identification models successfully detecting
 important cell types in the synthetic samples. Furthermore, we illustrate
 that the synthetic tiles maintain the cell fraction observed in bulk
 RNA-Seq data and that modifications in gene expression affect the
 composition of cell types in the synthetic tiles. Next, we utilize the
 synthetic data generated by RNA-CDM to pretrain machine learning models
 and observe improved performance compared to training from scratch. Our
 study emphasizes the potential usefulness of synthetic data in developing
 machine learning models in scarce-data settings, while also highlighting
 the possibility of imputing missing data modalities by leveraging the
 available information. In conclusion, our proposed RNA-CDM approach for
 synthetic data generation in biomedicine, particularly in the context of
 cancer diagnosis, offers a novel and promising solution to address data
 scarcity. By generating synthetic data that align with real-world
 distributions and leveraging it to pretrain machine learning models, we
 contribute to the development of robust clinical decision support systems
 and potential advancements in precision medicine.
description: # RNA-CDM Generated One Million Synthetic Images
 [https://doi.org/10.5061/dryad.6djh9w174](https://doi.org/10.5061/dryad.6djh9w174) One million synthetic digital pathology images were generated using the RNA-CDM model presented in the paper "RNA-to-image multi-cancer synthesis using cascaded diffusion models". ## Description of the data and file structure There are ten different h5 files per cancer type (TCGA-CESC, TCGA-COAD, TCGA-KIRP, TCGA-GBM, TCGA-LUAD). Each h5 file contains 20.000 images. The key is the tile number, ranging from 0-20,000 in the first file, and from 180,000-200,000 in the last file. The tiles are saved as numpy arrays. ## Code/Software The code used to generate this data is available under academic license in [https://rna-cdm.stanford.edu](https://rna-cdm.stanford.edu) . ## Manuscript citation Carrillo-Perez, F., Pizurica, M., Zheng, Y. *et al.* Generation of synthetic whole-slide image tiles of tumours from RNA-sequencing data via cascaded diffusion models. *Nat. Biomed. Eng* (2024). [https://doi.org/10.1038/s41551-024-01193-8](https://doi.org/10.1038/s41551-024-01193-8)