Image Dehazing as In-Context Tabular Inference
Abstract
Image dehazing is traditionally addressed through handcrafted physical priors or task-specific deep learning models, often requiring carefully designed architectures or extensive model training. Recent advances in tabular foundation models (TFMs), however, offer an alternative learning paradigm in which continuous relationships can be inferred directly from contextual examples without task-specific model training. Motivated by this capability, this paper investigates whether single-image dehazing can be effectively reformulated as an in-context tabular regression problem and introduces DehazeTab, a framework that estimates atmospheric transmission from structured image-patch representations. Specifically, overlapping patches extracted from hazy images are transformed into tabular samples using handcrafted haze-related descriptors, pretrained visual embeddings, or their hybrid combinations, while corresponding transmission patches are summarized as scalar regression targets. A pretrained TFM then performs in-context regression using labeled reference patches to predict transmission values for unseen images without any further fine-tuning. These predictions are spatially aggregated into a transmission map, refined through guided filtering, and incorporated into the atmospheric scattering model to recover haze-free images. Experiments on benchmark datasets demonstrate competitive restoration performance and reveal that physically motivated handcrafted features can outperform pretrained visual embeddings, while hybrid representations offer complementary benefits. Further analyses examine the effects of feature representations, patch selection, and contextual reference configurations on restoration quality. Beyond image dehazing, the findings highlight the potential of TFMs as an alternative paradigm for addressing low-level vision tasks through structured and in-context inference.
Figures & tables
| Type | Patch | Features | Target | ||||
| Context | 0.61 | 0.18 | 0.43 | 0.52 | 0.78 | ||
| 0.73 | 0.11 | 0.57 | 0.66 | 0.61 | |||
| 0.45 | 0.27 | 0.31 | 0.48 | 0.84 | |||
| Unseen | 0.68 | 0.15 | 0.49 | 0.58 | |||
| Type | Description | Research Question |
|---|---|---|
| (i) Handcrafted features | DCP, statistical, and texture features | Are physically motivated features effective for this reformulated task? |
| (ii) Local embedded features | Features from a pretrained CNN (e.g., ResNet) | Do local and hierarchical visual representations provide better transmission cues? |
| (iii) Global embedded features | Features from a pretrained ViT (e.g., ViT-Tiny) | Does global contextual information improve transmission estimation? |
| (iv) Hybrid features | Handcrafted + embedded features | Do handcrafted and learned features provide complementary information? |
| Method | Publication | Type | SOTS-Outdoor | HSTS | ||
|---|---|---|---|---|---|---|
| PSNR | SSIM | PSNR | SSIM | |||
| DCP [ 1 ] | TPAMI’11 | Prior | 18.38 | 0.819 | 17.01 | 0.803 |
| BCCR [ 22 ] | ICCV’13 | Prior | 15.71 | 0.769 | 15.21 | 0.747 |
| JEEF [ 23 ] | JVCIR’23 | Prior | 17.51 | 0.857 | 17.61 | 0.861 |
| RSVT [ 18 ] | PCS’24 | Prior | 22.31 | 0.903 | 21.53 | 0.887 |
| ZID [ 11 ] | TIP’20 | Zero-shot | 20.27 | 0.878 | 22.65 | 0.901 |
| Method | Type | Natural Images | |
|---|---|---|---|
| NIQE | BRISQUE | ||
| DCP [ 1 ] | Prior | 3.21 | 15.64 |
| BCCR [ 22 ] | Prior | 3.85 | 21.74 |
| RSVT [ 18 ] | Prior | 3.08 | 14.66 |
| USID-Net [ 24 ] | Unsupervised | 3.32 | 24.95 |
| SGDRL [ 27 ] | Unsupervised | 3.21 | 15.41 |
| Method | Sampling | SOTS-Outdoor | HSTS | ||
|---|---|---|---|---|---|
| PSNR | SSIM | PSNR | SSIM | ||
| DehazeTab H | Informative | 24.71 | 0.940 | 23.45 | 0.918 |
| DehazeTab CNN | Informative | 23.74 | 0.898 | 23.27 | 0.893 |
| DehazeTab ViT | Informative | 23.06 | 0.884 | 21.18 | 0.858 |
| DehazeTab Hybrid | Informative | 24.87 | 0.942 | 23.36 | 0.916 |
| DehazeTab H | Clustering | 24.85 | 0.940 | 23.29 | 0.908 |
| Method | #References | SOTS-Outdoor | HSTS | ||
|---|---|---|---|---|---|
| PSNR | SSIM | PSNR | SSIM | ||
| DehazeTab H | 5 | 24.71 | 0.940 | 23.45 | 0.918 |
| DehazeTab CNN | 5 | 23.74 | 0.898 | 23.27 | 0.893 |
| DehazeTab ViT | 5 | 23.06 | 0.884 | 21.18 | 0.858 |
| DehazeTab Hybrid | 5 | 24.87 | 0.942 | 23.36 | 0.916 |
| DehazeTab H | 7 | 24.79 | 0.942 | 23.38 | 0.919 |
| Method | #Patches | SOTS-Outdoor | HSTS | ||
|---|---|---|---|---|---|
| PSNR | SSIM | PSNR | SSIM | ||
| DehazeTab H | 50 | 24.33 | 0.934 | 22.82 | 0.900 |
| DehazeTab CNN | 50 | 23.49 | 0.890 | 23.36 | 0.883 |
| DehazeTab ViT | 50 | 22.96 | 0.885 | 20.89 | 0.851 |
| DehazeTab Hybrid | 50 | 24.36 | 0.934 | 23.10 | 0.902 |
| DehazeTab H | 100 | 24.71 | 0.940 | 23.45 | 0.918 |
| #Patches ( ) | 50 | 100 | 100 | 100 | 150 |
|---|---|---|---|---|---|
| #References ( ) | 5 | 5 | 7 | 10 | 5 |
| #Context Rows | 250 | 500 | 700 | 1000 | 750 |
| DehazeTab H,44 | 2.718 | 3.151 | 3.286 | 3.352 | 3.248 |
| DehazeTab CNN,128 | 1.930 | 2.683 | 3.978 | 5.854 | 4.238 |
| DehazeTab ViT,192 | 2.124 | 3.186 | 4.621 | 6.714 | 4.896 |
| DehazeTab Hybrid,172 | 3.155 | 4.338 | 5.601 | 7.879 | 5.677 |
Image Dehazing
Image dehazing restores clear scene details and colors from images obscured by haze, fog, or smoke.
See all 35 papers