RawGen: Learning Camera Raw Image Generation
Abstract
Cameras capture scene-referred linear raw images, which areprocessed by onboard image signal processors (ISPs) into display-referred8-bit sRGB outputs. Although raw data is more faithful for low-levelvision tasks, collecting large-scale raw datasets remains a major bottle-neck, as existing datasets are limited and tied to specific camera hard-ware. 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 representa-tions. This paper presents RawGen, to our knowledge the first diffusion-based framework enabling text-to-raw generation for arbitrary targetcameras, alongside sRGB-to-raw inversion. RawGen leverages the gener-ative priors of large-scale sRGB diffusion models to synthesize physicallymeaningful linear outputs, such as CIE XYZ or camera-specific raw rep-resentations, via specialized processing in latent and pixel spaces. Tohandle unknown and diverse ISP pipelines and photo-finishing effectsin diffusion-model training data, we build a many-to-one inverse-ISPdataset where multiple sRGB renditions of the same scene generatedusing diverse ISP parameters are anchored to a common scene-referredtarget. Fine-tuning a conditional denoiser and specialized decoder on thisdataset allows RawGen to obtain camera-centric linear reconstructionsthat effectively invert the rendering pipeline. We demonstrate RawGen’ssuperior performance over traditional inverse-ISP methods that assume afixed ISP. Furthermore, we show that augmenting training pipelines withRawGen’s scalable, text-driven synthetic data can benefit downstreamlow-level vision tasks.