Skip to content

[WACV 2025 oral] All-in-One Image Compression and Restoration.

Notifications You must be signed in to change notification settings

ZeldaM1/All-in-one

Repository files navigation

All-in-One Image Compression and Restoration

Huimin Zeng, Jiacheng Li, Ziqiang Zheng, Zhiwei Xiong

🔥 Update

🔥 2025/3/9: We provide benchmark for all-in-one image restoration.

2025/3/8: We release code and checkpoint for this project.

2025/1/20: Our All-in-One was selected as Oral presentation.

2024/10/28: All-in-One was accepted to WACV 2025

Introduction

Visual images corrupted by various types and levels of degradations are commonly encountered in practical image compression. However, most existing image compression methods are tailored for clean images, therefore struggling to achieve satisfying results on these images. Joint compression and restoration methods typically focus on a single type of degradation and fail to address a variety of degradations in practice. To this end, we propose a unified framework for all-in-one image compression and restoration, which incorporates the image restoration capability against various degradations into the process of image compression. Extensive experiments demonstrate the following merits of our model: 1) superior rate-distortion (RD) performance on various degraded inputs while preserving the performance on clean data; 2) strong generalization ability to real-world and unseen scenarios; 3) higher computing efficiency over compared methods.

Overview

The key challenges involve distinguishing authentic image content from degradations, and flexibly eliminating various degradations without prior knowledge. Specifically, the proposed framework approaches these challenges from two perspectives: i.e., content information aggregation, and degradation representation aggregation. image image image

Dataset

Setting Degradation Train Test
Weather Haze-Snow-Rain RESIDE-CSD-Rain1400 RESIDE-CSD-Rain1400
Gaussian Noise σ = 15-25-50 Open Images Kodak
  • The adopted datasets can be found above.
  • Download all the datasets and structure the data as follows:
data
|-- all-in-one-test
|   |-- CSD_test
|   |-- SOTS_outdoor
|   |-- rain1400_test
|   |-- Kodak_24
|   `-- all_in_one.json
`-- all-in-one-train
    |-- CSD_train
    |-- OTS_outdoor
    |-- rain1400_train
    |-- open_images
    |-- all_in_one.json
    `--  description_v2.json

Environment

We provide docker image to prepare the running enviroment. The docker image can be obtained using the following command:

docker pull registry.cn-hangzhou.aliyuncs.com/zenghuimin/zhm_docker:py37-torch18
pip install pytorch_msssim scipy mmengine timm==0.6.7

Test

  • Clean images
bash scripts/test_script_clean.sh 
  • The Weather Setting
bash scripts/test_script_weather.sh 
  • The Gaussian Noise Setting
bash scripts/test_script_noise.sh 

We provide pre-trained checkpoint on GoogleDrive. Please download and put it at ./ckpt.

Acknowledgement

This repository is partly built on DCVC-FM and MMagic. We appreciate their authors for creating these brilliant works and sharing codes with the community.

Citation

If you find our All-in-One useful, please star ⭐ this repository and consider citing:

@InProceedings{Zeng_2025_WACV,
    author    = {Zeng, Huimin and Li, Jiacheng and Zheng, Ziqiang and Xiong, Zhiwei},
    title     = {All-in-One Image Compression and Restoration},
    booktitle = {Proceedings of the Winter Conference on Applications of Computer Vision (WACV)},
    month     = {February},
    year      = {2025},
    pages     = {609-619}
}

About

[WACV 2025 oral] All-in-One Image Compression and Restoration.

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published