sienna223 commited on
Commit
a778b67
·
verified ·
1 Parent(s): c7b9af9

upload dataset folder to repo

Browse files
Files changed (1) hide show
  1. README.md +168 -124
README.md CHANGED
@@ -8,156 +8,200 @@ tags:
8
  - transformers
9
  ---
10
 
11
- <p align="center">
12
- <img src="https://github.com/VectorSpaceLab/EditScore/assets/logo.png" width="65%">
13
- </p>
14
 
15
- <p align="center">
16
- <a href="https://vectorspacelab.github.io/EditScore"><img src="https://img.shields.io/badge/Project%20Page-EditScore-yellow" alt="project page"></a>
17
- <a href="https://arxiv.org/abs/2506.18871"><img src="https://img.shields.io/badge/arXiv%20paper-2506.18871-b31b1b.svg" alt="arxiv"></a>
18
- <a href="https://huggingface.co/collections/EditScore/editscore-68d8e27ee676981221db3cfe"><img src="https://img.shields.io/badge/EditScore-🤗-yellow" alt="model"></a>
19
- <a href="https://huggingface.co/datasets/EditScore/EditReward-Bench"><img src="https://img.shields.io/badge/EditReward--Bench-🤗-yellow" alt="dataset"></a>
20
- </p>
21
 
22
- <h4 align="center">
23
- <p>
24
- <a href=#-news>News</a> |
25
- <a href=#-quick-start>Quick Start</a> |
26
- <a href=#-usage-tips>Usage Tips</a> |
27
- <a href=#-limitations-and-suggestions>Limitations</a> |
28
- <a href=#-gradio-demo>Online Demos</a> |
29
- <a href=#%EF%B8%8F-citing-us>Citation</a>
30
- <p>
31
- </h4>
32
 
33
- **EditScore** is a series of state-of-the-art open-source reward models (7B–72B) designed to evaluate and enhance instruction-guided image editing.
34
- ## ✨ Highlights
35
- - **State-of-the-Art Performance**: Effectively matches the performance of leading proprietary VLMs. With a self-ensembling strategy, **our largest model surpasses even GPT-5** on our comprehensive benchmark, **EditReward-Bench**.
36
- - **A Reliable Evaluation Standard**: We introduce **EditReward-Bench**, the first public benchmark specifically designed for evaluating reward models in image editing, featuring 13 subtasks, 11 state-of-the-art editing models (*including proprietary models*) and expert human annotations.
37
- - **Simple and Easy-to-Use**: Get an accurate quality score for your image edits with just a few lines of code.
38
- - **Versatile Applications**: Ready to use as a best-in-class reranker to improve editing outputs, or as a high-fidelity reward signal for **stable and effective Reinforcement Learning (RL) fine-tuning**.
39
 
