Update paper link and add usage instructions

#1
by nielsr HF Staff - opened
Files changed (1) hide show
  1. README.md +36 -18
README.md CHANGED
@@ -1,28 +1,30 @@
1
  ---
2
  base_model:
3
- - stabilityai/stable-diffusion-2
4
- pipeline_tag: image-to-image
5
  library_name: diffusers
 
6
  tags:
7
- - reflection-removal
8
- - reflection-separation
9
- - image-restoration
10
- - diffusion
11
- - stable-diffusion
12
- - cvpr2026
13
  ---
14
 
15
  # Reflection Separation from a Single Image via Joint Latent Diffusion
16
 
17
- Pre-trained checkpoints for the CVPR 2026 paper. Given a single photo taken
18
- through glass, the model jointly generates the **transmission** and
19
- **reflection** layers.
20
 
21
- - 🌐 Project page: https://brian90709.github.io/diff-reflection-separation/
22
- - πŸ’» Code: https://github.com/Brian90709/diff-reflection-separation-code
23
- - πŸ“„ Paper: arXiv (coming soon)
 
24
 
25
- [Zheng-Hui Huang](https://github.com/Brian90709), [Zhixiang Wang](https://lightchaserx.github.io), [Yu-Lun Liu](https://yulunalexliu.github.io), [Yung-Yu Chuang](https://www.csie.ntu.edu.tw/~cyy/)
 
26
 
27
  ## Files
28
 
@@ -34,13 +36,29 @@ through glass, the model jointly generates the **transmission** and
34
 
35
  ## Usage
36
 
37
- Download the weights into `./checkpoints`, then follow the
38
- [code repository](https://github.com/Brian90709/diff-reflection-separation-code):
 
 
 
 
 
 
 
 
 
39
 
40
  ```bash
41
  huggingface-cli download Brian9999/diff-reflection-separation --repo-type model --local-dir ./checkpoints
42
  ```
43
 
 
 
 
 
 
 
 
44
  ## Citation
45
 
46
  ```bibtex
@@ -50,4 +68,4 @@ huggingface-cli download Brian9999/diff-reflection-separation --repo-type model
50
  booktitle = {CVPR},
51
  year = {2026}
52
  }
53
- ```
 
1
  ---
2
  base_model:
3
+ - stabilityai/stable-diffusion-2
 
4
  library_name: diffusers
5
+ pipeline_tag: image-to-image
6
  tags:
7
+ - reflection-removal
8
+ - reflection-separation
9
+ - image-restoration
10
+ - diffusion
11
+ - stable-diffusion
12
+ - cvpr2026
13
  ---
14
 
15
  # Reflection Separation from a Single Image via Joint Latent Diffusion
16
 
17
+ This repository contains pre-trained checkpoints for the CVPR 2026 paper [Reflection Separation from a Single Image via Joint Latent Diffusion](https://huggingface.co/papers/2606.04107).
18
+
19
+ Given a single photo taken through glass, the model jointly generates the **transmission** (reflection-free) and **reflection** layers using a fine-tuned Stable Diffusion 2 architecture.
20
 
21
+ - **Authors:** Zheng-Hui Huang, Zhixiang Wang, Yu-Lun Liu, and Yung-Yu Chuang
22
+ - 🌐 **Project page:** [https://brian90709.github.io/diff-reflection-separation/](https://brian90709.github.io/diff-reflection-separation/)
23
+ - πŸ’» **Code:** [https://github.com/Brian90709/diff-reflection-separation-code](https://github.com/Brian90709/diff-reflection-separation-code)
24
+ - πŸ“„ **Paper:** [arXiv:2606.04107](https://arxiv.org/abs/2606.04107)
25
 
26
+ ## Method Overview
27
+ Single-image reflection separation is challenging under conditions like glare or weak reflections. This method leverages generative diffusion priors to simultaneously generate transmission and reflection layers through a unified diffusion model, incorporating a novel cross-layer self-attention mechanism for better feature disentanglement and a disjoint sampling strategy to reduce interference between layers.
28
 
29
  ## Files
30
 
 
36
 
37
  ## Usage
38
 
39
+ ### Installation
40
+ Clone the [official repository](https://github.com/Brian90709/diff-reflection-separation-code) and set up the environment:
41
+
42
+ ```bash
43
+ conda create -y -n diffrs python=3.10 && conda activate diffrs
44
+ pip install torch==2.5.1 torchvision==0.20.1 --index-url https://download.pytorch.org/whl/cu121
45
+ pip install -r requirements.txt
46
+ ```
47
+
48
+ ### Inference
49
+ Download the weights into `./checkpoints`:
50
 
51
  ```bash
52
  huggingface-cli download Brian9999/diff-reflection-separation --repo-type model --local-dir ./checkpoints
53
  ```
54
 
55
+ Run the inference script on a directory of images:
56
+
57
+ ```bash
58
+ python infer_layersep.py --input_dir ./samples --save_to_dir ./outputs
59
+ ```
60
+ Each input yields three files: `*_transmission.png` (reflection-free result), `*_reflection.png`, and `*_ori_transmission.png` (transmission before CFW refinement).
61
+
62
  ## Citation
63
 
64
  ```bibtex
 
68
  booktitle = {CVPR},
69
  year = {2026}
70
  }
71
+ ```