RawGen: Learning Camera Raw Image Generation
Organizations: AI Center - Toronto, Samsung Electronics · Yonsei University
Abstract
Cameras capture scene-referred linear raw images, which are processed by onboard image signal processors (ISPs) into display-referred 8-bit sRGB outputs. Although raw data is more faithful for low-level vision tasks, collecting large-scale raw datasets remains a major bottleneck, as existing datasets are limited and tied to specific camera hardware. Generative models offer a promising way to address this scarcity -- however, existing diffusion frameworks are designed to synthesize photo-finished sRGB images rather than physically consistent linear representations. This paper presents RawGen, to our knowledge the first diffusion-based framework enabling text-to-raw generation for arbitrary target cameras, alongside sRGB-to-raw inversion. RawGen leverages the generative priors of large-scale sRGB diffusion models to synthesize physically meaningful linear outputs, such as CIE XYZ or camera-specific raw representations, via specialized processing in latent and pixel spaces. To handle unknown and diverse ISP pipelines and photo-finishing effects in diffusion-model training data, we build a many-to-one inverse-ISP dataset where multiple sRGB renditions of the same scene generated using diverse ISP parameters are anchored to a common scene-referred target. Fine-tuning a conditional denoiser and specialized decoder on this dataset allows RawGen to obtain camera-centric linear reconstructions that effectively invert the rendering pipeline. We demonstrate RawGen's superior performance over traditional inverse-ISP methods that assume a fixed ISP. Furthermore, we show that augmenting training pipelines with RawGen's scalable, text-driven synthetic data can benefit downstream low-level vision tasks.
Figures & tables
| Expert A | Expert B | Expert C | Expert D | Expert E | ||||||
| Method | PSNR | SSIM | PSNR | SSIM | PSNR | SSIM | PSNR | SSIM | PSNR | SSIM |
| CIE XYZ Net [ 3 ] | 19.60 | 0.7861 | 21.04 | 0.8431 | 19.49 | 0.7795 | 19.44 | 0.8058 | 18.64 | 0.7918 |
| InvISP [ 70 ] | 16.04 | 0.6854 | 16.04 | 0.6854 | 14.92 | 0.6323 | 14.24 | 0.6802 | 13.30 | 0.6473 |
| Raw-Diffusion [ 54 ] | 19.30 | 0.7832 | 20.66 | 0.8397 | 18.79 | 0.7705 | 18.69 | 0.7966 | 17.49 | 0.7751 |
| RawGen | 19.57 | 0.7782 | 21.21 | 0.8349 | 19.48 | 0.7741 | 18.74 | 0.7929 | 18.07 | 0.7839 |
| RawGen (Ours) | 23.20 | 0.8432 | 24.35 | 0.8581 | 23.37 | 0.8387 | 23.51 | 0.8531 | 23.89 | 0.8500 |
| Denoising | ||||||||||
| Illuminant estimation | Neural ISP | ISO 1600 | ISO 3200 | |||||||
| Method | Mean | Median | Worst 25% | PSNR | SSIM | PSNR | SSIM | PSNR | SSIM | |
| EnlightenGAN [ 35 ] | 7.01 | 6.82 | 11.07 | 35.58 | 0.965 | 3.137 | 48.82 | 0.991 | 47.25 | 0.988 |
| UPI [ 11 ] | 6.26 | 5.89 | 10.33 | 36.43 | 0.966 | 2.907 | 49.05 | 0.990 | 47.51 | 0.988 |
| Graphics2RAW [ 61 ] | 4.21 | 3.38 | 8.57 | 38.10 | 0.974 | 2.301 | 49.37 | 0.991 | 48.16 | 0.989 |
| RawGen | 3.14 | 2.11 | 7.37 | 38.42 | 0.970 | 2.183 | 50.63 | 0.994 | 48.57 | 0.992 |
Appendix figures & tables14 assets
Supplementary material from the paper’s appendix.
Appendix
| Parameter | Distribution | Range | Stage |
| Red WB multiplier | Uniform | White balance | |
| Blue WB multiplier | Uniform | White balance | |
| Tone-map | Normal | (clip ) | Tone mapping |
| Tone-map | Normal | (clip ) | Tone mapping |
| Contrast | Uniform | sRGB |
Computational Imaging
Computational imaging combines optical and sensor design with algorithms to recover or infer scene information from indirect, compressed, or noisy measurements.
See all 123 papers