TL;DR
Standard 8-bit photos flatten the brightest parts of our world—turning suns, lamps, and bright windows into washed-out white blobs—while traditional generative AI fixes this by carelessly repainting the entire image from scratch. UniHDR realizes that an image is a physical measurement, not just a creative prompt: it locks in the pixels your camera actually captured, estimates the camera's secret color-mapping curve on the fly, and uses a diffusion transformer solely to regenerate the missing highlights. Remarkably, a single model handles both regular photos and 360° panoramas used for 3D virtual lighting.
What Problem Does This Paper Address?
When you snap a standard Low Dynamic Range (LDR) 8-bit photo, the camera sensor hits a ceiling. Anything brighter than that clip point saturates to pure white (255), permanently losing the true linear radiance of light sources. Recovering this High Dynamic Range (HDR) information from a single image is crucial for post-processing, HDR displays, and turning 360° panoramas into realistic lighting environments for 3D rendering.
Existing solutions fall into two traps:
- Feed-forward neural networks try to directly predict the missing light, but struggle to hallucinate compact, intense light sources many stops brighter than the sensor ceiling.
- Diffusion models generate plausible highlights, but treat the input photo merely as a loose condition, often altering unclipped pixels that didn't need fixing. Conversely, forcing the diffusion sampler to strictly copy the unclipped pixels all the way to the final step bakes sensor noise and compression artifacts straight into the output.
On top of that, cameras apply nonlinear camera response curves (tone mapping) to make RAW light look pleasing as a JPEG. Without knowing the exact inverse curve of an arbitrary photo, you can't accurately map its pixels back to real-world linear physics.
Methods
UniHDR fine-tunes a pretrained 20B-parameter image-editing diffusion transformer (Qwen-Image-Edit-2511) using Low-Rank Adaptation (LoRA), paired with a custom fine-tuned Variational Autoencoder (VAE) decoder.
- Piecewise HDR Encoding: Standard VAEs expect display-ready values in $[0, 1]$. UniHDR maps unclipped light into $[0, 0.7]$ and packs six logarithmic decades of clipped highlight intensity into the remaining $(0.7, 1.0]$ shoulder, fine-tuning only the VAE decoder on 16-bit targets so the generator's latent space stays intact.
- Noise-Adaptive Anchoring: During the $T=10$ sampling steps, UniHDR resets the latent representation of unclipped regions back to the linearized input at every step except the last $K$ steps. It blindly estimates the input image's sensor noise in mid-tone blocks to choose $K$: clean images get $K=0$ (preserving the exact measurement), while noisy high-ISO images get a larger $K$, giving the diffusion model breathing room at the end to denoise the scene.
- Self-Extracted Camera Response Curve: Instead of using a separate network or assuming a standard sRGB curve, UniHDR runs two unanchored diffusion steps first. Because the generator was trained on diverse camera curves to output linear radiance, comparing this quick 2-step linear sketch against the raw 8-bit input pixels reveals the camera's inverse response curve—ready to linearize the anchor for the main 10-step pass.
- One-Model Universality: Both perspective images and 360° panoramas use the exact same weights, differing only by a prompt indicator and horizontal edge-wrapping on the anchor mask for panoramas.
Datasets
- Training: 86,580 synthetic LDR–HDR pairs rendered from 4,170 panoramas (Laval Indoor/Outdoor, Poly Haven, UrbanSky), perspective crops, bracketed datasets, and the authors' RAW captures, augmented with measured camera response curves and sensor noise profiles.
- Evaluation & New Captures: Evaluated on held-out SI-HDR (181 perspective scenes), Laval Indoor (150 panoramas), and 117 recent Poly Haven outdoor panoramas. Response estimation is tested on 100 RAW scenes rendered through 5 digital camera curves and 5 classic film stocks (e.g., Kodak Ektachrome). The authors also captured 662 RAW images to calibrate their noise-to-$K$ rule and 46 real-world bracketed scenes to test out-of-camera JPEGs.
- New Evaluation Protocols: Because full-image metrics drown out small bright lights, the authors introduce Highlight Radiance Error (measuring total energy, quantile spread, and spatial placement in the clipped region) and a path-traced sphere protocol that scores panoramas by rendering diffuse, matte silver, and mirror spheres under the reconstructed light.
Key Insights and Ideas
- An LDR image is a measurement, not just a hint: Unclipped pixels already measure the scene's physics up to noise and tone-mapping. Treating HDR reconstruction as anchored generation stops the AI from hallucinating over real data while still unleashing diffusion where the sensor went blind.
- Standard sRGB assumptions quietly ruin anchoring: Real camera JPEGs deviate from sRGB by 0.4–0.5 stops (and over a full stop in the shadows). Anchoring to a naive sRGB assumption on panoramas actually performs 5.9 dB worse than not anchoring at all!
- A generative prior implicitly knows your camera's pipeline: Extracting the inverse response curve from just two steps of the diffusion model itself beats dedicated single-image curve estimators—even generalizing to analog film curves.
Key Results
- Perspective Images (SI-HDR): UniHDR ranks first across all full-reference metrics against nine baselines, beating the runner-up (RDRE) by +4.5 dB in PU21-PSNR (27.93 vs. 23.43) and cutting FID from 14.50 (DiffHDR) down to 8.75. Highlight Quantile Error drops to 0.49 stops (vs. 0.82 for the best baseline).
- 360° Panorama Lighting: Achieves the lowest error on every sphere-rendering metric. On outdoor scenes, UniHDR predicts sun direction within 1.8° on average (vs. 5.7° for DiffHDR-Pano) and keeps diffuse lighting energy error to 0.40 stops outdoors and 0.28 stops indoors.
- Camera & Film Curves: Reaches a median absolute curve error of 0.25 stops (0.10 stops in curve shape) across 1,000 camera and film images, outperforming CRF-net (0.38) and SingleHDR (0.56).
Limitations and Future Work
Because UniHDR builds on a massive 20-billion-parameter diffusion transformer (plus a vision-language model to caption the input prompt), accuracy comes at a steep computational cost: reconstructing a single image takes roughly 10 seconds on an NVIDIA B200 GPU (12 transformer evaluations total). Additionally, on digital cameras, its self-estimated response curves sit slightly too bright (0.2 to 0.4 stops) in the mid-tones, and comparison against ground-truth curves in Table 4 shows another ~3.3 dB of panorama PSNR headroom remains if curve estimation is improved further. Future work is not explicitly discussed in the paper.
Summary updated