---
title: maxim-s2-dehazing-sots-indoor
canonical_url: "https://www.modelscope.cn/models/google/maxim-s2-dehazing-sots-indoor"
md_url: "https://www.modelscope.cn/models/google/maxim-s2-dehazing-sots-indoor.md"
repository: google/maxim-s2-dehazing-sots-indoor
last_updated: 2025-04-22
license: apache-2.0
pipeline_tag: image-to-image
tasks:
  - image-to-image
library_name:
  - pytorch
frameworks:
  - pytorch
language:
  - en
downloads: 421
stars: 0
tags:
  - vision
  - maxim
  - image-to-image
---

# maxim-s2-dehazing-sots-indoor

> maxim-s2-dehazing-sots-indoor - google 在 ModelScope 开源的模型。MAXIM pre-trained on RESIDE-Indoor for image dehazing

google/maxim-s2-dehazing-sots-indoor 是 ModelScope 魔搭社区上的image-to-image模型，采用 apache-2.0 许可。

- **Repository**: google/maxim-s2-dehazing-sots-indoor
- **License**: apache-2.0
- **Tasks**: image-to-image
- **Tags**: vision, maxim, image-to-image
- **Downloads**: 421
- **Stars**: 0
- **Last updated**: 2025-04-22

Source: https://www.modelscope.cn/models/google/maxim-s2-dehazing-sots-indoor

---

# MAXIM pre-trained on RESIDE-Indoor for image dehazing 

MAXIM model pre-trained for image dehazing. It was introduced in the paper [MAXIM: Multi-Axis MLP for Image Processing](https://arxiv.org/abs/2201.02973) by Zhengzhong Tu, Hossein Talebi, Han Zhang, Feng Yang, Peyman Milanfar, Alan Bovik, Yinxiao Li and first released in [this repository](https://github.com/google-research/maxim). 

Disclaimer: The team releasing MAXIM did not write a model card for this model so this model card has been written by the Hugging Face team.

## Model description

MAXIM introduces a shared MLP-based backbone for different image processing tasks such as image deblurring, deraining, denoising, dehazing, low-light image enhancement, and retouching. The following figure depicts the main components of MAXIM:

![](https://github.com/google-research/maxim/raw/main/maxim/images/overview.png)

## Training procedure and results

The authors didn't release the training code. For more details on how the model was trained, refer to the [original paper](https://arxiv.org/abs/2201.02973). 

As per the [table](https://github.com/google-research/maxim#results-and-pre-trained-models), the model achieves a PSNR of 38.11 and an SSIM of 0.991. 

## Intended uses & limitations

You can use the raw model for image dehazing tasks. 

The model is [officially released in JAX](https://github.com/google-research/maxim). It was ported to TensorFlow in [this repository](https://github.com/sayakpaul/maxim-tf). 

### How to use

Here is how to use this model:

```python
from huggingface_hub import from_pretrained_keras
from PIL import Image

import tensorflow as tf
import numpy as np
import requests

url = "https://github.com/sayakpaul/maxim-tf/raw/main/images/Dehazing/input/1440_10.png"
image = Image.open(requests.get(url, stream=True).raw)
image = np.array(image)
image = tf.convert_to_tensor(image)
image = tf.image.resize(image, (256, 256))

model = from_pretrained_keras("google/maxim-s2-dehazing-sots-indoor")
predictions = model.predict(tf.expand_dims(image, 0))
```

For a more elaborate prediction pipeline, refer to [this Colab Notebook](https://colab.research.google.com/github/sayakpaul/maxim-tf/blob/main/notebooks/inference-dynamic-resize.ipynb). 

### Citation

```bibtex
@article{tu2022maxim,
  title={MAXIM: Multi-Axis MLP for Image Processing},
  author={Tu, Zhengzhong and Talebi, Hossein and Zhang, Han and Yang, Feng and Milanfar, Peyman and Bovik, Alan and Li, Yinxiao},
  journal={CVPR},
  year={2022},
}
```
