Improve model card: add metadata, paper, project page, code, and usage details

#1
by nielsr HF Staff - opened
Files changed (1) hide show
  1. README.md +114 -1
README.md CHANGED
@@ -1 +1,114 @@
1
- arxiv.org/abs/2511.20614
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ ---
2
+ license: cc-by-nc-4.0
3
+ pipeline_tag: image-to-image
4
+ library_name: diffusers
5
+ ---
6
+
7
+ # The Consistency Critic: Correcting Inconsistencies in Generated Images via Reference-Guided Attentive Alignment
8
+
9
+ This repository hosts **ImageCritic**, a reference-guided post-editing approach designed to correct inconsistencies in generated images. It aims to solve the inconsistency problem in generated images by applying attention alignment and a detail encoder, providing significant improvements over existing methods in various customized generation scenarios.
10
+
11
+ The model was presented in the paper [The Consistency Critic: Correcting Inconsistencies in Generated Images via Reference-Guided Attentive Alignment](https://huggingface.co/papers/2511.20614).
12
+
13
+ * πŸ“š [Paper (arXiv)](https://arxiv.org/abs/2511.20614)
14
+ * 🌐 [Project Page](https://ouyangziheng.github.io/ImageCritic-Page/)
15
+ * πŸ’» [Code (GitHub)](https://github.com/HVision-NKU/ImageCritic)
16
+ * πŸ€— [Hugging Face Space Demo](https://huggingface.co/spaces/ziheng1234/ImageCritic)
17
+ * πŸ“¦ [Hugging Face Dataset](https://huggingface.co/datasets/ziheng1234/Critic-10K)
18
+
19
+ <img src='https://github.com/HVision-NKU/ImageCritic/raw/main/figure/teaser.png' width='100%' />
20
+
21
+ ## πŸ–ΌοΈ Visual Results
22
+
23
+ ImageCritic can effectively resolve detail-related issues in various customized generation scenarios, providing significant improvements over existing methods.
24
+
25
+ <img src='https://github.com/HVision-NKU/ImageCritic/raw/main/figure/compare.png' width='100%' />
26
+
27
+ ## πŸ”§ Dependencies and Installation
28
+
29
+ We recommend using Python 3.10 and PyTorch with CUDA support. To set up the environment:
30
+
31
+ ```bash
32
+ # Create a new conda environment
33
+ conda create -n imagecritic python=3.10
34
+ conda activate imagecritic
35
+
36
+ # Install other dependencies
37
+ pip install -r requirements.txt
38
+ ```
39
+
40
+ ## ⚑ Quick Inference
41
+ ### Tips
42
+ Due to copyright issues, we have embedded the download of the kontext model weights in the inference code below, You can run following inference code directly.
43
+ If you have already downloaded the corresponding model, you can comment out the related code and directly replace the inference path.
44
+
45
+ ### Single case inference
46
+ ```bash
47
+ python infer.py
48
+ ```
49
+
50
+ ### Local Gradio Demo
51
+ ```bash
52
+ python app.py
53
+ ```
54
+
55
+ ### Single Model Download
56
+ You can download the base model FLUX.1-Kontext-dev directly from [Hugging Face](https://huggingface.co/black-forest-labs/FLUX.1-Kontext-dev).
57
+
58
+ Alternatively, you can download it via the following command
59
+ (⚠️ Remember to replace `your_hf_token` in the script with your actual Hugging Face access token):
60
+ ```bash
61
+ python ./download_kontext.py
62
+ ```
63
+
64
+ You can download our ImageCritic directly from [Hugging Face](https://huggingface.co/ziheng1234/ImageCritic).
65
+
66
+ Alternatively, you can download it via following code:
67
+
68
+ ```bash
69
+ python ./download_imageCritic.py
70
+ ```
71
+ Or using Git:
72
+ ```bash
73
+ git lfs install
74
+ git clone https://huggingface.co/ziheng1234/ImageCritic
75
+ ```
76
+
77
+ ## Dataset Download
78
+
79
+ You can download our training dataset Critic-10K directly from [Hugging Face](https://huggingface.co/datasets/ziheng1234/Critic-10K).
80
+
81
+ Alternatively, you can download it via Python:
82
+
83
+ ```bash
84
+ python /raid/users/oyzh/ImageCritic/download_dataset.py
85
+ ```
86
+ Or using Git:
87
+ ```bash
88
+ git lfs install
89
+ git clone https://huggingface.co/datasets/ziheng1234/Critic-10K
90
+ ```
91
+
92
+ ### Online HuggingFace Demo
93
+ You can try ImageCritic demo on [HuggingFace](https://huggingface.co/spaces/ziheng1234/ImageCritic).
94
+
95
+ ## Citation
96
+
97
+ If ImageCritic is helpful, please help to ⭐ the repo.
98
+
99
+ If you find this project useful for your research, please consider citing our paper:
100
+ ```bibtex
101
+ @article{ouyang2025consistency,
102
+ title={The Consistency Critic: Correcting Inconsistencies in Generated Images via Reference-Guided Attentive Alignment},
103
+ author={Ouyang, Ziheng and Song, Yiren and Liu, Yaoli and Zhu, Shihao and Hou, Qibin and Cheng, Ming-Ming and Shou, Mike Zheng},
104
+ journal={arXiv preprint arXiv:2511.20614},
105
+ year={2025}
106
+ }
107
+ ```
108
+
109
+ ## πŸ“§ Contact
110
+ If you have any comments or questions, please [open a new issue](https://github.com/HVision-NKU/ImageCritic/issues) or contact [Ziheng Ouyang](mailto:[email protected])
111
+
112
+ ## License
113
+ Licensed under a [Creative Commons Attribution-NonCommercial 4.0 International](https://creativecommons.org/licenses/by-nc/4.0/) for Non-commercial use only.
114
+ Any commercial use should get formal permission first.