40
- ## 🔥 News
41
- - **2025-09-29**: We are excited to release **EditScore** and **EditReward-Bench**! Model weights and the benchmark dataset are now publicly available. You can access them on Hugging Face: [Models Collection](https://huggingface.co/collections/EditScore/editscore-68d8e27ee676981221db3cfe) and [Benchmark Dataset](https://huggingface.co/datasets/EditScore/EditReward-Bench), and on ModelScope: [Models Collection](https://www.modelscope.cn/collections/EditScore-8b0d53aa945d4e) and [Benchmark Dataset](https://www.modelscope.cn/datasets/EditScore/EditReward-Bench).
42
 
43
- ## 📖 Introduction
44
- While Reinforcement Learning (RL) holds immense potential for this domain, its progress has been severely hindered by the absence of a high-fidelity, efficient reward signal.
45
 
46
- To overcome this barrier, we provide a systematic, two-part solution:
47
 
48
- - **A Rigorous Evaluation Standard**: We first introduce **EditReward-Bench**, a new public benchmark for the direct and reliable evaluation of reward models. It features 13 diverse subtasks and expert human annotations, establishing a gold standard for measuring reward signal quality.
49
 
50
- - **A Powerful & Versatile Tool**: Guided by our benchmark, we developed the **EditScore** model series. Through meticulous data curation and an effective self-ensembling strategy, EditScore sets a new state of the art for open-source reward models, even surpassing the accuracy of leading proprietary VLMs.
51
 
52
- <p align="center">
53
- <img src="https://github.com/VectorSpaceLab/EditScore/assets/table_reward_model_results.png" width="95%">
54
- <br>
55
- <em>Benchmark results on EditReward-Bench.</em>
56
- </p>
 
 
57
 
58
- We demonstrate the practical utility of EditScore through two key applications:
59
 
60
- - **As a State-of-the-Art Reranker**: Use EditScore to perform Best-of-*N* selection and instantly improve the output quality of diverse editing models.
61
- - **As a High-Fidelity Reward for RL**: Use EditScore as a robust reward signal to fine-tune models via RL, enabling stable training and unlocking significant performance gains where general-purpose VLMs fail.
62
 
63
- This repository releases both the **EditScore** models and the **EditReward-Bench** dataset to facilitate future research in reward modeling, policy optimization, and AI-driven model improvement.
 
 
64
 
65
- <p align="center">
66
- <img src="https://github.com/VectorSpaceLab/EditScore/assets/figure_edit_results.png" width="95%">
67
- <br>
68
- <em>EditScore as a superior reward signal for image editing.</em>
69
- </p>
70
 
 
71
 
72
- ## 📌 TODO
73
- We are actively working on improving EditScore and expanding its capabilities. Here's what's next:
74
- - [ ] Release RL training code applying EditScore to OmniGen2.
75
- - [ ] Provide Best-of-N inference scripts for OmniGen2, Flux-dev-Kontext, and Qwen-Image-Edit.
76
 
77
- ## 🚀 Quick Start
78
 
79
- ### 🛠️ Environment Setup
80
 
81
- #### Recommended Setup
82
 
83
- ```bash
84
- # 1. Clone the repo
85
- git clone git@github.com:VectorSpaceLab/EditScore.git
86
- cd EditScore
87
 
88
- # 2. (Optional) Create a clean Python environment
89
- conda create -n editscore python=3.12
90
- conda activate editscore
91
 
92
- # 3. Install dependencies
93
- # 3.1 Install PyTorch (choose correct CUDA version)
94
- pip install torch==2.7.1 torchvision --extra-index-url https://download.pytorch.org/whl/cu126
95
 
96
- # 3.2 Install other required packages
97
- pip install -r requirements.txt
98
- ```
99
 
100
- #### 🌏 For users in Mainland China
101
 
102
- ```bash
103
- # Install PyTorch from a domestic mirror
104
- pip install torch==2.7.1 torchvision --index-url https://mirror.sjtu.edu.cn/pytorch-wheels/cu126
105
 
106
- # Install other dependencies from Tsinghua mirror
107
- pip install -r requirements.txt -i https://pypi.tuna.tsinghua.edu.cn/simple
108
- ```
109
 
110
- ---
111
 
112
- ### 🧪 Usage Example
113
- Using EditScore is straightforward. The model will be automatically downloaded from the Hugging Face Hub on its first run.
114
- ```python
115
- from PIL import Image
116
- from editscore import EditScore
117
-
118
- # Load the EditScore model. It will be downloaded automatically.
119
- # Replace with the specific model version you want to use.
120
- model_path = "Qwen/Qwen2.5-VL-7B-Instruct"
121
- lora_path = "EditScore/EditScore-7B"
122
-
123
- scorer = EditScore(
124
- backbone="qwen25vl", # set to "qwen25vl_vllm" for faster inference
125
- model_name_or_path=model_path,
126
- enable_lora=True,
127
- lora_path=lora_path,
128
- score_range=25,
129
- num_pass=1, # Increase for better performance via self-ensembling
130
- )
131
-
132
- input_image = Image.open("example_images/input.png")
133
- output_image = Image.open("example_images/output.png")
134
- instruction = "Adjust the background to a glass wall."
135
-
136
- result = scorer.evaluate([input_image, output_image], instruction)
137
- print(f"Edit Score: {result['final_score']}")
138
- # Expected output: A dictionary containing the final score and other details.
139
- ```
140
 
141
- ---
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
142
 
143
- ## 📊 Benchmark Your Image-Editing Reward Model
144
- We provide an evaluation script to benchmark reward models on **EditReward-Bench**. To evaluate your own custom reward model, simply create a scorer class with a similar interface and update the script.
145
- ```bash
146
- # This script will evaluate the default EditScore model on the benchmark
147
- bash evaluate.sh
148
-
149
- # Or speed up inference with VLLM
150
- bash evaluate_vllm.sh
151
- ```
152
-
153
- ## ❤️ Citing Us
154
- If you find this repository or our work useful, please consider giving a star ⭐ and citation 🦖, which would be greatly appreciated:
155
-
156
- ```bibtex
157
- @article{luo2025editscore,
158
- title={EditScore: Unlocking Online RL for Image Editing via High-Fidelity Reward Modeling},
159
- author={Xin Luo and Jiahao Wang and Chenyuan Wu and Shitao Xiao and Xiyan Jiang and Defu Lian and Jiajun Zhang and Dong Liu and Zheng Liu},
160
- journal={arXiv preprint arXiv:},
161
- year={2025}
162
- }
163
- ```
 
8
  - transformers
9
  ---
10
 
11
+ # Model Card for Model ID
 
 
12
 
13
+ <!-- Provide a quick summary of what the model is/does. -->
 
 
 
 
 
14
 
 
 
 
 
 
 
 
 
 
 
15
 
 
 
 
 
 
 
16
 
17
+ ## Model Details
 
18
 
19
+ ### Model Description
 
20
 
21
+ <!-- Provide a longer summary of what this model is. -->
22
 
 
23
 
 
24
 
25
+ - **Developed by:** [More Information Needed]
26
+ - **Funded by [optional]:** [More Information Needed]
27
+ - **Shared by [optional]:** [More Information Needed]
28
+ - **Model type:** [More Information Needed]
29
+ - **Language(s) (NLP):** [More Information Needed]
30
+ - **License:** [More Information Needed]
31
+ - **Finetuned from model [optional]:** [More Information Needed]
32
 
33
+ ### Model Sources [optional]
34
 
35
+ <!-- Provide the basic links for the model. -->
 
36
 
37
+ - **Repository:** [More Information Needed]
38
+ - **Paper [optional]:** [More Information Needed]
39
+ - **Demo [optional]:** [More Information Needed]
40
 
41
+ ## Uses
 
 
 
 
42
 
43
+ <!-- Address questions around how the model is intended to be used, including the foreseeable users of the model and those affected by the model. -->
44
 
45
+ ### Direct Use
 
 
 
46
 
47
+ <!-- This section is for the model use without fine-tuning or plugging into a larger ecosystem/app. -->
48
 
49
+ [More Information Needed]
50
 
51
+ ### Downstream Use [optional]
52
 
53
+ <!-- This section is for the model use when fine-tuned for a task, or when plugged into a larger ecosystem/app -->
 
 
 
54
 
55
+ [More Information Needed]
 
 
56
 
57
+ ### Out-of-Scope Use
 
 
58
 
59
+ <!-- This section addresses misuse, malicious use, and uses that the model will not work well for. -->
 
 
60
 
61
+ [More Information Needed]
62
 
63
+ ## Bias, Risks, and Limitations
 
 
64
 
65
+ <!-- This section is meant to convey both technical and sociotechnical limitations. -->
 
 
66
 
67
+ [More Information Needed]
68
 
69
+ ### Recommendations
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
70
 
71
+ <!-- This section is meant to convey recommendations with respect to the bias, risk, and technical limitations. -->
72
+
73
+ Users (both direct and downstream) should be made aware of the risks, biases and limitations of the model. More information needed for further recommendations.
74
+
75
+ ## How to Get Started with the Model
76
+
77
+ Use the code below to get started with the model.
78
+
79
+ [More Information Needed]
80
+
81
+ ## Training Details
82
+
83
+ ### Training Data
84
+
85
+ <!-- This should link to a Dataset Card, perhaps with a short stub of information on what the training data is all about as well as documentation related to data pre-processing or additional filtering. -->
86
+
87
+ [More Information Needed]
88
+
89
+ ### Training Procedure
90
+
91
+ <!-- This relates heavily to the Technical Specifications. Content here should link to that section when it is relevant to the training procedure. -->
92
+
93
+ #### Preprocessing [optional]
94
+
95
+ [More Information Needed]
96
+
97
+
98
+ #### Training Hyperparameters
99
+
100
+ - **Training regime:** [More Information Needed] <!--fp32, fp16 mixed precision, bf16 mixed precision, bf16 non-mixed precision, fp16 non-mixed precision, fp8 mixed precision -->
101
+
102
+ #### Speeds, Sizes, Times [optional]
103
+
104
+ <!-- This section provides information about throughput, start/end time, checkpoint size if relevant, etc. -->
105
+
106
+ [More Information Needed]
107
+
108
+ ## Evaluation
109
+
110
+ <!-- This section describes the evaluation protocols and provides the results. -->
111
+
112
+ ### Testing Data, Factors & Metrics
113
+
114
+ #### Testing Data
115
+
116
+ <!-- This should link to a Dataset Card if possible. -->
117
+
118
+ [More Information Needed]
119
+
120
+ #### Factors
121
+
122
+ <!-- These are the things the evaluation is disaggregating by, e.g., subpopulations or domains. -->
123
+
124
+ [More Information Needed]
125
+
126
+ #### Metrics
127
+
128
+ <!-- These are the evaluation metrics being used, ideally with a description of why. -->
129
+
130
+ [More Information Needed]
131
+
132
+ ### Results
133
+
134
+ [More Information Needed]
135
+
136
+ #### Summary
137
+
138
+
139
+
140
+ ## Model Examination [optional]
141
+
142
+ <!-- Relevant interpretability work for the model goes here -->
143
+
144
+ [More Information Needed]
145
+
146
+ ## Environmental Impact
147
+
148
+ <!-- Total emissions (in grams of CO2eq) and additional considerations, such as electricity usage, go here. Edit the suggested text below accordingly -->
149
+
150
+ Carbon emissions can be estimated using the [Machine Learning Impact calculator](https://mlco2.github.io/impact#compute) presented in [Lacoste et al. (2019)](https://arxiv.org/abs/1910.09700).
151
+
152
+ - **Hardware Type:** [More Information Needed]
153
+ - **Hours used:** [More Information Needed]
154
+ - **Cloud Provider:** [More Information Needed]
155
+ - **Compute Region:** [More Information Needed]
156
+ - **Carbon Emitted:** [More Information Needed]
157
+
158
+ ## Technical Specifications [optional]
159
+
160
+ ### Model Architecture and Objective
161
+
162
+ [More Information Needed]
163
+
164
+ ### Compute Infrastructure
165
+
166
+ [More Information Needed]
167
+
168
+ #### Hardware
169
+
170
+ [More Information Needed]
171
+
172
+ #### Software
173
+
174
+ [More Information Needed]
175
+
176
+ ## Citation [optional]
177
+
178
+ <!-- If there is a paper or blog post introducing the model, the APA and Bibtex information for that should go in this section. -->
179
+
180
+ **BibTeX:**
181
+
182
+ [More Information Needed]
183
+
184
+ **APA:**
185
+
186
+ [More Information Needed]
187
+
188
+ ## Glossary [optional]
189
+
190
+ <!-- If relevant, include terms and calculations in this section that can help readers understand the model or model card. -->
191
+
192
+ [More Information Needed]
193
+
194
+ ## More Information [optional]
195
+
196
+ [More Information Needed]
197
+
198
+ ## Model Card Authors [optional]
199
+
200
+ [More Information Needed]
201
+
202
+ ## Model Card Contact
203
+
204
+ [More Information Needed]
205
+ ### Framework versions
206
 
207
+ - PEFT 0.17.1