ZHANGYUXUAN-zR commited on
Commit
2c7e504
·
verified ·
1 Parent(s): 6c82a9e

Add files using upload-large-folder tool

Browse files
parse/dev/08Yk-n5l2Al/08Yk-n5l2Al_content_list.json ADDED
@@ -0,0 +1,1777 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ [
2
+ {
3
+ "type": "text",
4
+ "text": "Photorealistic Text-to-Image Diffusion Models with Deep Language Understanding ",
5
+ "text_level": 1,
6
+ "bbox": [
7
+ 222,
8
+ 122,
9
+ 777,
10
+ 172
11
+ ],
12
+ "page_idx": 0
13
+ },
14
+ {
15
+ "type": "text",
16
+ "text": "Chitwan Saharia∗, William Chan∗, Saurabh Saxena†, Lala Li†, Jay Whang†, Emily Denton, Seyed Kamyar Seyed Ghasemipour, Burcu Karagol Ayan, S. Sara Mahdavi, Raphael Gontijo-Lopes, Tim Salimans, Jonathan Ho†, David J Fleet†‡, Mohammad Norouzi∗ ",
17
+ "text_level": 1,
18
+ "bbox": [
19
+ 233,
20
+ 224,
21
+ 766,
22
+ 282
23
+ ],
24
+ "page_idx": 0
25
+ },
26
+ {
27
+ "type": "text",
28
+ "text": "{sahariac,williamchan,mnorouzi}@google.com {srbs,lala,jwhang,jonathanho,davidfleet}@google.com ",
29
+ "bbox": [
30
+ 281,
31
+ 290,
32
+ 717,
33
+ 318
34
+ ],
35
+ "page_idx": 0
36
+ },
37
+ {
38
+ "type": "text",
39
+ "text": "Google Research, Brain Team Toronto, Ontario, Canada ",
40
+ "bbox": [
41
+ 400,
42
+ 324,
43
+ 596,
44
+ 352
45
+ ],
46
+ "page_idx": 0
47
+ },
48
+ {
49
+ "type": "text",
50
+ "text": "Abstract ",
51
+ "text_level": 1,
52
+ "bbox": [
53
+ 462,
54
+ 387,
55
+ 535,
56
+ 405
57
+ ],
58
+ "page_idx": 0
59
+ },
60
+ {
61
+ "type": "text",
62
+ "text": "We present Imagen, a text-to-image diffusion model with an unprecedented degree of photorealism and a deep level of language understanding. Imagen builds on the power of large transformer language models in understanding text and hinges on the strength of diffusion models in high-fidelity image generation. Our key discovery is that generic large language models (e.g. T5), pretrained on text-only corpora, are surprisingly effective at encoding text for image synthesis: increasing the size of the language model in Imagen boosts both sample fidelity and image-text alignment much more than increasing the size of the image diffusion model. Imagen achieves a new state-of-the-art FID score of 7.27 on the COCO dataset, without ever training on COCO, and human raters find Imagen samples to be on par with the COCO data itself in image-text alignment. To assess text-to-image models in greater depth, we introduce DrawBench, a comprehensive and challenging benchmark for text-to-image models. With DrawBench, we compare Imagen with recent methods including VQ-GAN $^ +$ CLIP, Latent Diffusion Models, GLIDE and DALL-E 2, and find that human raters prefer Imagen over other models in side-by-side comparisons, both in terms of sample quality and image-text alignment. ",
63
+ "bbox": [
64
+ 233,
65
+ 417,
66
+ 766,
67
+ 638
68
+ ],
69
+ "page_idx": 0
70
+ },
71
+ {
72
+ "type": "text",
73
+ "text": "1 Introduction ",
74
+ "text_level": 1,
75
+ "bbox": [
76
+ 174,
77
+ 659,
78
+ 310,
79
+ 675
80
+ ],
81
+ "page_idx": 0
82
+ },
83
+ {
84
+ "type": "text",
85
+ "text": "Multimodal learning has come into prominence recently, with text-to-image synthesis [55, 12, 59] and image-text contrastive learning [51, 32, 77] at the forefront. These models have transformed the research community and captured widespread public attention with creative image generation [22, 56] and editing applications [21, 43, 36]. To pursue this research direction further, we introduce Imagen, a text-to-image diffusion model that combines the power of transformer language models (LMs) [15, 54] with high-fidelity diffusion models [28, 29, 16, 43] to deliver an unprecedented degree of photorealism and a deep level of language understanding in text-to-image synthesis. In contrast to prior work that uses only image-text data for model training [e.g., 55, 43], the key finding behind Imagen is that text embeddings from large LMs [54, 15], pretrained on text-only corpora, are remarkably effective for text-to-image synthesis. See Fig. 1 for select samples. ",
86
+ "bbox": [
87
+ 174,
88
+ 683,
89
+ 825,
90
+ 820
91
+ ],
92
+ "page_idx": 0
93
+ },
94
+ {
95
+ "type": "text",
96
+ "text": "Imagen comprises a frozen T5-XXL [54] encoder to map input text into a sequence of embeddings and a $6 4 { \\times } 6 4$ image diffusion model, followed by two super-resolution diffusion models for generating ",
97
+ "bbox": [
98
+ 174,
99
+ 827,
100
+ 821,
101
+ 854
102
+ ],
103
+ "page_idx": 0
104
+ },
105
+ {
106
+ "type": "image",
107
+ "img_path": "images/0ff9e780ce44befdb2c77a49a7ce0086b5f308273c92ede52962e1ab8b00c749.jpg",
108
+ "image_caption": [
109
+ "Sprouts in the shape of text ‘Imagen’ coming out of a fairytale book. "
110
+ ],
111
+ "image_footnote": [],
112
+ "bbox": [
113
+ 27,
114
+ 18,
115
+ 339,
116
+ 258
117
+ ],
118
+ "page_idx": 1
119
+ },
120
+ {
121
+ "type": "image",
122
+ "img_path": "images/a90d2875f0f71a7880a4f9999f2959e6b84d99379874084fa1d032099b85aa10.jpg",
123
+ "image_caption": [
124
+ "A photo of a Shiba Inu dog with a backpack riding a bike. It is wearing sunglasses and a beach hat. "
125
+ ],
126
+ "image_footnote": [],
127
+ "bbox": [
128
+ 343,
129
+ 18,
130
+ 653,
131
+ 258
132
+ ],
133
+ "page_idx": 1
134
+ },
135
+ {
136
+ "type": "image",
137
+ "img_path": "images/3c198b3eadeb94945246663ef4c6dae0b989e7d97952f7ea2332f3dd947bcde4.jpg",
138
+ "image_caption": [
139
+ "A high contrast portrait of a very happy fuzzy panda dressed as a chef in a high end kitchen making dough. There is a painting of flowers on the wall behind him. "
140
+ ],
141
+ "image_footnote": [],
142
+ "bbox": [
143
+ 658,
144
+ 18,
145
+ 970,
146
+ 258
147
+ ],
148
+ "page_idx": 1
149
+ },
150
+ {
151
+ "type": "image",
152
+ "img_path": "images/48b8a8522a41cc9c73e62e7f2ef771576bd5ac051adf46b5d65ced3cc02a49c2.jpg",
153
+ "image_caption": [
154
+ "Teddy bears swimming at the Olympics $4 0 0 \\mathrm { m }$ Butterfly event. "
155
+ ],
156
+ "image_footnote": [],
157
+ "bbox": [
158
+ 27,
159
+ 310,
160
+ 338,
161
+ 550
162
+ ],
163
+ "page_idx": 1
164
+ },
165
+ {
166
+ "type": "image",
167
+ "img_path": "images/33f07cefc0579a8976e7d3fbc51c35dce1587f32c88f4a9b37bb99ad93d694af.jpg",
168
+ "image_caption": [
169
+ "A cute corgi lives in a house made out of sushi. "
170
+ ],
171
+ "image_footnote": [],
172
+ "bbox": [
173
+ 343,
174
+ 310,
175
+ 653,
176
+ 550
177
+ ],
178
+ "page_idx": 1
179
+ },
180
+ {
181
+ "type": "image",
182
+ "img_path": "images/3c999c04be104204ac5db8d506fc8543bd0ddabd898e52be09dbdeed78969e1b.jpg",
183
+ "image_caption": [
184
+ "A cute sloth holding a small treasure chest. A bright golden glow is coming from the chest. "
185
+ ],
186
+ "image_footnote": [],
187
+ "bbox": [
188
+ 660,
189
+ 310,
190
+ 970,
191
+ 550
192
+ ],
193
+ "page_idx": 1
194
+ },
195
+ {
196
+ "type": "image",
197
+ "img_path": "images/b389ccbd42808c75b83b8659d3c6c74986ebf665df48de4d72c8459bdaa64aec.jpg",
198
+ "image_caption": [],
199
+ "image_footnote": [],
200
+ "bbox": [
201
+ 26,
202
+ 588,
203
+ 339,
204
+ 829
205
+ ],
206
+ "page_idx": 1
207
+ },
208
+ {
209
+ "type": "image",
210
+ "img_path": "images/d8c08f121dd94ec09f2a8e0ac7013aa4c8f7b7d8cfaa8cc36770a78f2e927d33.jpg",
211
+ "image_caption": [
212
+ "A dragon fruit wearing karate belt in the snow. "
213
+ ],
214
+ "image_footnote": [],
215
+ "bbox": [
216
+ 343,
217
+ 588,
218
+ 653,
219
+ 828
220
+ ],
221
+ "page_idx": 1
222
+ },
223
+ {
224
+ "type": "image",
225
+ "img_path": "images/88f4635cd39ea7c005b308b126b0c8dca5d983c580eb7850d54a9a7d381ab46d.jpg",
226
+ "image_caption": [
227
+ "A strawberry mug filled with white sesame seeds. The mug is floating in a dark chocolate sea. "
228
+ ],
229
+ "image_footnote": [],
230
+ "bbox": [
231
+ 660,
232
+ 588,
233
+ 970,
234
+ 828
235
+ ],
236
+ "page_idx": 1
237
+ },
238
+ {
239
+ "type": "text",
240
+ "text": "A brain riding a rocketship heading towards the moon. ",
241
+ "bbox": [
242
+ 27,
243
+ 835,
244
+ 339,
245
+ 848
246
+ ],
247
+ "page_idx": 1
248
+ },
249
+ {
250
+ "type": "text",
251
+ "text": "Figure 1: Select $1 0 2 4 \\times 1 0 2 4$ Imagen samples for various text inputs. We only include photorealistic images in this figure and leave artistic content to the Appendix, since generating photorealistic images is more challenging from a technical point of view. Figs. A.1 to A.3 show more samples. ",
252
+ "bbox": [
253
+ 173,
254
+ 869,
255
+ 825,
256
+ 912
257
+ ],
258
+ "page_idx": 1
259
+ },
260
+ {
261
+ "type": "text",
262
+ "text": "$2 5 6 \\times 2 5 6$ and $1 0 2 4 \\times 1 0 2 4$ images (see Fig. A.4). All diffusion models are conditioned on the text embedding sequence and use classifier-free guidance [27]. Imagen relies on new sampling techniques to allow usage of large guidance weights without sample quality degradation observed in prior work, resulting in images with higher fidelity and better image-text alignment than previously possible. ",
263
+ "bbox": [
264
+ 174,
265
+ 90,
266
+ 825,
267
+ 147
268
+ ],
269
+ "page_idx": 2
270
+ },
271
+ {
272
+ "type": "text",
273
+ "text": "While conceptually simple and easy to train, Imagen yields surprisingly strong results. Imagen outperforms other methods on COCO [38] with zero-shot FID-30K of 7.27, significantly outperforming prior work such as GLIDE [43] (at 12.4) and the concurrent work of DALL-E 2 [56] (at 10.4). Our zero-shot FID score is also better than state-of-the-art models trained on COCO, e.g., Make-A-Scene [22] (at 7.6). Additionally, human raters indicate that generated samples from Imagen are on-par in image-text alignment to the reference images on COCO captions. ",
274
+ "bbox": [
275
+ 174,
276
+ 154,
277
+ 825,
278
+ 237
279
+ ],
280
+ "page_idx": 2
281
+ },
282
+ {
283
+ "type": "text",
284
+ "text": "We introduce DrawBench, a new structured suite of text prompts for text-to-image evaluation. DrawBench enables deeper insights through a multi-dimensional evaluation of text-to-image models, with text prompts designed to probe different semantic properties of models. These include compositionality, cardinality, spatial relations, the ability to handle complex text prompts or prompts with rare words, and they include creative prompts that push the limits of models’ ability to generate highly implausible scenes well beyond the scope of the training data. With DrawBench, extensive human evaluation shows that Imagen outperforms other recent methods [59, 12, 56] by a significant margin. We further demonstrate some of the clear advantages of the use of large pre-trained language models [54] over multi-modal embeddings such as CLIP [51] as a text encoder for Imagen. ",
285
+ "bbox": [
286
+ 173,
287
+ 242,
288
+ 825,
289
+ 367
290
+ ],
291
+ "page_idx": 2
292
+ },
293
+ {
294
+ "type": "text",
295
+ "text": "Key contributions of the paper include: ",
296
+ "bbox": [
297
+ 176,
298
+ 373,
299
+ 429,
300
+ 388
301
+ ],
302
+ "page_idx": 2
303
+ },
304
+ {
305
+ "type": "text",
306
+ "text": "1. We discover that large frozen language models trained only on text data are surprisingly very effective text encoders for text-to-image generation, and that scaling the size of frozen text encoder improves sample quality significantly more than scaling the size of image diffusion model. \n2. We introduce dynamic thresholding, a new diffusion sampling technique to leverage high guidance weights and generating more photorealistic and detailed images than previously possible. \n3. We highlight several important diffusion architecture design choices and propose Efficient U-Net, a new architecture variant which is simpler, converges faster and is more memory efficient. \n4. We achieve a new state-of-the-art COCO FID of 7.27. Human raters find Imagen to be on-par with the reference images in terms of image-text alignment. \n5. We introduce DrawBench, a new comprehensive and challenging evaluation benchmark for the text-to-image task. On DrawBench human evaluation, we find Imagen to outperform all other work, including the concurrent work of DALL-E 2 [56]. ",
307
+ "bbox": [
308
+ 176,
309
+ 395,
310
+ 826,
311
+ 560
312
+ ],
313
+ "page_idx": 2
314
+ },
315
+ {
316
+ "type": "text",
317
+ "text": "2 Imagen ",
318
+ "text_level": 1,
319
+ "bbox": [
320
+ 174,
321
+ 570,
322
+ 269,
323
+ 587
324
+ ],
325
+ "page_idx": 2
326
+ },
327
+ {
328
+ "type": "text",
329
+ "text": "Imagen consists of a text encoder that maps text to a sequence of embeddings and a cascade of conditional diffusion models that map these embeddings to images of increasing resolutions (see Fig. A.4). In the following subsections, we describe each of these components in detail. ",
330
+ "bbox": [
331
+ 176,
332
+ 590,
333
+ 823,
334
+ 632
335
+ ],
336
+ "page_idx": 2
337
+ },
338
+ {
339
+ "type": "text",
340
+ "text": "2.1 Pretrained text encoders ",
341
+ "text_level": 1,
342
+ "bbox": [
343
+ 174,
344
+ 637,
345
+ 383,
346
+ 651
347
+ ],
348
+ "page_idx": 2
349
+ },
350
+ {
351
+ "type": "text",
352
+ "text": "Text-to-image models need powerful semantic text encoders to capture the complexity and compositionality of arbitrary natural language text inputs. Text encoders trained on paired image-text data are standard in current text-to-image models; they can be trained from scratch [43, 55] or pretrained on image-text data [56] (e.g., CLIP [51]). The image-text training objectives suggest that these text encoders may encode visually semantic and meaningful representations especially relevant for the text-to-image generation task. Large language models can be another models of choice to encode text for text-to-image generation. Recent progress in large language models (e.g., BERT [15], GPT [49, 50, 7], T5 [54]) have led to leaps in textual understanding and generative capabilities. Language models are trained on text only corpus significantly larger than paired image-text data, thus being exposed to a very rich and wide distribution of text. These models are also generally much larger than text encoders in current image-text models [51, 32, 83] (e.g. PaLM [11] has 540B parameters, while CoCa [83] has a $\\approx 1 \\mathbf { B }$ parameter text encoder). ",
353
+ "bbox": [
354
+ 173,
355
+ 656,
356
+ 825,
357
+ 821
358
+ ],
359
+ "page_idx": 2
360
+ },
361
+ {
362
+ "type": "text",
363
+ "text": "It thus becomes natural to explore both families of text encoders for the text-to-image task. Imagen explores pretrained text encoders: BERT [15], T5 [53] and CLIP [48]. For simplicity, we freeze the weights of these text encoders. Freezing has several advantages such as offline computation of embeddings, resulting in negligible computation or memory footprint during training of the textto-image model. In our work, we find that there is a clear conviction that scaling the text encoder size improves the quality of text-to-image generation. We also find that while T5-XXL and CLIP text encoders perform similarly on simple benchmarks such as MS-COCO, human evaluators prefer T5-XXL encoders over CLIP text encoders in both image-text alignment and image fidelity on DrawBench, a set of challenging and compositional prompts. We refer the reader to Section 4.4 for summary of our findings, and Appendix D.1 for detailed ablations. ",
364
+ "bbox": [
365
+ 174,
366
+ 828,
367
+ 825,
368
+ 911
369
+ ],
370
+ "page_idx": 2
371
+ },
372
+ {
373
+ "type": "text",
374
+ "text": "",
375
+ "bbox": [
376
+ 174,
377
+ 90,
378
+ 825,
379
+ 147
380
+ ],
381
+ "page_idx": 3
382
+ },
383
+ {
384
+ "type": "text",
385
+ "text": "2.2 Diffusion models and classifier-free guidance ",
386
+ "text_level": 1,
387
+ "bbox": [
388
+ 176,
389
+ 166,
390
+ 524,
391
+ 181
392
+ ],
393
+ "page_idx": 3
394
+ },
395
+ {
396
+ "type": "text",
397
+ "text": "Here we give a brief introduction to diffusion models; a precise description is in Appendix A. Diffusion models [66, 28, 68] are a class of generative models that convert Gaussian noise into samples from a learned data distribution via an iterative denoising process. These models can be conditional, for example on class labels, text, or low-resolution images [e.g. 16, 29, 62, 61, 78, 43, 56]. A diffusion model $\\hat { \\mathbf { x } } _ { \\theta }$ is trained on a denoising objective of the form ",
398
+ "bbox": [
399
+ 174,
400
+ 188,
401
+ 825,
402
+ 257
403
+ ],
404
+ "page_idx": 3
405
+ },
406
+ {
407
+ "type": "equation",
408
+ "img_path": "images/7a47b7136809987931e491cd587b62109722653076961ec1bc701840ae73c2ce.jpg",
409
+ "text": "$$\n\\mathbb { E } _ { \\mathbf { x } , \\mathbf { c } , \\epsilon , t } \\Big [ w _ { t } \\big \\| \\hat { \\mathbf { x } } _ { \\boldsymbol { \\theta } } \\big ( \\alpha _ { t } \\mathbf { x } + \\sigma _ { t } \\mathbf { \\epsilon } , \\mathbf { c } \\big ) - \\mathbf { x } \\big \\| _ { 2 } ^ { 2 } \\Big ]\n$$",
410
+ "text_format": "latex",
411
+ "bbox": [
412
+ 372,
413
+ 265,
414
+ 625,
415
+ 285
416
+ ],
417
+ "page_idx": 3
418
+ },
419
+ {
420
+ "type": "text",
421
+ "text": "where $\\displaystyle ( \\mathbf { x } , \\mathbf { c } )$ are data-conditioning pairs, $t \\sim \\mathcal { U } ( [ 0 , 1 ] )$ , $\\mathbf { \\epsilon } \\epsilon \\sim \\mathcal { N } ( \\mathbf { 0 } , \\mathbf { I } )$ , and $\\alpha _ { t } , \\sigma _ { t } , w _ { t }$ are functions of $t$ that influence sample quality. Intuitively, $\\hat { \\mathbf { x } } _ { \\theta }$ is trained to denoise $\\mathbf { z } _ { t } : = \\alpha _ { t } \\mathbf { x } + \\sigma _ { t } \\mathbf { \\epsilon } \\mathbf { \\epsilon }$ into $\\mathbf { x }$ using a squared error loss, weighted to emphasize certain values of $t$ . Sampling such as the ancestral sampler [28] and DDIM [67] start from pure noise ${ \\bf z } _ { 1 } \\sim \\mathcal { N } ( { \\bf 0 } , { \\bf I } )$ and iteratively generate points $\\mathbf { z } _ { t _ { 1 } } , \\ldots , \\mathbf { z } _ { t _ { T } }$ , where $1 = t _ { 1 } > \\cdot \\cdot \\cdot > t _ { T } = 0$ , that gradually decrease in noise content. These points are functions of the $\\mathbf { x }$ -predictions $\\hat { \\mathbf { x } } _ { 0 } ^ { t } : = \\hat { \\mathbf { x } } _ { \\theta } ( \\mathbf { z } _ { t } , \\mathbf { c } )$ . ",
422
+ "bbox": [
423
+ 173,
424
+ 294,
425
+ 825,
426
+ 378
427
+ ],
428
+ "page_idx": 3
429
+ },
430
+ {
431
+ "type": "text",
432
+ "text": "Classifier guidance [16] is a technique to improve sample quality while reducing diversity in conditional diffusion models using gradients from a pretrained model $p ( \\mathbf { c } | \\mathbf { z } _ { t } )$ during sampling. Classifierfree guidance [27] is an alternative technique that avoids this pretrained model by instead jointly training a single diffusion model on conditional and unconditional objectives via randomly dropping c during training (e.g. with $10 \\%$ probability). Sampling is performed using the adjusted $\\mathbf { x }$ -prediction $( \\mathbf { z } _ { t } - \\sigma \\tilde { \\epsilon } _ { \\theta } ) / \\alpha _ { t }$ , where ",
433
+ "bbox": [
434
+ 173,
435
+ 383,
436
+ 825,
437
+ 468
438
+ ],
439
+ "page_idx": 3
440
+ },
441
+ {
442
+ "type": "equation",
443
+ "img_path": "images/208aad94f67abcb580a82d01d611666f0effda3344a5166e15ac1024f6eedb42.jpg",
444
+ "text": "$$\n\\widetilde \\epsilon _ { \\theta } ( \\mathbf { z } _ { t } , \\mathbf { c } ) = w \\epsilon _ { \\theta } ( \\mathbf { z } _ { t } , \\mathbf { c } ) + ( 1 - w ) \\epsilon _ { \\theta } ( \\mathbf { z } _ { t } ) .\n$$",
445
+ "text_format": "latex",
446
+ "bbox": [
447
+ 362,
448
+ 477,
449
+ 635,
450
+ 494
451
+ ],
452
+ "page_idx": 3
453
+ },
454
+ {
455
+ "type": "text",
456
+ "text": "Here, $\\epsilon _ { \\theta } ( \\mathbf { z } _ { t } , \\mathbf { c } )$ and $\\epsilon _ { \\theta } ( { \\mathbf { z } } _ { t } )$ are conditional and unconditional $\\epsilon$ -predictions, given by $\\boldsymbol { \\epsilon } _ { \\theta } : = ( \\mathbf { z } _ { t } - $ $\\alpha _ { t } \\hat { \\mathbf { x } } _ { \\theta } ) / \\sigma _ { t }$ , and $w$ is the guidance weight. Setting $w = 1$ disables classifier-free guidance, while increasing $w > 1$ strengthens the effect of guidance. Imagen depends critically on classifier-free guidance for effective text conditioning. ",
457
+ "bbox": [
458
+ 173,
459
+ 503,
460
+ 825,
461
+ 560
462
+ ],
463
+ "page_idx": 3
464
+ },
465
+ {
466
+ "type": "text",
467
+ "text": "2.3 Large guidance weight samplers ",
468
+ "text_level": 1,
469
+ "bbox": [
470
+ 174,
471
+ 579,
472
+ 437,
473
+ 594
474
+ ],
475
+ "page_idx": 3
476
+ },
477
+ {
478
+ "type": "text",
479
+ "text": "We corroborate the results of recent text-guided diffusion work [16, 43, 56] and find that increasing the classifier-free guidance weight improves image-text alignment, but damages image fidelity producing highly saturated and unnatural images [27]. We find that this is due to a train-test mismatch arising from high guidance weights. At each sampling step $t$ , the $\\mathbf { x }$ -prediction $\\hat { \\mathbf { x } } _ { 0 } ^ { t }$ must be within the same bounds as training data $\\mathbf { x }$ , i.e. within $[ - 1 , 1 ]$ , but we find empirically that high guidance weights cause $\\mathbf { x }$ -predictions to exceed these bounds. This is a train-test mismatch, and since the diffusion model is iteratively applied on its own output throughout sampling, the sampling process produces unnatural images and sometimes even diverges. To counter this problem, we investigate static thresholding and dynamic thresholding. See Appendix Fig. A.31 for reference implementation of the techniques and Appendix Fig. A.9 for visualizations of their effects. ",
480
+ "bbox": [
481
+ 173,
482
+ 599,
483
+ 825,
484
+ 738
485
+ ],
486
+ "page_idx": 3
487
+ },
488
+ {
489
+ "type": "text",
490
+ "text": "Static thresholding: We refer to elementwise clipping the $\\mathbf { x }$ -prediction to $[ - 1 , 1 ]$ as static thresholding. This method was in fact used but not emphasized in previous work [28], and to our knowledge its importance has not been investigated in the context of guided sampling. We discover that static thresholding is essential to sampling with large guidance weights and prevents generation of blank images. Nonetheless, static thresholding still results in over-saturated and less detailed images as the guidance weight further increases. ",
491
+ "bbox": [
492
+ 173,
493
+ 744,
494
+ 825,
495
+ 828
496
+ ],
497
+ "page_idx": 3
498
+ },
499
+ {
500
+ "type": "text",
501
+ "text": "Dynamic thresholding: We introduce a new dynamic thresholding method: at each sampling step we set $s$ to a certain percentile absolute pixel value in $\\hat { \\mathbf { x } } _ { 0 } ^ { t }$ , and if $s > 1$ , then we threshold $\\hat { \\mathbf { x } } _ { 0 } ^ { t }$ to the range $[ - s , s ]$ and then divide by $s$ . Dynamic thresholding pushes saturated pixels (those near $^ { - 1 }$ and 1) inwards, thereby actively preventing pixels from saturation at each step. We find that dynamic thresholding results in significantly better photorealism as well as better image-text alignment, especially when using very large guidance weights. ",
502
+ "bbox": [
503
+ 174,
504
+ 833,
505
+ 825,
506
+ 917
507
+ ],
508
+ "page_idx": 3
509
+ },
510
+ {
511
+ "type": "text",
512
+ "text": "2.4 Robust cascaded diffusion models ",
513
+ "text_level": 1,
514
+ "bbox": [
515
+ 176,
516
+ 90,
517
+ 446,
518
+ 106
519
+ ],
520
+ "page_idx": 4
521
+ },
522
+ {
523
+ "type": "text",
524
+ "text": "Imagen utilizes a pipeline of a base $6 4 \\times 6 4$ model, and two text-conditional super-resolution diffusion models to upsample a $6 4 \\times 6 4$ generated image into a $2 5 6 \\times 2 5 6$ image, and then to $1 0 2 4 \\times 1 0 2 4$ image. Cascaded diffusion models with noise conditioning augmentation [29] have been extremely effective in progressively generating high-fidelity images. Furthermore, making the super-resolution models aware of the amount of noise added, via noise level conditioning, significantly improves the sample quality and helps improving the robustness of the super-resolution models to handle artifacts generated by lower resolution models [29]. Imagen uses noise conditioning augmentation for both the super-resolution models. We find this to be a critical for generating high fidelity images. ",
525
+ "bbox": [
526
+ 174,
527
+ 111,
528
+ 825,
529
+ 222
530
+ ],
531
+ "page_idx": 4
532
+ },
533
+ {
534
+ "type": "text",
535
+ "text": "Given a conditioning low-resolution image and augmentation level (a.k.a aug_level) (e.g., strength of Gaussian noise or blur), we corrupt the low-resolution image with the augmentation (corresponding to aug_level), and condition the diffusion model on aug_level. During training, aug_level is chosen randomly, while during inference, we sweep over its different values to find the best sample quality. In our case, we use Gaussian noise as a form of augmentation, and apply variance preserving Gaussian noise augmentation resembling the forward process used in diffusion models (Appendix A). The augmentation level is specified using aug_level $\\in [ 0 , 1 ]$ . See Fig. A.32 for reference pseudocode. ",
536
+ "bbox": [
537
+ 174,
538
+ 228,
539
+ 825,
540
+ 325
541
+ ],
542
+ "page_idx": 4
543
+ },
544
+ {
545
+ "type": "text",
546
+ "text": "2.5 Neural network architecture ",
547
+ "text_level": 1,
548
+ "bbox": [
549
+ 174,
550
+ 344,
551
+ 411,
552
+ 359
553
+ ],
554
+ "page_idx": 4
555
+ },
556
+ {
557
+ "type": "text",
558
+ "text": "Base model: We adapt the U-Net [60] architecture from [42] for our base $6 4 \\times 6 4$ text-to-image diffusion model. The network is conditioned on text embeddings via a pooled embedding vector, added to the diffusion timestep embedding similar to the class embedding conditioning method used in [16, 29]. We further condition on the entire sequence of text embeddings by adding cross attention [59] over the text embeddings at multiple resolutions. We study various methods of text conditioning in Appendix D.3.1. Furthermore, we found Layer Normalization [2] for text embeddings in the attention and pooling layers to help considerably improve performance. ",
559
+ "bbox": [
560
+ 173,
561
+ 366,
562
+ 825,
563
+ 464
564
+ ],
565
+ "page_idx": 4
566
+ },
567
+ {
568
+ "type": "text",
569
+ "text": "Super-resolution models: For $6 4 \\times 6 4 2 5 6 \\times 2 5 6$ super-resolution, we use the U-Net model adapted from [42, 61]. We make several modifications to this U-Net model for improving memory efficiency, inference time and convergence speed (our variant is $2 { - } 3 \\mathbf { x }$ faster in steps/second over the U-Net used in [42, 61]). We call this variant Efficient $U$ -Net (See Appendix B.1 for more details and comparisons). Our $2 5 6 \\times 2 5 6 \\to 1 0 2 4 \\times 1 0 2 4$ super-resolution model trains on $6 4 \\times 6 4 2 5 6 \\times 2 5 6$ crops of the $1 0 2 4 \\times 1 0 2 4$ image. To facilitate this, we remove the self-attention layers, however we keep the text cross-attention layers which we found to be critical. During inference, the model receives the full $2 5 6 \\times 2 5 6$ low-resolution images as inputs, and returns upsampled $1 0 2 4 \\times 1 0 2 4$ images as outputs. Note that we use text cross attention for both our super-resolution models. ",
570
+ "bbox": [
571
+ 173,
572
+ 469,
573
+ 825,
574
+ 594
575
+ ],
576
+ "page_idx": 4
577
+ },
578
+ {
579
+ "type": "text",
580
+ "text": "3 Evaluating Text-to-Image Models ",
581
+ "text_level": 1,
582
+ "bbox": [
583
+ 174,
584
+ 608,
585
+ 485,
586
+ 626
587
+ ],
588
+ "page_idx": 4
589
+ },
590
+ {
591
+ "type": "text",
592
+ "text": "The COCO [38] validation set is the standard benchmark for evaluating text-to-image models for both the supervised [85, 22] and the zero-shot setting [55, 43]. The key automated performance metrics used are FID [26] to measure image fidelity, and CLIP score [25, 51] to measure image-text alignment. Consistent with previous works, we report zero-shot FID-30K, for which 30K prompts are drawn randomly from the validation set, and the model samples generated on these prompts are compared with reference images from the full validation set. Since guidance weight is an important ingredient to control image quality and text alignment, we report most of our ablation results using trade-off (or pareto) curves between CLIP and FID scores across a range of guidance weights. ",
593
+ "bbox": [
594
+ 174,
595
+ 635,
596
+ 825,
597
+ 746
598
+ ],
599
+ "page_idx": 4
600
+ },
601
+ {
602
+ "type": "text",
603
+ "text": "Both FID and CLIP scores have limitations, for example FID is not fully aligned with perceptual quality [44], and CLIP is ineffective at counting [51]. Due to these limitations, we use human evaluation to assess image quality and caption similarity, with ground truth reference caption-image pairs as a baseline. We use two experimental paradigms: ",
604
+ "bbox": [
605
+ 174,
606
+ 751,
607
+ 825,
608
+ 808
609
+ ],
610
+ "page_idx": 4
611
+ },
612
+ {
613
+ "type": "text",
614
+ "text": "1. To probe image quality, the rater is asked to select between the model generation and reference image using the question: “Which image is more photorealistic (looks more real)?”. We report the percentage of times raters choose model generations over reference images (the preference rate). 2. To probe alignment, human raters are shown an image and a prompt and asked “Does the caption accurately describe the above image?”. They must respond with “yes”, “somewhat”, or “no”. These responses are scored as 100, 50, and 0, respectively. These ratings are obtained independently for model samples and reference images, and both are reported. ",
615
+ "bbox": [
616
+ 176,
617
+ 814,
618
+ 825,
619
+ 911
620
+ ],
621
+ "page_idx": 4
622
+ },
623
+ {
624
+ "type": "image",
625
+ "img_path": "images/e328083f23f74118580db879b9e3d624adc72f98d21ca1febe6e5d55c2e915e6.jpg",
626
+ "image_caption": [
627
+ "Figure 2: Non-cherry picked Imagen samples for different categories of prompts from DrawBench. "
628
+ ],
629
+ "image_footnote": [],
630
+ "bbox": [
631
+ 173,
632
+ 87,
633
+ 825,
634
+ 386
635
+ ],
636
+ "page_idx": 5
637
+ },
638
+ {
639
+ "type": "text",
640
+ "text": "For both cases we use 200 randomly chosen image-caption pairs from the COCO validation set. Subjects were shown batches of 50 images. We also used interleaved “control\" trials, and only include rater data from those who correctly answered at least $80 \\%$ of the control questions. This netted 73 and 51 ratings per image for image quality and image-text alignment evaluations, respectively. ",
641
+ "bbox": [
642
+ 174,
643
+ 419,
644
+ 825,
645
+ 474
646
+ ],
647
+ "page_idx": 5
648
+ },
649
+ {
650
+ "type": "text",
651
+ "text": "DrawBench: While COCO is a valuable benchmark, it is increasingly clear that it has a limited spectrum of prompts that do not readily provide insight into differences between models (e.g., see Sec. 4.2). Recent work by [10] proposed a new evaluation set called PaintSkills to systematically evaluate visual reasoning skills and social biases beyond COCO. With similar motivation, we introduce DrawBench, a comprehensive and challenging set of prompts that support the evaluation and comparison of text-to-image models. DrawBench contains 11 categories of prompts, testing different capabilities of models such as the ability to faithfully render different colors, numbers of objects, spatial relations, text in the scene, and unusual interactions between objects. Categories also include complex prompts, including long, intricate textual descriptions, rare words, and also misspelled prompts. We also include sets of prompts collected from DALL-E [55], Gary Marcus et al. [40] and Reddit. Across these 11 categories, DrawBench comprises 200 prompts in total, striking a good balance between the desire for a large, comprehensive dataset, and small enough that human evaluation remains feasible. (Appendix C provides a more detailed description of DrawBench. Fig. 2 shows example prompts from DrawBench with Imagen samples.) ",
652
+ "bbox": [
653
+ 174,
654
+ 481,
655
+ 825,
656
+ 675
657
+ ],
658
+ "page_idx": 5
659
+ },
660
+ {
661
+ "type": "text",
662
+ "text": "We use DrawBench to directly compare different models. To this end, human raters are presented with two sets of images, one from Model A and one from Model B, each of which has 8 samples. Human raters are asked to compare Model A and Model B on sample fidelity and image-text alignment. They respond with one of three choices: Prefer Model A; Indifferent; or Prefer Model B. ",
663
+ "bbox": [
664
+ 174,
665
+ 681,
666
+ 825,
667
+ 736
668
+ ],
669
+ "page_idx": 5
670
+ },
671
+ {
672
+ "type": "text",
673
+ "text": "4 Experiments ",
674
+ "text_level": 1,
675
+ "bbox": [
676
+ 174,
677
+ 750,
678
+ 312,
679
+ 767
680
+ ],
681
+ "page_idx": 5
682
+ },
683
+ {
684
+ "type": "text",
685
+ "text": "Section 4.1 describes training details, Sections 4.2 and 4.3 analyze results on MS-COCO and DrawBench, and Section 4.4 summarizes our ablation studies and key findings. For all experiments below, the images are fair random samples from Imagen with no post-processing or re-ranking. ",
686
+ "bbox": [
687
+ 174,
688
+ 775,
689
+ 825,
690
+ 816
691
+ ],
692
+ "page_idx": 5
693
+ },
694
+ {
695
+ "type": "text",
696
+ "text": "4.1 Training details ",
697
+ "text_level": 1,
698
+ "bbox": [
699
+ 174,
700
+ 834,
701
+ 323,
702
+ 849
703
+ ],
704
+ "page_idx": 5
705
+ },
706
+ {
707
+ "type": "text",
708
+ "text": "Unless specified, we train a 2B parameter model for the $6 4 \\times 6 4$ text-to-image synthesis, and $6 0 0 \\mathbf { M }$ and 400M parameter models for $6 4 \\times 6 4 2 5 6 \\times 2 5 6$ and $2 5 6 \\times 2 5 6 \\to 1 0 2 4 \\times 1 0 2 4$ for superresolution respectively. We use a batch size of 2048 and $2 . 5 \\mathbf { M }$ training steps for all models. We use 256 TPU-v4 chips for our base $6 4 \\times 6 4$ model, and 128 TPU-v4 chips for both super-resolution models. We do not find over-fitting to be an issue, and we believe further training might improve overall performance. We use Adafactor for our base $6 4 \\times 6 4$ model, because initial comparisons with Adam suggested similar performance with much smaller memory footprint for Adafactor. For superresolution models, we use Adam as we found Adafactor to hurt model quality in our initial ablations. For classifier-free guidance, we joint-train unconditionally via zeroing out the text embeddings with $10 \\%$ probability for all three models. We train on a combination of internal datasets, with $\\approx 4 6 0 \\mathrm { M }$ image-text pairs, and the publicly available LAION-400M dataset [64], with $\\approx 4 0 0 { \\mathrm { M } }$ image-text pairs. There are limitations in our training data, and we refer the reader to Section 6 for details. See Appendix F for more implementation details. ",
709
+ "bbox": [
710
+ 176,
711
+ 856,
712
+ 825,
713
+ 911
714
+ ],
715
+ "page_idx": 5
716
+ },
717
+ {
718
+ "type": "table",
719
+ "img_path": "images/2856a1ee3295267acedd84a4baa0d89c87ce2efc8e83f4764343ab3a448004a6.jpg",
720
+ "table_caption": [
721
+ "Table 1: MS-COCO $2 5 6 \\times 2 5 6$ FID-30K. We use a guidance weight of 1.35 for our $6 4 \\times 6 4$ model, and a guidance weight of 8.0 for our super-resolution model. "
722
+ ],
723
+ "table_footnote": [],
724
+ "table_body": "<table><tr><td>Model</td><td>FID-30K</td><td>Zero-shot FID-30K</td></tr><tr><td>AttnGAN [79]</td><td>35.49</td><td></td></tr><tr><td>DM-GAN [86]</td><td>32.64</td><td></td></tr><tr><td>DF-GAN[72]</td><td>21.42</td><td></td></tr><tr><td>DM-GAN + CL [81]</td><td>20.79</td><td></td></tr><tr><td>XMC-GAN [84]</td><td>9.33</td><td></td></tr><tr><td>LAFITE [85]</td><td>8.12</td><td></td></tr><tr><td>Make-A-Scene [22]</td><td>7.55</td><td></td></tr><tr><td>DALL-E [55]</td><td></td><td>17.89</td></tr><tr><td>LAFITE [85]</td><td></td><td>26.94</td></tr><tr><td>GLIDE [43]</td><td></td><td>12.24</td></tr><tr><td>DALL-E 2 [56]</td><td></td><td>10.39</td></tr><tr><td>Imagen (Our Work)</td><td></td><td>7.27</td></tr></table>",
725
+ "bbox": [
726
+ 199,
727
+ 145,
728
+ 506,
729
+ 352
730
+ ],
731
+ "page_idx": 6
732
+ },
733
+ {
734
+ "type": "table",
735
+ "img_path": "images/8ff27774bbbb53a50bb448d32abefaefc37b14a186c4b3f001596aa4ad8412f6.jpg",
736
+ "table_caption": [
737
+ "Table 2: COCO $2 5 6 \\times 2 5 6$ human evaluation comparing model outputs and original images. For the bottom part (no people), we filter out prompts containing one of man, men, woman, women, person, people, child, adult, adults, boy, boys, girl, girls, guy, lady, ladies, someone, toddler, (sport) player, workers, spectators. "
738
+ ],
739
+ "table_footnote": [],
740
+ "table_body": "<table><tr><td>Model</td><td>Photorealism个</td><td>Alignment 个</td></tr><tr><td>Original</td><td></td><td></td></tr><tr><td>Original</td><td>50.0%</td><td>91.9 ± 0.42</td></tr><tr><td>Imagen</td><td>39.5 ± 0.75%</td><td>91.4 ± 0.44</td></tr><tr><td>No people</td><td></td><td></td></tr><tr><td>Original</td><td>50.0%</td><td>92.2 ± 0.54</td></tr><tr><td>Imagen</td><td>43.9 ± 1.01%</td><td>92.1 ± 0.55</td></tr></table>",
741
+ "bbox": [
742
+ 552,
743
+ 234,
744
+ 821,
745
+ 347
746
+ ],
747
+ "page_idx": 6
748
+ },
749
+ {
750
+ "type": "text",
751
+ "text": "",
752
+ "bbox": [
753
+ 173,
754
+ 375,
755
+ 825,
756
+ 501
757
+ ],
758
+ "page_idx": 6
759
+ },
760
+ {
761
+ "type": "text",
762
+ "text": "4.2 Results on COCO ",
763
+ "text_level": 1,
764
+ "bbox": [
765
+ 174,
766
+ 516,
767
+ 338,
768
+ 530
769
+ ],
770
+ "page_idx": 6
771
+ },
772
+ {
773
+ "type": "text",
774
+ "text": "We evaluate Imagen on the COCO validation set using FID score, similar to [55, 43]. Table 1 displays the results. Imagen achieves state of the art zero-shot FID on COCO at 7.27, outperforming the concurrent work of DALL-E 2 [56] and even models trained on COCO. Table 2 reports the human evaluation to test image quality and alignment on the COCO validation set. We report results on the original COCO validation set, as well as a filtered version in which all reference data with people have been removed. For photorealism, Imagen achieves $3 9 . 2 \\%$ preference rate indicating high image quality generation. On the set with no people, there is a boost in preference rate of Imagen to $4 3 . 6 \\%$ , indicating Imagen’s limited ability to generate photorealistic people. On caption similarity, Imagen’s score is on-par with the original reference images, suggesting Imagen’s ability to generate images that align well with COCO captions. ",
775
+ "bbox": [
776
+ 173,
777
+ 541,
778
+ 825,
779
+ 680
780
+ ],
781
+ "page_idx": 6
782
+ },
783
+ {
784
+ "type": "text",
785
+ "text": "4.3 Results on DrawBench ",
786
+ "text_level": 1,
787
+ "bbox": [
788
+ 174,
789
+ 695,
790
+ 370,
791
+ 710
792
+ ],
793
+ "page_idx": 6
794
+ },
795
+ {
796
+ "type": "text",
797
+ "text": "Using DrawBench, we compare Imagen with DALL-E 2 (the public version) [56], GLIDE [43], Latent Diffusion [59], and CLIP-guided VQ-GAN [12]. Fig. 3 shows the human evaluation results for pairwise comparison of Imagen with each of the three models. We report the percentage of time raters prefer Model A, Model B, or are indifferent for both image fidelity and image-text alignment. We aggregate the scores across all the categories and raters. We find the human raters to exceedingly prefer Imagen over all others models in both image-text alignment and image fidelity. We refer the reader to Appendix E for a more detailed category wise comparison and qualitative comparison. ",
798
+ "bbox": [
799
+ 174,
800
+ 715,
801
+ 825,
802
+ 813
803
+ ],
804
+ "page_idx": 6
805
+ },
806
+ {
807
+ "type": "text",
808
+ "text": "4.4 Analysis of Imagen ",
809
+ "text_level": 1,
810
+ "bbox": [
811
+ 174,
812
+ 828,
813
+ 346,
814
+ 843
815
+ ],
816
+ "page_idx": 6
817
+ },
818
+ {
819
+ "type": "text",
820
+ "text": "For a detailed analysis of Imagen see Appendix D. Key findings are discussed in Fig. 4 and below. ",
821
+ "bbox": [
822
+ 171,
823
+ 848,
824
+ 815,
825
+ 863
826
+ ],
827
+ "page_idx": 6
828
+ },
829
+ {
830
+ "type": "text",
831
+ "text": "Scaling text encoder size is extremely effective. We observe that scaling the size of the text encoder leads to consistent improvement in both image-text alignment and image fidelity. Imagen trained with our largest text encoder, T5-XXL (4.6B parameters), yields the best results (Fig. 4a). ",
832
+ "bbox": [
833
+ 176,
834
+ 869,
835
+ 823,
836
+ 911
837
+ ],
838
+ "page_idx": 6
839
+ },
840
+ {
841
+ "type": "image",
842
+ "img_path": "images/24ca4d3c7f8634c15f2022c2c074c1836017d293941e17dfb354ab14a41a4af6.jpg",
843
+ "image_caption": [
844
+ "Figure 3: Comparison between Imagen and DALL-E 2 [56], GLIDE [43], VQ-GAN $^ +$ CLIP [12] and Latent Diffusion [59] on DrawBench: User preference rates (with $9 5 \\%$ confidence intervals) for image-text alignment and image fidelity. "
845
+ ],
846
+ "image_footnote": [],
847
+ "bbox": [
848
+ 174,
849
+ 88,
850
+ 825,
851
+ 242
852
+ ],
853
+ "page_idx": 7
854
+ },
855
+ {
856
+ "type": "image",
857
+ "img_path": "images/ee8585b585ca243a7444cb527dbf9f45bfc630767909e6dd14978415c4a388c0.jpg",
858
+ "image_caption": [
859
+ "Figure 4: Summary of some of the critical findings of Imagen with pareto curves sweeping over different guidance values. See Appendix D for more details. "
860
+ ],
861
+ "image_footnote": [],
862
+ "bbox": [
863
+ 183,
864
+ 310,
865
+ 813,
866
+ 441
867
+ ],
868
+ "page_idx": 7
869
+ },
870
+ {
871
+ "type": "text",
872
+ "text": "Scaling text encoder size is more important than U-Net size. While scaling the size of the diffusion model U-Net improves sample quality, we found scaling the text encoder size to be significantly more impactful than the U-Net size (Fig. 4b). ",
873
+ "bbox": [
874
+ 173,
875
+ 493,
876
+ 825,
877
+ 535
878
+ ],
879
+ "page_idx": 7
880
+ },
881
+ {
882
+ "type": "text",
883
+ "text": "Dynamic thresholding is critical. We show that dynamic thresholding results in samples with significantly better photorealism and alignment with text, over static or no thresholding, especially under the presence of large classifier-free guidance weights (Fig. 4c). ",
884
+ "bbox": [
885
+ 173,
886
+ 541,
887
+ 821,
888
+ 584
889
+ ],
890
+ "page_idx": 7
891
+ },
892
+ {
893
+ "type": "text",
894
+ "text": "Human raters prefer T5-XXL over CLIP on DrawBench. The models trained with T5-XXL and CLIP text encoders perform similarly on the COCO validation set in terms of CLIP and FID scores. However, we find that human raters prefer T5-XXL over CLIP on DrawBench across all 11 categories. ",
895
+ "bbox": [
896
+ 174,
897
+ 589,
898
+ 825,
899
+ 645
900
+ ],
901
+ "page_idx": 7
902
+ },
903
+ {
904
+ "type": "text",
905
+ "text": "Noise conditioning augmentation is critical. We show that training the super-resolution models with noise conditioning augmentation leads to better CLIP and FID scores. We also show that noise conditioning augmentation enables stronger text conditioning for the super-resolution model, resulting in improved CLIP and FID scores at higher guidance weights. Adding noise to the low-res image during inference along with the use of large guidance weights allows the super-resolution models to generate diverse upsampled outputs while removing artifacts from the low-res image. ",
906
+ "bbox": [
907
+ 174,
908
+ 651,
909
+ 825,
910
+ 736
911
+ ],
912
+ "page_idx": 7
913
+ },
914
+ {
915
+ "type": "text",
916
+ "text": "Text conditioning method is critical. We observe that conditioning over the sequence of text embeddings with cross attention significantly outperforms simple mean or attention based pooling in both sample fidelity as well as image-text alignment. ",
917
+ "bbox": [
918
+ 174,
919
+ 741,
920
+ 823,
921
+ 784
922
+ ],
923
+ "page_idx": 7
924
+ },
925
+ {
926
+ "type": "text",
927
+ "text": "Efficient U-Net is critical. Our Efficient U-Net implementation uses less memory, converges faster, and has better sample quality with faster inference. ",
928
+ "bbox": [
929
+ 173,
930
+ 790,
931
+ 825,
932
+ 818
933
+ ],
934
+ "page_idx": 7
935
+ },
936
+ {
937
+ "type": "text",
938
+ "text": "5 Related Work ",
939
+ "text_level": 1,
940
+ "bbox": [
941
+ 174,
942
+ 830,
943
+ 321,
944
+ 847
945
+ ],
946
+ "page_idx": 7
947
+ },
948
+ {
949
+ "type": "text",
950
+ "text": "Diffusion models have seen wide success in image generation [28, 42, 62, 16, 29, 61], outperforming GANs in fidelity and diversity, without training instability and mode collapse issues [6, 16, 29]. Autoregressive models [39], GANs [79, 84], VQ-VAE Transformer-based methods [55, 22], and diffusion models have seen remarkable progress in text-to-image [59, 43, 59], including the concurrent ",
951
+ "bbox": [
952
+ 174,
953
+ 856,
954
+ 825,
955
+ 911
956
+ ],
957
+ "page_idx": 7
958
+ },
959
+ {
960
+ "type": "text",
961
+ "text": "DALL-E 2 [56], which uses a diffusion prior on CLIP text latents and cascaded diffusion models to generate high resolution $1 0 2 4 \\times 1 0 2 4$ images; we believe Imagen is much simpler, as Imagen does not need to learn a latent prior, yet achieves better results in both MS-COCO FID and human evaluation on DrawBench. GLIDE [43] also uses cascaded diffusion models for text-to-image, but we use large pretrained frozen language models, which we found to be instrumental to both image fidelity and image-text alignment. XMC-GAN [84] also uses BERT as a text encoder, but we scale to much larger text encoders and demonstrate the effectiveness thereof. The use of cascaded models is also popular throughout the literature [14, 41] and has been used with success in diffusion models to generate high resolution images [16, 29]. ",
962
+ "bbox": [
963
+ 173,
964
+ 90,
965
+ 825,
966
+ 217
967
+ ],
968
+ "page_idx": 8
969
+ },
970
+ {
971
+ "type": "text",
972
+ "text": "6 Conclusions, Limitations and Societal Impact ",
973
+ "text_level": 1,
974
+ "bbox": [
975
+ 173,
976
+ 226,
977
+ 584,
978
+ 242
979
+ ],
980
+ "page_idx": 8
981
+ },
982
+ {
983
+ "type": "text",
984
+ "text": "Imagen showcases the effectiveness of frozen large pretrained language models as text encoders for the text-to-image generation using diffusion models. Our observation that scaling the size of these language models have significantly more impact than scaling the U-Net size on overall performance encourages future research directions on exploring even bigger language models as text encoders. Furthermore, through Imagen we re-emphasize the importance of classifier-free guidance, and we introduce dynamic thresholding, which allows usage of much higher guidance weights than seen in previous works. With these novel components, Imagen produces $1 0 2 4 \\times 1 0 2 4$ samples with unprecedented photorealism and alignment with text. ",
985
+ "bbox": [
986
+ 174,
987
+ 248,
988
+ 825,
989
+ 361
990
+ ],
991
+ "page_idx": 8
992
+ },
993
+ {
994
+ "type": "text",
995
+ "text": "Our primary aim with Imagen is to advance research on generative methods, using text-to-image synthesis as a test bed. While end-user applications of generative methods remain largely out of scope, we recognize the potential downstream applications of this research are varied and may impact society in complex ways. On the one hand, generative models have a great potential to complement, extend, and augment human creativity [30]. Text-to-image generation models, in particular, have the potential to extend image-editing capabilities and lead to the development of new tools for creative practitioners. On the other hand, generative methods can be leveraged for malicious purposes, including harassment and misinformation spread [20], and raise many concerns regarding social and cultural exclusion and bias [70, 65, 71]. These considerations inform our decision to not to release code or a public demo. In future work we will explore a framework for responsible externalization that balances the value of external auditing with the risks of unrestricted open-access. ",
996
+ "bbox": [
997
+ 174,
998
+ 366,
999
+ 825,
1000
+ 518
1001
+ ],
1002
+ "page_idx": 8
1003
+ },
1004
+ {
1005
+ "type": "text",
1006
+ "text": "Another ethical challenge relates to the large scale data requirements of text-to-image models, which have have led researchers to rely heavily on large, mostly uncurated, web-scraped datasets. While this approach has enabled rapid algorithmic advances in recent years, datasets of this nature have been critiqued and contested along various ethical dimensions. For example, public and academic discourse regarding appropriate use of public data has raised concerns regarding data subject awareness and consent [24, 18, 63, 45]. Dataset audits have revealed these datasets tend to reflect social stereotypes, oppressive viewpoints, and derogatory, or otherwise harmful, associations to marginalized identity groups [46, 4]. Training text-to-image models on this data risks reproducing these associations and causing significant representational harm that would disproportionately impact individuals and communities already experiencing marginalization, discrimination and exclusion within society. As such, there are a multitude of data challenges that must be addressed before text-to-image models like Imagen can be safely integrated into user-facing applications. While we do not directly address these challenges in this work, an awareness of the limitations of our training data guide our decision not to release Imagen for public use. We strongly caution against the use text-to-image generation methods for any user-facing tools without close care and attention to the contents of the training dataset. ",
1007
+ "bbox": [
1008
+ 174,
1009
+ 525,
1010
+ 825,
1011
+ 732
1012
+ ],
1013
+ "page_idx": 8
1014
+ },
1015
+ {
1016
+ "type": "text",
1017
+ "text": "Imagen’s training data was drawn from several pre-existing datasets of image and English alt-text pairs. 400 million examples came from FIT400M, a cleaned version of the Alt-Text dataset [33, 31]. This data was filtered to removed noise and undesirable content, such as pornographic imagery and toxic language. However, a recent audit of another one of our data sources, LAION-400M [64], uncovered a wide range of inappropriate content including pornographic imagery, racist slurs, and harmful social stereotypes [4]. This finding informs our assessment that Imagen is not suitable for public use at this time and also demonstrates the value of rigorous dataset audits and comprehensive dataset documentation (e.g. [23, 47]) in informing consequent decisions about the model’s appropriate and safe use. Imagen also relies on text encoders trained on uncurated web-scale data, and thus inherits the social biases and limitations of large language models [5, 3, 52]. ",
1018
+ "bbox": [
1019
+ 174,
1020
+ 738,
1021
+ 825,
1022
+ 877
1023
+ ],
1024
+ "page_idx": 8
1025
+ },
1026
+ {
1027
+ "type": "text",
1028
+ "text": "While we leave an in-depth empirical analysis of social and cultural biases encoded by Imagen to future work, our small scale internal assessments reveal several limitations that guide our decision not to release Imagen at this time. First, all generative models, including Imagen, Imagen, may run into danger of dropping modes of the data distribution, which may further compound the social consequence of dataset bias. Second, Imagen exhibits serious limitations when generating images depicting people. Our human evaluations found Imagen obtains significantly higher preference rates when evaluated on images that do not portray people, indicating a degradation in image fidelity. Finally, our preliminary assessment also suggests Imagen encodes several social biases and stereotypes, including an overall bias towards generating images of people with lighter skin tones and a tendency for images portraying different professions to align with Western gender stereotypes. Even when we focus generations away from people, our preliminary analysis indicates Imagen encodes a range of social and cultural biases when generating images of activities, events, and objects. ",
1029
+ "bbox": [
1030
+ 174,
1031
+ 883,
1032
+ 821,
1033
+ 911
1034
+ ],
1035
+ "page_idx": 8
1036
+ },
1037
+ {
1038
+ "type": "text",
1039
+ "text": "",
1040
+ "bbox": [
1041
+ 174,
1042
+ 90,
1043
+ 825,
1044
+ 229
1045
+ ],
1046
+ "page_idx": 9
1047
+ },
1048
+ {
1049
+ "type": "text",
1050
+ "text": "While there has been extensive work auditing image-to-text and image labeling models for forms of social bias (e.g. [8, 9, 71]), there has been comparatively less work on social bias evaluation methods for text-to-image models, with the recent exception of [10]. We believe this is a critical avenue for future research and we intend to explore benchmark evaluations for social and cultural bias in future work—for example, exploring whether it is possible to generalize the normalized pointwise mutual information metric [1] to the measurement of biases in image generation models. There is also a great need to develop a conceptual vocabulary around potential harms of text-to-image models that could guide the development of evaluation metrics and inform responsible model release. We aim to address these challenges in future work. ",
1051
+ "bbox": [
1052
+ 174,
1053
+ 236,
1054
+ 825,
1055
+ 359
1056
+ ],
1057
+ "page_idx": 9
1058
+ },
1059
+ {
1060
+ "type": "text",
1061
+ "text": "7 Acknowledgements ",
1062
+ "text_level": 1,
1063
+ "bbox": [
1064
+ 176,
1065
+ 382,
1066
+ 367,
1067
+ 400
1068
+ ],
1069
+ "page_idx": 9
1070
+ },
1071
+ {
1072
+ "type": "text",
1073
+ "text": "We give thanks to Ben Poole for reviewing our manuscript, early discussions, and providing many helpful comments and suggestions throughout the project. Special thanks to Kathy Meier-Hellstern, Austin Tarango, and Sarah Laszlo for helping us incorporate important responsible AI practices around this project. We appreciate valuable feedback and support from Elizabeth Adkison, Zoubin Ghahramani, Jeff Dean, Yonghui Wu, and Eli Collins. We are grateful to Tom Small for designing the Imagen watermark. We thank Jason Baldridge, Han Zhang, and Kevin Murphy for initial discussions and feedback. We acknowledge hard work and support from Fred Alcober, Hibaq Ali, Marian Croak, Aaron Donsbach, Tulsee Doshi, Toju Duke, Douglas Eck, Jason Freidenfelds, Brian Gabriel, Molly FitzMorris, David Ha, Philip Parham, Laura Pearce, Evan Rapoport, Lauren Skelly, Johnny Soraker, Negar Rostamzadeh, Vijay Vasudevan, Tris Warkentin, Jeremy Weinstein, and Hugh Williams for giving us advice along the project and assisting us with the publication process. We thank Victor Gomes and Erica Moreira for their consistent and critical help with TPU resource allocation. We also give thanks to Shekoofeh Azizi, Harris Chan, Chris A. Lee, and Nick Ma for volunteering a considerable amount of their time for testing out DrawBench. We thank Aditya Ramesh, Prafulla Dhariwal, and Alex Nichol for allowing us to use DALL-E 2 samples and providing us with GLIDE samples. We are thankful to Matthew Johnson and Roy Frostig for starting the JAX project and to the whole JAX team for building such a fantastic system for high-performance machine learning research. Special thanks to Durk Kingma, Jascha Sohl-Dickstein, Lucas Theis and the Toronto Brain team for helpful discussions and spending time Imagening! ",
1074
+ "bbox": [
1075
+ 173,
1076
+ 415,
1077
+ 825,
1078
+ 678
1079
+ ],
1080
+ "page_idx": 9
1081
+ },
1082
+ {
1083
+ "type": "text",
1084
+ "text": "References ",
1085
+ "text_level": 1,
1086
+ "bbox": [
1087
+ 174,
1088
+ 700,
1089
+ 266,
1090
+ 715
1091
+ ],
1092
+ "page_idx": 9
1093
+ },
1094
+ {
1095
+ "type": "text",
1096
+ "text": "[1] Osman Aka, Ken Burke, Alex Bauerle, Christina Greer, and Margaret Mitchell. Measuring Model Biases in the Absence of Ground Truth. In Proceedings of the 2021 AAAI/ACM Conference on AI, Ethics, and Society, 2021. \n[2] Jimmy Lei Ba, Jamie Ryan Kiros, and Geoffrey E Hinton. Layer normalization. arXiv preprint arXiv:1607.06450, 2016. \n[3] Emily M. Bender, Timnit Gebru, Angelina McMillan-Major, and Shmargaret Shmitchell. On the dangers of stochastic parrots: Can language models be too big? . In Proceedings of FAccT 2021, 2021. \n[4] Abeba Birhane, Vinay Uday Prabhu, and Emmanuel Kahembwe. Multimodal datasets: misogyny, pornography, and malignant stereotypes. In arXiv:2110.01963, 2021. ",
1097
+ "bbox": [
1098
+ 178,
1099
+ 724,
1100
+ 828,
1101
+ 911
1102
+ ],
1103
+ "page_idx": 9
1104
+ },
1105
+ {
1106
+ "type": "text",
1107
+ "text": "[5] Shikha Bordia and Samuel R. Bowman. Identifying and Reducing Gender Bias in Word-Level Language Models. In NAACL, 2017. ",
1108
+ "bbox": [
1109
+ 178,
1110
+ 90,
1111
+ 823,
1112
+ 119
1113
+ ],
1114
+ "page_idx": 10
1115
+ },
1116
+ {
1117
+ "type": "text",
1118
+ "text": "[6] Andrew Brock, Jeff Donahue, and Karen Simonyan. Large scale gan training for high fidelity natural image synthesis. arXiv preprint arXiv:1809.11096, 2018. ",
1119
+ "bbox": [
1120
+ 179,
1121
+ 128,
1122
+ 823,
1123
+ 157
1124
+ ],
1125
+ "page_idx": 10
1126
+ },
1127
+ {
1128
+ "type": "text",
1129
+ "text": "[7] Tom B. Brown, Benjamin Mann, Nick Ryder, Melanie Subbiah, Jared Kaplan, Prafulla Dhariwal, Arvind Neelakantan, Pranav Shyam, Girish Sastry, Amanda Askell, Sandhini Agarwal, Ariel Herbert-Voss, Gretchen Krueger, Tom Henighan, Rewon Child, Aditya Ramesh, Daniel M. Ziegler, Jeffrey Wu, Clemens Winter, Christopher Hesse, Mark Chen, Eric Sigler, Mateusz Litwin, Scott Gray, Benjamin Chess, Jack Clark, Christopher Berner, Sam McCandlish, Alec Radford, Ilya Sutskever, and Dario Amodei. Language Models are Few-Shot Learners. In NeurIPS, 2020. ",
1130
+ "bbox": [
1131
+ 183,
1132
+ 165,
1133
+ 823,
1134
+ 263
1135
+ ],
1136
+ "page_idx": 10
1137
+ },
1138
+ {
1139
+ "type": "text",
1140
+ "text": "[8] Joy Buolamwini and Timnit Gebru. Gender shades: Intersectional accuracy disparities in commercial gender classification. In Conference on Fairness, Accountability and Transparency, FAT 2018, 23-24 February 2018, New York, NY, USA, Proceedings of Machine Learning Research. PMLR, 2018. ",
1141
+ "bbox": [
1142
+ 181,
1143
+ 272,
1144
+ 825,
1145
+ 329
1146
+ ],
1147
+ "page_idx": 10
1148
+ },
1149
+ {
1150
+ "type": "text",
1151
+ "text": "[9] Kaylee Burns, Lisa Hendricks, Trevor Darrell, and Anna Rohrbach. Women also snowboard: Overcoming bias in captioning models. In European Conference on Computer Vision (ECCV), 2018. ",
1152
+ "bbox": [
1153
+ 178,
1154
+ 338,
1155
+ 823,
1156
+ 380
1157
+ ],
1158
+ "page_idx": 10
1159
+ },
1160
+ {
1161
+ "type": "text",
1162
+ "text": "[10] Jaemin Cho, Abhay Zala, and Mohit Bansal. Dall-eval: Probing the reasoning skills and social biases of text-to-image generative transformers. arxiv:2202.04053, 2022. ",
1163
+ "bbox": [
1164
+ 173,
1165
+ 388,
1166
+ 823,
1167
+ 417
1168
+ ],
1169
+ "page_idx": 10
1170
+ },
1171
+ {
1172
+ "type": "text",
1173
+ "text": "[11] Aakanksha Chowdhery, Sharan Narang, Jacob Devlin, Maarten Bosma, Gaurav Mishra, Adam Roberts, Paul Barham, Hyung Won Chung, Charles Sutton, Sebastian Gehrmann, Parker Schuh, Kensen Shi, Sasha Tsvyashchenko, Joshua Maynez, Abhishek Rao, Parker Barnes, Yi Tay, Noam Shazeer, Vinodkumar Prabhakaran, Emily Reif, Nan Du, Ben Hutchinson, Reiner Pope, James Bradbury, Jacob Austin, Michael Isard, Guy Gur-Ari, Pengcheng Yin, Toju Duke, Anselm Levskaya, Sanjay Ghemawat, Sunipa Dev, Henryk Michalewski, Xavier Garcia, Vedant Misra, Kevin Robinson, Liam Fedus, Denny Zhou, Daphne Ippolito, David Luan, Hyeontaek Lim, Barret Zoph, Alexander Spiridonov, Ryan Sepassi, David Dohan, Shivani Agrawal, Mark Omernick, Andrew M. Dai, Thanumalayan Sankaranarayana Pillai, Marie Pellat, Aitor Lewkowycz, Erica Moreira, Rewon Child, Oleksandr Polozov, Katherine Lee, Zongwei Zhou, Xuezhi Wang, Brennan Saeta, Mark Diaz, Orhan Firat, Michele Catasta, Jason Wei, Kathy Meier-Hellstern, Douglas Eck, Jeff Dean, Slav Petrov, and Noah Fiedel. PaLM: Scaling Language Modeling with Pathways. In arXiv:2001.08361, 2022. ",
1174
+ "bbox": [
1175
+ 178,
1176
+ 426,
1177
+ 825,
1178
+ 607
1179
+ ],
1180
+ "page_idx": 10
1181
+ },
1182
+ {
1183
+ "type": "text",
1184
+ "text": "[12] Katherine Crowson, Stella Biderman, Daniel Kornis, Dashiell Stander, Eric Hallahan, Louis Castricato, and Edward Raff. Vqgan-clip: Open domain image generation and editing with natural language guidance. arXiv preprint arXiv:2204.08583, 2022. ",
1185
+ "bbox": [
1186
+ 171,
1187
+ 616,
1188
+ 821,
1189
+ 659
1190
+ ],
1191
+ "page_idx": 10
1192
+ },
1193
+ {
1194
+ "type": "text",
1195
+ "text": "[13] Valentin De Bortoli, James Thornton, Jeremy Heng, and Arnaud Doucet. Diffusion schrödinger bridge with applications to score-based generative modeling. Advances in Neural Information Processing Systems, 34, 2021. ",
1196
+ "bbox": [
1197
+ 173,
1198
+ 666,
1199
+ 823,
1200
+ 710
1201
+ ],
1202
+ "page_idx": 10
1203
+ },
1204
+ {
1205
+ "type": "text",
1206
+ "text": "[14] Emily Denton, Soumith Chintala, Arthur Szlam, and Rob Fergus. Deep Generative Image Models using a Laplacian Pyramid of Adversarial Networks. In NIPS, 2015. ",
1207
+ "bbox": [
1208
+ 169,
1209
+ 718,
1210
+ 823,
1211
+ 747
1212
+ ],
1213
+ "page_idx": 10
1214
+ },
1215
+ {
1216
+ "type": "text",
1217
+ "text": "[15] Jacob Devlin, Ming-Wei Chang, Kenton Lee, and Kristina Toutanova. BERT: Pre-training of Deep Bidirectional Transformers for Language Understanding. In NAACL, 2019. ",
1218
+ "bbox": [
1219
+ 173,
1220
+ 756,
1221
+ 821,
1222
+ 785
1223
+ ],
1224
+ "page_idx": 10
1225
+ },
1226
+ {
1227
+ "type": "text",
1228
+ "text": "[16] Prafulla Dhariwal and Alex Nichol. Diffusion models beat gans on image synthesis. In NeurIPS, 2022. ",
1229
+ "bbox": [
1230
+ 173,
1231
+ 794,
1232
+ 825,
1233
+ 821
1234
+ ],
1235
+ "page_idx": 10
1236
+ },
1237
+ {
1238
+ "type": "text",
1239
+ "text": "[17] Ming Ding, Zhuoyi Yang, Wenyi Hong, Wendi Zheng, Chang Zhou, Da Yin, Junyang Lin, Xu Zou, Zhou Shao, Hongxia Yang, et al. Cogview: Mastering text-to-image generation via transformers. Advances in Neural Information Processing Systems, 34, 2021. ",
1240
+ "bbox": [
1241
+ 174,
1242
+ 832,
1243
+ 821,
1244
+ 875
1245
+ ],
1246
+ "page_idx": 10
1247
+ },
1248
+ {
1249
+ "type": "text",
1250
+ "text": "[18] Dulhanty, Chris. Issues in Computer Vision Data Collection: Bias, Consent, and Label Taxonomy. In UWSpace, 2020. ",
1251
+ "bbox": [
1252
+ 173,
1253
+ 882,
1254
+ 821,
1255
+ 911
1256
+ ],
1257
+ "page_idx": 10
1258
+ },
1259
+ {
1260
+ "type": "text",
1261
+ "text": "[19] Patrick Esser, Robin Rombach, and Bjorn Ommer. Taming transformers for high-resolution image synthesis. In Proceedings of the IEEE/CVF Conference on Computer Vision and Pattern Recognition, pages 12873–12883, 2021. ",
1262
+ "bbox": [
1263
+ 171,
1264
+ 90,
1265
+ 823,
1266
+ 133
1267
+ ],
1268
+ "page_idx": 11
1269
+ },
1270
+ {
1271
+ "type": "text",
1272
+ "text": "[20] Mary Anne Franks and Ari Ezra Waldman. Sex, lies and videotape: deep fakes and free speech delusions. Maryland Law Review, 78(4):892–898, 2019. ",
1273
+ "bbox": [
1274
+ 169,
1275
+ 142,
1276
+ 823,
1277
+ 171
1278
+ ],
1279
+ "page_idx": 11
1280
+ },
1281
+ {
1282
+ "type": "text",
1283
+ "text": "[21] Tsu-Jui Fu, Xin Eric Wang, and William Yang Wang. Language-Driven Image Style Transfer. arXiv preprint arXiv:2106.00178, 2021. ",
1284
+ "bbox": [
1285
+ 174,
1286
+ 180,
1287
+ 825,
1288
+ 210
1289
+ ],
1290
+ "page_idx": 11
1291
+ },
1292
+ {
1293
+ "type": "text",
1294
+ "text": "[22] Oran Gafni, Adam Polyak, Oron Ashual, Shelly Sheynin, Devi Parikh, and Yaniv Taigman. Make-a-scene: Scene-based text-to-image generation with human priors. arXiv preprint arXiv:2203.13131, 2022. ",
1295
+ "bbox": [
1296
+ 173,
1297
+ 219,
1298
+ 825,
1299
+ 262
1300
+ ],
1301
+ "page_idx": 11
1302
+ },
1303
+ {
1304
+ "type": "text",
1305
+ "text": "[23] Timnit Gebru, Jamie Morgenstern, Briana Vecchione, Jennifer Wortman Vaughan, Hanna Wallach, Hal Daumé III, and Kate Crawford. Datasheets for Datasets. arXiv:1803.09010 [cs], March 2020. ",
1306
+ "bbox": [
1307
+ 173,
1308
+ 271,
1309
+ 825,
1310
+ 314
1311
+ ],
1312
+ "page_idx": 11
1313
+ },
1314
+ {
1315
+ "type": "text",
1316
+ "text": "[24] Adam Harvey and Jules LaPlace. MegaPixels: Origins and endpoints of biometric datasets \"In the Wild\". https://megapixels.cc, 2019. ",
1317
+ "bbox": [
1318
+ 173,
1319
+ 324,
1320
+ 823,
1321
+ 353
1322
+ ],
1323
+ "page_idx": 11
1324
+ },
1325
+ {
1326
+ "type": "text",
1327
+ "text": "[25] Jack Hessel, Ari Holtzman, Maxwell Forbes, Ronan Le Bras, and Yejin Choi. Clipscore: A reference-free evaluation metric for image captioning. arXiv preprint arXiv:2104.08718, 2021. ",
1328
+ "bbox": [
1329
+ 174,
1330
+ 362,
1331
+ 825,
1332
+ 391
1333
+ ],
1334
+ "page_idx": 11
1335
+ },
1336
+ {
1337
+ "type": "text",
1338
+ "text": "[26] Martin Heusel, Hubert Ramsauer, Thomas Unterthiner, Bernhard Nessler, and Sepp Hochreiter. Gans trained by a two time-scale update rule converge to a local nash equilibrium. arXiv preprint arXiv:1706.08500, 2017. ",
1339
+ "bbox": [
1340
+ 174,
1341
+ 400,
1342
+ 823,
1343
+ 443
1344
+ ],
1345
+ "page_idx": 11
1346
+ },
1347
+ {
1348
+ "type": "text",
1349
+ "text": "[27] Jonathan Ho and Tim Salimans. Classifier-free diffusion guidance. In NeurIPS 2021 Workshop on Deep Generative Models and Downstream Applications, 2021. ",
1350
+ "bbox": [
1351
+ 171,
1352
+ 452,
1353
+ 825,
1354
+ 482
1355
+ ],
1356
+ "page_idx": 11
1357
+ },
1358
+ {
1359
+ "type": "text",
1360
+ "text": "[28] Jonathan Ho, Ajay Jain, and Pieter Abbeel. Denoising Diffusion Probabilistic Models. NeurIPS, 2020. ",
1361
+ "bbox": [
1362
+ 178,
1363
+ 489,
1364
+ 825,
1365
+ 520
1366
+ ],
1367
+ "page_idx": 11
1368
+ },
1369
+ {
1370
+ "type": "text",
1371
+ "text": "[29] Jonathan Ho, Chitwan Saharia, William Chan, David J Fleet, Mohammad Norouzi, and Tim Salimans. Cascaded diffusion models for high fidelity image generation. JMLR, 2022. ",
1372
+ "bbox": [
1373
+ 174,
1374
+ 529,
1375
+ 825,
1376
+ 559
1377
+ ],
1378
+ "page_idx": 11
1379
+ },
1380
+ {
1381
+ "type": "text",
1382
+ "text": "[30] Rowan T. Hughes, Liming Zhu, and Tomasz Bednarz. Generative adversarial networks-enabled human-artificial intelligence collaborative applications for creative and design industries: A systematic review of current approaches and trends. Frontiers in artificial intelligence, 4, 2021. ",
1383
+ "bbox": [
1384
+ 173,
1385
+ 568,
1386
+ 823,
1387
+ 609
1388
+ ],
1389
+ "page_idx": 11
1390
+ },
1391
+ {
1392
+ "type": "text",
1393
+ "text": "[31] Aashi Jain, Mandy Guo, Krishna Srinivasan, Ting Chen, Sneha Kudugunta, Chao Jia, Yinfei Yang, and Jason Baldridge. MURAL: Multimodal, multitask representations across languages. In Findings of the Association for Computational Linguistics: EMNLP 2021, pages 3449– 3463, Punta Cana, Dominican Republic, November 2021. Association for Computational Linguistics. doi: 10.18653/v1/2021.findings-emnlp.293. URL https://aclanthology.org/ 2021.findings-emnlp.293. ",
1394
+ "bbox": [
1395
+ 174,
1396
+ 619,
1397
+ 828,
1398
+ 704
1399
+ ],
1400
+ "page_idx": 11
1401
+ },
1402
+ {
1403
+ "type": "text",
1404
+ "text": "[32] Chao Jia, Yinfei Yang, Ye Xia, Yi-Ting Chen, Zarana Parekh, Hieu Pham, Quoc Le, YunHsuan Sung, Zhen Li, and Tom Duerig. Scaling up visual and vision-language representation learning with noisy text supervision. In International Conference on Machine Learning, pages 4904–4916. PMLR, 2021. ",
1405
+ "bbox": [
1406
+ 174,
1407
+ 713,
1408
+ 826,
1409
+ 768
1410
+ ],
1411
+ "page_idx": 11
1412
+ },
1413
+ {
1414
+ "type": "text",
1415
+ "text": "[33] Chao Jia, Yinfei Yang, Ye Xia, Yi-Ting Chen, Zarana Parekh, Hieu Pham, Quoc V. Le, YunHsuan Sung, Zhen Li, and Tom Duerig. Scaling up visual and vision-language representation learning with noisy text supervision. In ICML, 2021. ",
1416
+ "bbox": [
1417
+ 171,
1418
+ 779,
1419
+ 823,
1420
+ 821
1421
+ ],
1422
+ "page_idx": 11
1423
+ },
1424
+ {
1425
+ "type": "text",
1426
+ "text": "[34] Zahra Kadkhodaie and Eero P Simoncelli. Solving linear inverse problems using the prior implicit in a denoiser. arXiv preprint arXiv:2007.13640, 2020. ",
1427
+ "bbox": [
1428
+ 169,
1429
+ 830,
1430
+ 823,
1431
+ 859
1432
+ ],
1433
+ "page_idx": 11
1434
+ },
1435
+ {
1436
+ "type": "text",
1437
+ "text": "[35] Zahra Kadkhodaie and Eero P Simoncelli. Stochastic solutions for linear inverse problems using the prior implicit in a denoiser. Advances in Neural Information Processing Systems, 34, 2021. ",
1438
+ "bbox": [
1439
+ 174,
1440
+ 869,
1441
+ 826,
1442
+ 911
1443
+ ],
1444
+ "page_idx": 11
1445
+ },
1446
+ {
1447
+ "type": "text",
1448
+ "text": "[36] Gwanghyun Kim and Jong Chul Ye. Diffusionclip: Text-guided image manipulation using diffusion models. arXiv preprint arXiv:2110.02711, 2021. \n[37] Diederik P Kingma, Tim Salimans, Ben Poole, and Jonathan Ho. Variational diffusion models. arXiv preprint arXiv:2107.00630, 2021. \n[38] Tsung-Yi Lin, Michael Maire, Serge Belongie, Lubomir Bourdev, Ross Girshick, James Hays, Pietro Perona, Deva Ramanan, Lawrence Zitnick, and Piotr Dollár. Microsoft COCO: Common Objects in Context. In ECCV, 2014. \n[39] Elman Mansimov, Emilio Parisotto, Jimmy Lei Ba, and Ruslan Salakhutdinov. Generating Images from Captions with Attention. In ICLR, 2016. \n[40] Gary Marcus, Ernest Davis, and Scott Aaronson. A very preliminary analysis of DALL-E 2. In arXiv:2204.13807, 2022. \n[41] Jacob Menick and Nal Kalchbrenner. Generating High Fidelity Images with Subscale Pixel Networks and Multidimensional Upscaling. In ICLR, 2019. \n[42] Alex Nichol and Prafulla Dhariwal. Improved denoising diffusion probabilistic models. arXiv preprint arXiv:2102.09672, 2021. \n[43] Alex Nichol, Prafulla Dhariwal, Aditya Ramesh, Pranav Shyam, Bob McGrew Pamela Mishkin, Ilya Sutskever, and Mark Chen. GLIDE: Towards Photorealistic Image Generation and Editing with Text-Guided Diffusion Models. In arXiv:2112.10741, 2021. \n[44] Gaurav Parmar, Richard Zhang, and Jun-Yan Zhu. On Aliased Resizing and Surprising Subtleties in GAN Evaluation. In CVPR, 2022. \n[45] Amandalynne Paullada, Inioluwa Deborah Raji, Emily M. Bender, Emily Denton, and Alex Hanna. Data and its (dis)contents: A survey of dataset development and use in machine learning research. Patterns, 2(11):100336, 2021. \n[46] Vinay Uday Prabhu and Abeba Birhane. Large image datasets: A pyrrhic win for computer vision? arXiv:2006.16923, 2020. \n[47] Mahima Pushkarna, Andrew Zaldivar, and Oddur Kjartansson. Data cards: Purposeful and transparent dataset documentation for responsible ai. In Proceedings of the 2021 ACM Conference on Fairness, Accountability, and Transparency, 2022. \n[48] Alec Radford, Rafal Jozefowicz, and Ilya Sutskever. Learning to Generate Reviews and Discovering Sentiment. In arXiv:1704.01444, 2017. \n[49] Alec Radford, Karthik Narasimhan, Tim Salimans, and Ilya Sutskever. Improving Language Understanding by Generative Pre-Training. In preprint, 2018. \n[50] Alec Radford, Jeffrey Wu, Rewon Child, David Luan, Dario Amodei, and Ilya Sutskever. Language Models are Unsupervised Multitask Learners. In preprint, 2019. \n[51] Alec Radford, Jong Wook Kim, Chris Hallacy, Aditya Ramesh, Gabriel Goh, Sandhini Agarwal, Girish Sastry, Amanda Askell, Pamela Mishkin, Jack Clark, Gretchen Krueger, and Ilya Sutskever. Learning Transferable Visual Models From Natural Language Supervision. In ICML, 2021. \n[52] Jack Rae, Sebastian Borgeaud, Trevor Cai, Katie Millican, Jordan Hoffmann, Francis Song, John Aslanides, Sarah Henderson, Roman Ring, Susannah Young, Eliza Rutherford, Tom Hennigan, Jacob Menick, Albin Cassirer, Richard Powell, George Driessche, Lisa Hendricks, Maribeth Rauh, Po-Sen Huang, and Geoffrey Irving. Scaling language models: Methods, analysis & insights from training gopher. arXiv:2112.11446, 2021. \n[53] Colin Raffel, Minh-Thang Luong, Peter J. Liu, Ron J. Weiss, and Douglas Eck. Online and Linear-Time Attention by Enforcing Monotonic Alignments. In ICML, 2017. ",
1449
+ "bbox": [
1450
+ 169,
1451
+ 65,
1452
+ 826,
1453
+ 914
1454
+ ],
1455
+ "page_idx": 12
1456
+ },
1457
+ {
1458
+ "type": "text",
1459
+ "text": "[54] Colin Raffel, Noam Shazeer, Adam Roberts, Katherine Lee, Sharan Narang, Michael Matena, Yanqi Zhou, Wei Li, and Peter J. Liu. Exploring the Limits of Transfer Learning with a Unified Text-to-Text Transformer. JMLR, 21(140), 2020. ",
1460
+ "bbox": [
1461
+ 171,
1462
+ 90,
1463
+ 823,
1464
+ 133
1465
+ ],
1466
+ "page_idx": 13
1467
+ },
1468
+ {
1469
+ "type": "text",
1470
+ "text": "[55] Aditya Ramesh, Mikhail Pavlov, Gabriel Goh, Scott Gray, Chelsea Voss, Alec Radford, Mark Chen, and Ilya Sutskever. Zero-Shot Text-to-Image Generation. In ICML, 2021. ",
1471
+ "bbox": [
1472
+ 173,
1473
+ 143,
1474
+ 823,
1475
+ 172
1476
+ ],
1477
+ "page_idx": 13
1478
+ },
1479
+ {
1480
+ "type": "text",
1481
+ "text": "[56] Aditya Ramesh, Prafulla Dhariwal, Alex Nichol, Casey Chu, and Mark Chen. Hierarchical Text-Conditional Image Generation with CLIP Latents. In arXiv, 2022. ",
1482
+ "bbox": [
1483
+ 173,
1484
+ 183,
1485
+ 821,
1486
+ 212
1487
+ ],
1488
+ "page_idx": 13
1489
+ },
1490
+ {
1491
+ "type": "text",
1492
+ "text": "[57] Ali Razavi, Aaron van den Oord, and Oriol Vinyals. Generating diverse high-fidelity images with vq-vae-2. arXiv preprint arXiv:1906.00446, 2019. ",
1493
+ "bbox": [
1494
+ 171,
1495
+ 222,
1496
+ 823,
1497
+ 251
1498
+ ],
1499
+ "page_idx": 13
1500
+ },
1501
+ {
1502
+ "type": "text",
1503
+ "text": "[58] Scott Reed, Zeynep Akata, Xinchen Yan, Lajanugen Logeswaran, Bernt Schiele, and Honglak Lee. Generative adversarial text to image synthesis. In International conference on machine learning, pages 1060–1069. PMLR, 2016. ",
1504
+ "bbox": [
1505
+ 173,
1506
+ 261,
1507
+ 823,
1508
+ 304
1509
+ ],
1510
+ "page_idx": 13
1511
+ },
1512
+ {
1513
+ "type": "text",
1514
+ "text": "[59] Robin Rombach, Andreas Blattmann, Dominik Lorenz, Patrick Esser, and Björn Ommer. High-Resolution Image Synthesis with Latent Diffusion Models. In CVPR, 2022. ",
1515
+ "bbox": [
1516
+ 171,
1517
+ 314,
1518
+ 825,
1519
+ 343
1520
+ ],
1521
+ "page_idx": 13
1522
+ },
1523
+ {
1524
+ "type": "text",
1525
+ "text": "[60] Olaf Ronneberger, Philipp Fischer, and Thomas Brox. U-net: Convolutional networks for biomedical image segmentation. In International Conference on Medical image computing and computer-assisted intervention, pages 234–241. Springer, 2015. ",
1526
+ "bbox": [
1527
+ 174,
1528
+ 353,
1529
+ 825,
1530
+ 397
1531
+ ],
1532
+ "page_idx": 13
1533
+ },
1534
+ {
1535
+ "type": "text",
1536
+ "text": "[61] Chitwan Saharia, William Chan, Huiwen Chang, Chris A. Lee, Jonathan Ho, Tim Salimans, David J. Fleet, and Mohammad Norouzi. Palette: Image-to-Image Diffusion Models. In arXiv:2111.05826, 2021. ",
1537
+ "bbox": [
1538
+ 176,
1539
+ 406,
1540
+ 823,
1541
+ 449
1542
+ ],
1543
+ "page_idx": 13
1544
+ },
1545
+ {
1546
+ "type": "text",
1547
+ "text": "[62] Chitwan Saharia, Jonathan Ho, William Chan, Tim Salimans, David J Fleet, and Mohammad Norouzi. Image super-resolution via iterative refinement. arXiv preprint arXiv:2104.07636, 2021. ",
1548
+ "bbox": [
1549
+ 174,
1550
+ 459,
1551
+ 825,
1552
+ 502
1553
+ ],
1554
+ "page_idx": 13
1555
+ },
1556
+ {
1557
+ "type": "text",
1558
+ "text": "[63] Morgan Klaus Scheuerman, Emily L. Denton, and A. Hanna. Do datasets have politics? disciplinary values in computer vision dataset development. Proceedings of the ACM on Human-Computer Interaction, 5:1 – 37, 2021. ",
1559
+ "bbox": [
1560
+ 173,
1561
+ 512,
1562
+ 825,
1563
+ 555
1564
+ ],
1565
+ "page_idx": 13
1566
+ },
1567
+ {
1568
+ "type": "text",
1569
+ "text": "[64] Christoph Schuhmann, Richard Vencu, Romain Beaumont, Robert Kaczmarczyk, Clayton Mullis, Aarush Katta, Theo Coombes, Jenia Jitsev, and Aran Komatsuzaki. Laion-400m: Open dataset of clip-filtered 400 million image-text pairs. arXiv preprint arXiv:2111.02114, 2021. ",
1570
+ "bbox": [
1571
+ 171,
1572
+ 564,
1573
+ 825,
1574
+ 608
1575
+ ],
1576
+ "page_idx": 13
1577
+ },
1578
+ {
1579
+ "type": "text",
1580
+ "text": "[65] Lucas Sequeira, Bruno Moreschi, Amanda Jurno, and Vinicius Arruda dos Santos. Which faces can AI generate? Normativity, whiteness and lack of diversity in This Person Does Not Exist. In CVPR Workshop Beyond Fairness: Towards a Just, Equitable, and Accountable Computer Vision, 2021. ",
1581
+ "bbox": [
1582
+ 173,
1583
+ 617,
1584
+ 826,
1585
+ 674
1586
+ ],
1587
+ "page_idx": 13
1588
+ },
1589
+ {
1590
+ "type": "text",
1591
+ "text": "[66] Jascha Sohl-Dickstein, Eric Weiss, Niru Maheswaranathan, and Surya Ganguli. Deep unsupervised learning using nonequilibrium thermodynamics. In International Conference on Machine Learning, pages 2256–2265. PMLR, 2015. ",
1592
+ "bbox": [
1593
+ 173,
1594
+ 684,
1595
+ 823,
1596
+ 728
1597
+ ],
1598
+ "page_idx": 13
1599
+ },
1600
+ {
1601
+ "type": "text",
1602
+ "text": "[67] Jiaming Song, Chenlin Meng, and Stefano Ermon. Denoising diffusion implicit models. arXiv preprint arXiv:2010.02502, 2020. ",
1603
+ "bbox": [
1604
+ 173,
1605
+ 737,
1606
+ 823,
1607
+ 767
1608
+ ],
1609
+ "page_idx": 13
1610
+ },
1611
+ {
1612
+ "type": "text",
1613
+ "text": "[68] Yang Song and Stefano Ermon. Generative Modeling by Estimating Gradients of the Data Distribution. NeurIPS, 2019. ",
1614
+ "bbox": [
1615
+ 169,
1616
+ 776,
1617
+ 825,
1618
+ 806
1619
+ ],
1620
+ "page_idx": 13
1621
+ },
1622
+ {
1623
+ "type": "text",
1624
+ "text": "[69] Yang Song, Jascha Sohl-Dickstein, Diederik P Kingma, Abhishek Kumar, Stefano Ermon, and Ben Poole. Score-based generative modeling through stochastic differential equations. In ICLR, 2021. ",
1625
+ "bbox": [
1626
+ 171,
1627
+ 815,
1628
+ 825,
1629
+ 858
1630
+ ],
1631
+ "page_idx": 13
1632
+ },
1633
+ {
1634
+ "type": "text",
1635
+ "text": "[70] Ramya Srinivasan and Kanji Uchino. Biases in generative art: A causal look from the lens of art history. In Proceedings of the 2021 ACM Conference on Fairness, Accountability, and Transparency, page 41–51, 2021. ",
1636
+ "bbox": [
1637
+ 174,
1638
+ 868,
1639
+ 826,
1640
+ 912
1641
+ ],
1642
+ "page_idx": 13
1643
+ },
1644
+ {
1645
+ "type": "text",
1646
+ "text": "[71] Ryan Steed and Aylin Caliskan. Image representations learned with unsupervised pre-training contain human-like biases. In Proceedings of the 2021 ACM Conference on Fairness, Accountability, and Transparency, FAccT ’21, page 701–713. Association for Computing Machinery, 2021. \n[72] Ming Tao, Hao Tang, Songsong Wu, Nicu Sebe, Xiao-Yuan Jing, Fei Wu, and Bingkun Bao. Df-gan: Deep fusion generative adversarial networks for text-to-image synthesis. arXiv preprint arXiv:2008.05865, 2020. \n[73] Belinda Tzen and Maxim Raginsky. Neural Stochastic Differential Equations: Deep Latent Gaussian Models in the Diffusion Limit. In arXiv:1905.09883, 2019. \n[74] Aaron Van Den Oord, Oriol Vinyals, et al. Neural discrete representation learning. Advances in neural information processing systems, 30, 2017. \n[75] Pascal Vincent. A connection between score matching and denoising autoencoders. Neural Computation, 23(7):1661–1674, 2011. \n[76] Ting-Chun Wang, Ming-Yu Liu, Jun-Yan Zhu, Andrew Tao, Jan Kautz, and Bryan Catanzaro. High-resolution image synthesis and semantic manipulation with conditional gans. In Proceedings of the IEEE conference on computer vision and pattern recognition, pages 8798–8807, 2018. \n[77] Jason Weston, Samy Bengio, and Nicolas Usunier. Wsabie: Scaling up to large vocabulary image annotation. In Twenty-Second International Joint Conference on Artificial Intelligence, 2011. \n[78] Jay Whang, Mauricio Delbracio, Hossein Talebi, Chitwan Saharia, Alexandros G Dimakis, and Peyman Milanfar. Deblurring via stochastic refinement. arXiv preprint arXiv:2112.02475, 2021. \n[79] Tao Xu, Pengchuan Zhang, Qiuyuan Huang, Han Zhang, Zhe Gan, Xiaolei Huang, and Xiaodong He. AttnGAN: Fine-Grained Text to Image Generation with Attentional Generative Adversarial Networks. In CVPR, 2018. \n[80] Tao Xu, Pengchuan Zhang, Qiuyuan Huang, Han Zhang, Zhe Gan, Xiaolei Huang, and Xiaodong He. Attngan: Fine-grained text to image generation with attentional generative adversarial networks. In Proceedings of the IEEE conference on computer vision and pattern recognition, pages 1316–1324, 2018. \n[81] Hui Ye, Xiulong Yang, Martin Takac, Rajshekhar Sunderraman, and Shihao Ji. Improving text-to-image synthesis using contrastive learning. arXiv preprint arXiv:2107.02423, 2021. \n[82] Jiahui Yu, Xin Li, Jing Yu Koh, Han Zhang, Ruoming Pang, James Qin, Alexander Ku, Yuanzhong Xu, Jason Baldridge, and Yonghui Wu. Vector-quantized image modeling with improved vqgan. arXiv preprint arXiv:2110.04627, 2021. \n[83] Jiahui Yu, Zirui Wang, Vijay Vasudevan, Legg Yeung, Mojtaba Seyedhosseini, and Yonghui Wu. Coca: Contrastive captioners are image-text foundation models. arXiv preprint arXiv:2205.01917, 2022. \n[84] Han Zhang, Jing Yu Koh, Jason Baldridge, Honglak Lee, and Yinfei Yang. Cross-Modal Contrastive Learning for Text-to-Image Generation. In CVPR, 2021. \n[85] Yufan Zhou, Ruiyi Zhang, Changyou Chen, Chunyuan Li, Chris Tensmeyer, Tong Yu, Jiuxiang Gu, Jinhui Xu, and Tong Sun. Lafite: Towards language-free training for text-to-image generation. arXiv preprint arXiv:2111.13792, 2021. \n[86] Minfeng Zhu, Pingbo Pan, Wei Chen, and Yi Yang. Dm-gan: Dynamic memory generative adversarial networks for text-to-image synthesis. In Proceedings of the IEEE/CVF Conference on Computer Vision and Pattern Recognition, pages 5802–5810, 2019. \n[87] Yukun Zhu, Ryan Kiros, Rich Zemel, Ruslan Salakhutdinov, Raquel Urtasun, Antonio Torralba, and Sanja Fidler. Aligning books and movies: Towards story-like visual explanations by watching movies and reading books. In ICCV, 2015. ",
1647
+ "bbox": [
1648
+ 169,
1649
+ 70,
1650
+ 826,
1651
+ 912
1652
+ ],
1653
+ "page_idx": 14
1654
+ },
1655
+ {
1656
+ "type": "text",
1657
+ "text": "Checklist ",
1658
+ "text_level": 1,
1659
+ "bbox": [
1660
+ 174,
1661
+ 89,
1662
+ 254,
1663
+ 106
1664
+ ],
1665
+ "page_idx": 15
1666
+ },
1667
+ {
1668
+ "type": "text",
1669
+ "text": "1. For all authors... ",
1670
+ "bbox": [
1671
+ 214,
1672
+ 116,
1673
+ 339,
1674
+ 130
1675
+ ],
1676
+ "page_idx": 15
1677
+ },
1678
+ {
1679
+ "type": "text",
1680
+ "text": "(a) Do the main claims made in the abstract and introduction accurately reflect the paper’s contributions and scope? [Yes] \n(b) Did you describe the limitations of your work? [Yes] See Section 6. \n(c) Did you discuss any potential negative societal impacts of your work? [Yes] See Section 6. \n(d) Have you read the ethics review guidelines and ensured that your paper conforms to them? [Yes] ",
1681
+ "bbox": [
1682
+ 238,
1683
+ 135,
1684
+ 825,
1685
+ 239
1686
+ ],
1687
+ "page_idx": 15
1688
+ },
1689
+ {
1690
+ "type": "text",
1691
+ "text": "2. If you are including theoretical results... ",
1692
+ "bbox": [
1693
+ 214,
1694
+ 243,
1695
+ 493,
1696
+ 258
1697
+ ],
1698
+ "page_idx": 15
1699
+ },
1700
+ {
1701
+ "type": "text",
1702
+ "text": "(a) Did you state the full set of assumptions of all theoretical results? [N/A] (b) Did you include complete proofs of all theoretical results? [N/A] ",
1703
+ "bbox": [
1704
+ 238,
1705
+ 262,
1706
+ 738,
1707
+ 294
1708
+ ],
1709
+ "page_idx": 15
1710
+ },
1711
+ {
1712
+ "type": "text",
1713
+ "text": "3. If you ran experiments... ",
1714
+ "bbox": [
1715
+ 212,
1716
+ 299,
1717
+ 393,
1718
+ 313
1719
+ ],
1720
+ "page_idx": 15
1721
+ },
1722
+ {
1723
+ "type": "text",
1724
+ "text": "(a) Did you include the code, data, and instructions needed to reproduce the main experimental results (either in the supplemental material or as a URL)? [No] \n(b) Did you specify all the training details (e.g., data splits, hyperparameters, how they were chosen)? [Yes] \n(c) Did you report error bars (e.g., with respect to the random seed after running experiments multiple times)? [No] \n(d) Did you include the total amount of compute and the type of resources used (e.g., type of GPUs, internal cluster, or cloud provider)? [Yes] ",
1725
+ "bbox": [
1726
+ 238,
1727
+ 316,
1728
+ 825,
1729
+ 435
1730
+ ],
1731
+ "page_idx": 15
1732
+ },
1733
+ {
1734
+ "type": "text",
1735
+ "text": "4. If you are using existing assets (e.g., code, data, models) or curating/releasing new assets... ",
1736
+ "bbox": [
1737
+ 218,
1738
+ 439,
1739
+ 823,
1740
+ 454
1741
+ ],
1742
+ "page_idx": 15
1743
+ },
1744
+ {
1745
+ "type": "text",
1746
+ "text": "(a) If your work uses existing assets, did you cite the creators? [Yes] \n(b) Did you mention the license of the assets? [Yes] We describe the license of the public data we use in Section 6. \n(c) Did you include any new assets either in the supplemental material or as a URL? [Yes] We include DrawBench prompts in the supplemental material. \n(d) Did you discuss whether and how consent was obtained from people whose data you’re using/curating? [Yes] We discuss the lack of consent from data subjects in web-scraped data in Section 6. \n(e) Did you discuss whether the data you are using/curating contains personally identifiable information or offensive content? [Yes] See Section 6. ",
1747
+ "bbox": [
1748
+ 238,
1749
+ 458,
1750
+ 825,
1751
+ 607
1752
+ ],
1753
+ "page_idx": 15
1754
+ },
1755
+ {
1756
+ "type": "text",
1757
+ "text": "5. If you used crowdsourcing or conducted research with human subjects... ",
1758
+ "bbox": [
1759
+ 214,
1760
+ 611,
1761
+ 705,
1762
+ 626
1763
+ ],
1764
+ "page_idx": 15
1765
+ },
1766
+ {
1767
+ "type": "text",
1768
+ "text": "(a) Did you include the full text of instructions given to participants and screenshots, if applicable? [Yes] \n(b) Did you describe any potential participant risks, with links to Institutional Review Board (IRB) approvals, if applicable? [No] \n(c) Did you include the estimated hourly wage paid to participants and the total amount spent on participant compensation? [Yes] ",
1769
+ "bbox": [
1770
+ 238,
1771
+ 630,
1772
+ 825,
1773
+ 719
1774
+ ],
1775
+ "page_idx": 15
1776
+ }
1777
+ ]
parse/dev/08Yk-n5l2Al/08Yk-n5l2Al_middle.json ADDED
The diff for this file is too large to render. See raw diff
 
parse/dev/08Yk-n5l2Al/08Yk-n5l2Al_model.json ADDED
The diff for this file is too large to render. See raw diff
 
parse/dev/9-umxtNPx5E/9-umxtNPx5E.md ADDED
@@ -0,0 +1,488 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ # MASKED FREQUENCY MODELING FOR SELF-SUPERVISED VISUAL PRE-TRAINING
2
+
3
+ Jiahao Xie1,2, Wei $\mathbf { L i } ^ { 1 , 2 }$ , Xiaohang Zhan3, Ziwei ${ \bf L i u ^ { 1 , 2 } }$ , Yew Soon $\mathbf { O n g ^ { 2 , 4 } }$ , Chen Change Loy1,2
4
+ 1S-Lab, NTU 2SCSE, NTU 3CUHK 4A\*STAR, Singapore
5
+ {jiahao003, wei.l, ziwei.liu, asysong, ccloy}@ntu.edu.sg
6
+ xiaohangzhan@outlook.com
7
+
8
+ # ABSTRACT
9
+
10
+ We present Masked Frequency Modeling (MFM), a unified frequency-domainbased approach for self-supervised pre-training of visual models. Instead of randomly inserting mask tokens to the input embeddings in the spatial domain, in this paper, we shift the perspective to the frequency domain. Specifically, MFM first masks out a portion of frequency components of the input image and then predicts the missing frequencies on the frequency spectrum. Our key insight is that predicting masked components in the frequency domain is more ideal to reveal underlying image patterns rather than predicting masked patches in the spatial domain, due to the heavy spatial redundancy. Our findings suggest that with the right configuration of mask-and-predict strategy, both the structural information within high-frequency components and the low-level statistics among low-frequency counterparts are useful in learning good representations. For the first time, MFM demonstrates that, for both ViT and CNN, a simple nonSiamese framework can learn meaningful representations even using none of the following: (i) extra data, (ii) extra model, (iii) mask token. Experimental results on image classification and semantic segmentation, as well as several robustness benchmarks show the competitive performance and advanced robustness of MFM compared with recent masked image modeling approaches. Furthermore, we also comprehensively investigate the effectiveness of classical image restoration tasks for representation learning from a unified frequency perspective and reveal their intriguing relations with our MFM approach. Project page: https://www.mmlab-ntu.com/project/mfm/index.html.
11
+
12
+ # 1 INTRODUCTION
13
+
14
+ Following the success of Masked Language Modeling (MLM) such as BERT (Devlin et al., 2019) in natural language processing (NLP), Masked Image Modeling (MIM) (Bao et al., 2022; He et al., 2022; Wei et al., 2022; Xie et al., 2022) has shown promising performance in self-supervised pretraining of visual models. Both MLM and MIM follow a common corrupt-and-predict paradigm – randomly masking a portion of input data and then learning to predict the missing parts. This simple recipe enables modern Transformer-based deep architectures (Vaswani et al., 2017; Dosovitskiy et al., 2020) to learn generalizable representations from ubiquitous unlabeled text or image data.
15
+
16
+ By default, current MIM methods such as BEiT (Bao et al., 2022), MAE (He et al., 2022) and SimMIM (Xie et al., 2022) perform masking in the spatial domain by excluding image patches randomly, a strategy inspired by MLM that performs masking on words (Figure 1(a-b)). However, unlike human-generated language that is succinct and highly semantic, raw pixel values in the spatial domain are of low information density. To cope with heavy spatial redundancy in images, MAE (He et al., 2022) shows that one would need to mask a very high proportion (e.g., $7 5 \%$ ) to encourage the learning of meaningful features.
17
+
18
+ Beyond masking image patches, which is a particular way of corruption, in this paper, we are interested in investigating the effectiveness of other corruption strategies for self-supervised representation learning. We first explore the corruption recipes commonly applied in low-level image processing tasks, including image super-resolution (SR), deblurring and denoising. As shown in
19
+
20
+ ![](images/3e72c2c4dd5406a3272b0257009779dde837d3da71a3c7e34aa6a5eef73b18c9.jpg)
21
+ Figure 1: Comparison of masking recipes in Masked Language Modeling (MLM), Masked Image Modeling (MIM), low-level image processing and Masked Frequency Modeling (MFM). Note the differences of masked information among MIM, low-level image processing and MFM.
22
+
23
+ Figure 1(c), the downsampling, blur, and noise operations can degrade the exemplar image effectively in the spatial domain, thus potentially serving as useful corruption strategies. However, the corruption induced in the spatial domain prevents us from analyzing what specific information is corrupted and needs to be reconstructed. To better understand these low-level corruptions, we shift our attention from the spatial image domain to the frequency domain.
24
+
25
+ In the frequency domain, one could observe underlying patterns of an image not conveniently visible from raw pixel values. For example, the downsampling and blur operations dominantly remove the high-frequency image details, while adding noises tends to corrupt the full frequency spectrum of an image globally (Figure 1(c)).
26
+
27
+ Driven by this observation, we present a simple and effective masking strategy in the frequency domain for self-supervised visual representation learning, dubbed as Masked Frequency Modeling (MFM). Specifically, we first perform Fast Fourier Transform (FFT) to convert each input image into its frequency representation, i.e., frequency spectrum. We then mask a portion of frequencies on the frequency spectrum using a low-/high-pass filter. With inverse FFT (iFFT), we finally take the corrupted image with some of the frequencies attenuated as input. Our encoder is quite flexible as no mask tokens are inserted. Thus, MFM can embrace both the vision Transformer (ViT) (Dosovitskiy et al., 2020) and convolutional neural network (CNN) (LeCun et al., 1989) families. Our decoder is a lightweight linear layer that reconstructs the masked frequency values on the frequency spectrum via a frequency loss. As shown in Figure 1(d), an image with low or high frequencies attenuated would reveal entirely different patterns: the low-frequency components usually contain object smooth structure such as colors and styles, while the high-frequency counterparts largely depict the object outline or silhouette structure. Such unique properties of the frequency domain make it appealing for reducing information redundancy, thus creating a nontrivial and meaningful self-supervisory task.
28
+
29
+ Our contributions are summarized as follows:
30
+
31
+ 1) We propose a new masked frequency modeling task to pre-train visual encoders in a selfsupervised manner. Our MFM is agnostic to the architectures, and we demonstrate the flexibility of applying MFM for both ViT and CNN families.
32
+
33
+ 2) We contribute the first study of low-level corruption tasks for self-supervised learning (SSL) in frequency domain. We investigate the effectiveness of corruption strategies commonly adopted in low-level image processing tasks (i.e., SR, deblurring and denoising) for SSL from a unified frequency perspective and reveal that the representation learning capability of these corruption tasks actually depends on the architectures: they can achieve comparable and even better results than their supervised counterpart on ViT, but no gains are observed on CNN.
34
+
35
+ 3) Extensive experiments show that our MFM can achieve competitive performance among existing MIM approaches on downstream tasks, such as image classification and semantic segmentation, while not using mask tokens or other more complex designs. Further analysis on several robustness benchmarks also exhibits more appealing robustness of the studied corruption tasks than MIM.
36
+
37
+ # 2 RELATED WORK
38
+
39
+ Masked language modeling and its auto-regressive variants, such as BERT (Devlin et al., 2019) and GPT (Radford et al., 2018; 2019; Brown et al., 2020), have achieved great success in pretraining large-scale language models in the NLP community. These approaches perform masking on the human-generated language by holding out random words and then predicting the missing content. This simple mask-word recipe has shown excellent ability in pre-training generalizable representations for broad NLP applications.
40
+
41
+ Masked image modeling leverages images corrupted by masking to learn useful representations. Pioneered with stacked autoencoders (Vincent et al., 2010) and context encoders (Pathak et al., 2016) using CNNs, recent approaches (Bao et al., 2022; He et al., 2022; Xie et al., 2022; Wei et al., 2022; Chen et al., 2022) follow the mask-word strategy in NLP to randomly mask image patches in the spatial domain using the vision Transformers (Dosovitskiy et al., 2020; Liu et al., 2021). Along with this mask-patch strategy, different types of prediction targets have been studied, including discrete tokens (Bao et al., 2022; Dong et al., 2021), raw pixels (He et al., 2022; Xie et al., 2022), and handcrafted features (Wei et al., 2022). Besides, iGPT (Chen et al., 2020a) takes a low-resolution image sequence as input and predicts missing pixels in an auto-regressive manner. Several methods (Zhou et al., 2022; El-Nouby et al., 2021) also integrate MIM into contrastive-based Siamese frameworks. Our work differs from previous approaches in that we perform masking in the frequency domain, which relies on none of the following: (i) extra data (Bao et al., 2022; Dong et al., 2021; Fang et al., 2022), (ii) extra model (Zhou et al., 2022; El-Nouby et al., 2021; Fang et al., 2022; Shi et al., 2022; Chen et al., 2022), or (iii) mask token (Bao et al., 2022; He et al., 2022; Xie et al., 2022; Wei et al., 2022; Chen et al., 2022). CIM (Fang et al., 2022) also does not use mask token. However, introducing an auxiliary generator to corrupt the input images adds nontrivial pre-training overhead. In contrast, our frequency-domain-based corruption strategy can achieve comparable performance with negligible computational cost.
42
+
43
+ Self-supervised learning mainly focuses on designing effective pretext tasks for pre-training (Doersch et al., 2015; Wang & Gupta, 2015; Noroozi & Favaro, 2016; Larsson et al., 2016; Zhang et al., 2016; 2017c; Noroozi et al., 2017; Bojanowski & Joulin, 2017; Pathak et al., 2017; Gidaris et al., 2018). Contrastive learning (Wu et al., 2018; He et al., 2020; Misra & Maaten, 2020; Chen et al., 2020b;c; Grill et al., 2020; Chen & He, 2021; Chen et al., 2021; Caron et al., 2021) has dominated the field over the past few years. Unlike the mask-and-predict pretext task, contrastive learning typically uses a Siamese framework and greatly relies on data augmentation.
44
+
45
+ Low-level image processing tasks, such as image super-resolution (Dong et al., 2015), deblurring (Zhang et al., 2022) and denoising (Zhang et al., 2017b), focus on restoring the high-fidelity image from its corrupted input. The corrupted images are usually generated with degradation transformations, which consist of downsampling, blur, noise and JPEG compression. Recent promising results of MIM motivate us to investigate the effectiveness of these corruption operations in the context of representation learning.
46
+
47
+ Frequency domain analysis has been widely adopted in many computer vision tasks, such as image generation (Jiang et al., 2021), domain adaptation (Xu et al., 2021), and image superresolution (Pang et al., 2020). Early studies (Oppenheim et al., 1979; Oppenheim & Lim, 1981; Piotrowski & Campbell, 1982; Hansen & Hess, 2007) have revealed that in the frequency domain, the phase component largely captures high-level semantics of the original signals, while the amplitude component mainly retains low-level statistics. As such, underlying image patterns can be more conveniently observed in the frequency representation, compared with the raw pixel values in the spatial domain. Motivated by the intriguing properties of the Fourier domain, we propose a novel mask-frequency recipe and conduct the first study w.r.t. masked information modeling in the frequency domain for image data.
48
+
49
+ # 3 APPROACH
50
+
51
+ Our masked frequency modeling (MFM) is a simple yet effective self-supervised pre-training approach, which masks out a portion of image frequency components and predicts the missing frequencies on the frequency spectrum. Figure 2 shows the overview of our approach. The framework consists of four components: masking strategy, encoder, decoder, and reconstruction target. We first detail each component of MFM in Section 3.1, and then discuss the relation of our approach with low-level image processing tasks in Section 3.2.
52
+
53
+ ![](images/75a64e1574cade9db08c679d2f564bf65113f5054ed30d5b33ceb574d0387e7b.jpg)
54
+ Figure 2: Overview of our MFM pre-training pipeline. We convert each input image into frequency domain via FFT and mask a portion of frequencies on the frequency spectrum via a low-pass (top) or high-pass (bottom) filter. After iFFT, the low-/high-pass filtered spatial images are then randomly fed to the encoder (e.g., ViT, CNN), with a lightweight one-layer head to predict the masked frequency values on the frequency spectrum via a frequency loss. The red circle denotes the selected mask radius, and the dice icon refers to the random sampling process of low-/high-pass filters, following a Bernoulli distribution.
55
+
56
+ # 3.1 MASKED FREQUENCY MODELING
57
+
58
+ Preliminary: Frequency representation of images. Given a single channel image1 x ∈ RH×W , we can obtain the corresponding frequency representation via 2D Discrete Fourier Transform $\mathcal { F } \left( x \right)$ :
59
+
60
+ $$
61
+ \mathcal { F } \left( x \right) \left( u , v \right) = \sum _ { h = 0 } ^ { H - 1 } \sum _ { w = 0 } ^ { W - 1 } x \left( h , w \right) e ^ { - i 2 \pi \left( \frac { u h } { H } + \frac { v w } { W } \right) } ,
62
+ $$
63
+
64
+ where $x \left( h , w \right)$ is the real pixel value at the coordinate of $( h , w )$ on the spatial image, $\mathcal { F } \left( \boldsymbol { x } \right) \left( u , v \right)$ is the complex frequency value at the coordinate of $( u , v )$ on the frequency spectrum, $e$ and $i$ are Euler’s number and the imaginary unit, respectively. Accordingly, ${ \mathcal { F } } ^ { { \bar { - } } 1 } \left( x \right)$ defines the inverse Fourier transform that maps spectral signals back into original image space. Both the Fourier transform and its inverse can be calculated efficiently using the FFT algorithm (Nussbaumer, 1981).
65
+
66
+ Masking strategy. We define a mask $M \in \{ 0 , 1 \} ^ { H \times W }$ , whose value is determined by a thresholding function that separates the low and high frequency components from $\mathcal { F } \left( x \right)$ according to a hyper-parameter, i.e., radius $r$ :
67
+
68
+ $$
69
+ M \left( u , v \right) = \left\{ \begin{array} { l l } { 1 , \mathrm { ~ i f ~ } d \left( \left( u , v \right) , \left( c _ { h } , c _ { w } \right) \right) < r } \\ { 0 , \mathrm { ~ o t h e r w i s e } } \end{array} \right.
70
+ $$
71
+
72
+ where $\left( { { c _ { h } } , { c _ { w } } } \right)$ denotes the center of the image, $d \left( \cdot , \cdot \right)$ denotes a certain distance criterion. Here, we use the Euclidean distance, i.e., a circle mask as default. Note that the mask shape is not solely restricted to a circle one, and we study the effects of different mask shapes in the experiment section.
73
+
74
+ With the predefined mask $M$ , we can easily obtain the decomposed low-pass filtered image $x _ { l }$ and the high-pass filtered counterpart $x _ { h }$ as follows:
75
+
76
+ $$
77
+ x _ { l } = \mathcal { F } ^ { - 1 } \left( \mathcal { F } \left( \boldsymbol { x } \right) \odot \boldsymbol { M } \right) , \quad x _ { h } = \mathcal { F } ^ { - 1 } \left( \mathcal { F } \left( \boldsymbol { x } \right) \odot \left( \mathbb { 1 } - \boldsymbol { M } \right) \right) ,
78
+ $$
79
+
80
+ where $\mathbb { 1 }$ is the all-ones matrix, $\odot$ is the Hadamard product between matrices. These filtered images are then randomly selected with a Bernoulli distribution and fed to an encoder as input2.
81
+
82
+ MFM encoder. The architecture of our encoder is quite flexible since we do not insert any mask tokens on the corrupted non-overlapping patch embeddings as in MIM (Bao et al., 2022; He et al., 2022; Xie et al., 2022; Wei et al., 2022). Therefore, our MFM can be applied on both ViT and CNN architectures without any special designs. In this paper, we mainly use a standard ViT (Dosovitskiy et al., 2020) as our encoder for a direct comparison with MIM methods. Specifically, we first divide a filtered spatial image into regular non-overlapping patches. Then, the encoder embeds the patches by linear projection with added positional embeddings. The combined embeddings are then processed via a series of self-attention-based Transformer blocks (Vaswani et al., 2017). We also consider a typical CNN architecture, i.e., ResNet-50 (He et al., 2016), to demonstrate the versatility of MFM. To this end, we simply send the filtered spatial image to the CNN encoder as input.
83
+
84
+ MFM decoder. The decoder accomplishes the frequency reconstruction task. It can be of arbitrary form as long as its input is compatible with the encoder’s output. Here, we simply adopt a lightweight linear layer as our decoder for efficiency, after which we perform FFT to convert each output image into the frequency domain for frequency reconstruction. The effect of different decoders is further studied in Appendix A.
85
+
86
+ Reconstruction target. Our MFM reconstructs the input by predicting the missing frequency values on the frequency spectrum. To faithfully recover the frequency values, we should define a frequency distance metric that considers both amplitude and phase as a loss function. Regarding each frequency value $\mathcal { F } \left( \boldsymbol { x } \right) \left( u , v \right)$ as a two-dimensional Euclidean vector $\bar { f }$ , one can easily derive that the magnitude of the vector corresponds to the amplitude while the angle corresponds to the phase. Inspired by Jiang et al. (2021), we thus define the frequency distance $\mathcal { D } \left( \cdot , \cdot \right)$ as the distance between the reconstructed vector $\vec { f _ { r } }$ and the original vector $\vec { f _ { o } }$ at each spectrum coordinate $( u , v )$ :
87
+
88
+ $$
89
+ \begin{array} { r l } & { \mathcal { D } \left( \vec { f } _ { r } , \vec { f } _ { o } \right) = \left\| \vec { f } _ { r } - \vec { f } _ { o } \right\| _ { 2 } ^ { \gamma } = \left| \mathcal { F } _ { r } \left( x \right) \left( u , v \right) - \mathcal { F } _ { o } \left( x \right) \left( u , v \right) \right| ^ { \gamma } } \\ & { \quad \quad \quad = \left( \left( \mathcal { R } _ { r } \left( x \right) \left( u , v \right) - \mathcal { R } _ { o } \left( x \right) \left( u , v \right) \right) ^ { 2 } + \left( \mathcal { T } _ { r } \left( x \right) \left( u , v \right) - \mathcal { T } _ { o } \left( x \right) \left( u , v \right) \right) ^ { 2 } \right) ^ { \gamma / 2 } , } \end{array}
90
+ $$
91
+
92
+ where $\mathcal { R } ( x )$ and $\mathcal { T } ( x )$ are the real and imaginary part of $\mathcal { F } ( x )$ , respectively, $\gamma$ is an exponent to control the sharpness of the distance function and is set to 1 by default. For each image, the final loss function, $i . e .$ , the average frequency distance of all spectrum positions can thus be written as:
93
+
94
+ $$
95
+ \mathcal { L } = \mathcal { D } \left( \mathcal { F } _ { r } \left( x \right) , \mathcal { F } _ { o } \left( x \right) \right) = \frac { 1 } { H W } \sum _ { u = 0 } ^ { H - 1 } \sum _ { v = 0 } ^ { W - 1 } \left| \mathcal { F } _ { r } \left( x \right) \left( u , v \right) - \mathcal { F } _ { o } \left( x \right) \left( u , v \right) \right| ^ { \gamma } .
96
+ $$
97
+
98
+ In practice, we compute the loss only on the masked area of the frequency spectrum instead of the full spectrum as the latter tends to decrease the accuracy according to our experiments.
99
+
100
+ # 3.2 RELATION WITH LOW-LEVEL IMAGE PROCESSING TASKS
101
+
102
+ The notion of recovering masked frequency components in MFM is reminiscent to the objectives in low-level image processing tasks, such as image super-resolution (SR), deblurring and denoising. In these tasks, a model takes a degraded image as input, and the aim is to restore the missing components. Different degradations corrupt different components in the frequency domain. As discussed in Section 1, for the image SR and deblurring tasks, most of the high-frequency components are removed while the low-frequency counterparts are retained; for the image denoising task, both lowand high-frequencies are significantly altered.
103
+
104
+ By analyzing the frequency spectrum of these tasks, we can observe how different frequencies of an image contribute to visual representation learning, thus gaining better insights on designing more effective learning objectives. Compared with these tasks, MFM provides a more general and unified frequency perspective to perform these low-level corruptions while being conceptually simpler: we directly remove certain frequencies on the frequency spectrum via a low-/high-pass filter. Our experiments show that MFM can achieve better performance than these tasks for representation learning. We will comprehensively study these tasks and show more details in the experiment section.
105
+
106
+ # 4 EXPERIMENTS
107
+
108
+ # 4.1 IMPLEMENTATION DETAILS
109
+
110
+ We use the vanilla ViT-Small (ViT-S/16), ViT-Base (ViT-B/16) and ResNet-50 models as the backbones in our study. We perform self-supervised pre-training on the ImageNet-1K (Deng et al., 2009) training set without labels. For ViT, our pre-training setting generally follows BEiT (Bao et al., 2022), while we only use random resized cropping $2 2 4 \times 2 2 4$ resolution) and flipping as data
111
+
112
+ Table 1: Ablations for MFM with ViT-B/16 on ImageNet-1K. All models are based on 300-epoch pre-training, and we report top-1 fine-tuning accuracy. Unless specified, the default settings are: the mask type is random (i.e., random sampling of low-/high-pass filters), the mask radius is 16, the mask shape is circle, the sampling ratio for low-pass filters is $50 \%$ (i.e., $50 \%$ for low-pass filters and $50 \%$ for high-pass counterparts), the reconstruction target is masked frequencies on the spectrum, and the loss function is a frequency loss with $\gamma = 1$ . Default entry is marked in gray .
113
+
114
+ (a) Mask type. Random sampling of both filters works the best.
115
+
116
+ (b) Mask radius. Using a fixed radius is enough.
117
+
118
+ <table><tr><td>Mask radius</td><td>Top-1 acc (%)</td></tr><tr><td>8</td><td>82.8</td></tr><tr><td>16</td><td>83.1</td></tr><tr><td>24</td><td>82.7</td></tr><tr><td>32</td><td>82.6</td></tr><tr><td>[8,24]</td><td>83.0</td></tr></table>
119
+
120
+ (c) Mask shape. A circle mask is more accurate.
121
+
122
+ <table><tr><td>Mask shape</td><td>Top-1 acc (%)</td></tr><tr><td>circle</td><td>83.1</td></tr><tr><td>square</td><td>82.9</td></tr><tr><td>rhombus</td><td>82.8</td></tr></table>
123
+
124
+ (e) Reconstruction target. Predicting only the masked frequencies yields better performance.
125
+
126
+ <table><tr><td>Mask type</td><td>Top-1 acc (%)</td></tr><tr><td>none</td><td>76.5</td></tr><tr><td>low-pass</td><td>82.4</td></tr><tr><td>high-pass</td><td>82.3</td></tr><tr><td>random</td><td>83.1</td></tr></table>
127
+
128
+ (d) Sampling ratio. Sampling low-/high-pass filters with an equal probability is effective.
129
+
130
+ (f) Loss function. A frequency loss works better than spatial loss.
131
+
132
+ <table><tr><td>Loss</td><td>Top-1 acc (%)</td></tr><tr><td>freq. (γ = 1)</td><td>83.1</td></tr><tr><td>freq.(γ = 2)</td><td>82.5</td></tr><tr><td>l1</td><td>82.3</td></tr><tr><td>l</td><td>82.2</td></tr></table>
133
+
134
+ <table><tr><td>Sampling ratio</td><td>Top-1 acc (%)</td></tr><tr><td>0.3</td><td>82.5</td></tr><tr><td>0.5</td><td>83.1</td></tr><tr><td>0.7</td><td>82.7</td></tr></table>
135
+
136
+ <table><tr><td>Reconstruction target</td><td>Top-1 acc (%)</td></tr><tr><td>masked spectrum</td><td>83.1</td></tr><tr><td>full spectrum</td><td>82.4</td></tr></table>
137
+
138
+ augmentation, with dropout and stochastic depth not applied. We also do not use relative position or layer scaling. After pre-training, we conduct supervised end-to-end fine-tuning on ImageNet-1K image classification and ADE20K (Zhou et al., 2017) semantic segmentation to evaluate the quality of learned representations, following BEiT (Bao et al., 2022). For ResNet-50, we adopt the same pre-training configuration as that in ViT without further parameter tuning. We provide the detailed pre-training and fine-tuning recipes in Appendix G.
139
+
140
+ # 4.2 MAIN PROPERTIES
141
+
142
+ We start by ablating our MFM using ViT-B/16 as the default backbone. All experiments are conducted with 300-epoch pre-training and 100-epoch fine-tuning on the ImageNet-1K dataset unless otherwise specified. Several intriguing properties are observed.
143
+
144
+ Masking strategy. We first study different masking strategies on the frequency spectrum. We consider two kinds of filters: low-pass filter (i.e., mask high frequencies), and high-pass filter (i.e., mask low frequencies). As shown in Table 1a, masking and predicting either high frequencies (“lowpass” entry) or low frequencies (“high-pass” entry) perform significantly better than simply encoding and reconstructing the original image (“none” entry). This indicates that both high-frequency and low-frequency components are useful in representation learning, where the former largely depicts the object structure information such as outline or silhouette and the latter usually captures low-level statistics such as colors and styles. A random variant, i.e., randomly selecting one filter from both low-pass and high-pass filters (“random” entry), benefits from all lens of frequencies, thus further improving the performance.
145
+
146
+ Mask radius. Table 1b studies the effect of mask radius, which controls the difficulty of our task. A larger radius leaves more frequencies for a low-pass filter while removes more frequencies for a high-pass filter. MFM works the best with a moderate difficulty. Using a fixed radius (e.g., 16) performs slightly better than a random one, i.e., the radius is uniformly sampled within a range (e.g., [8, 24]).
147
+
148
+ Mask shape. We study three centrosymmetric mask shapes in Table 1c. Different mask shapes focus on different masking directions. Take low-pass filter as an example, a square shape removes more frequencies in the horizontal and vertical direction, while a rhombus one removes more in the diagonal direction. The results demonstrate that a circle mask shape that pays an equal attention to each direction on the frequency spectrum performs the best. We hypothesize that the effect of different mask shapes is largely correlated with the category statistics of pre-training datasets.
149
+
150
+ Table 2: Comparison of SR, deblurring, denoising and MFM tasks with ViT-B/16 on ImageNet1K. All models are pre-trained for 300 epochs, and evaluated with top-1 fine-tuning accuracy. Corrupted image samples from ImageNet-1K training set with different degradation levels are visualized in both image and frequency domain. The studied hyper-parameter that controls the difficulty of degradation for each task is (a) downsampling scale factor, (b) Gaussian blur sigma, (c) Gaussian noise sigma, and (d) mask radius, respectively. More examples are provided in Appendix H. Zoom in for best view.
151
+
152
+ <table><tr><td>Task</td><td>Parameter</td><td>Top-l acc (%)</td></tr><tr><td rowspan="5">(a)SR</td><td>×2</td><td>82.1</td></tr><tr><td>×4</td><td>82.2</td></tr><tr><td>×8</td><td>82.4</td></tr><tr><td>×16</td><td>82.1</td></tr><tr><td>1</td><td>79.7</td></tr><tr><td rowspan="4">(b)Deblur</td><td>3</td><td>81.2</td></tr><tr><td>5</td><td>81.7</td></tr><tr><td>7</td><td>81.5</td></tr><tr><td></td><td></td></tr><tr><td rowspan="4">(c) Denoise</td><td>25</td><td>82.4</td></tr><tr><td>50</td><td>82.6</td></tr><tr><td>75</td><td>82.7</td></tr><tr><td>100</td><td>82.6</td></tr><tr><td rowspan="4">(d)MFM</td><td>8</td><td>82.8</td></tr><tr><td>16</td><td>83.1</td></tr><tr><td>24</td><td>82.7</td></tr><tr><td>32</td><td>82.6</td></tr></table>
153
+
154
+ ![](images/a9ab4a5e58c9826dc0093435e3db5c6fa572316421aaad0fd647438e013bb3c8.jpg)
155
+
156
+ Sampling ratio. Table 1d ablates different sampling ratios for low-/high-pass filters. Here, the sampling ratio denotes the probability of sampling a low-pass filter, following a Bernoulli distribution. The results show that simply sampling both filters with an equal probability works the best.
157
+
158
+ Reconstruction target. Table 1e compares two reconstruction targets: 1) predicting only the masked frequencies on the frequency spectrum as in our default setting, and 2) recovering both the masked and unmasked frequencies on the frequency spectrum. Predicting the masked spectrum performs better than reconstructing the full spectrum by a clear margin $8 3 . 1 \%$ vs. $8 2 . 4 \%$ . This suggests that predicting the invisible signals is a more favourable task in representation learning, which is in accordance with the observation in recent MIM approaches.
159
+
160
+ Loss function. Table 1f studies the design of loss functions. A frequency loss (freq.) performs better than a spatial loss $( \ell _ { 1 } , \ell _ { 2 } )$ , with $\gamma = 1$ working the best. It makes sense as directly predicting the missing frequencies in the frequency domain better aligns to our MFM task.
161
+
162
+ # 4.3 DIAGNOSIS OF LOW-LEVEL IMAGE PROCESSING TASKS
163
+
164
+ In this subsection, we study the representation learning capability of low-level image processing tasks from a unified frequency perspective. We examine three representative tasks: image superresolution (SR), deblurring, and denoising.
165
+
166
+ Setup. To ensure a direct comparison, we adopt the same pre-training and fine-tuning hyperparameters as MFM and only alter the types of image degradation during pre-training. Specifically, for the SR task, we first use its standard data pre-processing, i.e., bicubic downsampling, to downsample the input images by a scale factor. We then upsample them back to the original input size, i.e., $2 2 4 \times 2 2 4$ . For the deblurring task, we consider the commonly-used isotropic Gaussian filter and uniformly select the blur kernel size from $\{ 7 , 9 , 1 1 , 1 3 , 1 5 , 1 7 , 1 9 , 2 1 \}$ as suggested in Wang et al. (2021). For the denoising task, we employ the typical Gaussian noise. The intensity of both deblurring and denoising tasks is controlled by the standard deviation (i.e., sigma value) of the Gaussian distribution. For all tasks, the reconstruction target is the original image but in the frequency domain via the same frequency loss as MFM.
167
+
168
+ Observations. Table 2 shows the results with different levels of degradation for each task. We first notice that the optimal degradation level of each task in the context of representation learning is much heavier than its original task setting. For instance, a standard SR task usually has a downsampling factor within $\times 4$ , while we show that a much heavier $\times 8$ setting works the best. With right configuration of the task difficulty, all these tasks can achieve comparable or even better performance than their supervised counterpart (e.g., $8 1 . 8 \%$ in Touvron et al. (2021a)), indicating that these low-level tasks are more or less helpful in representation learning. In addition, we observe that representation learning benefits from all lens of frequencies. This can be verified by the superior performance of denoising over SR and deblurring. As visualized in the frequency spectrum of the example image, denoising tends to intensify all frequencies of the spectrum, while SR and deblurring only removes high-frequency components. Thus, the performance of denoising is much closer to MFM, as both utilize the full frequency spectrum. Attenuating and intensifying frequencies on the spectrum are essentially two different ways of performing corruption in the frequency domain. We believe other corruption types may also work well and leave this exploration for future work.
169
+
170
+ # 4.4 COMPARISON WITH PREVIOUS METHODS
171
+
172
+ # 4.4.1 IMAGE CLASSIFICATION
173
+
174
+ Table 3: ImageNet-1K top-1 fine-tuning accuracy of self-supervised models using ViT-S/16 and ViT-B/16 as the encoder. DINO and MoCo v3 use extra momentum encoder. BEiT requires extra 250M DALL-E data (Ramesh et al., 2021) to pre-train dVAE. BEiT and MAE also use mask tokens (inserted either in the encoder or the decoder). All entries are on an image size of $2 2 4 \times 2 2 4$ . We use the actual processed images/views to measure the effective pre-training epochs (Zhou et al., 2022). Scratch indicates the supervised baseline in Touvron et al. (2021a). †: doubled attention heads. ‡: our reproduced results with official code.
175
+
176
+ <table><tr><td>Method</td><td>Pre-train data</td><td>Extra model</td><td>Mask token</td><td>Epochs</td><td>ViT-S</td><td>ViT-B</td></tr><tr><td>Scratch (Touvron et al.,2021a)</td><td>=</td><td>=</td><td>-</td><td>-</td><td>79.9</td><td>81.8</td></tr><tr><td>MoCo v3 (Chen et al.,2021)</td><td>IN-1K</td><td>momentum ViT</td><td></td><td>600</td><td>81.4+</td><td>83.2</td></tr><tr><td>DINO (Caron et al.,2021)</td><td>IN-1K</td><td>momentum ViT</td><td>=</td><td>1600</td><td>81.5</td><td>82.8</td></tr><tr><td>BEiT (Bao et al.,2022)</td><td>IN-1K+DALL-E</td><td>dVAE</td><td>√</td><td>300</td><td>81.3</td><td>82.9</td></tr><tr><td>MAE (He et al.,2022)</td><td>IN-1K</td><td>-</td><td>√</td><td>300</td><td>80.6</td><td>82.9</td></tr><tr><td>SR</td><td>IN-1K</td><td></td><td></td><td>300</td><td>80.8</td><td>82.4</td></tr><tr><td>Deblur</td><td>IN-1K</td><td></td><td></td><td>300</td><td>79.4</td><td>81.7</td></tr><tr><td>Denoise</td><td>IN-1K</td><td></td><td></td><td>300</td><td>81.1</td><td>82.7</td></tr><tr><td>MFM</td><td>IN-1K</td><td></td><td></td><td>300</td><td>81.6</td><td>83.1</td></tr></table>
177
+
178
+ Table 4: ImageNet-1K top-1 fine-tuning accuracy of self-supervised models using ResNet-50 as the encoder. Table is split to three sub-tables for better placement. Results for other methods are taken from Fang et al. (2022) as we adopt the same fine-tuning recipe. †: modified ResNet-50 architecture.
179
+
180
+ (a) Training-from-scratch baselines.
181
+
182
+ (b) Fine-tuning for 100 epochs.
183
+
184
+ <table><tr><td>Method</td><td>Epochs</td><td>Top-1 acc (%)</td></tr><tr><td>RSB A3</td><td>-</td><td>78.1</td></tr><tr><td>SR</td><td>300</td><td>77.9</td></tr><tr><td>Deblur</td><td>300</td><td>78.0</td></tr><tr><td>Denoise</td><td>300</td><td>77.5</td></tr><tr><td>MFM</td><td>300</td><td>78.5</td></tr></table>
185
+
186
+ <table><tr><td>Method</td><td>Epochs</td><td>Top-1 acc (%)</td></tr><tr><td>Original90</td><td>=</td><td>75.3</td></tr><tr><td>PyTorch90</td><td></td><td>76.1</td></tr><tr><td>FixReS120</td><td></td><td>77.0</td></tr><tr><td>DeiT300</td><td></td><td>78.4</td></tr><tr><td></td><td></td><td>78.8</td></tr><tr><td>FAMS400</td><td></td><td>79.5</td></tr></table>
187
+
188
+ <table><tr><td colspan="3">(c) Fine-tuning for 300 epochs.</td></tr><tr><td>Method</td><td>Epochs</td><td>Top-1 acc (%)</td></tr><tr><td>RSB A2</td><td>-</td><td>79.8</td></tr><tr><td>SimSiam</td><td>400</td><td>79.1</td></tr><tr><td>MoCo v2</td><td>400</td><td>79.6</td></tr><tr><td>SimCLR</td><td>800</td><td>79.9</td></tr><tr><td>BYOL</td><td>400</td><td>80.0</td></tr><tr><td>SwAV</td><td>600</td><td>80.1</td></tr><tr><td>MFM</td><td>300</td><td>80.1</td></tr></table>
189
+
190
+ ViT. In Table 3, we compare the ImageNet-1K end-to-end fine-tuning results of self-supervised ViTS/16 and ViT-B/16 models. We fine-tune ViT-S/16 for 200 epochs, and ViT-B/16 for 100 epochs. Other self-supervised models use the same or longer fine-tuning schedule. Compared with other representative self-supervised learners, our MFM can achieve comparable performance with fewer pre-training epochs while using none of the following: (i) extra data, (ii) extra model, (iii) mask token. This demonstrates the great potential of masked frequency modeling.
191
+
192
+ ResNet-50. We demonstrate that MFM can also pre-train a high-capacity ResNet-50 model. We simply adopt the same pre-training settings as ViT. During fine-tuning, we generally follow the advanced vanilla ResNet “training from scratch” recipe in RSB (Wightman et al., 2021) except that we use the AdamW optimizer (Loshchilov & Hutter, 2017) following Fang et al. (2022). Table 4 shows the results. Different from ViT, we observe performance degeneration of low-level image processing tasks like SR, deblurring and denoising compared with the RSB training-from-scratch baseline (Table 4b). We hypothesize this discrepancy is due to the architectural difference between ViT and CNN. Compared with ViT, the convolution operation in CNN tends to be more effective in capturing high-frequency components. Thus, encouraging a CNN model to reconstruct high-frequency components of images brings no benefits to the performance. Instead, learning high-frequency information can compensate for the ability of ViT models in capturing the high-frequency components. In contrast, our MFM outperforms its supervised counterparts in both ViT and CNN architectures as it leverages both low- and high-frequency components. Even under a demanding training procedure, e.g., fine-tuning for 300 epochs (Table 4c), MFM can still improve the supervised RSB A2 baseline by $0 . 3 \%$ and surpass several representative contrastive-based self-supervised learning methods.
193
+
194
+ # 4.4.2 SEMANTIC SEGMENTATION
195
+
196
+ We evaluate MFM and low-level image processing tasks on the ADE20K semantic segmentation benchmark. We use UperNet (Xiao et al., 2018) and adopt the same setup following BEiT (Bao et al., 2022). All models are fine-tuned for 160K iterations with an input resolution of $5 1 2 \times 5 1 2$ . As shown in Table 5, our corruption-based models can achieve competitive performance compared with other representative self-supervised learners that are usually more expensive to compute.
197
+
198
+ Table 5: ADE20K semantic segmentation (mIoU) of ViT-B/16 models.
199
+
200
+ <table><tr><td>Method</td><td>mIoU</td></tr><tr><td>Supervised (Touvron et al.,2021a)</td><td>45.3</td></tr><tr><td>MoCo v3 (Chen et al.,2021) DINO (Caron et al.,2021)</td><td>47.2 46.8</td></tr><tr><td>BEiT (Bao et al.,2022) MAE (He et al., 2022)</td><td>47.7 48.1</td></tr><tr><td>SR</td><td>48.5</td></tr><tr><td>Deblur Denoise</td><td>47.0</td></tr><tr><td>MFM</td><td>47.6 48.6</td></tr></table>
201
+
202
+ Table 6: Robustness evaluation on six robustness benchmarks. We report top-1 accuracy of ViTB/16 (left) and ResNet-50 (right) models except for IN-C that uses the mean corruption error (mCE). The original ImageNet top-1 fine-tuning results are also appended for reference. The best results are in bold, and the second best results are underlined.
203
+
204
+ <table><tr><td rowspan="2">Method</td><td colspan="6">Robustness benchmarks</td><td rowspan="2">Orig.</td></tr><tr><td>FGSM</td><td>PGD</td><td>IN-C (↓)</td><td>IN-A</td><td>IN-R</td><td>IN-SK</td></tr><tr><td>Scratch</td><td>46.3</td><td>21.2</td><td>48.5</td><td>28.1</td><td>44.7</td><td>32.0</td><td>81.8</td></tr><tr><td>MAE</td><td>38.9</td><td>11.2</td><td>52.3</td><td>31.5</td><td>48.3</td><td>33.8</td><td>82.9</td></tr><tr><td>SR</td><td>46.1</td><td>21.5</td><td>46.3</td><td>29.1</td><td>49.2</td><td>35.5</td><td>82.4</td></tr><tr><td>Deblur</td><td>42.5</td><td>17.2</td><td>49.2</td><td>25.3</td><td>46.9</td><td>33.2</td><td>81.7</td></tr><tr><td>Denoise</td><td>47.6</td><td>24.3</td><td>47.8</td><td>30.7</td><td>48.4</td><td>34.8</td><td>82.7</td></tr><tr><td>MFM</td><td>47.7</td><td>24.4</td><td>47.5</td><td>32.7</td><td>48.6</td><td>34.8</td><td>83.1</td></tr></table>
205
+
206
+ <table><tr><td rowspan="2">Method</td><td colspan="6">Robustness benchmarks</td><td rowspan="2">Orig.</td></tr><tr><td>FGSM</td><td>PGD</td><td>IN-C (↓)</td><td>IN-A</td><td>IN-R</td><td>IN-SK</td></tr><tr><td>Scratch</td><td>20.2</td><td>3.4</td><td>77.0</td><td>6.6</td><td>36.0</td><td>25.0</td><td>78.1</td></tr><tr><td>SimMIM</td><td>16.8</td><td>2.1</td><td>77.0</td><td>5.7</td><td>34.9</td><td>24.2</td><td>77.7</td></tr><tr><td>SR</td><td>17.2</td><td>1.9</td><td>73.6</td><td>6.5</td><td>35.8</td><td>25.4</td><td>77.9</td></tr><tr><td>Deblur</td><td>17.2</td><td>2.0</td><td>74.8</td><td>8.2</td><td>37.2</td><td>26.5</td><td>78.0</td></tr><tr><td>Denoise</td><td>15.8</td><td>1.8</td><td>78.0</td><td>7.2</td><td>35.6</td><td>24.7</td><td>77.5</td></tr><tr><td>MFM</td><td>18.5</td><td>2.3</td><td>74.2</td><td>9.0</td><td>36.9</td><td>26.7</td><td>78.5</td></tr></table>
207
+
208
+ # 4.5 ROBUSTNESS EVALUATION
209
+
210
+ We evaluate the robustness of our models on a series of benchmarks in three aspects: (i) adversarial robustness, (ii) common corruption robustness, and (iii) out-of-distribution robustness. For (i), we study the adversarial examples generated by white-box attackers (e.g., FGSM (Goodfellow et al., 2014) and PGD (Madry et al., 2017)) on ImageNet-1K validation set as well as natural adversarial examples on ImageNet-A (Hendrycks et al., 2021b); for (ii), we evaluate on ImageNet-C (Hendrycks & Dietterich, 2019) that includes 15 types of algorithmically generated corruptions with five levels of severity; for (iii), we test on ImageNet-R (Hendrycks et al., 2021a) and ImageNet-Sketch (Wang et al., 2019) that contain images with naturally occurring distribution shifts. We evaluate the same models fine-tuned on original ImageNet-1K (ViT-B/16 in Table 3 and ResNet-50 in Table 4b) without any specialized fine-tuning on the different validation sets. As shown in Table 6, we can conclude three observations: 1) Transformer-based models (e.g., ViT) are more robust than the CNN counterparts (e.g., ResNet-50). 2) Corruption-based tasks (e.g., SR, Deblur, Denoise and MFM) are generally more robust than the MIM task (e.g., MAE and SimMIM). 3) MFM achieves the best trade-off between standard performance and robustness (the robustness of MFM always ranks within the top two, while the standard accuracy is the best).
211
+
212
+ # 5 CONCLUSION
213
+
214
+ In this work, we have studied the effectiveness of low-level image processing tasks for visual representation learning from a new frequency perspective and introduced a unified, flexible and robust self-supervised visual pre-training framework to perform image corruptions in the frequency domain. We show that without relying on mask tokens or more complex designs (e.g., discrete visual tokens), a simple mask-frequency strategy can achieve competitive performance for both ViT and CNN. We hope our unique frequency perspective can motivate the community to rethink the role of low-level tasks for unsupervised representation learning.
215
+
216
+ # ETHICS STATEMENT
217
+
218
+ The proposed method learns statistics of the training dataset and may reflect the biases in the data. Debiased measures thus have to be taken. The method may be deployed with large-scale models and data, causing negative impacts on the environment.
219
+
220
+ # REPRODUCIBILITY STATEMENT
221
+
222
+ We provide detailed hyper-parameter specifications for our experiments in the main text (Section 4) and the supplementary material (Appendix G) to ensure reproducibility. Code and models will be released at https://www.mmlab-ntu.com/project/mfm/index.html to facilitate future research.
223
+
224
+ # ACKNOWLEDGEMENTS
225
+
226
+ This work is supported by NTU NAP, MOE AcRF Tier 2 (MOE-T2EP20120-0001, MOET2EP20221-0012), and under the RIE2020 Industry Alignment Fund – Industry Collaboration Projects (IAF-ICP) Funding Initiative, as well as cash and in-kind contribution from the industry partner(s).
227
+
228
+ # REFERENCES
229
+
230
+ Mahmoud Assran, Mathilde Caron, Ishan Misra, Piotr Bojanowski, Florian Bordes, Pascal Vincent, Armand Joulin, Michael Rabbat, and Nicolas Ballas. Masked siamese networks for label-efficient learning. arXiv preprint arXiv:2204.07141, 2022.
231
+
232
+ Alexei Baevski, Wei-Ning Hsu, Qiantong Xu, Arun Babu, Jiatao Gu, and Michael Auli. Data2vec: A general framework for self-supervised learning in speech, vision and language. arXiv preprint arXiv:2202.03555, 2022.
233
+
234
+ Hangbo Bao, Li Dong, Songhao Piao, and Furu Wei. Beit: Bert pre-training of image transformers. In ICLR, 2022.
235
+
236
+ Maxim Berman, Herve J ´ egou, Andrea Vedaldi, Iasonas Kokkinos, and Matthijs Douze. Multigrain:´ a unified image embedding for classes and instances. arXiv preprint arXiv:1902.05509, 2019.
237
+
238
+ Piotr Bojanowski and Armand Joulin. Unsupervised learning by predicting noise. In ICML, 2017.
239
+
240
+ Tom Brown, Benjamin Mann, Nick Ryder, Melanie Subbiah, Jared D Kaplan, Prafulla Dhariwal, Arvind Neelakantan, Pranav Shyam, Girish Sastry, Amanda Askell, et al. Language models are few-shot learners. In NeurIPS, 2020.
241
+
242
+ Mathilde Caron, Hugo Touvron, Ishan Misra, Herve J ´ egou, Julien Mairal, Piotr Bojanowski, and ´ Armand Joulin. Emerging properties in self-supervised vision transformers. In ICCV, 2021.
243
+
244
+ Mark Chen, Alec Radford, Rewon Child, Jeffrey Wu, Heewoo Jun, David Luan, and Ilya Sutskever. Generative pretraining from pixels. In ICML, 2020a.
245
+
246
+ Ting Chen, Simon Kornblith, Mohammad Norouzi, and Geoffrey Hinton. A simple framework for contrastive learning of visual representations. In ICML, 2020b.
247
+
248
+ Xiaokang Chen, Mingyu Ding, Xiaodi Wang, Ying Xin, Shentong Mo, Yunhao Wang, Shumin Han, Ping Luo, Gang Zeng, and Jingdong Wang. Context autoencoder for self-supervised representation learning. arXiv preprint arXiv:2202.03026, 2022.
249
+
250
+ Xinlei Chen and Kaiming He. Exploring simple siamese representation learning. In CVPR, 2021.
251
+
252
+ Xinlei Chen, Haoqi Fan, Ross Girshick, and Kaiming He. Improved baselines with momentum contrastive learning. arXiv preprint arXiv:2003.04297, 2020c.
253
+
254
+ Xinlei Chen, Saining Xie, and Kaiming He. An empirical study of training self-supervised vision transformers. In ICCV, 2021.
255
+
256
+ Kevin Clark, Minh-Thang Luong, Quoc V Le, and Christopher D Manning. Electra: Pre-training text encoders as discriminators rather than generators. arXiv preprint arXiv:2003.10555, 2020.
257
+
258
+ Ekin D Cubuk, Barret Zoph, Jonathon Shlens, and Quoc V Le. Randaugment: Practical automated data augmentation with a reduced search space. In CVPRW, 2020.
259
+
260
+ Jia Deng, Wei Dong, Richard Socher, Li-Jia Li, Kai Li, and Li Fei-Fei. Imagenet: A large-scale hierarchical image database. In CVPR, 2009.
261
+
262
+ Jacob Devlin, Ming-Wei Chang, Kenton Lee, and Kristina Toutanova. Bert: Pre-training of deep bidirectional transformers for language understanding. In NAACL, 2019.
263
+
264
+ Carl Doersch, Abhinav Gupta, and Alexei A Efros. Unsupervised visual representation learning by context prediction. In ICCV, 2015.
265
+
266
+ Chao Dong, Chen Change Loy, Kaiming He, and Xiaoou Tang. Image super-resolution using deep convolutional networks. TPAMI, 2015.
267
+
268
+ Xiaoyi Dong, Jianmin Bao, Ting Zhang, Dongdong Chen, Weiming Zhang, Lu Yuan, Dong Chen, Fang Wen, and Nenghai Yu. Peco: Perceptual codebook for bert pre-training of vision transformers. arXiv preprint arXiv:2111.12710, 2021.
269
+
270
+ Alexey Dosovitskiy, Lucas Beyer, Alexander Kolesnikov, Dirk Weissenborn, Xiaohua Zhai, Thomas Unterthiner, Mostafa Dehghani, Matthias Minderer, Georg Heigold, Sylvain Gelly, et al. An image is worth 16x16 words: Transformers for image recognition at scale. In ICLR, 2020.
271
+
272
+ Alaaeldin El-Nouby, Gautier Izacard, Hugo Touvron, Ivan Laptev, Herve Jegou, and Edouard ´ Grave. Are large-scale datasets necessary for self-supervised pre-training? arXiv preprint arXiv:2112.10740, 2021.
273
+
274
+ Yuxin Fang, Li Dong, Hangbo Bao, Xinggang Wang, and Furu Wei. Corrupted image modeling for self-supervised visual pre-training. arXiv preprint arXiv:2202.03382, 2022.
275
+
276
+ Spyros Gidaris, Praveer Singh, and Nikos Komodakis. Unsupervised representation learning by predicting image rotations. In ICLR, 2018.
277
+
278
+ Ian J Goodfellow, Jonathon Shlens, and Christian Szegedy. Explaining and harnessing adversarial examples. arXiv preprint arXiv:1412.6572, 2014.
279
+
280
+ Jean-Bastien Grill, Florian Strub, Florent Altche, Corentin Tallec, Pierre H Richemond, Elena ´ Buchatskaya, Carl Doersch, Bernardo Avila Pires, Zhaohan Daniel Guo, Mohammad Gheshlaghi Azar, et al. Bootstrap your own latent: A new approach to self-supervised learning. In NeurIPS, 2020.
281
+
282
+ Bruce C Hansen and Robert F Hess. Structural sparseness and spatial phase alignment in natural scenes. JOSA A, 2007.
283
+
284
+ Kaiming He, Xiangyu Zhang, Shaoqing Ren, and Jian Sun. Deep residual learning for image recognition. In CVPR, 2016.
285
+
286
+ Kaiming He, Haoqi Fan, Yuxin Wu, Saining Xie, and Ross Girshick. Momentum contrast for unsupervised visual representation learning. In CVPR, 2020.
287
+
288
+ Kaiming He, Xinlei Chen, Saining Xie, Yanghao Li, Piotr Dollar, and Ross Girshick. Masked ´ autoencoders are scalable vision learners. In CVPR, 2022.
289
+
290
+ Dan Hendrycks and Thomas Dietterich. Benchmarking neural network robustness to common corruptions and perturbations. arXiv preprint arXiv:1903.12261, 2019.
291
+
292
+ Dan Hendrycks, Steven Basart, Norman Mu, Saurav Kadavath, Frank Wang, Evan Dorundo, Rahul Desai, Tyler Zhu, Samyak Parajuli, Mike Guo, et al. The many faces of robustness: A critical analysis of out-of-distribution generalization. In ICCV, 2021a.
293
+
294
+ Dan Hendrycks, Kevin Zhao, Steven Basart, Jacob Steinhardt, and Dawn Song. Natural adversarial examples. In CVPR, 2021b.
295
+
296
+ Elad Hoffer, Tal Ben-Nun, Itay Hubara, Niv Giladi, Torsten Hoefler, and Daniel Soudry. Augment your batch: better training with larger batches. arXiv preprint arXiv:1901.09335, 2019.
297
+
298
+ Gao Huang, Yu Sun, Zhuang Liu, Daniel Sedra, and Kilian Q Weinberger. Deep networks with stochastic depth. In ECCV, 2016.
299
+
300
+ Liming Jiang, Bo Dai, Wayne Wu, and Chen Change Loy. Focal frequency loss for image reconstruction and synthesis. In ICCV, 2021.
301
+
302
+ Gustav Larsson, Michael Maire, and Gregory Shakhnarovich. Learning representations for automatic colorization. In ECCV, 2016.
303
+
304
+ Yann LeCun, Bernhard Boser, John S Denker, Donnie Henderson, Richard E Howard, Wayne Hubbard, and Lawrence D Jackel. Backpropagation applied to handwritten zip code recognition. Neural computation, 1989.
305
+
306
+ Hao Liu, Xinghua Jiang, Xin Li, Antai Guo, Deqiang Jiang, and Bo Ren. The devil is in the frequency: Geminated gestalt autoencoder for self-supervised visual pre-training. arXiv preprint arXiv:2204.08227, 2022.
307
+
308
+ Ze Liu, Yutong Lin, Yue Cao, Han Hu, Yixuan Wei, Zheng Zhang, Stephen Lin, and Baining Guo. Swin transformer: Hierarchical vision transformer using shifted windows. In ICCV, 2021.
309
+
310
+ Ilya Loshchilov and Frank Hutter. Decoupled weight decay regularization. arXiv preprint arXiv:1711.05101, 2017.
311
+
312
+ Aleksander Madry, Aleksandar Makelov, Ludwig Schmidt, Dimitris Tsipras, and Adrian Vladu. Towards deep learning models resistant to adversarial attacks. arXiv preprint arXiv:1706.06083, 2017.
313
+
314
+ Ishan Misra and Laurens van der Maaten. Self-supervised learning of pretext-invariant representations. In CVPR, 2020.
315
+
316
+ Mehdi Noroozi and Paolo Favaro. Unsupervised learning of visual representations by solving jigsaw puzzles. In ECCV, 2016.
317
+
318
+ Mehdi Noroozi, Hamed Pirsiavash, and Paolo Favaro. Representation learning by learning to count. In ICCV, 2017.
319
+
320
+ Henri J Nussbaumer. The fast fourier transform. In Fast Fourier Transform and Convolution Algorithms, pp. 80–111. Springer, 1981.
321
+
322
+ A Oppenheim, Jae Lim, Gary Kopec, and SC Pohlig. Phase in speech and pictures. In ICASSP, 1979.
323
+
324
+ Alan V Oppenheim and Jae S Lim. The importance of phase in signals. Proc. IEEE, 1981.
325
+
326
+ Yingxue Pang, Xin Li, Xin Jin, Yaojun Wu, Jianzhao Liu, Sen Liu, and Zhibo Chen. Fan: frequency aggregation network for real image super-resolution. In ECCV, 2020.
327
+
328
+ Deepak Pathak, Philipp Krahenbuhl, Jeff Donahue, Trevor Darrell, and Alexei A Efros. Context encoders: Feature learning by inpainting. In CVPR, 2016.
329
+
330
+ Deepak Pathak, Ross Girshick, Piotr Dollar, Trevor Darrell, and Bharath Hariharan. Learning fea-´ tures by watching objects move. In CVPR, 2017.
331
+
332
+ Leon N Piotrowski and Fergus W Campbell. A demonstration of the visual importance and flexibility of spatial-frequency amplitude and phase. Perception, 1982.
333
+
334
+ Yada Pruksachatkun, Jason Phang, Haokun Liu, Phu Mon Htut, Xiaoyi Zhang, Richard Yuanzhe Pang, Clara Vania, Katharina Kann, and Samuel R Bowman. Intermediate-task transfer learning with pretrained models for natural language understanding: When and why does it work? In ACL, 2020.
335
+
336
+ Alec Radford, Karthik Narasimhan, Tim Salimans, and Ilya Sutskever. Improving language understanding by generative pre-training. 2018.
337
+
338
+ Alec Radford, Jeffrey Wu, Rewon Child, David Luan, Dario Amodei, Ilya Sutskever, et al. Language models are unsupervised multitask learners. OpenAI blog, 2019.
339
+
340
+ Aditya Ramesh, Mikhail Pavlov, Gabriel Goh, Scott Gray, Chelsea Voss, Alec Radford, Mark Chen, and Ilya Sutskever. Zero-shot text-to-image generation. In ICML, 2021.
341
+
342
+ Yuge Shi, N Siddharth, Philip Torr, and Adam R Kosiorek. Adversarial masking for self-supervised learning. In ICML, 2022.
343
+
344
+ Nitish Srivastava, Geoffrey Hinton, Alex Krizhevsky, Ilya Sutskever, and Ruslan Salakhutdinov. Dropout: a simple way to prevent neural networks from overfitting. JMLR, 2014.
345
+
346
+ Christian Szegedy, Vincent Vanhoucke, Sergey Ioffe, Jon Shlens, and Zbigniew Wojna. Rethinking the inception architecture for computer vision. In CVPR, 2016.
347
+
348
+ Hugo Touvron, Matthieu Cord, Matthijs Douze, Francisco Massa, Alexandre Sablayrolles, and Herve J ´ egou. Training data-efficient image transformers & distillation through attention. In ´ ICML, 2021a.
349
+
350
+ Hugo Touvron, Matthieu Cord, Alexandre Sablayrolles, Gabriel Synnaeve, and Herve J ´ egou. Going ´ deeper with image transformers. In ICCV, 2021b.
351
+
352
+ Ashish Vaswani, Noam Shazeer, Niki Parmar, Jakob Uszkoreit, Llion Jones, Aidan N Gomez, Łukasz Kaiser, and Illia Polosukhin. Attention is all you need. In NeurIPS, 2017.
353
+
354
+ Pascal Vincent, Hugo Larochelle, Isabelle Lajoie, Yoshua Bengio, Pierre-Antoine Manzagol, and Leon Bottou. Stacked denoising autoencoders: Learning useful representations in a deep network ´ with a local denoising criterion. JMLR, 2010.
355
+
356
+ Haohan Wang, Songwei Ge, Zachary Lipton, and Eric P Xing. Learning robust global representations by penalizing local predictive power. In NeurIPS, 2019.
357
+
358
+ Xiaolong Wang and Abhinav Gupta. Unsupervised learning of visual representations using videos. In ICCV, 2015.
359
+
360
+ Xintao Wang, Liangbin Xie, Chao Dong, and Ying Shan. Real-esrgan: Training real-world blind super-resolution with pure synthetic data. In ICCVW, 2021.
361
+
362
+ Chen Wei, Haoqi Fan, Saining Xie, Chao-Yuan Wu, Alan Yuille, and Christoph Feichtenhofer. Masked feature prediction for self-supervised visual pre-training. In CVPR, 2022.
363
+
364
+ Ross Wightman, Hugo Touvron, and Herve J ´ egou. Resnet strikes back: An improved training ´ procedure in timm. arXiv preprint arXiv:2110.00476, 2021.
365
+
366
+ Zhirong Wu, Yuanjun Xiong, Stella X Yu, and Dahua Lin. Unsupervised feature learning via nonparametric instance discrimination. In CVPR, 2018.
367
+
368
+ Tete Xiao, Yingcheng Liu, Bolei Zhou, Yuning Jiang, and Jian Sun. Unified perceptual parsing for scene understanding. In ECCV, 2018.
369
+
370
+ Zhenda Xie, Zheng Zhang, Yue Cao, Yutong Lin, Jianmin Bao, Zhuliang Yao, Qi Dai, and Han Hu. Simmim: A simple framework for masked image modeling. In CVPR, 2022.
371
+
372
+ Qinwei Xu, Ruipeng Zhang, Ya Zhang, Yanfeng Wang, and Qi Tian. A fourier-based framework for domain generalization. In CVPR, 2021.
373
+
374
+ Sangdoo Yun, Dongyoon Han, Seong Joon Oh, Sanghyuk Chun, Junsuk Choe, and Youngjoon Yoo. Cutmix: Regularization strategy to train strong classifiers with localizable features. In ICCV, 2019.
375
+
376
+ Hongyi Zhang, Moustapha Cisse, Yann N Dauphin, and David Lopez-Paz. mixup: Beyond empirical risk minimization. arXiv preprint arXiv:1710.09412, 2017a.
377
+
378
+ Kai Zhang, Wangmeng Zuo, Yunjin Chen, Deyu Meng, and Lei Zhang. Beyond a gaussian denoiser: Residual learning of deep cnn for image denoising. TIP, 2017b.
379
+
380
+ Kaihao Zhang, Wenqi Ren, Wenhan Luo, Wei-Sheng Lai, Bjorn Stenger, Ming-Hsuan Yang, and Hongdong Li. Deep image deblurring: A survey. arXiv preprint arXiv:2201.10700, 2022.
381
+
382
+ Richard Zhang, Phillip Isola, and Alexei A Efros. Colorful image colorization. In ECCV, 2016.
383
+
384
+ Richard Zhang, Phillip Isola, and Alexei A Efros. Split-brain autoencoders: Unsupervised learning by cross-channel prediction. In CVPR, 2017c.
385
+
386
+ Bolei Zhou, Hang Zhao, Xavier Puig, Sanja Fidler, Adela Barriuso, and Antonio Torralba. Scene parsing through ade20k dataset. In CVPR, 2017.
387
+
388
+ Jinghao Zhou, Chen Wei, Huiyu Wang, Wei Shen, Cihang Xie, Alan Yuille, and Tao Kong. ibot: Image bert pre-training with online tokenizer. In ICLR, 2022.
389
+
390
+ A MORE ABLATIONS
391
+
392
+ Table 7: More Ablations for MFM on ImageNet-1K. All models are pre-trained for 300 epochs, and evaluated with top-1 fine-tuning accuracy. Default entry (the same settings as in Table 1 of the main text) is marked in gray .
393
+
394
+ (a) Decoder depth. A simple linear layer performs the best with lower training costs (Transformer blocks have a hidden size of 384 with 12 heads).
395
+
396
+ (b) Masking in different domains. Frequency masking is a more flexible and unified option for different architectures.
397
+
398
+ <table><tr><td>Decoder</td><td>Blocks</td><td>Top-1 acc (%)</td></tr><tr><td>linear</td><td>1</td><td>83.1</td></tr><tr><td rowspan="4">Transformer blocks</td><td>1</td><td>83.0</td></tr><tr><td>2</td><td>83.1</td></tr><tr><td>4</td><td>83.1</td></tr><tr><td>8</td><td>83.1</td></tr></table>
399
+
400
+ <table><tr><td>Arch.</td><td>Task</td><td>Top-1 acc (%)</td></tr><tr><td rowspan="2">ViT-B/16</td><td>MIM</td><td>82.8</td></tr><tr><td>MFM</td><td>83.1</td></tr><tr><td rowspan="2">ResNet-50</td><td>MIM</td><td>77.7</td></tr><tr><td>MFM</td><td>78.5</td></tr></table>
401
+
402
+ Decoder depth. Table 7a ablates the effect of different decoders. MFM can work the best with a simple linear layer while benefiting from lower training costs compared with a deeper decoder.
403
+
404
+ Frequency masking vs. spatial masking. Considering that different design choices in existing masked image modeling (MIM) methods could affect the performance significantly, to eliminate the interference of other factors, we directly replace our frequency-domain-based masking with spatialdomain-based random patch masking for a fair comparison. The results are shown in Table 7b. Applying MIM to ResNet-50 leads to inferior performance even than the supervised baseline (i.e., $7 8 . 1 \%$ in RSB A3 (Wightman et al., 2021)). In contrast, MFM outperforms the supervised RSB baseline as well as the MIM counterpart regardless of architectures, demonstrating that frequency masking is indeed a more flexible and unified option for different architectures.
405
+
406
+ # B TRAINING TIME COMPARISON
407
+
408
+ We measure the pre-training time per epoch in Table 8. Note that MoCo v3 (Chen et al., 2021) and DINO (Caron et al., 2021) need to switch two global views and have four and 14 forward passes in total, respectively. BEiT (Bao et al., 2022), MAE (He et al., 2022) and MFM are 1-view methods without switching. MFM is relatively efficient compared with other MIM methods (e.g., BEiT) except for MAE. However, taking only visible patches as input breaks the regular 2D structure of images, which makes MAE only applicable to ViT. In contrast, MFM is agnostic to architectures and can be flexibly applied for both ViT and CNN families. Considering the flexibility and universality of MFM, a slightly increasing time over MAE is acceptable.
409
+
410
+ Table 8: Training time comparison. The time is measured on the same 8-GPU machine with the same batch size using ViT-B/16, counted in relative to our approach. †: BEiT requires an additional stage to pre-train dVAE, which is not included.
411
+
412
+ <table><tr><td>Method</td><td>Setup</td><td>Time per epoch</td></tr><tr><td>MoCo v3</td><td>2-view, 4-pass</td><td>1.84×</td></tr><tr><td>DINO</td><td>(2+10)-view,14-pass</td><td>2.04×</td></tr><tr><td>BEiT</td><td>1-view, 2-pass</td><td>1.53×+</td></tr><tr><td>MAE</td><td>1-view,1-pass</td><td>0.82×</td></tr><tr><td>MFM</td><td>1-view, 1-pass</td><td>1.00×</td></tr></table>
413
+
414
+ # C COMBINATION OF LOW-LEVEL IMAGE PROCESSING TASKS
415
+
416
+ In Table 1a of the main text, we have shown that randomly sampling low-/high-pass filters to predict both high and low frequencies benefits as MFM can make full use of the frequency spectrum, thus leading to better performance. Here, we further study the effect of combining low-level image processing tasks, i.e., SR, deblurring and denoising. Table 9 reports the ImageNet-1K top-1 finetuning accuracy of ViT-B/16 models. We find that combining these low-level corruptions does not bring similar benefits as MFM and even degrades the performance.
417
+
418
+ Table 9: Combination of SR, deblurring, denoising tasks using ViT-B/16 on ImageNet-1K. All models are pre-trained for 300 epochs, and evaluated with top-1 fine-tuning accuracy.
419
+
420
+ <table><tr><td>Task</td><td>Top-1 acc (%)</td></tr><tr><td>Individual task:</td><td></td></tr><tr><td>SR</td><td>82.4</td></tr><tr><td>Deblur</td><td>81.7</td></tr><tr><td>Denoise</td><td>82.7</td></tr><tr><td>Integrated task:</td><td></td></tr><tr><td>SR+Denoise</td><td>82.2</td></tr><tr><td>Deblur+Denoise</td><td>82.5</td></tr></table>
421
+
422
+ # D FURTHER DISCUSSION
423
+
424
+ Mask tokens. In MIM methods, mask tokens are learnable patch embeddings inserted in the position where the input tokens are masked out. They are highly coupled with the Transformer architecture and not directly applicable to CNNs. Introducing special mask tokens in any intermediate stage of CNN is infeasible, as the intrinsic dense-sliding-window paradigm in convolution layers brings information leakage between visual features in previous layers (Fang et al., 2022). Thus, the large CNN family cannot directly benefit from this pre-training scheme like Transformers. In contrast, our MFM performs masking in the frequency domain without relying on mask tokens. Thus, MFM is agnostic to the architectures and can be flexibly applied for broader ViT and CNN families.
425
+
426
+ Table 10: System-level comparison with Siamese-based hybrid MIM methods (e.g., iBOT (Zhou et al., 2022) and data2vec (Baevski et al., 2022)) using ViT-B/16 on ImageNet-1K. For a fair comparison, we re-implement iBOT without multi-crop augmentation (but keeping the two global views) and data2vec (Baevski et al., 2022) without additional losses of intermediate Transformer layers using their official code. Training costs are counted in relative to our approach. Note that MFM is agnostic to architectures while these hybrid methods are not.
427
+
428
+ <table><tr><td>Method</td><td>Pre-text task</td><td>#Views</td><td>#Epochs</td><td>Top-1 acc (%)</td><td>Training costs</td></tr><tr><td>iBOT</td><td>MIM+CL</td><td>2</td><td>300</td><td>82.0</td><td>2.14×</td></tr><tr><td>data2vec</td><td>MIM+CL</td><td>2</td><td>300</td><td>83.0</td><td>1.60×</td></tr><tr><td>MFM</td><td>MFM</td><td>1</td><td>300</td><td>83.1</td><td>1.00×</td></tr></table>
429
+
430
+ Comparison with hybrid MIM methods. A line of recent research (Zhou et al., 2022; Baevski et al., 2022; Assran et al., 2022) combines MIM with contrastive learning (CL) into a Siamese framework and achieves better performance than a single task. Apart from adopting a Siamese network, additional techniques used in these works include multi-crop augmentation in Zhou et al. (2022); Assran et al. (2022) and multiple losses of intermediate Transformer layers in Baevski et al. (2022), without which their performance will be degraded significantly as shown in Table 10 (we take iBOT and data2vec as examples here since most of these works are concurrent to ours). Therefore, to eliminate the interference of other design factors, we mainly compare with pure MIM methods in our study. More advanced techniques used in these works may also be incorporated into MFM to further improve the performance, which is beyond the focus of this work.
431
+
432
+ Concurrent work. A concurrent work (Liu et al., 2022) also involves self-supervised learning in the frequency domain. Our work differs from theirs in the following aspects: 1) It aims at improving upon existing MIM approaches by additionally designing a more complex frequency decoder and computing losses in both spatial and frequency domain. In contrast, we aim at exploring an alternative frequency corruption strategy beyond MIM. Our method does not rely on any existing MIM approaches and we show that MFM can also work well independently. 2) It is based on MAE (He et al., 2022) and still performs spatial masking with mask tokens. Thus, it is still not applicable to CNNs, whereas our frequency-domain-based masking strategy is agnostic to architectures. 3) As opposed to Liu et al. (2022) that mainly targets at improving MIM performance, we comprehensively study the effectiveness of low-level image processing tasks for representation learning from a unified frequency perspective and provide rather different insights that other low-level tasks beyond MIM can also work well.
433
+
434
+ Limitations. Our study has several limitations: 1) We mainly focus on the architectural flexibility and universality of MFM, while leaving the scaling behaviour under-explored. 2) We mainly evaluate the quality of learned representations on representative benchmarks, i.e., ImageNet-1K image classification and ADE20K semantic segmentation, following Bao et al. (2022). The transferability on more downstream tasks can be studied in future research. 3) Despite the intriguing properties of the Fourier domain, the redundancy in frequencies may still exist. More advanced information suppression strategies can be further explored. We believe that our MFM can also complement contrastive learning and MIM approaches to further improve the performance. We leave these explorations for future work.
435
+
436
+ Future work. In this paper, we have shown that MFM is a simple, unified and flexible selfsupervised pretext task for various architectures. Compared with MIM, MFM can embrace broader architectures (e.g., ViT, CNN, etc.) and has more appealing robustness. Some possible future research directions may include: 1) More self-supervised learning works in the frequency domain with different modalities (e.g., image, video, audio, etc.). 2) Combine MFM with existing contrastive learning and MIM paradigms to further improve the performance. 3) Apply MFM for model robustness analysis and calibration. 4) The idea of MFM may also be used in low-level image reconstruction and synthesis tasks.
437
+
438
+ # E PSEUDOCODE
439
+
440
+ # Algorithm 1 Pseudocode of MFM in a PyTorch-like style.
441
+
442
+ # f: backbone encoder (e.g., vit, cnn) $^ +$ linear prediction head
443
+ # mask: frequency mask of low-/high-pass filters sampled with a Bernoulli distribution, i.e., mask $=$ Bernoulli(p) ? m : 1 - m (m is defined in Eq. (2), p is the probability of sampling a low-pass filter m) gamma: exponent to control the sharpness of the frequency distance
444
+ for (x, mask) in loader: # load a minibatch $_ \textrm { x }$ with N samples $\qquad \mathrm { \vartriangle { \mathbf { \Sigma } } } \times \quad =$ aug(x) # random view, NxCxHxW # convert spatial domain into frequency domain x_freq $=$ fft2(x) # 2D FFT x_freq $=$ fftshift(x_freq, dim $\underline { { \underline { { \mathbf { \Pi } } } } } =$ (-2, -1)) # shift low frequency to the center x_freq $=$ x_freq $\star$ mask # mask a portion of frequencies x_freq $=$ ifftshift(x_freq, dim $\underline { { \boldsymbol { \mathbf { \Pi } } } } =$ (-2, -1)) # restore the original frequency order # convert frequency domain back into spatial domain x_corrupted $=$ ifft2(x_freq).real # 2D iFFT (only keep the real part) x_predicted $=$ f(x_corrupted) # predicted view, NxCxHxW loss $=$ FrequencyLoss(x_predicted, x, gamma) # frequency loss # only compute the frequency loss on the masked area loss $=$ (loss $\star$ (1 - mask)).sum() / (1 - mask).sum()
445
+
446
+ # update model loss.backward() update(f)
447
+
448
+ def FrequencyLoss(x, y, gamma): x_freq, y_freq $=$ fft2(x), fft2(y) # 2D FFT # shift low frequency to the center x_freq $=$ fftshift(x_freq, dim $1 { = }$ (-2, -1)) y_freq $=$ fftshift(y_freq, dim $\underline { { \underline { { \mathbf { \Pi } } } } } =$ (-2, -1)) # stack the real and imaginary parts along the last dimension x_freq $=$ stack([x_freq.real, x_freq.imag], -1) y_freq $=$ stack([y_freq.real, y_freq.imag], -1) # compute the frequency distance d = (x_freq - y_freq) \*\* 2 return (d[..., 0] + d[..., 1]) \*\* (0.5 \* gamma)
449
+
450
+ ![](images/dc4803776609b59b411d450718897d6279b737fedea7d5714baeb2cbefeaa24e.jpg)
451
+ Figure 3: Example frequency spectrums of spatial-domain-based random patch masking from ImageNet-1K training set. The masking ratio is $7 5 \%$ . Performing patch-wise masking in the spatial domain incurs grid-wise artifacts on the frequency spectrum.
452
+
453
+ # F FREQUENCY SPECTRUM OF MIM
454
+
455
+ Figure 3 visualizes some example frequency spectrums of spatial-domain-based random patch masking used in MIM. Performing patch-wise masking in the spatial domain incurs grid-wise artifacts on the frequency spectrum, preventing further meaningful observations.
456
+
457
+ # G IMPLEMENTATION DETAILS
458
+
459
+ Pre-training. Table 11 summarizes the pre-training settings for vanilla ViT and ResNet-50 models. All experiments are conducted on 16 V100 32G GPUs for ViT models and 8 V100 32G GPUs for ResNet-50. The configurations are shared by different architectures, without specialized tuning. This demonstrates that MFM is general across architectures.
460
+
461
+ Fine-tuning. Table 12 and Table 13 summarize the fine-tuning settings for vanilla ViT and ResNet50 models, respectively. The configurations for ViT are shared across models, except that smaller models are fine-tuned longer. The configurations for ResNet-50 basically follow Wightman et al. (2021), except that we adopt the AdamW optimizer following Fang et al. (2022).
462
+
463
+ Semantic segmentation on ADE20K. We use UperNet (Xiao et al., 2018) following the configurations in BEiT (Bao et al., 2022). Specifically, we use AdamW as the optimizer and fine-tune for 160K iterations with a batch size of 16. We search the learning rate for all the results in Table 5 of the main text. The input resolution is $5 1 2 \times 5 1 2$ , and we use single-scale inference. As suggested in BEiT (Bao et al., 2022), we initialize all segmentation models using model weights after supervised fine-tuning on ImageNet-1K, following the common practice of BERT (Devlin et al., 2019) fine-tuning in NLP (Pruksachatkun et al., 2020).
464
+
465
+ Table 11: Pre-training settings for vanilla ViT-S/16, ViT-B/16 and ResNet-50 models on ImageNet-1K. Note that we adopt the same pre-training configurations across different architectures without further parameter tuning.
466
+
467
+ <table><tr><td>Configuration</td><td>Value</td></tr><tr><td>Optimizer</td><td>AdamW (Loshchilov &amp; Hutter,2017)</td></tr><tr><td>Pre-training epochs</td><td>300</td></tr><tr><td>Peak learning rate</td><td>1.2e-3</td></tr><tr><td>Batch size</td><td>2048</td></tr><tr><td>Weight decay</td><td>0.05</td></tr><tr><td>Optimizer momentum</td><td>β1,β2 = 0.9,0.95 (Chen et al.,2020a)</td></tr><tr><td>Learning rate schedule</td><td>Cosine decay</td></tr><tr><td>Warmup epochs</td><td>20</td></tr><tr><td>Gradient clipping</td><td>3.0</td></tr><tr><td>Dropout (Srivastava et al., 2014)</td><td>X</td></tr><tr><td>Stochastic depth (Huang et al.,2016)</td><td>X</td></tr><tr><td>LayerScale (Touvron et al., 2021b)</td><td>X</td></tr><tr><td>Data augmentation</td><td>RandomResizedCrop</td></tr><tr><td>Pos.emb.in Transformer layers</td><td>1-D absolute pos. emb. (Dosovitskiy et al., 2020)</td></tr><tr><td>Patch size</td><td>16</td></tr><tr><td>Pre-training resolution</td><td>224</td></tr></table>
468
+
469
+ Table 12: Fine-tuning settings for vanilla ViT-S/16 and ViT-B/16 on ImageNet-1K. We fine-tune ViT-S/16 for 200 epochs, and ViT-B/16 for 100 epochs. All other hyper-parameters are the same.
470
+
471
+ <table><tr><td>Configuration</td><td>Value</td></tr><tr><td>Optimizer</td><td>AdamW (Loshchilov &amp; Hutter,2017)</td></tr><tr><td>Fine-tuning epochs</td><td>200 (S),100 (B)</td></tr><tr><td>Peak learning rate</td><td>8e-3</td></tr><tr><td>Layer-wise learning rate decay (Bao et al.,2022)</td><td>0.8 (Clark et al., 2020)</td></tr><tr><td>Batch size</td><td>2048</td></tr><tr><td>Weight decay</td><td>0.05</td></tr><tr><td>Optimizer momentum</td><td>β1,β2 = 0.9,0.999</td></tr><tr><td>Learning rate schedule</td><td>Cosine decay</td></tr><tr><td>Warmup epochs</td><td>5</td></tr><tr><td>Loss function</td><td>Cross-entropy loss</td></tr><tr><td>Gradient clipping</td><td>X</td></tr><tr><td>Dropout (Srivastava et al., 2014)</td><td>X</td></tr><tr><td>Stochastic depth (Huang et al., 2016)</td><td>0.1</td></tr><tr><td>Mixup (Zhang et al., 2017a)</td><td>0.8</td></tr><tr><td>Cutmix (Yun et al.,2019)</td><td>1.0</td></tr><tr><td>Label smoothing (Szegedy et al., 2016)</td><td>0.1</td></tr><tr><td>Random augmentation (Cubuk et al., 2020)</td><td>9 /0.5</td></tr><tr><td>Patch size</td><td>16</td></tr><tr><td>Fine-tuning resolution</td><td>224</td></tr><tr><td>Test resolution</td><td>224</td></tr></table>
472
+
473
+ Table 13: Fine-tuning settings for vanilla ResNet-50 on ImageNet-1K. The hyper-parameters generally follow Wightman et al. (2021), except that we adopt the AdamW optimizer following Fang et al. (2022).
474
+
475
+ <table><tr><td>Configuration</td><td>100 epoch FT</td><td>300 epoch FT</td></tr><tr><td>Optimizer</td><td colspan="2">AdamW (Loshchilov &amp; Hutter,2017)</td></tr><tr><td>Peak learning rate</td><td colspan="2">12e-3</td></tr><tr><td>Layer-wise learning rate decay (Bao et al., 2022)</td><td colspan="2">X</td></tr><tr><td>Batch size</td><td colspan="2">2048</td></tr><tr><td>Weight decay</td><td colspan="2">0.02</td></tr><tr><td>Learning rate schedule</td><td colspan="2">Cosine decay</td></tr><tr><td>Warmup epochs</td><td colspan="2">5</td></tr><tr><td>Loss function</td><td colspan="2">Binary cross-entropy loss</td></tr><tr><td>Gradient clipping</td><td colspan="2">X</td></tr><tr><td>Dropout (Srivastava et al.,2014)</td><td colspan="2">X</td></tr><tr><td>Stochastic depth (Huang et al., 2016)</td><td colspan="2">X</td></tr><tr><td>Mixup (Zhang et al.,2017a)</td><td colspan="2">0.1</td></tr><tr><td>Cutmix (Yun et al., 2019)</td><td>1.0</td><td></td></tr><tr><td>Label smoothing (Szegedy et al., 2016)</td><td>0.1</td><td>×</td></tr><tr><td>Repeated augmentation (Berman et al.,2O19; Hoffer et al., 2019)</td><td>X</td><td>√</td></tr><tr><td>Random augmentation (Cubuk et al., 2020)</td><td>6/0.5</td><td>7/0.5</td></tr><tr><td>Fine-tuning resolution</td><td>160</td><td>224</td></tr><tr><td>Test resolution</td><td colspan="2">224</td></tr><tr><td>Test crop ratio</td><td colspan="2">0.95</td></tr></table>
476
+
477
+ # H VISUALIZATION
478
+
479
+ We provide more qualitative results of corrupted images in Figure 4 following Table 2 in the main text, as well as recovered images using unseen ImageNet-1K (Figure 5) and COCO (Figure 6) validation images.
480
+
481
+ ![](images/56be4d2ecb906e716ecc24f77aca11b9fe2c918f1e81a860a411dbde0d6f50be.jpg)
482
+ Figure 4: More visualizations of corrupted image samples from ImageNet-1K training set following Table 2 in the main text. We visualize both images and their frequency spectrums with different degradation levels. (a) SR, (b) Deblur (kernel size 21), (c) Denoise, (d) MFM. Each task achieves its best performance with a moderate degradation intensity. See Section 4.3 in the main text for more discussion. Zoom in for best view.
483
+
484
+ ![](images/650004af74b2d9c4c6ccc4cf0748a0f9cde0e4120eb606be50495e8d2f33235e.jpg)
485
+ Figure 5: Example results of recovered images on ImageNet-1K validation set for SR, deblurring, denoising and MFM tasks. We visualize both images and their frequency spectrums. We use the best pre-trained model of each task in Table 2 of the main text for visualization, i.e., the downsampling scale factor is $\times 8$ for SR, the Gaussian blur sigma is 5 for Deblur, the Gaussian noise sigma is 75 for Denoise, and the mask radius is 16 for MFM†. Compared with SR, Deblur and Denoise, MFM can utilize both high-frequency and low-frequency information for prediction. Zoom in for best view. †As MFM only predicts the masked area of the frequency spectrum, we overlay the output with the visible frequency spectrum for better visual quality.
486
+
487
+ ![](images/507efbe79be5ca0cdda5c6652078233e03b7f184d987831313bda69eb8b2da5c.jpg)
488
+ Figure 6: Example results of recovered images on COCO validation set for SR, deblurring, denoising and MFM tasks, using the models pre-trained on ImageNet-1K (the same model weights as in Figure 5). We visualize both images and their frequency spectrums. Zoom in for best view.
parse/dev/9-umxtNPx5E/9-umxtNPx5E_content_list.json ADDED
The diff for this file is too large to render. See raw diff
 
parse/dev/9-umxtNPx5E/9-umxtNPx5E_middle.json ADDED
The diff for this file is too large to render. See raw diff
 
parse/dev/IUikebJ1Bf0/IUikebJ1Bf0.md ADDED
@@ -0,0 +1,370 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ # Autoformalization with Large Language Models
2
+
3
+ Yuhuai Wu1,2† Albert Q. Jiang3 Wenda Li3
4
+
5
+ Markus N. Rabe1 Charles Staats1 Mateja Jamnik3 Christian Szegedy1
6
+
7
+ 1Google Research
8
+ 2Stanford University
9
+ 3University of Cambridge
10
+
11
+ # Abstract
12
+
13
+ Autoformalization is the process of automatically translating from natural language mathematics to formal specifications and proofs. A successful autoformalization system could advance the fields of formal verification, program synthesis, and artificial intelligence. While the long-term goal of autoformalization seemed elusive for a long time, we show large language models provide new prospects towards this goal. We make the surprising observation that LLMs can correctly translate a significant portion $( 2 5 . { \bar { 3 } } \% )$ of mathematical competition problems perfectly to formal specifications in Isabelle/HOL. We demonstrate the usefulness of this process by improving a previously introduced neural theorem prover via training on these autoformalized theorems. Our methodology results in a new state-of-the-art result on the MiniF2F theorem proving benchmark, improving the proof rate from $2 9 . 6 \%$ to $3 5 . 2 \%$ .
14
+
15
+ # 1 Introduction
16
+
17
+ Autoformalization refers to the task of automatically translating from natural language mathematics to a formal language [46, 42]. The implication of a successful autoformalization tool is huge in both practical and philosophical terms. It would reduce the currently excessive cost of formalization efforts [27], and in the long-term it could connect the various research fields that automate aspects of mathematical reasoning, such as automated theorem proving and computer algebra, to the vast body of mathematical knowledge exclusively written up in natural language. Moreover, autoformalization would be a true testament to machine understanding, grasping both the fuzziness of natural language and the preciseness of formal language.
18
+
19
+ Recent advances in large language models [8, 10] showed promising capabilities of understanding formal languages [9, 32]. However, the existing successes are limited to formal languages where there exists a large body of corpus on the web (e.g., Python language). Formal mathematics data is very scarce. For example, one of the largest formal mathematics libraries, the Archive of Formal Proofs, is only 180MB in size, that is less than $0 . 1 8 \%$ of the training data for the large language model Codex [9]. Moreover, unlike in the case of commonly used programming languages, where natural language docstrings are broadly available, there is almost zero aligned data between natural language and formal mathematics. Therefore, it is unclear the recent successes can directly contribute to the development of autoformalization.
20
+
21
+ In this work, we explore the prospects of autoformalization with large language models. To our surprise, we find that large language models already have a decent capability of formalizing natural
22
+
23
+ ![](images/436fcd5cc20f1bf53d74784a940fdc4ef86e72d2d03f8b591f1361b3b3c86dd8.jpg)
24
+
25
+ Figure 1: Case study 1: An example of a perfect translation from natural language to Isabelle code.
26
+
27
+ language mathematics in an interactive theorem prover. See Figure 1 for a perfect autoformalization example. The model not only translates into syntactically correct Isabelle code, but also grasps the non-trivial reasoning in natural language. We randomly pick 150 formalizations and manually evaluate their correctness. Among them, LLMs are capable of producing 38 perfect formalizations! As an application, we further demonstrate that autoformalization can provide useful training data for neural theorem provers. We use autoformalized statements as targets for proof search with a neural theorem prover for Isabelle/HOL. After fine-tuning our neural theorem prover on the proofs it found, its success rate on the MiniF2F benchmark [52] increases significantly, achieving a new state-of-the-art result of $3 5 . 2 \%$ theorems proven.
28
+
29
+ # 2 Related Work
30
+
31
+ Early applications of machine learning in theorem proving include the works by Schulz [40] and Urban [43], and later, directly guiding interactive proof assistants using machine learning techniques [15]. The revolution of deep learning then kicked off a new wave of interest in the topic starting with DeepMath [1, 33].
32
+
33
+ Several approaches have been suggested to address data scarcity: Imitation-free reinforcement learning was used to avoid the need for training on human proofs [31, 6, 15, 49]. Also, hindsight experience replay [2] was used to generate additional training data [5]. Hahn et al. [19], Schmitt et al. [39], Kreber & Hahn [29] and Wu et al. [50] have shown that training on synthetic formulas can be successful for temporal logics and inequalities. Rabe et al. [37] masked out different subexpressions from formal mathematical statements and generated 100 training examples for each source statement. Skip-tree data can also be used to improve the performance of neural theorem provers [22].
34
+
35
+ Wang et al. [46] explored the use of supervised and unsupervised translation techniques for autoformalization. Supervised translation yielded interesting results, but relied on synthetic (natural-looking) data that was generated by the Mizar theorem prover, while we rely on models trained via selfsupervised language modeling, not trained for this particular purpose.
36
+
37
+ # 3 Background
38
+
39
+ Formal Mathematics A few important and complex results of mathematics and computer science have been formalized manually using interactive theorem provers, such as the four color theorem [16], the Kepler conjecture [20], the odd-order theorem [17] and the verification of a microkernel [27]. This gives us almost complete certainty about the correctness of proofs, which can be of great value to resolve doubt about the correctness of complicated mathematical proofs or proving certain properties of software used in safety-critical applications, such as aircraft components [28].
40
+
41
+ These projects relied on interactive theorem provers, such as Isabelle [48], Coq [12], HOL Light [23], and Lean [13], which are essentially programming languages that enable users to enter their statements and proofs in a formal language, and which can then be checked automatically for correctness. Interactive theorem provers offer a limited amount of automation, but projects that formalize complex problems typically span many years of tedious work by specialists. Only in narrow domains like chip design and the verification of drivers in operating systems has the automation of logic made sufficient progress to find commercial applications.
42
+
43
+ Progress in autoformalization and the automation of proofs might eventually make mathematics a universally available tool and enable a paradigm shift in science and the development of (safetycritical) software. Our interest in formalizing mathematics, however, has an additional aspect. We believe that autoformalization will serve a dual purpose and will not only accelerate the development of tools for mathematical reasoning, but also provide a means to ground machine learning systems, enabling a positive feedback loop between machine learning and formal systems (cf. [42]).
44
+
45
+ Large Language Models Our work relies heavily on large language models (LLMs), in particular on PaLM [10] and Codex [9]. The training goal of these models is to predict the next word given some prefix. This allows us to train these models on arbitrary text, which is available in vast quantities. After training the models on hundreds of billions of words (cf. [25]), they are often able to generate high-quality text. We can also give these models an arbitrary prefix (the prompt) that they are then supposed to continue, which gives us some control over what they generate. This has been demonstrated with news articles, conversations, summaries, jokes, and poems. LLMs have also been evaluated on natural language word problems on datasets such as GSM8K [11] and MATH [24], and have been shown to make progress on these benchmarks with increasing scale [10].
46
+
47
+ In-context Learning Large language models have shown a remarkable ability to learn patterns and tasks within the current input (context) that they are given [8]: this is called in-context learning or few-shot learning. For example, if we prompt a language model with a few pairs of English and matching French sentences, and end with a new English sentence, then the language model is very likely to pick up on the translation task and attempt a translation of the last English sentence. This observation has been used, for example, to achieve strong translation performance without access to large corpora of matching sentence pairs [21].
48
+
49
+ This allows us to specify the task of autoformalization simply by giving a couple of example formalizations. In Section 4 we will detail how exactly we use in-context learning for autoformalization.
50
+
51
+ # 4 Autoformalization for Mathematical Competition Problems
52
+
53
+ Inspired by the success of LLMs for synthesizing computer code by co-training on both natural language and code on web-scale data, we explore the capabilities of LLMs to turn natural language mathematics into formalized theorems for the interactive theorem prover Isabelle. This can be seen as a machine translation task (cf. [47]) in which the input language is English and output language is formal code used by the interactive proof assistant Isabelle [48].
54
+
55
+ We first study autoformalization in a constrained setting – formalizing mathematical competition problem statements. This setting has the advantage that most of the required background theory and definition has been formalized in the current libraries of Isabelle, so that formalizations are often possible without introducing additional definitions.
56
+
57
+ We start assessing LLMs’ abilities to do autoformalization with a case study. We manually pick two interesting natural language mathematical statements, and prompt PaLM models of various scales [10] as well as Codex [9] to translate them into a formal statement in Isabelle. Next, we study a dataset in which we have human ground truth formalizations. The dataset is a subset of the miniF2F [24] dataset consisting of 140 algebra problems and 120 number theory problems. Using human formalizations as the reference, we compute the BLEU scores of the formalizations produced by several LLMs. Lastly, we perform human evaluations on failure cases in autoformalization on 150 problems.
58
+
59
+ Note that many mathematical competition statements are often of the form in which one asks to find the answer to a certain problem, instead of proving a given proposition. However, formal mathematical statements are in the form of propositions, instead of questions.
60
+
61
+ To transform a question into a proposition, we append the final answer after the question:
62
+
63
+ \$Problem_Statement The final answer is \$Answer.
64
+
65
+ The format of the prompt we use to do autoformalization is:
66
+
67
+ Natural language version: $\$ 1$ Natural_Language_Statement.
68
+
69
+ Translate the natural language version to an Isabelle version:
70
+
71
+ # 4.1 Mathematical Competition Datasets
72
+
73
+ MATH [24] contains in total 12,500 (7,500 training and 5,000 test) middle school and high school mathematical competition problems. Problems are taken from past mathematical competitions, including AMC 10, AMC 12, AIME, and more, and many can be found at http: //aops.com/community/c3158_usa_contests. The dataset contains seven categories: algebra, pre-algebra, intermediate algebra, number_theory, precalculus, probability, geometry. Problem statements are written in LaTeX.
74
+
75
+ MiniF2F [52] is a recently introduced benchmark containing 488 mathematical competition statements manually formalized by humans in three different formal languages. Its goal is to compare and benchmark methods across different theorem provers for machine learning research. Some of these problems come from the valid and test set of MATH algebra and number_theory, and others come from previous International Mathematical Olympiad competitions or $\mathbf { A o P S } ^ { 1 }$ . Note that the Isabelle formalizations of the miniF2F benchmark were committed to the repository during March, 2022. According to the public information of the training data, we think it is highly unlikely these formalizations were included in the pre-training corpus.
76
+
77
+ # 4.2 Case Studies
78
+
79
+ Experimental setup For all our experiments, we use the standard greedy decoding (i.e., temperature 0, $p = 1$ ) to obtain the autoformalizations. We randomly select two mathematical statements for constructing the prompt, which we provide in Appendix A.1. That is, no prompt engineering / tuning is performed when constructing the prompt. The natural language problem statements used in the case studies are taken from the miniF2F dataset. In the case studies below, we highlight the output of language models in red to distinguish it from the prompt.
80
+
81
+ Case Study 1 (Figure 1) We study the example shown in Figure 1, in which we ask LLMs to autoformalize an International Mathematical Olympiad problem2 in natural language. Surprisingly, Codex is able to autoformalize the natural language statement as an Isabelle theorem perfectly, with output given. This is surprising for the following reasons.
82
+
83
+ First of all, the amount of Isabelle code is very scarce on the internet. The entire AFP library, the largest formal library that contains most of Isabelle proofs, is only 180MB in size. Even assuming that all of this data was included in the training of Codex, this makes at most $0 . 1 8 \%$ of the pretraining data on which Codex was trained. The fact that the model can write syntactically correct Isabelle code at all is already fascinating.
84
+
85
+ Second, there is almost zero aligned data from natural language to Isabelle on the web. While some Isabelle files have comments, they typically only give a very high level description of what the theory being formalized is about. So either LLMs are able to transfer knowledge quite successfully between natural language and formal mathematics, or the task was learned mostly via few-shot learning.
86
+
87
+ Last but not least, the model is capable of understanding and formalizing nontrivial reasoning. First, the model is able to formalize the non-existence statement via proof-by-contradiction. To formalize “there is no function $f . . . ^ { \ ' }$ , it assumes there is such a function, and aims to prove “False”. Second, the model understands what it means by the phrase “to itself”, and correctly infers the domain of function: f :: "nat \<Rightarrow> nat".
88
+
89
+ On the other hand, PaLM made some syntactic mistakes while getting most of the structure of the proof correctly, with outputs shown in Appendix C.1.
90
+
91
+ # Case Study 2 Question:
92
+
93
+ Natural Language version: "When all the girls at Madeline’s school line up in rows of eight, there are seven left over. If instead they line up in rows of four, how many are left over? The final answer is 3." Translate the natural language version to an Isabelle version:
94
+
95
+ # Case Study 3 Question:
96
+
97
+ Natural language version: "Let $f$ be a linear function for which $f ( 6 ) - f ( 2 ) = 1 2$ . What is $f ( 1 2 ) - f ( 2 ) !$ The final answer is 30." Translate the natural language version to an Isabelle version:
98
+
99
+ ![](images/0aaa05a216df4cc0568df308ece9e46bcd792a53a439bc81ac19ca989be5180e.jpg)
100
+ Figure 2: Autoformalizations from natural language to Isabelle code. Left: Case study 2 – perfect formalization by PaLM. Right: Case study $3 -$ incorrect formalization by Codex.
101
+
102
+ Case Study 2 (Figure 2) In the next example, we ask LLMs to autoformalize a grade school mathematical word problem. Remarkably, PaLM and Codex are both capable of formalizing the statement perfectly. This is surprising because formalizations of grade school math problems in interactive theorem provers are rare (if they exist at all), as this type of mathematics is not of interest to formal mathematicians. Even more, none of the examples in the prompt (see Appendix A.1) that we provide are of this type. It is hence remarkable that the model is capable of extrapolating to this type of statement, showing a great promise of using LLMs for autoformalization.
103
+
104
+ To study this problem in more depth, we probe PaLM models of various sizes (8B, 64B, 540B) with outputs shown in Appendix C.2, and notice that scale is crucial for the LLMs ability to formalize. We observe that the 8B and 64B models are incapable of formalizing this problem, but the largest 540B model is able to produce a correct formalization.
105
+
106
+ Case Study 3 (Figure 2) In our third case study, Codex gives an incorrect formalization in Isabelle. The mathematical statement involves a concept of “linear function”, which the model fails to formalize correctly. Codex assumes this is already a known concept in Isabelle, and made up a name: linear f. Can the model learn to formalize such problems if the prompt contains an example that explains the concept of a line? We explore this and give an affirmative answer to the question (see Appendix C.3). Once seeing a tangentially related problem that explains the concept of a “line”, Codex is able to perfectly formalize a “linear function”. This shows the importance of the few shot examples we include, and also how good a few-shot learners these models are!
107
+
108
+ Has the model memorized these formalizations? Whilst we do not have access to the training set of Codex, we attempted to find any occurrences of the formalizations produced in the case studies on the internet. We Googled them in different variants and inspected the first page of the search results. We tried variants with and without an “Isabelle” prefix, with and without quotation marks and other special characters, and also individual parts of it, such as “Isabelle ${ \ " } { \mathbf { n } }$ mod $8 \ = \ 7 " \quad$ , but we did not find any occurrences of related statements. We also tested that we are indeed able to find occurrences of Isabelle formalizations on the web with this methodology, using pieces of formalizations picked from several websites, including the Archive of Formal Proofs. Hence, we are confident that the model has not memorized the formalizations it generated.
109
+
110
+ # 4.3 BLEU for Model Comparisons
111
+
112
+ The miniF2F benchmark contains 140 algebra problems and 120 number theory problems from the MATH dataset. For these problems, we have human ground truth formalizations in Isabelle, which gives us an evaluation set with pairs of natural language statements (from MATH) and their formalizations. We use this dataset to quantitatively compare different LLMs.
113
+
114
+ Table 1: BLEU scores between the autoformalized statements and human formalized ground truth.
115
+
116
+ <table><tr><td>Models\ Subject</td><td>algebra</td><td>number_theory</td></tr><tr><td>PaLM8B</td><td>31.49</td><td>22.10</td></tr><tr><td>PaLM64B</td><td>43.13</td><td>31.43</td></tr><tr><td>PaLM540B</td><td>50.30</td><td>36.16</td></tr><tr><td>Codex</td><td>57.13</td><td>43.33</td></tr></table>
117
+
118
+ Table 2: Failure case study of 150 problems formalized by Codex.
119
+
120
+ <table><tr><td>Failure cases\Subjects</td><td>algebra</td><td>number_theory</td><td>inter_alg</td></tr><tr><td>Perfect translation</td><td>13</td><td>17</td><td>8</td></tr><tr><td>Incomplete/ill-formed/unclear prompt</td><td>9</td><td>3</td><td>14</td></tr><tr><td>Fail to align definitions or concepts</td><td>10</td><td>18</td><td>18</td></tr><tr><td>Inconsistent/missing assumption</td><td>8</td><td>9</td><td>9</td></tr><tr><td>Syntactical/type error</td><td>7</td><td>2</td><td>11</td></tr><tr><td>Missing definition in Isabelle</td><td>0</td><td>12</td><td>3</td></tr><tr><td>Wrong application of functions</td><td>6</td><td>13</td><td>16</td></tr><tr><td>Other</td><td>6</td><td>2</td><td>1</td></tr></table>
121
+
122
+ Given the observation about few shot learning in Case study 3, we decided to add more relevant examples to each subject to improve the quality of autoformalization. For each subject (i.e., algebra and number_theory), we randomly sample 10 problems to construct the few shot prompt. The rest of the problems are used for evaluation (i.e., 130 for algebra and 110 for number_theory. We provide the prompt used in the Appendix B.1 and B.2.
123
+
124
+ We use PaLM models of varying sizes and Codex to perform the autoformalization, and compute the BLEU scores of the formalizations, shown in Table 1. Confirming our observation in Case study 2, we see a clear trend that scaling improves translation, as the BLEU scores consistently improve when we scale PaLM models from 8B to 540B, for both subjects. In addition, we see that the Codex model is better at autoformalization measured by BLEU, possibly due to the fact that Codex was trained on more formal data than PaLM.
125
+
126
+ # 4.4 Human Evaluation of Failure cases
127
+
128
+ To better understand LLMs’ ability to do autoformalization, we manually inspect Codex’s autoformalizations of 150 random problems from the MATH dataset [24]. 50 of the problem statements are sampled from the algebra training set, 50 from number_theory and 50 from intermediate_algebra. For algebra and number_theory, we use their corresponding prompt as in the last section, shown in Appendix B.1 and B.2. For intermediate_algebra, we use the prompt we used for algebra (Appendix B.1). We classify the failure modes of these translations, shown in Table 2.
129
+
130
+ We see that out of 150 problems, Codex is capable of translating 38 problems perfectly – a success rate of $2 5 . 3 \%$ . The majority of the failures are due to the misalignment of informal and formal definitions. For example, when seeing the phrase “the greatest possible value”, the LLMs often fail to align it with the function Greatest/Max in Isabelle. Another example is the failure to align the factorial of $n$ (i.e., !n) to fact $\pmb { n }$ in Isabelle. Other common failure modes include the misapplication of functions (e.g., applying a prefix function in an infix way).
131
+
132
+ # 5 Autoformalization for Neural Theorem Proving
133
+
134
+ To demonstrate the usefulness of the formalized statements, we explore if one can improve neural theorem provers by training the neural models on proofs of automatically translated theorems. In this section, we combine autoformalization with expert iteration algorithms [4], and achieve a new state of the art in miniF2F benchmark.
135
+
136
+ # 5.1 Expert Iteration with Autoformalization
137
+
138
+ The basic idea of expert iteration [4] is to iteratively generate a better dataset using the model, and use the data to improve the model quality. This allows the model to generate an even better quality of the dataset and hence a better model, forming a self-improvement cycle.
139
+
140
+ In neural theorem proving, one way to get better quality data is to use feedback from the proof checker to run many proof searches (or generate multiple proofs) and check the proof attempts for correctness. Newly found correct proofs can then be used as the new training data to improve the neural prover [7, 35, 36]. The main critical ingredient that is needed is a set of problem statements on which the model can perform proof search to obtain new training data. However, unlike in Polu et al. [36], where one asks humans to manually formalize a set of problems to get formal statements, here we use LLMs to autoformalize the theorems in order to kick off the self-improvement cycle.
141
+
142
+ More formally, denote a base neural theorem prover as $M _ { 0 }$ . Let the set of autoformalized problems be $\mathcal { A }$ . For each iteration $i = 1 \dots N$ , we carry out the following procedure: use the language model $M _ { i - 1 }$ with best-first search to prove as many theorems as possible in $\mathcal { A }$ , collect the set of successful proofs $S _ { i }$ , concatenate successful problems from all iterations with the formal mathematics problems to create the set $\begin{array} { r } { \mathscr { A } _ { i } = ( \bigcup _ { j \leq i } S _ { i } ) \bar { \cup } \bar { B } } \end{array}$ , and fine-tune $M _ { 0 }$ on it for exactly one epoch to get a new model $M _ { i }$ . When we take the union of successful proofs from all past iterations, we perform deduplication by problem statements, similar to Polu et al. [36].
143
+
144
+ # 5.2 Neural Theorem Provers
145
+
146
+ To demonstrate the effectiveness of the approach, we start with a recently introduced neural theorem prover for Isabelle, LISA [26]. The LISA agent is fine-tuned on the PISA dataset [26] (extraction and interaction code under a BSD license), which consists of 2.49 million proof steps from the Isabelle/HOL library (under a BSD-style license) and the Archive of Formal Proofs (under various licenses as described here). The model is trained with the objective to predict the next token in a proof step, given the proof state and the last proof step. Following the setup of Thor [3], which achieves SOTA performance in the no-additional-training-data category on MiniF2F, we invoke Sledgehammer with a 30 second timeout when the model generates a step containing any of the keywords metis, meson, and smt.
147
+
148
+ We use Wang [45]’s implementation (under an Apache license 2.0) of a GPT-2 [38] style decoder-only transformer [44] model with 700M non-embedding parameters. The model has 24 layers, 24 attention heads, a hidden dimension of 1536, and a vocabulary size of 50400. We pre-train the model on the GitHub $^ +$ arXiv subsets of The Pile [14] for 200,000 steps, with a context length of 2048 tokens. In pre-training we use a warmup strategy [18], raising the learning rate linearly from 0 to $2 \times 1 0 ^ { - 4 }$ in 3,000 steps. We then use a cosine learning rate scheduler [34] for the rest of the pre-training, with a final learning rate of $1 . 2 \times 1 0 ^ { - 5 }$ . We use a global batch size of 32 sequences, or 65,536 tokens. For fine-tuning we use the same learning rate schedule, with 10,000 warmup steps, 90,000 annealing steps, maximum learning rate $3 \times 1 0 ^ { - 4 }$ and final learning rate $3 \times 1 0 ^ { - 5 }$ . The global batch size is 144 sequences, or 294,912 tokens. The model’s evaluation loss reaches a minimum after 13,000 steps and we use that checkpoint. For the fine-tuning in expert iteration, we fix the learning rate at $3 \times 1 0 ^ { - 4 }$ and the batch size at 144 sequences, and train the model for exactly one epoch.
149
+
150
+ Here we give the details regarding the best-first search strategy used in evaluation: we maintain a priority queue of search nodes with queue length 32. The accumulated log probability of the proof steps is used as the queue priority. For each theorem to prove, we first initialize the queue with one node that has the theorem declared and no proof step applied to it. At each time-step, we deque and sample 32 possible proof steps to apply to the node. The nodes corresponding to steps that successfully proceed the proofs then get added to the queue. We repeat this process until the theorem is successfully proven, or we reach our computational budget.
151
+
152
+ Machine specification For pre-training, fine-tuning, and evaluation, we use a TPUv3 with 8 cores from Google Cloud Platform. The Isabelle process has access to up to 32 CPU cores. We estimate that running all the experiments in this paper requires a total of 780 TPU hours.
153
+
154
+ Table 3: Proof success rates on miniF2F.
155
+
156
+ <table><tr><td>Model</td><td>valid</td><td>test</td></tr><tr><td>PACT[22]</td><td>23.9%</td><td>24.6%</td></tr><tr><td>FMSCL [36]</td><td>33.6%</td><td>29.6%</td></tr><tr><td>Ours</td><td>37.3%</td><td>35.2%</td></tr></table>
157
+
158
+ # 5.3 Result
159
+
160
+ We use Codex with greedy decoding to formalize 3908 mathematical problems in algebra, intermediate algebra, and number theory from the training set of MATH [24], with the same few shot prompts used in Section 4.4. Out of them, 3363 of the autoformalized theorems are syntactically correct. We then perform expert iteration on this dataset.
161
+
162
+ We start with a neural theorem prover $( M _ { 0 } )$ as described in Section 5.2. In our first iteration, $M _ { 0 }$ proves 782 theorems, with a success rate of $2 3 . 3 \%$ (out of 3363). This gives us a new set of verified proofs to further train the neural theorem prover. We proceed to fine-tune our neural theorem prover in the fashion described in Section 5.1 to get a new prover $( M _ { 1 } )$ . This process is repeated in the second iteration, giving us 1011 successful proofs from the autoformalized theorems $\bar { ( 3 0 . 1 \% ) }$ . We fine-tuned $M _ { 0 }$ again on all available deduplicated proofs to obtain $M _ { 2 }$ .
163
+
164
+ After each stage of fine-tuning, we evaluate the neural theorem prover on miniF2F [52]. The results are shown in Table 3. The base model $( M _ { 0 } )$ has a success rate of $2 8 . 3 \%$ and $2 9 . 9 \%$ on the validation and test fractions of miniF2F respectively. It can be observed that the first expert iteration increases the success rate of the neural prover by $\mathrm { 7 . 8 \% }$ and $4 . 1 \%$ to $3 6 . 1 \%$ and $3 4 . 0 \%$ on the valid and test sets. The second iteration further improves them both by $1 . 2 \%$ , to $3 7 . 3 \%$ and $3 5 . 2 \%$ . By doing two expert iterations on the autoformalized theorems, the neural prover achieves a success rate that is $5 . { \bar { 6 } } \%$ higher than the previous state-of-the-art.
165
+
166
+ # 6 An Outlook on Autoformalizing Advanced Mathematics
167
+
168
+ So far, we focused on mathematical competition problems, in which we achieve significant results using autoformalization. Not only can LLMs autoformalize non-trivial theorems, the autoformalized theorems can also improve neural prover performance. In this section, we take a peek into more advanced mathematics. We hope to identify some of the limitations of our methods when it comes to autoformalizing mathematics in the wild.
169
+
170
+ # 6.1 Autoformalization: from Natural Language to Isabelle
171
+
172
+ Autoformalization is extremely challenging in the sense that the model needs to (1) bridge the logical gaps left in pen-and-paper proofs, (2) assume the implicit contexts and assumptions, and (3) align informal definitions/concepts to formal ones. This task is further complicated considering the context can change from time to time and the same mathematical object can be formalized in subtly different ways. In this paper, we only deal with autoformalization of theorem statements, where the model is mainly challenged by definition alignments. Compared to competition problems in Section 4.4, advanced mathematical statements assume more context information that additionally obscures the alignment.
173
+
174
+ Figure 3 shows a typical case where the model fails to align the informal definition to the formal one. Based on the notation used, the model does not correctly distinguish between products of numbers, products of sets, and products of topological spaces. In Isabelle, the correct conclusion for the statement should be compact_space (product_topology $\textbf { \textit { X } } _ { I } )$ , where $I$ is an index set that ought to have been introduced in the fixes and assumes sections.
175
+
176
+ # 6.2 Informalization: from Isabelle to Natural Language
177
+
178
+ So far, we explored one direction of translation: from natural language statement to formal statement in Isabelle. The other direction, informalization, is also of great importance for two reasons: (1) the informal texts are much easier for humans to comprehend and communicate, and (2) we can
179
+
180
+ Question: An arbitrary product of compact spaces is compact.
181
+
182
+ # Codex Output:
183
+
184
+ theorem
185
+
186
+ fixes X :: "’a set set" assumes "\<forall>x \<in>X. compact x" shows "compact (\<Prod> x \<in> X. x)"
187
+
188
+ Figure 3: A formalization for an advanced mathematical statement by Codex.
189
+
190
+ lemma topologyI:
191
+
192
+ lemma seteqI: "[[Vx. x∈A =⇒ x∈B;
193
+ Vx. x∈B =⇒ x∈A ]]
194
+ =⇒ A = B" "[[ V x y. [[ is_open T x; is_open T y ]] =⇒
195
+ is_open T (x ∩ y); V M. ∀ m ∈ M. is_open T ${ \textbf { \em m } } \implies$
196
+ is_open T (S M) $\mathbb { I } \Longrightarrow$ topology T"
197
+
198
+ Translate the Isabelle version to a natural language version:
199
+
200
+ Translate the Isabelle version to a natural language version:
201
+
202
+ # Codex Output:
203
+
204
+ # Codex Output:
205
+
206
+ "If $A$ and $B$ are sets such that $A \subseteq B$ and $B \subseteq A$ then $A = B$ ."
207
+
208
+ "If $T$ is a set and $T$ is closed under finite intersections and arbitrary unions, then $T$ is a topology."
209
+
210
+ Figure 4: Two perfect translations from Isabelle code to natural language by Codex.
211
+
212
+ align translated informal statements with formal ones to create data, and use the back-translation techniques [41] to potentially boost the translator’s performance further. In this section, we explore Codex’s capability of translating formal Isabelle statement to natural language.
213
+
214
+ A corpus of 38 formal-language theorems, lemmas, and definitions is selected by an Isabelle expert. These statements are automatically translated to informal mathematics using Codex; to see the prompt we used and the results for all 38 examples, see Appendix B.3 and E.2. We present two examples of informalization in Figure 4. Of the 38 examples, 36 were translated to a reasonably coherent statement, and 29 of these statements $( 7 6 \% )$ were more-or-less correct, giving a vastly better success rate than the $25 \%$ success rate of formalization (Section 4.4). Our main conclusion is that for advanced mathematics, the model is better at informalization than formalization, showing the prospect of backtranslation style algorithms.
215
+
216
+ Note that the standard is more relaxed here since we assume a human reader will supply the obvious context and correct mistakes when the intended meaning is obvious (intended by the hypothetical human writer of these sentences). To illustrate, an example of a minor “acceptable” error: assuming that “ $w , z$ are in the same connected component of the plane” when, in context, it is clear that $w , z$ should be assumed to be in the same connected component of the complement of a previously specified curve. (The assumption as originally stated is trivial.) For an example of a major error: almost-perfect translation of the Central Limit Theorem that omits the assumption of identical distributions.
217
+
218
+ # 7 Discussion
219
+
220
+ Promise of Autoformalization with LLMs We have seen that automated formalization of informally given natural language statements is generally possible, even with language models not trained for this particular task. Also, automatically formalized statements are useful for training and improving the reasoning capabilities of automated neural provers. Our hope is that improved versions of this methodology will be capable of enabling a positive feedback loop involving formalization and formal reasoning that has the potential of reaching human level capabilities in both respects, as was suggested by [42].
221
+
222
+ Limitations and future directions We use a static model for the formalization process. For largescale autoformalization, we will need to formalize larger theories, preferably without fine tuning the model, as training it could be cumbersome and resource consuming. However, in order to utilize the newly added notions, the model would need to keep whole large theories in the current context window, which exceeds those of the current LLMs. This limits our approach to the generation of fairly small pieces of formal mathematics and the automatic formalization of entire theories including their definitions will require new research ideas. One path towards this goal might be the use of continuous training or expert iteration, cycle-consistency-based training [30, 46], or novel uses of in-context learning. To generate larger theories we will also need neural networks that can recall longer sequences (current LLMs are typically limited to a few thousand words). Retrieval-augmented language models, such as the memorizing transformer [51] offer one path to overcome this limitation.
223
+
224
+ Societal Impact While the potential of creating negative societal impact through formalizations is small, the use of LLMs always comes with risks. For example, for deploying an autoformalization tool using LLMs we would need to consider the inclusivity of variable and lemma names, and of the attribution of scientific ideas.
225
+
226
+ # Acknowledgement
227
+
228
+ AQJ is supported by a Peterhouse Graduate Research Studentship. WL is supported by the ERC Advanced Grant ALEXANDRIA (Project GA 742178).
229
+
230
+ # References
231
+
232
+ [1] Alexander A. Alemi, François Chollet, Niklas Eén, Geoffrey Irving, Christian Szegedy, and Josef Urban. Deepmath - deep sequence models for premise selection. In Daniel D. Lee, Masashi Sugiyama, Ulrike von Luxburg, Isabelle Guyon, and Roman Garnett (eds.), Advances in Neural Information Processing Systems 29: Annual Conference on Neural Information Processing Systems 2016, December 5-10, 2016, Barcelona, Spain, pp. 2235–2243, 2016. URL http://papers.nips.cc/paper/ 6280-deepmath-deep-sequence-models-for-premise-selection.
233
+ [2] Marcin Andrychowicz, Filip Wolski, Alex Ray, Jonas Schneider, Rachel Fong, Peter Welinder, Bob McGrew, Josh Tobin, Pieter Abbeel, and Wojciech Zaremba. Hindsight experience replay. CoRR, abs/1707.01495, 2017. URL http://arxiv.org/abs/1707.01495.
234
+ [3] Anon Anonymous. Thor: Wielding hammers to integrate language models and automated theorem provers. 2022.
235
+ [4] Thomas Anthony, Zheng Tian, and David Barber. Thinking fast and slow with deep learning and tree search. In Isabelle Guyon, Ulrike von Luxburg, Samy Bengio, Hanna M. Wallach, Rob Fergus, S. V. N. Vishwanathan, and Roman Garnett (eds.), Advances in Neural Information Processing Systems 30: Annual Conference on Neural Information Processing Systems 2017, December 4-9, 2017, Long Beach, CA, USA, pp. 5360–5370, 2017. URL https://proceedings.neurips.cc/paper/2017/hash/ d8e1344e27a5b08cdfd5d027d9b8d6de-Abstract.html.
236
+ [5] Eser Aygün, Laurent Orseau, Ankit Anand, Xavier Glorot, Vlad Firoiu, Lei M. Zhang, Doina Precup, and Shibl Mourad. Proving theorems using incremental learning and hindsight experience replay. CoRR, abs/2112.10664, 2021. URL https://arxiv.org/abs/2112.10664.
237
+ [6] Kshitij Bansal, Sarah M. Loos, Markus N. Rabe, and Christian Szegedy. Learning to reason in large theories without imitation. CoRR, abs/1905.10501, 2019. URL http://arxiv.org/ abs/1905.10501.
238
+ [7] Kshitij Bansal, Sarah M. Loos, Markus N. Rabe, Christian Szegedy, and Stewart Wilcox. Holist: An environment for machine learning of higher order logic theorem proving. In Kamalika Chaudhuri and Ruslan Salakhutdinov (eds.), Proceedings of the 36th International Conference on Machine Learning, ICML 2019, 9-15 June 2019, Long Beach, California, USA, volume 97 of Proceedings of Machine Learning Research, pp. 454–463. PMLR, 2019. URL http://proceedings.mlr.press/v97/bansal19a.html.
239
+
240
+ [8] Tom B. Brown, Benjamin Mann, Nick Ryder, Melanie Subbiah, Jared Kaplan, Prafulla Dhariwal, Arvind Neelakantan, Pranav Shyam, Girish Sastry, Amanda Askell, Sandhini Agarwal, Ariel Herbert-Voss, Gretchen Krueger, Tom Henighan, Rewon Child, Aditya Ramesh, Daniel M. Ziegler, Jeffrey Wu, Clemens Winter, Christopher Hesse, Mark Chen, Eric Sigler, Mateusz Litwin, Scott Gray, Benjamin Chess, Jack Clark, Christopher Berner, Sam McCandlish, Alec Radford, Ilya Sutskever, and Dario Amodei. Language models are few-shot learners. In NeurIPS, 2020.
241
+
242
+ [9] Mark Chen, Jerry Tworek, Heewoo Jun, Qiming Yuan, Henrique Ponde de Oliveira Pinto, Jared Kaplan, Harrison Edwards, Yuri Burda, Nicholas Joseph, Greg Brockman, Alex Ray, Raul Puri, Gretchen Krueger, Michael Petrov, Heidy Khlaaf, Girish Sastry, Pamela Mishkin, Brooke Chan, Scott Gray, Nick Ryder, Mikhail Pavlov, Alethea Power, Lukasz Kaiser, Mohammad Bavarian, Clemens Winter, Philippe Tillet, Felipe Petroski Such, Dave Cummings, Matthias Plappert, Fotios Chantzis, Elizabeth Barnes, Ariel Herbert-Voss, William Hebgen Guss, Alex Nichol, Alex Paino, Nikolas Tezak, Jie Tang, Igor Babuschkin, Suchir Balaji, Shantanu Jain, William Saunders, Christopher Hesse, Andrew N. Carr, Jan Leike, Joshua Achiam, Vedant Misra, Evan Morikawa, Alec Radford, Matthew Knight, Miles Brundage, Mira Murati, Katie Mayer, Peter Welinder, Bob McGrew, Dario Amodei, Sam McCandlish, Ilya Sutskever, and Wojciech Zaremba. Evaluating large language models trained on code. CoRR, abs/2107.03374, 2021. URL https://arxiv.org/abs/2107.03374.
243
+
244
+ [10] Aakanksha Chowdhery, Sharan Narang, Jacob Devlin, Maarten Bosma, Gaurav Mishra, Adam Roberts, Paul Barham, Hyung Won Chung, Charles Sutton, Sebastian Gehrmann, Parker Schuh, Kensen Shi, Sasha Tsvyashchenko, Joshua Maynez, Abhishek Rao, Parker Barnes, Yi Tay, Noam Shazeer, Vinodkumar Prabhakaran, Emily Reif, Nan Du, Ben Hutchinson, Reiner Pope, James Bradbury, Jacob Austin, Michael Isard, Guy Gur-Ari, Pengcheng Yin, Toju Duke, Anselm Levskaya, Sanjay Ghemawat, Sunipa Dev, Henryk Michalewski, Xavier Garcia, Vedant Misra, Kevin Robinson, Liam Fedus, Denny Zhou, Daphne Ippolito, David Luan, Hyeontaek Lim, Barret Zoph, Alexander Spiridonov, Ryan Sepassi, David Dohan, Shivani Agrawal, Mark Omernick, Andrew M. Dai, Thanumalayan Sankaranarayana Pillai, Marie Pellat, Aitor Lewkowycz, Erica Moreira, Rewon Child, Oleksandr Polozov, Katherine Lee, Zongwei Zhou, Xuezhi Wang, Brennan Saeta, Mark Diaz, Orhan Firat, Michele Catasta, Jason Wei, Kathy Meier-Hellstern, Douglas Eck, Jeff Dean, Slav Petrov, and Noah Fiedel. PaLM: Scaling language modeling with pathways. CoRR, abs/2204.02311, 2022. doi: 10.48550/arXiv.2204.02311. URL https://doi.org/10.48550/arXiv.2204.02311.
245
+
246
+ [11] Karl Cobbe, Vineet Kosaraju, Mohammad Bavarian, Jacob Hilton, Reiichiro Nakano, Christopher Hesse, and John Schulman. Training verifiers to solve math word problems. CoRR, abs/2110.14168, 2021. URL https://arxiv.org/abs/2110.14168.
247
+
248
+ [12] Coq. The Coq Proof Assistant. http://coq.inria.fr. URL http://coq.inria.fr.
249
+
250
+ [13] Leonardo Mendonça de Moura, Soonho Kong, Jeremy Avigad, Floris van Doorn, and Jakob von Raumer. The lean theorem prover (system description). In Amy P. Felty and Aart Middeldorp (eds.), Automated Deduction - CADE-25 - 25th International Conference on Automated Deduction, Berlin, Germany, August 1-7, 2015, Proceedings, volume 9195 of Lecture Notes in Computer Science, pp. 378–388. Springer, 2015. doi: 10.1007/978-3-319-21401-6\_26. URL https://doi.org/10.1007/978-3-319-21401-6_26.
251
+
252
+ [14] Leo Gao, Stella Biderman, Sid Black, Laurence Golding, Travis Hoppe, Charles Foster, Jason Phang, Horace He, Anish Thite, Noa Nabeshima, Shawn Presser, and Connor Leahy. The Pile: An 800gb dataset of diverse text for language modeling. arXiv preprint arXiv:2101.00027, 2020.
253
+
254
+ [15] Thibault Gauthier, Cezary Kaliszyk, Josef Urban, Ramana Kumar, and Michael Norrish. Tactictoe: Learning to prove with tactics. J. Autom. Reason., 65(2):257–286, 2021. doi: 10.1007/s10817-020-09580-x. URL https://doi.org/10.1007/s10817-020-09580-x.
255
+
256
+ [16] Georges Gonthier. The four colour theorem: Engineering of a formal proof. In Deepak Kapur (ed.), Computer Mathematics, 8th Asian Symposium, ASCM 2007, Singapore, December 15-17, 2007. Revised and Invited Papers, volume 5081 of Lecture Notes in Computer Science, pp. 333. Springer, 2007. doi: 10.1007/978-3-540-87827-8\_28.
257
+
258
+ [17] Georges Gonthier, Andrea Asperti, Jeremy Avigad, Yves Bertot, Cyril Cohen, François Garillot, Stéphane Le Roux, Assia Mahboubi, Russell O’Connor, Sidi Ould Biha, Ioana Pasca, Laurence Rideau, Alexey Solovyev, Enrico Tassi, and Laurent Théry. A machine-checked proof of the odd order theorem. In Sandrine Blazy, Christine Paulin-Mohring, and David Pichardie (eds.), Interactive Theorem Proving - 4th International Conference, ITP 2013, Rennes, France, July 22-26, 2013. Proceedings, volume 7998 of Lecture Notes in Computer Science, pp. 163–179. Springer, 2013. doi: 10.1007/978-3-642-39634-2\_14.
259
+
260
+ [18] Priya Goyal, Piotr Dollár, Ross Girshick, Pieter Noordhuis, Lukasz Wesolowski, Aapo Kyrola, Andrew Tulloch, Yangqing Jia, and Kaiming He. Accurate, large minibatch sgd: Training imagenet in 1 hour. arXiv preprint arXiv:1706.02677, 2017.
261
+
262
+ [19] Christopher Hahn, Frederik Schmitt, Jens U. Kreber, Markus N. Rabe, and Bernd Finkbeiner. Teaching temporal logics to neural networks. In ICLR, 2021.
263
+
264
+ [20] Thomas Hales, Mark Adams, Gertrud Bauer, Tat Dat Dang, John Harrison, Hoang Le Truong, Cezary Kaliszyk, Victor Magron, Sean McLaughlin, Tat Thang Nguyen, et al. A formal proof of the Kepler conjecture. In Forum of Mathematics, $P i$ , volume 5, pp. e2. Cambridge University Press, 2017.
265
+
266
+ [21] Jesse Michael Han, Igor Babuschkin, Harrison Edwards, Arvind Neelakantan, Tao Xu, Stanislas Polu, Alex Ray, Pranav Shyam, Aditya Ramesh, Alec Radford, and Ilya Sutskever. Unsupervised neural machine translation with generative language models only. CoRR, abs/2110.05448, 2021. URL https://arxiv.org/abs/2110.05448.
267
+
268
+ [22] Jesse Michael Han, Jason Rute, Yuhuai Wu, Edward Ayers, and Stanislas Polu. Proof artifact co-training for theorem proving with language models. In International Conference on Learning Representations, 2022. URL https://openreview.net/forum?id=rpxJc9j04U.
269
+
270
+ [23] John Harrison. HOL Light: A tutorial introduction. In Mandayam K. Srivas and Albert John Camilleri (eds.), Formal Methods in Computer-Aided Design, First International Conference, FMCAD ’96, Palo Alto, California, USA, November 6-8, 1996, Proceedings, volume 1166 of Lecture Notes in Computer Science, pp. 265–269. Springer, 1996.
271
+
272
+ [24] Dan Hendrycks, Collin Burns, Saurav Kadavath, Akul Arora, Steven Basart, Eric Tang, Dawn Song, and Jacob Steinhardt. Measuring mathematical problem solving with the MATH dataset. CoRR, abs/2103.03874, 2021. URL https://arxiv.org/abs/2103.03874.
273
+
274
+ [25] Jordan Hoffmann, Sebastian Borgeaud, Arthur Mensch, Elena Buchatskaya, Trevor Cai, Eliza Rutherford, Diego de Las Casas, Lisa Anne Hendricks, Johannes Welbl, Aidan Clark, Tom Hennigan, Eric Noland, Katie Millican, George van den Driessche, Bogdan Damoc, Aurelia Guy, Simon Osindero, Karen Simonyan, Erich Elsen, Jack W. Rae, Oriol Vinyals, and Laurent Sifre. Training compute-optimal large language models. CoRR, abs/2203.15556, 2022. doi: 10.48550/arXiv.2203.15556. URL https://doi.org/10.48550/arXiv.2203.15556.
275
+
276
+ [26] Albert Q. Jiang, Wenda Li, Jesse Michael Han, and Yuhuai Wu. Lisa: Language models of isabelle proofs. 6th Conference on Artificial Intelligence and Theorem Proving, 2021.
277
+
278
+ [27] Gerwin Klein, Kevin Elphinstone, Gernot Heiser, June Andronick, David Cock, Philip Derrin, Dhammika Elkaduwe, Kai Engelhardt, Rafal Kolanski, Michael Norrish, Thomas Sewell, Harvey Tuch, and Simon Winwood. seL4: formal verification of an OS kernel. In Jeanna Neefe Matthews and Thomas E. Anderson (eds.), Proceedings of the 22nd ACM Symposium on Operating Systems Principles 2009, SOSP 2009, Big Sky, Montana, USA, October 11-14, 2009, pp. 207–220. ACM, 2009. doi: 10.1145/1629575.1629596.
279
+
280
+ [28] Gerwin Klein, June Andronick, Matthew Fernandez, Ihor Kuz, Toby C. Murray, and Gernot Heiser. Formally verified software in the real world. Commun. ACM, 61(10):68–77, 2018. doi: 10.1145/3230627. URL https://doi.org/10.1145/3230627.
281
+
282
+ [29] Jens U. Kreber and Christopher Hahn. Generating symbolic reasoning problems with transformer GANs. CoRR, abs/2110.10054, 2021. URL https://arxiv.org/abs/2110.10054.
283
+
284
+ [30] Guillaume Lample, Alexis Conneau, Ludovic Denoyer, and Marc’Aurelio Ranzato. Unsupervised machine translation using monolingual corpora only. In 6th International Conference on Learning Representations, ICLR 2018, Vancouver, BC, Canada, April 30 - May 3, 2018, Conference Track Proceedings. OpenReview.net, 2018. URL https://openreview.net/ forum?id=rkYTTf-AZ.
285
+
286
+ [31] Gil Lederman, Markus N. Rabe, Sanjit Seshia, and Edward A. Lee. Learning heuristics for quantified boolean formulas through reinforcement learning. In 8th International Conference on Learning Representations, ICLR 2020, Addis Ababa, Ethiopia, April 26-30, 2020. OpenReview.net, 2020. URL https://openreview.net/forum?id=BJluxREKDB.
287
+
288
+ [32] Yujia Li, David Choi, Junyoung Chung, Nate Kushman, Julian Schrittwieser, Rémi Leblond, Tom Eccles, James Keeling, Felix Gimeno, Agustin Dal Lago, Thomas Hubert, Peter Choy, Cyprien de Masson d’Autume, Igor Babuschkin, Xinyun Chen, Po-Sen Huang, Johannes Welbl, Sven Gowal, Alexey Cherepanov, James Molloy, Daniel J. Mankowitz, Esme Sutherland Robson, Pushmeet Kohli, Nando de Freitas, Koray Kavukcuoglu, and Oriol Vinyals. Competition-level code generation with alphacode. DeepMind, 2022.
289
+
290
+ [33] Sarah M. Loos, Geoffrey Irving, Christian Szegedy, and Cezary Kaliszyk. Deep network guided proof search. In Thomas Eiter and David Sands (eds.), LPAR-21, 21st International Conference on Logic for Programming, Artificial Intelligence and Reasoning, Maun, Botswana, May 7-12, 2017, volume 46 of EPiC Series in Computing, pp. 85–105. EasyChair, 2017. doi: 10.29007/8mwc. URL https://doi.org/10.29007/8mwc.
291
+
292
+ [34] Ilya Loshchilov and Frank Hutter. SGDR: Stochastic gradient descent with warm restarts. arXiv preprint arXiv:1608.03983, 2016.
293
+
294
+ [35] Stanislas Polu and Ilya Sutskever. Generative language modeling for automated theorem proving. CoRR, abs/2009.03393, 2020. URL https://arxiv.org/abs/2009.03393.
295
+
296
+ [36] Stanislas Polu, Jesse Michael Han, Kunhao Zheng, Mantas Baksys, Igor Babuschkin, and Ilya Sutskever. Formal mathematics statement curriculum learning, 2022. URL https://arxiv. org/abs/2202.01344.
297
+
298
+ [37] Markus N. Rabe, Dennis Lee, Kshitij Bansal, and Christian Szegedy. Mathematical reasoning via self-supervised skip-tree training. In ICLR, 2021.
299
+
300
+ [38] Alec Radford, Jeffrey Wu, Rewon Child, David Luan, Dario Amodei, Ilya Sutskever, et al. Language models are unsupervised multitask learners. OpenAI blog, 1(8):9, 2019.
301
+
302
+ [39] Frederik Schmitt, Christopher Hahn, Markus N. Rabe, and Bernd Finkbeiner. Neural circuit synthesis from specification patterns. In Marc’Aurelio Ranzato, Alina Beygelzimer, Yann N. Dauphin, Percy Liang, and Jennifer Wortman Vaughan (eds.), Advances in Neural Information Processing Systems 34: Annual Conference on Neural Information Processing Systems 2021, NeurIPS 2021, December 6-14, 2021, virtual, pp. 15408–15420, 2021. URL https://proceedings.neurips.cc/paper/2021/hash/ 8230bea7d54bcdf99cdfe85cb07313d5-Abstract.html.
303
+
304
+ [40] Stephan Schulz. Learning search control knowledge for equational theorem proving. In Franz Baader, Gerhard Brewka, and Thomas Eiter (eds.), KI 2001: Advances in Artificial Intelligence, Joint German/Austrian Conference on AI, Vienna, Austria, September 19-21, 2001, Proceedings, volume 2174 of Lecture Notes in Computer Science, pp. 320–334. Springer, 2001. doi: 10.1007/3-540-45422-5\_23.
305
+
306
+ [41] Rico Sennrich, Barry Haddow, and Alexandra Birch. Improving neural machine translation models with monolingual data. In Proceedings of the 54th Annual Meeting of the Association for Computational Linguistics, ACL 2016, August 7-12, 2016, Berlin, Germany, Volume 1: Long Papers. The Association for Computer Linguistics, 2016. doi: 10.18653/v1/p16-1009. URL https://doi.org/10.18653/v1/p16-1009.
307
+
308
+ [42] Christian Szegedy. A promising path towards autoformalization and general artificial intelligence. In Christoph Benzmüller and Bruce R. Miller (eds.), Intelligent Computer Mathematics - 13th International Conference, CICM 2020, Bertinoro, Italy, July 26-31, 2020, Proceedings, volume 12236 of Lecture Notes in Computer Science, pp. 3–20. Springer, 2020. doi: 10.1007/ 978-3-030-53518-6\_1. URL https://doi.org/10.1007/978-3-030-53518-6_1.
309
+
310
+ [43] Josef Urban. MPTP - motivation, implementation, first experiments. J. Autom. Reason., 33 (3-4):319–339, 2004. doi: 10.1007/s10817-004-6245-1.
311
+
312
+ [44] Ashish Vaswani, Noam Shazeer, Niki Parmar, Jakob Uszkoreit, Llion Jones, Aidan N Gomez, Łukasz Kaiser, and Illia Polosukhin. Attention is all you need. In NeurIPS, 2017.
313
+
314
+ [45] Ben Wang. Mesh-Transformer-JAX: Model-Parallel Implementation of Transformer Language Model with JAX. https://github.com/kingoflolz/mesh-transformer-jax, May 2021.
315
+
316
+ [46] Qingxiang Wang, Cezary Kaliszyk, and Josef Urban. First experiments with neural translation of informal to formal mathematics. In Florian Rabe, William M. Farmer, Grant O. Passmore, and Abdou Youssef (eds.), Intelligent Computer Mathematics - 11th International Conference, CICM 2018, Hagenberg, Austria, August 13-17, 2018, Proceedings, volume 11006 of Lecture Notes in Computer Science, pp. 255–270. Springer, 2018. doi: 10.1007/978-3-319-96812-4\_22. URL https://doi.org/10.1007/978-3-319-96812-4_22.
317
+
318
+ [47] Qingxiang Wang, Chad Brown, Cezary Kaliszyk, and Josef Urban. Exploration of neural machine translation in autoformalization of mathematics in mizar. In International Conference on Certified Programs and Proofs, 2020.
319
+
320
+ [48] Makarius Wenzel, Lawrence C. Paulson, and Tobias Nipkow. The Isabelle framework. In Otmane Aït Mohamed, César A. Muñoz, and Sofiène Tahar (eds.), Theorem Proving in Higher Order Logics, 21st International Conference, TPHOLs 2008, Montreal, Canada, August 18-21, 2008. Proceedings, volume 5170 of Lecture Notes in Computer Science, pp. 33–38. Springer, 2008. doi: 10.1007/978-3-540-71067-7\_7.
321
+
322
+ [49] Minchao Wu, Michael Norrish, Christian Walder, and Amir Dezfouli. TacticZero: Learning to prove theorems from scratch with deep reinforcement learning. CoRR, abs/2102.09756, 2021. URL https://arxiv.org/abs/2102.09756.
323
+
324
+ [50] Yuhuai Wu, Albert Jiang, Jimmy Ba, and Roger Baker Grosse. INT: an inequality benchmark for evaluating generalization in theorem proving. In 9th International Conference on Learning Representations, ICLR 2021, Virtual Event, Austria, May 3-7, 2021. OpenReview.net, 2021. URL https://openreview.net/forum?id $\cdot ^ { = }$ O6LPudowNQm.
325
+
326
+ [51] Yuhuai Wu, Markus N Rabe, DeLesley Hutchins, and Christian Szegedy. Memorizing transformers. arXiv preprint arXiv:2203.08913, 2022.
327
+
328
+ [52] Kunhao Zheng, Jesse Michael Han, and Stanislas Polu. MiniF2F: a cross-system benchmark for formal olympiad-level mathematics. arXiv preprint arXiv:2109.00110, 2021.
329
+
330
+ # Checklist
331
+
332
+ The checklist follows the references. Please read the checklist guidelines carefully for information on how to answer these questions. For each question, change the default [TODO] to [Yes] , [No] , or [N/A] . You are strongly encouraged to include a justification to your answer, either by referencing the appropriate section of your paper or providing a brief inline description. For example:
333
+
334
+ • Did you include the license to the code and datasets? [Yes] See Section ??.
335
+ • Did you include the license to the code and datasets? [No] The code and the data are proprietary.
336
+ • Did you include the license to the code and datasets? [N/A]
337
+
338
+ Please do not modify the questions and only use the provided macros for your answers. Note that the Checklist section does not count towards the page limit. In your paper, please delete this instructions block and only keep the Checklist section heading above along with the questions/answers below.
339
+
340
+ 1. For all authors...
341
+
342
+ (a) Do the main claims made in the abstract and introduction accurately reflect the paper’s contributions and scope? [Yes]
343
+ (b) Did you describe the limitations of your work? [Yes] See discussion section.
344
+ (c) Did you discuss any potential negative societal impacts of your work? [Yes] See discussion section.
345
+ (d) Have you read the ethics review guidelines and ensured that your paper conforms to them? [Yes]
346
+
347
+ 2. If you are including theoretical results...
348
+
349
+ (a) Did you state the full set of assumptions of all theoretical results? [N/A] (b) Did you include complete proofs of all theoretical results? [N/A]
350
+
351
+ 3. If you ran experiments...
352
+
353
+ (a) Did you include the code, data, and instructions needed to reproduce the main experimental results (either in the supplemental material or as a URL)? [Yes]
354
+ (b) Did you specify all the training details (e.g., data splits, hyperparameters, how they were chosen)? [Yes]
355
+ (c) Did you report error bars (e.g., with respect to the random seed after running experiments multiple times)? [No] It is expensive to run multiple times, and we believe the results are significant.
356
+ (d) Did you include the total amount of compute and the type of resources used (e.g., type of GPUs, internal cluster, or cloud provider)? [Yes] See Section 5.2.
357
+
358
+ 4. If you are using existing assets (e.g., code, data, models) or curating/releasing new assets...
359
+
360
+ (a) If your work uses existing assets, did you cite the creators? [Yes] We cited the creators of the assets when we first mentioned them.
361
+ (b) Did you mention the license of the assets? [Yes] We included the links to the licenses of the assets when we first mentioned them in Section 5.
362
+ (c) Did you include any new assets either in the supplemental material or as a URL? [Yes] We include the code we used to train the models in the supplemental material. The data we used are all under open-source licenses.
363
+ (d) Did you discuss whether and how consent was obtained from people whose data you’re using/curating? [Yes] The assets we used mostly have open-sourced licenses as mentioned previously.
364
+ (e) Did you discuss whether the data you are using/curating contains personally identifiable information or offensive content? [No] The data we used are mathematical proofs so we think it is apparent that they do not contain personally identifiable information or any offensive content.
365
+
366
+ 5. If you used crowdsourcing or conducted research with human subjects...
367
+
368
+ (a) Did you include the full text of instructions given to participants and screenshots, if applicable? [N/A]
369
+ (b) Did you describe any potential participant risks, with links to Institutional Review Board (IRB) approvals, if applicable? [N/A]
370
+ (c) Did you include the estimated hourly wage paid to participants and the total amount spent on participant compensation? [N/A]
parse/dev/IUikebJ1Bf0/IUikebJ1Bf0_content_list.json ADDED
@@ -0,0 +1,1941 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ [
2
+ {
3
+ "type": "text",
4
+ "text": "Autoformalization with Large Language Models ",
5
+ "text_level": 1,
6
+ "bbox": [
7
+ 204,
8
+ 122,
9
+ 794,
10
+ 148
11
+ ],
12
+ "page_idx": 0
13
+ },
14
+ {
15
+ "type": "text",
16
+ "text": "Yuhuai Wu1,2† Albert Q. Jiang3 Wenda Li3 ",
17
+ "bbox": [
18
+ 254,
19
+ 199,
20
+ 740,
21
+ 217
22
+ ],
23
+ "page_idx": 0
24
+ },
25
+ {
26
+ "type": "text",
27
+ "text": "Markus N. Rabe1 Charles Staats1 Mateja Jamnik3 Christian Szegedy1 ",
28
+ "bbox": [
29
+ 192,
30
+ 234,
31
+ 792,
32
+ 251
33
+ ],
34
+ "page_idx": 0
35
+ },
36
+ {
37
+ "type": "text",
38
+ "text": "1Google Research \n2Stanford University \n3University of Cambridge ",
39
+ "bbox": [
40
+ 411,
41
+ 271,
42
+ 584,
43
+ 315
44
+ ],
45
+ "page_idx": 0
46
+ },
47
+ {
48
+ "type": "text",
49
+ "text": "Abstract ",
50
+ "text_level": 1,
51
+ "bbox": [
52
+ 462,
53
+ 351,
54
+ 535,
55
+ 367
56
+ ],
57
+ "page_idx": 0
58
+ },
59
+ {
60
+ "type": "text",
61
+ "text": "Autoformalization is the process of automatically translating from natural language mathematics to formal specifications and proofs. A successful autoformalization system could advance the fields of formal verification, program synthesis, and artificial intelligence. While the long-term goal of autoformalization seemed elusive for a long time, we show large language models provide new prospects towards this goal. We make the surprising observation that LLMs can correctly translate a significant portion $( 2 5 . { \\bar { 3 } } \\% )$ of mathematical competition problems perfectly to formal specifications in Isabelle/HOL. We demonstrate the usefulness of this process by improving a previously introduced neural theorem prover via training on these autoformalized theorems. Our methodology results in a new state-of-the-art result on the MiniF2F theorem proving benchmark, improving the proof rate from $2 9 . 6 \\%$ to $3 5 . 2 \\%$ . ",
62
+ "bbox": [
63
+ 233,
64
+ 381,
65
+ 764,
66
+ 546
67
+ ],
68
+ "page_idx": 0
69
+ },
70
+ {
71
+ "type": "text",
72
+ "text": "1 Introduction ",
73
+ "text_level": 1,
74
+ "bbox": [
75
+ 174,
76
+ 570,
77
+ 310,
78
+ 588
79
+ ],
80
+ "page_idx": 0
81
+ },
82
+ {
83
+ "type": "text",
84
+ "text": "Autoformalization refers to the task of automatically translating from natural language mathematics to a formal language [46, 42]. The implication of a successful autoformalization tool is huge in both practical and philosophical terms. It would reduce the currently excessive cost of formalization efforts [27], and in the long-term it could connect the various research fields that automate aspects of mathematical reasoning, such as automated theorem proving and computer algebra, to the vast body of mathematical knowledge exclusively written up in natural language. Moreover, autoformalization would be a true testament to machine understanding, grasping both the fuzziness of natural language and the preciseness of formal language. ",
85
+ "bbox": [
86
+ 174,
87
+ 602,
88
+ 825,
89
+ 713
90
+ ],
91
+ "page_idx": 0
92
+ },
93
+ {
94
+ "type": "text",
95
+ "text": "Recent advances in large language models [8, 10] showed promising capabilities of understanding formal languages [9, 32]. However, the existing successes are limited to formal languages where there exists a large body of corpus on the web (e.g., Python language). Formal mathematics data is very scarce. For example, one of the largest formal mathematics libraries, the Archive of Formal Proofs, is only 180MB in size, that is less than $0 . 1 8 \\%$ of the training data for the large language model Codex [9]. Moreover, unlike in the case of commonly used programming languages, where natural language docstrings are broadly available, there is almost zero aligned data between natural language and formal mathematics. Therefore, it is unclear the recent successes can directly contribute to the development of autoformalization. ",
96
+ "bbox": [
97
+ 174,
98
+ 719,
99
+ 825,
100
+ 843
101
+ ],
102
+ "page_idx": 0
103
+ },
104
+ {
105
+ "type": "text",
106
+ "text": "In this work, we explore the prospects of autoformalization with large language models. To our surprise, we find that large language models already have a decent capability of formalizing natural ",
107
+ "bbox": [
108
+ 176,
109
+ 851,
110
+ 823,
111
+ 878
112
+ ],
113
+ "page_idx": 0
114
+ },
115
+ {
116
+ "type": "image",
117
+ "img_path": "images/436fcd5cc20f1bf53d74784a940fdc4ef86e72d2d03f8b591f1361b3b3c86dd8.jpg",
118
+ "image_caption": [],
119
+ "image_footnote": [],
120
+ "bbox": [
121
+ 223,
122
+ 95,
123
+ 785,
124
+ 244
125
+ ],
126
+ "page_idx": 1
127
+ },
128
+ {
129
+ "type": "text",
130
+ "text": "Figure 1: Case study 1: An example of a perfect translation from natural language to Isabelle code. ",
131
+ "bbox": [
132
+ 173,
133
+ 257,
134
+ 820,
135
+ 272
136
+ ],
137
+ "page_idx": 1
138
+ },
139
+ {
140
+ "type": "text",
141
+ "text": "language mathematics in an interactive theorem prover. See Figure 1 for a perfect autoformalization example. The model not only translates into syntactically correct Isabelle code, but also grasps the non-trivial reasoning in natural language. We randomly pick 150 formalizations and manually evaluate their correctness. Among them, LLMs are capable of producing 38 perfect formalizations! As an application, we further demonstrate that autoformalization can provide useful training data for neural theorem provers. We use autoformalized statements as targets for proof search with a neural theorem prover for Isabelle/HOL. After fine-tuning our neural theorem prover on the proofs it found, its success rate on the MiniF2F benchmark [52] increases significantly, achieving a new state-of-the-art result of $3 5 . 2 \\%$ theorems proven. ",
142
+ "bbox": [
143
+ 174,
144
+ 289,
145
+ 825,
146
+ 414
147
+ ],
148
+ "page_idx": 1
149
+ },
150
+ {
151
+ "type": "text",
152
+ "text": "2 Related Work ",
153
+ "text_level": 1,
154
+ "bbox": [
155
+ 174,
156
+ 438,
157
+ 321,
158
+ 455
159
+ ],
160
+ "page_idx": 1
161
+ },
162
+ {
163
+ "type": "text",
164
+ "text": "Early applications of machine learning in theorem proving include the works by Schulz [40] and Urban [43], and later, directly guiding interactive proof assistants using machine learning techniques [15]. The revolution of deep learning then kicked off a new wave of interest in the topic starting with DeepMath [1, 33]. ",
165
+ "bbox": [
166
+ 174,
167
+ 472,
168
+ 825,
169
+ 529
170
+ ],
171
+ "page_idx": 1
172
+ },
173
+ {
174
+ "type": "text",
175
+ "text": "Several approaches have been suggested to address data scarcity: Imitation-free reinforcement learning was used to avoid the need for training on human proofs [31, 6, 15, 49]. Also, hindsight experience replay [2] was used to generate additional training data [5]. Hahn et al. [19], Schmitt et al. [39], Kreber & Hahn [29] and Wu et al. [50] have shown that training on synthetic formulas can be successful for temporal logics and inequalities. Rabe et al. [37] masked out different subexpressions from formal mathematical statements and generated 100 training examples for each source statement. Skip-tree data can also be used to improve the performance of neural theorem provers [22]. ",
176
+ "bbox": [
177
+ 174,
178
+ 535,
179
+ 825,
180
+ 632
181
+ ],
182
+ "page_idx": 1
183
+ },
184
+ {
185
+ "type": "text",
186
+ "text": "Wang et al. [46] explored the use of supervised and unsupervised translation techniques for autoformalization. Supervised translation yielded interesting results, but relied on synthetic (natural-looking) data that was generated by the Mizar theorem prover, while we rely on models trained via selfsupervised language modeling, not trained for this particular purpose. ",
187
+ "bbox": [
188
+ 176,
189
+ 637,
190
+ 825,
191
+ 694
192
+ ],
193
+ "page_idx": 1
194
+ },
195
+ {
196
+ "type": "text",
197
+ "text": "3 Background ",
198
+ "text_level": 1,
199
+ "bbox": [
200
+ 174,
201
+ 718,
202
+ 308,
203
+ 734
204
+ ],
205
+ "page_idx": 1
206
+ },
207
+ {
208
+ "type": "text",
209
+ "text": "Formal Mathematics A few important and complex results of mathematics and computer science have been formalized manually using interactive theorem provers, such as the four color theorem [16], the Kepler conjecture [20], the odd-order theorem [17] and the verification of a microkernel [27]. This gives us almost complete certainty about the correctness of proofs, which can be of great value to resolve doubt about the correctness of complicated mathematical proofs or proving certain properties of software used in safety-critical applications, such as aircraft components [28]. ",
210
+ "bbox": [
211
+ 174,
212
+ 752,
213
+ 825,
214
+ 835
215
+ ],
216
+ "page_idx": 1
217
+ },
218
+ {
219
+ "type": "text",
220
+ "text": "These projects relied on interactive theorem provers, such as Isabelle [48], Coq [12], HOL Light [23], and Lean [13], which are essentially programming languages that enable users to enter their statements and proofs in a formal language, and which can then be checked automatically for correctness. Interactive theorem provers offer a limited amount of automation, but projects that formalize complex problems typically span many years of tedious work by specialists. Only in narrow domains like chip design and the verification of drivers in operating systems has the automation of logic made sufficient progress to find commercial applications. ",
221
+ "bbox": [
222
+ 176,
223
+ 842,
224
+ 825,
225
+ 911
226
+ ],
227
+ "page_idx": 1
228
+ },
229
+ {
230
+ "type": "text",
231
+ "text": "",
232
+ "bbox": [
233
+ 174,
234
+ 92,
235
+ 823,
236
+ 119
237
+ ],
238
+ "page_idx": 2
239
+ },
240
+ {
241
+ "type": "text",
242
+ "text": "Progress in autoformalization and the automation of proofs might eventually make mathematics a universally available tool and enable a paradigm shift in science and the development of (safetycritical) software. Our interest in formalizing mathematics, however, has an additional aspect. We believe that autoformalization will serve a dual purpose and will not only accelerate the development of tools for mathematical reasoning, but also provide a means to ground machine learning systems, enabling a positive feedback loop between machine learning and formal systems (cf. [42]). ",
243
+ "bbox": [
244
+ 174,
245
+ 126,
246
+ 825,
247
+ 209
248
+ ],
249
+ "page_idx": 2
250
+ },
251
+ {
252
+ "type": "text",
253
+ "text": "Large Language Models Our work relies heavily on large language models (LLMs), in particular on PaLM [10] and Codex [9]. The training goal of these models is to predict the next word given some prefix. This allows us to train these models on arbitrary text, which is available in vast quantities. After training the models on hundreds of billions of words (cf. [25]), they are often able to generate high-quality text. We can also give these models an arbitrary prefix (the prompt) that they are then supposed to continue, which gives us some control over what they generate. This has been demonstrated with news articles, conversations, summaries, jokes, and poems. LLMs have also been evaluated on natural language word problems on datasets such as GSM8K [11] and MATH [24], and have been shown to make progress on these benchmarks with increasing scale [10]. ",
254
+ "bbox": [
255
+ 173,
256
+ 223,
257
+ 825,
258
+ 348
259
+ ],
260
+ "page_idx": 2
261
+ },
262
+ {
263
+ "type": "text",
264
+ "text": "In-context Learning Large language models have shown a remarkable ability to learn patterns and tasks within the current input (context) that they are given [8]: this is called in-context learning or few-shot learning. For example, if we prompt a language model with a few pairs of English and matching French sentences, and end with a new English sentence, then the language model is very likely to pick up on the translation task and attempt a translation of the last English sentence. This observation has been used, for example, to achieve strong translation performance without access to large corpora of matching sentence pairs [21]. ",
265
+ "bbox": [
266
+ 174,
267
+ 363,
268
+ 825,
269
+ 460
270
+ ],
271
+ "page_idx": 2
272
+ },
273
+ {
274
+ "type": "text",
275
+ "text": "This allows us to specify the task of autoformalization simply by giving a couple of example formalizations. In Section 4 we will detail how exactly we use in-context learning for autoformalization. ",
276
+ "bbox": [
277
+ 173,
278
+ 467,
279
+ 825,
280
+ 494
281
+ ],
282
+ "page_idx": 2
283
+ },
284
+ {
285
+ "type": "text",
286
+ "text": "4 Autoformalization for Mathematical Competition Problems ",
287
+ "text_level": 1,
288
+ "bbox": [
289
+ 174,
290
+ 513,
291
+ 700,
292
+ 531
293
+ ],
294
+ "page_idx": 2
295
+ },
296
+ {
297
+ "type": "text",
298
+ "text": "Inspired by the success of LLMs for synthesizing computer code by co-training on both natural language and code on web-scale data, we explore the capabilities of LLMs to turn natural language mathematics into formalized theorems for the interactive theorem prover Isabelle. This can be seen as a machine translation task (cf. [47]) in which the input language is English and output language is formal code used by the interactive proof assistant Isabelle [48]. ",
299
+ "bbox": [
300
+ 174,
301
+ 545,
302
+ 825,
303
+ 614
304
+ ],
305
+ "page_idx": 2
306
+ },
307
+ {
308
+ "type": "text",
309
+ "text": "We first study autoformalization in a constrained setting – formalizing mathematical competition problem statements. This setting has the advantage that most of the required background theory and definition has been formalized in the current libraries of Isabelle, so that formalizations are often possible without introducing additional definitions. ",
310
+ "bbox": [
311
+ 174,
312
+ 621,
313
+ 825,
314
+ 676
315
+ ],
316
+ "page_idx": 2
317
+ },
318
+ {
319
+ "type": "text",
320
+ "text": "We start assessing LLMs’ abilities to do autoformalization with a case study. We manually pick two interesting natural language mathematical statements, and prompt PaLM models of various scales [10] as well as Codex [9] to translate them into a formal statement in Isabelle. Next, we study a dataset in which we have human ground truth formalizations. The dataset is a subset of the miniF2F [24] dataset consisting of 140 algebra problems and 120 number theory problems. Using human formalizations as the reference, we compute the BLEU scores of the formalizations produced by several LLMs. Lastly, we perform human evaluations on failure cases in autoformalization on 150 problems. ",
321
+ "bbox": [
322
+ 174,
323
+ 683,
324
+ 823,
325
+ 794
326
+ ],
327
+ "page_idx": 2
328
+ },
329
+ {
330
+ "type": "text",
331
+ "text": "Note that many mathematical competition statements are often of the form in which one asks to find the answer to a certain problem, instead of proving a given proposition. However, formal mathematical statements are in the form of propositions, instead of questions. ",
332
+ "bbox": [
333
+ 174,
334
+ 800,
335
+ 825,
336
+ 842
337
+ ],
338
+ "page_idx": 2
339
+ },
340
+ {
341
+ "type": "text",
342
+ "text": "To transform a question into a proposition, we append the final answer after the question: ",
343
+ "bbox": [
344
+ 173,
345
+ 90,
346
+ 756,
347
+ 106
348
+ ],
349
+ "page_idx": 3
350
+ },
351
+ {
352
+ "type": "text",
353
+ "text": "\\$Problem_Statement The final answer is \\$Answer. ",
354
+ "bbox": [
355
+ 318,
356
+ 111,
357
+ 678,
358
+ 126
359
+ ],
360
+ "page_idx": 3
361
+ },
362
+ {
363
+ "type": "text",
364
+ "text": "The format of the prompt we use to do autoformalization is: ",
365
+ "bbox": [
366
+ 174,
367
+ 138,
368
+ 566,
369
+ 152
370
+ ],
371
+ "page_idx": 3
372
+ },
373
+ {
374
+ "type": "text",
375
+ "text": "Natural language version: $\\$ 1$ Natural_Language_Statement. ",
376
+ "bbox": [
377
+ 292,
378
+ 159,
379
+ 705,
380
+ 172
381
+ ],
382
+ "page_idx": 3
383
+ },
384
+ {
385
+ "type": "text",
386
+ "text": "Translate the natural language version to an Isabelle version: ",
387
+ "bbox": [
388
+ 300,
389
+ 176,
390
+ 704,
391
+ 190
392
+ ],
393
+ "page_idx": 3
394
+ },
395
+ {
396
+ "type": "text",
397
+ "text": "4.1 Mathematical Competition Datasets ",
398
+ "text_level": 1,
399
+ "bbox": [
400
+ 176,
401
+ 205,
402
+ 462,
403
+ 220
404
+ ],
405
+ "page_idx": 3
406
+ },
407
+ {
408
+ "type": "text",
409
+ "text": "MATH [24] contains in total 12,500 (7,500 training and 5,000 test) middle school and high school mathematical competition problems. Problems are taken from past mathematical competitions, including AMC 10, AMC 12, AIME, and more, and many can be found at http: //aops.com/community/c3158_usa_contests. The dataset contains seven categories: algebra, pre-algebra, intermediate algebra, number_theory, precalculus, probability, geometry. Problem statements are written in LaTeX. ",
410
+ "bbox": [
411
+ 174,
412
+ 231,
413
+ 826,
414
+ 314
415
+ ],
416
+ "page_idx": 3
417
+ },
418
+ {
419
+ "type": "text",
420
+ "text": "MiniF2F [52] is a recently introduced benchmark containing 488 mathematical competition statements manually formalized by humans in three different formal languages. Its goal is to compare and benchmark methods across different theorem provers for machine learning research. Some of these problems come from the valid and test set of MATH algebra and number_theory, and others come from previous International Mathematical Olympiad competitions or $\\mathbf { A o P S } ^ { 1 }$ . Note that the Isabelle formalizations of the miniF2F benchmark were committed to the repository during March, 2022. According to the public information of the training data, we think it is highly unlikely these formalizations were included in the pre-training corpus. ",
421
+ "bbox": [
422
+ 174,
423
+ 320,
424
+ 825,
425
+ 433
426
+ ],
427
+ "page_idx": 3
428
+ },
429
+ {
430
+ "type": "text",
431
+ "text": "4.2 Case Studies ",
432
+ "text_level": 1,
433
+ "bbox": [
434
+ 174,
435
+ 446,
436
+ 302,
437
+ 462
438
+ ],
439
+ "page_idx": 3
440
+ },
441
+ {
442
+ "type": "text",
443
+ "text": "Experimental setup For all our experiments, we use the standard greedy decoding (i.e., temperature 0, $p = 1$ ) to obtain the autoformalizations. We randomly select two mathematical statements for constructing the prompt, which we provide in Appendix A.1. That is, no prompt engineering / tuning is performed when constructing the prompt. The natural language problem statements used in the case studies are taken from the miniF2F dataset. In the case studies below, we highlight the output of language models in red to distinguish it from the prompt. ",
444
+ "bbox": [
445
+ 174,
446
+ 473,
447
+ 825,
448
+ 556
449
+ ],
450
+ "page_idx": 3
451
+ },
452
+ {
453
+ "type": "text",
454
+ "text": "Case Study 1 (Figure 1) We study the example shown in Figure 1, in which we ask LLMs to autoformalize an International Mathematical Olympiad problem2 in natural language. Surprisingly, Codex is able to autoformalize the natural language statement as an Isabelle theorem perfectly, with output given. This is surprising for the following reasons. ",
455
+ "bbox": [
456
+ 174,
457
+ 570,
458
+ 825,
459
+ 627
460
+ ],
461
+ "page_idx": 3
462
+ },
463
+ {
464
+ "type": "text",
465
+ "text": "First of all, the amount of Isabelle code is very scarce on the internet. The entire AFP library, the largest formal library that contains most of Isabelle proofs, is only 180MB in size. Even assuming that all of this data was included in the training of Codex, this makes at most $0 . 1 8 \\%$ of the pretraining data on which Codex was trained. The fact that the model can write syntactically correct Isabelle code at all is already fascinating. ",
466
+ "bbox": [
467
+ 174,
468
+ 632,
469
+ 825,
470
+ 703
471
+ ],
472
+ "page_idx": 3
473
+ },
474
+ {
475
+ "type": "text",
476
+ "text": "Second, there is almost zero aligned data from natural language to Isabelle on the web. While some Isabelle files have comments, they typically only give a very high level description of what the theory being formalized is about. So either LLMs are able to transfer knowledge quite successfully between natural language and formal mathematics, or the task was learned mostly via few-shot learning. ",
477
+ "bbox": [
478
+ 174,
479
+ 708,
480
+ 823,
481
+ 763
482
+ ],
483
+ "page_idx": 3
484
+ },
485
+ {
486
+ "type": "text",
487
+ "text": "Last but not least, the model is capable of understanding and formalizing nontrivial reasoning. First, the model is able to formalize the non-existence statement via proof-by-contradiction. To formalize “there is no function $f . . . ^ { \\ ' }$ , it assumes there is such a function, and aims to prove “False”. Second, the model understands what it means by the phrase “to itself”, and correctly infers the domain of function: f :: \"nat \\<Rightarrow> nat\". ",
488
+ "bbox": [
489
+ 173,
490
+ 770,
491
+ 825,
492
+ 840
493
+ ],
494
+ "page_idx": 3
495
+ },
496
+ {
497
+ "type": "text",
498
+ "text": "On the other hand, PaLM made some syntactic mistakes while getting most of the structure of the proof correctly, with outputs shown in Appendix C.1. ",
499
+ "bbox": [
500
+ 176,
501
+ 847,
502
+ 823,
503
+ 875
504
+ ],
505
+ "page_idx": 3
506
+ },
507
+ {
508
+ "type": "text",
509
+ "text": "Case Study 2 Question: ",
510
+ "text_level": 1,
511
+ "bbox": [
512
+ 199,
513
+ 101,
514
+ 364,
515
+ 114
516
+ ],
517
+ "page_idx": 4
518
+ },
519
+ {
520
+ "type": "text",
521
+ "text": "Natural Language version: \"When all the girls at Madeline’s school line up in rows of eight, there are seven left over. If instead they line up in rows of four, how many are left over? The final answer is 3.\" Translate the natural language version to an Isabelle version: ",
522
+ "bbox": [
523
+ 199,
524
+ 114,
525
+ 457,
526
+ 210
527
+ ],
528
+ "page_idx": 4
529
+ },
530
+ {
531
+ "type": "text",
532
+ "text": "Case Study 3 Question: ",
533
+ "text_level": 1,
534
+ "bbox": [
535
+ 506,
536
+ 106,
537
+ 671,
538
+ 119
539
+ ],
540
+ "page_idx": 4
541
+ },
542
+ {
543
+ "type": "text",
544
+ "text": "Natural language version: \"Let $f$ be a linear function for which $f ( 6 ) - f ( 2 ) = 1 2$ . What is $f ( 1 2 ) - f ( 2 ) !$ The final answer is 30.\" Translate the natural language version to an Isabelle version: ",
545
+ "bbox": [
546
+ 504,
547
+ 121,
548
+ 816,
549
+ 189
550
+ ],
551
+ "page_idx": 4
552
+ },
553
+ {
554
+ "type": "image",
555
+ "img_path": "images/0aaa05a216df4cc0568df308ece9e46bcd792a53a439bc81ac19ca989be5180e.jpg",
556
+ "image_caption": [
557
+ "Figure 2: Autoformalizations from natural language to Isabelle code. Left: Case study 2 – perfect formalization by PaLM. Right: Case study $3 -$ incorrect formalization by Codex. "
558
+ ],
559
+ "image_footnote": [],
560
+ "bbox": [
561
+ 504,
562
+ 199,
563
+ 816,
564
+ 309
565
+ ],
566
+ "page_idx": 4
567
+ },
568
+ {
569
+ "type": "text",
570
+ "text": "Case Study 2 (Figure 2) In the next example, we ask LLMs to autoformalize a grade school mathematical word problem. Remarkably, PaLM and Codex are both capable of formalizing the statement perfectly. This is surprising because formalizations of grade school math problems in interactive theorem provers are rare (if they exist at all), as this type of mathematics is not of interest to formal mathematicians. Even more, none of the examples in the prompt (see Appendix A.1) that we provide are of this type. It is hence remarkable that the model is capable of extrapolating to this type of statement, showing a great promise of using LLMs for autoformalization. ",
571
+ "bbox": [
572
+ 174,
573
+ 367,
574
+ 825,
575
+ 465
576
+ ],
577
+ "page_idx": 4
578
+ },
579
+ {
580
+ "type": "text",
581
+ "text": "To study this problem in more depth, we probe PaLM models of various sizes (8B, 64B, 540B) with outputs shown in Appendix C.2, and notice that scale is crucial for the LLMs ability to formalize. We observe that the 8B and 64B models are incapable of formalizing this problem, but the largest 540B model is able to produce a correct formalization. ",
582
+ "bbox": [
583
+ 174,
584
+ 470,
585
+ 825,
586
+ 526
587
+ ],
588
+ "page_idx": 4
589
+ },
590
+ {
591
+ "type": "text",
592
+ "text": "Case Study 3 (Figure 2) In our third case study, Codex gives an incorrect formalization in Isabelle. The mathematical statement involves a concept of “linear function”, which the model fails to formalize correctly. Codex assumes this is already a known concept in Isabelle, and made up a name: linear f. Can the model learn to formalize such problems if the prompt contains an example that explains the concept of a line? We explore this and give an affirmative answer to the question (see Appendix C.3). Once seeing a tangentially related problem that explains the concept of a “line”, Codex is able to perfectly formalize a “linear function”. This shows the importance of the few shot examples we include, and also how good a few-shot learners these models are! ",
593
+ "bbox": [
594
+ 174,
595
+ 547,
596
+ 826,
597
+ 659
598
+ ],
599
+ "page_idx": 4
600
+ },
601
+ {
602
+ "type": "text",
603
+ "text": "Has the model memorized these formalizations? Whilst we do not have access to the training set of Codex, we attempted to find any occurrences of the formalizations produced in the case studies on the internet. We Googled them in different variants and inspected the first page of the search results. We tried variants with and without an “Isabelle” prefix, with and without quotation marks and other special characters, and also individual parts of it, such as “Isabelle ${ \\ \" } { \\mathbf { n } }$ mod $8 \\ = \\ 7 \" \\quad$ , but we did not find any occurrences of related statements. We also tested that we are indeed able to find occurrences of Isabelle formalizations on the web with this methodology, using pieces of formalizations picked from several websites, including the Archive of Formal Proofs. Hence, we are confident that the model has not memorized the formalizations it generated. ",
604
+ "bbox": [
605
+ 174,
606
+ 679,
607
+ 825,
608
+ 804
609
+ ],
610
+ "page_idx": 4
611
+ },
612
+ {
613
+ "type": "text",
614
+ "text": "4.3 BLEU for Model Comparisons ",
615
+ "text_level": 1,
616
+ "bbox": [
617
+ 176,
618
+ 827,
619
+ 426,
620
+ 842
621
+ ],
622
+ "page_idx": 4
623
+ },
624
+ {
625
+ "type": "text",
626
+ "text": "The miniF2F benchmark contains 140 algebra problems and 120 number theory problems from the MATH dataset. For these problems, we have human ground truth formalizations in Isabelle, which gives us an evaluation set with pairs of natural language statements (from MATH) and their formalizations. We use this dataset to quantitatively compare different LLMs. ",
627
+ "bbox": [
628
+ 174,
629
+ 856,
630
+ 825,
631
+ 911
632
+ ],
633
+ "page_idx": 4
634
+ },
635
+ {
636
+ "type": "table",
637
+ "img_path": "images/2805c253c7d3897941390d7c2f390c1e317c605afb6bbfcdd0d402d2363cc75e.jpg",
638
+ "table_caption": [
639
+ "Table 1: BLEU scores between the autoformalized statements and human formalized ground truth. "
640
+ ],
641
+ "table_footnote": [],
642
+ "table_body": "<table><tr><td>Models\\ Subject</td><td>algebra</td><td>number_theory</td></tr><tr><td>PaLM8B</td><td>31.49</td><td>22.10</td></tr><tr><td>PaLM64B</td><td>43.13</td><td>31.43</td></tr><tr><td>PaLM540B</td><td>50.30</td><td>36.16</td></tr><tr><td>Codex</td><td>57.13</td><td>43.33</td></tr></table>",
643
+ "bbox": [
644
+ 325,
645
+ 109,
646
+ 671,
647
+ 195
648
+ ],
649
+ "page_idx": 5
650
+ },
651
+ {
652
+ "type": "table",
653
+ "img_path": "images/572096adbf596d56d60aef7233e35954c7ad8f3b2550603f6dd99da160839ef2.jpg",
654
+ "table_caption": [
655
+ "Table 2: Failure case study of 150 problems formalized by Codex. "
656
+ ],
657
+ "table_footnote": [],
658
+ "table_body": "<table><tr><td>Failure cases\\Subjects</td><td>algebra</td><td>number_theory</td><td>inter_alg</td></tr><tr><td>Perfect translation</td><td>13</td><td>17</td><td>8</td></tr><tr><td>Incomplete/ill-formed/unclear prompt</td><td>9</td><td>3</td><td>14</td></tr><tr><td>Fail to align definitions or concepts</td><td>10</td><td>18</td><td>18</td></tr><tr><td>Inconsistent/missing assumption</td><td>8</td><td>9</td><td>9</td></tr><tr><td>Syntactical/type error</td><td>7</td><td>2</td><td>11</td></tr><tr><td>Missing definition in Isabelle</td><td>0</td><td>12</td><td>3</td></tr><tr><td>Wrong application of functions</td><td>6</td><td>13</td><td>16</td></tr><tr><td>Other</td><td>6</td><td>2</td><td>1</td></tr></table>",
659
+ "bbox": [
660
+ 210,
661
+ 236,
662
+ 787,
663
+ 376
664
+ ],
665
+ "page_idx": 5
666
+ },
667
+ {
668
+ "type": "text",
669
+ "text": "Given the observation about few shot learning in Case study 3, we decided to add more relevant examples to each subject to improve the quality of autoformalization. For each subject (i.e., algebra and number_theory), we randomly sample 10 problems to construct the few shot prompt. The rest of the problems are used for evaluation (i.e., 130 for algebra and 110 for number_theory. We provide the prompt used in the Appendix B.1 and B.2. ",
670
+ "bbox": [
671
+ 174,
672
+ 409,
673
+ 825,
674
+ 478
675
+ ],
676
+ "page_idx": 5
677
+ },
678
+ {
679
+ "type": "text",
680
+ "text": "We use PaLM models of varying sizes and Codex to perform the autoformalization, and compute the BLEU scores of the formalizations, shown in Table 1. Confirming our observation in Case study 2, we see a clear trend that scaling improves translation, as the BLEU scores consistently improve when we scale PaLM models from 8B to 540B, for both subjects. In addition, we see that the Codex model is better at autoformalization measured by BLEU, possibly due to the fact that Codex was trained on more formal data than PaLM. ",
681
+ "bbox": [
682
+ 174,
683
+ 483,
684
+ 825,
685
+ 568
686
+ ],
687
+ "page_idx": 5
688
+ },
689
+ {
690
+ "type": "text",
691
+ "text": "4.4 Human Evaluation of Failure cases ",
692
+ "text_level": 1,
693
+ "bbox": [
694
+ 176,
695
+ 592,
696
+ 455,
697
+ 606
698
+ ],
699
+ "page_idx": 5
700
+ },
701
+ {
702
+ "type": "text",
703
+ "text": "To better understand LLMs’ ability to do autoformalization, we manually inspect Codex’s autoformalizations of 150 random problems from the MATH dataset [24]. 50 of the problem statements are sampled from the algebra training set, 50 from number_theory and 50 from intermediate_algebra. For algebra and number_theory, we use their corresponding prompt as in the last section, shown in Appendix B.1 and B.2. For intermediate_algebra, we use the prompt we used for algebra (Appendix B.1). We classify the failure modes of these translations, shown in Table 2. ",
704
+ "bbox": [
705
+ 174,
706
+ 619,
707
+ 826,
708
+ 703
709
+ ],
710
+ "page_idx": 5
711
+ },
712
+ {
713
+ "type": "text",
714
+ "text": "We see that out of 150 problems, Codex is capable of translating 38 problems perfectly – a success rate of $2 5 . 3 \\%$ . The majority of the failures are due to the misalignment of informal and formal definitions. For example, when seeing the phrase “the greatest possible value”, the LLMs often fail to align it with the function Greatest/Max in Isabelle. Another example is the failure to align the factorial of $n$ (i.e., !n) to fact $\\pmb { n }$ in Isabelle. Other common failure modes include the misapplication of functions (e.g., applying a prefix function in an infix way). ",
715
+ "bbox": [
716
+ 174,
717
+ 709,
718
+ 825,
719
+ 792
720
+ ],
721
+ "page_idx": 5
722
+ },
723
+ {
724
+ "type": "text",
725
+ "text": "5 Autoformalization for Neural Theorem Proving ",
726
+ "text_level": 1,
727
+ "bbox": [
728
+ 173,
729
+ 819,
730
+ 602,
731
+ 837
732
+ ],
733
+ "page_idx": 5
734
+ },
735
+ {
736
+ "type": "text",
737
+ "text": "To demonstrate the usefulness of the formalized statements, we explore if one can improve neural theorem provers by training the neural models on proofs of automatically translated theorems. In this section, we combine autoformalization with expert iteration algorithms [4], and achieve a new state of the art in miniF2F benchmark. ",
738
+ "bbox": [
739
+ 174,
740
+ 854,
741
+ 823,
742
+ 911
743
+ ],
744
+ "page_idx": 5
745
+ },
746
+ {
747
+ "type": "text",
748
+ "text": "5.1 Expert Iteration with Autoformalization ",
749
+ "text_level": 1,
750
+ "bbox": [
751
+ 174,
752
+ 90,
753
+ 491,
754
+ 106
755
+ ],
756
+ "page_idx": 6
757
+ },
758
+ {
759
+ "type": "text",
760
+ "text": "The basic idea of expert iteration [4] is to iteratively generate a better dataset using the model, and use the data to improve the model quality. This allows the model to generate an even better quality of the dataset and hence a better model, forming a self-improvement cycle. ",
761
+ "bbox": [
762
+ 174,
763
+ 123,
764
+ 825,
765
+ 165
766
+ ],
767
+ "page_idx": 6
768
+ },
769
+ {
770
+ "type": "text",
771
+ "text": "In neural theorem proving, one way to get better quality data is to use feedback from the proof checker to run many proof searches (or generate multiple proofs) and check the proof attempts for correctness. Newly found correct proofs can then be used as the new training data to improve the neural prover [7, 35, 36]. The main critical ingredient that is needed is a set of problem statements on which the model can perform proof search to obtain new training data. However, unlike in Polu et al. [36], where one asks humans to manually formalize a set of problems to get formal statements, here we use LLMs to autoformalize the theorems in order to kick off the self-improvement cycle. ",
772
+ "bbox": [
773
+ 174,
774
+ 171,
775
+ 825,
776
+ 268
777
+ ],
778
+ "page_idx": 6
779
+ },
780
+ {
781
+ "type": "text",
782
+ "text": "More formally, denote a base neural theorem prover as $M _ { 0 }$ . Let the set of autoformalized problems be $\\mathcal { A }$ . For each iteration $i = 1 \\dots N$ , we carry out the following procedure: use the language model $M _ { i - 1 }$ with best-first search to prove as many theorems as possible in $\\mathcal { A }$ , collect the set of successful proofs $S _ { i }$ , concatenate successful problems from all iterations with the formal mathematics problems to create the set $\\begin{array} { r } { \\mathscr { A } _ { i } = ( \\bigcup _ { j \\leq i } S _ { i } ) \\bar { \\cup } \\bar { B } } \\end{array}$ , and fine-tune $M _ { 0 }$ on it for exactly one epoch to get a new model $M _ { i }$ . When we take the union of successful proofs from all past iterations, we perform deduplication by problem statements, similar to Polu et al. [36]. ",
783
+ "bbox": [
784
+ 174,
785
+ 273,
786
+ 825,
787
+ 373
788
+ ],
789
+ "page_idx": 6
790
+ },
791
+ {
792
+ "type": "text",
793
+ "text": "5.2 Neural Theorem Provers ",
794
+ "text_level": 1,
795
+ "bbox": [
796
+ 174,
797
+ 405,
798
+ 385,
799
+ 420
800
+ ],
801
+ "page_idx": 6
802
+ },
803
+ {
804
+ "type": "text",
805
+ "text": "To demonstrate the effectiveness of the approach, we start with a recently introduced neural theorem prover for Isabelle, LISA [26]. The LISA agent is fine-tuned on the PISA dataset [26] (extraction and interaction code under a BSD license), which consists of 2.49 million proof steps from the Isabelle/HOL library (under a BSD-style license) and the Archive of Formal Proofs (under various licenses as described here). The model is trained with the objective to predict the next token in a proof step, given the proof state and the last proof step. Following the setup of Thor [3], which achieves SOTA performance in the no-additional-training-data category on MiniF2F, we invoke Sledgehammer with a 30 second timeout when the model generates a step containing any of the keywords metis, meson, and smt. ",
806
+ "bbox": [
807
+ 174,
808
+ 438,
809
+ 825,
810
+ 563
811
+ ],
812
+ "page_idx": 6
813
+ },
814
+ {
815
+ "type": "text",
816
+ "text": "We use Wang [45]’s implementation (under an Apache license 2.0) of a GPT-2 [38] style decoder-only transformer [44] model with 700M non-embedding parameters. The model has 24 layers, 24 attention heads, a hidden dimension of 1536, and a vocabulary size of 50400. We pre-train the model on the GitHub $^ +$ arXiv subsets of The Pile [14] for 200,000 steps, with a context length of 2048 tokens. In pre-training we use a warmup strategy [18], raising the learning rate linearly from 0 to $2 \\times 1 0 ^ { - 4 }$ in 3,000 steps. We then use a cosine learning rate scheduler [34] for the rest of the pre-training, with a final learning rate of $1 . 2 \\times 1 0 ^ { - 5 }$ . We use a global batch size of 32 sequences, or 65,536 tokens. For fine-tuning we use the same learning rate schedule, with 10,000 warmup steps, 90,000 annealing steps, maximum learning rate $3 \\times 1 0 ^ { - 4 }$ and final learning rate $3 \\times 1 0 ^ { - 5 }$ . The global batch size is 144 sequences, or 294,912 tokens. The model’s evaluation loss reaches a minimum after 13,000 steps and we use that checkpoint. For the fine-tuning in expert iteration, we fix the learning rate at $3 \\times 1 0 ^ { - 4 }$ and the batch size at 144 sequences, and train the model for exactly one epoch. ",
817
+ "bbox": [
818
+ 173,
819
+ 569,
820
+ 825,
821
+ 734
822
+ ],
823
+ "page_idx": 6
824
+ },
825
+ {
826
+ "type": "text",
827
+ "text": "Here we give the details regarding the best-first search strategy used in evaluation: we maintain a priority queue of search nodes with queue length 32. The accumulated log probability of the proof steps is used as the queue priority. For each theorem to prove, we first initialize the queue with one node that has the theorem declared and no proof step applied to it. At each time-step, we deque and sample 32 possible proof steps to apply to the node. The nodes corresponding to steps that successfully proceed the proofs then get added to the queue. We repeat this process until the theorem is successfully proven, or we reach our computational budget. ",
828
+ "bbox": [
829
+ 174,
830
+ 741,
831
+ 825,
832
+ 838
833
+ ],
834
+ "page_idx": 6
835
+ },
836
+ {
837
+ "type": "text",
838
+ "text": "Machine specification For pre-training, fine-tuning, and evaluation, we use a TPUv3 with 8 cores from Google Cloud Platform. The Isabelle process has access to up to 32 CPU cores. We estimate that running all the experiments in this paper requires a total of 780 TPU hours. ",
839
+ "bbox": [
840
+ 176,
841
+ 869,
842
+ 823,
843
+ 911
844
+ ],
845
+ "page_idx": 6
846
+ },
847
+ {
848
+ "type": "table",
849
+ "img_path": "images/5b574fe39bca67f72dffc676fa31477907b4d6d598414cff3231a3b581b1d24a.jpg",
850
+ "table_caption": [
851
+ "Table 3: Proof success rates on miniF2F. "
852
+ ],
853
+ "table_footnote": [],
854
+ "table_body": "<table><tr><td>Model</td><td>valid</td><td>test</td></tr><tr><td>PACT[22]</td><td>23.9%</td><td>24.6%</td></tr><tr><td>FMSCL [36]</td><td>33.6%</td><td>29.6%</td></tr><tr><td>Ours</td><td>37.3%</td><td>35.2%</td></tr></table>",
855
+ "bbox": [
856
+ 375,
857
+ 107,
858
+ 616,
859
+ 179
860
+ ],
861
+ "page_idx": 7
862
+ },
863
+ {
864
+ "type": "text",
865
+ "text": "5.3 Result ",
866
+ "text_level": 1,
867
+ "bbox": [
868
+ 173,
869
+ 199,
870
+ 258,
871
+ 213
872
+ ],
873
+ "page_idx": 7
874
+ },
875
+ {
876
+ "type": "text",
877
+ "text": "We use Codex with greedy decoding to formalize 3908 mathematical problems in algebra, intermediate algebra, and number theory from the training set of MATH [24], with the same few shot prompts used in Section 4.4. Out of them, 3363 of the autoformalized theorems are syntactically correct. We then perform expert iteration on this dataset. ",
878
+ "bbox": [
879
+ 173,
880
+ 224,
881
+ 826,
882
+ 280
883
+ ],
884
+ "page_idx": 7
885
+ },
886
+ {
887
+ "type": "text",
888
+ "text": "We start with a neural theorem prover $( M _ { 0 } )$ as described in Section 5.2. In our first iteration, $M _ { 0 }$ proves 782 theorems, with a success rate of $2 3 . 3 \\%$ (out of 3363). This gives us a new set of verified proofs to further train the neural theorem prover. We proceed to fine-tune our neural theorem prover in the fashion described in Section 5.1 to get a new prover $( M _ { 1 } )$ . This process is repeated in the second iteration, giving us 1011 successful proofs from the autoformalized theorems $\\bar { ( 3 0 . 1 \\% ) }$ . We fine-tuned $M _ { 0 }$ again on all available deduplicated proofs to obtain $M _ { 2 }$ . ",
889
+ "bbox": [
890
+ 174,
891
+ 286,
892
+ 825,
893
+ 371
894
+ ],
895
+ "page_idx": 7
896
+ },
897
+ {
898
+ "type": "text",
899
+ "text": "After each stage of fine-tuning, we evaluate the neural theorem prover on miniF2F [52]. The results are shown in Table 3. The base model $( M _ { 0 } )$ has a success rate of $2 8 . 3 \\%$ and $2 9 . 9 \\%$ on the validation and test fractions of miniF2F respectively. It can be observed that the first expert iteration increases the success rate of the neural prover by $\\mathrm { 7 . 8 \\% }$ and $4 . 1 \\%$ to $3 6 . 1 \\%$ and $3 4 . 0 \\%$ on the valid and test sets. The second iteration further improves them both by $1 . 2 \\%$ , to $3 7 . 3 \\%$ and $3 5 . 2 \\%$ . By doing two expert iterations on the autoformalized theorems, the neural prover achieves a success rate that is $5 . { \\bar { 6 } } \\%$ higher than the previous state-of-the-art. ",
900
+ "bbox": [
901
+ 174,
902
+ 376,
903
+ 825,
904
+ 473
905
+ ],
906
+ "page_idx": 7
907
+ },
908
+ {
909
+ "type": "text",
910
+ "text": "6 An Outlook on Autoformalizing Advanced Mathematics ",
911
+ "text_level": 1,
912
+ "bbox": [
913
+ 176,
914
+ 494,
915
+ 671,
916
+ 511
917
+ ],
918
+ "page_idx": 7
919
+ },
920
+ {
921
+ "type": "text",
922
+ "text": "So far, we focused on mathematical competition problems, in which we achieve significant results using autoformalization. Not only can LLMs autoformalize non-trivial theorems, the autoformalized theorems can also improve neural prover performance. In this section, we take a peek into more advanced mathematics. We hope to identify some of the limitations of our methods when it comes to autoformalizing mathematics in the wild. ",
923
+ "bbox": [
924
+ 174,
925
+ 525,
926
+ 825,
927
+ 595
928
+ ],
929
+ "page_idx": 7
930
+ },
931
+ {
932
+ "type": "text",
933
+ "text": "6.1 Autoformalization: from Natural Language to Isabelle ",
934
+ "text_level": 1,
935
+ "bbox": [
936
+ 174,
937
+ 613,
938
+ 591,
939
+ 627
940
+ ],
941
+ "page_idx": 7
942
+ },
943
+ {
944
+ "type": "text",
945
+ "text": "Autoformalization is extremely challenging in the sense that the model needs to (1) bridge the logical gaps left in pen-and-paper proofs, (2) assume the implicit contexts and assumptions, and (3) align informal definitions/concepts to formal ones. This task is further complicated considering the context can change from time to time and the same mathematical object can be formalized in subtly different ways. In this paper, we only deal with autoformalization of theorem statements, where the model is mainly challenged by definition alignments. Compared to competition problems in Section 4.4, advanced mathematical statements assume more context information that additionally obscures the alignment. ",
946
+ "bbox": [
947
+ 173,
948
+ 638,
949
+ 825,
950
+ 750
951
+ ],
952
+ "page_idx": 7
953
+ },
954
+ {
955
+ "type": "text",
956
+ "text": "Figure 3 shows a typical case where the model fails to align the informal definition to the formal one. Based on the notation used, the model does not correctly distinguish between products of numbers, products of sets, and products of topological spaces. In Isabelle, the correct conclusion for the statement should be compact_space (product_topology $\\textbf { \\textit { X } } _ { I } )$ , where $I$ is an index set that ought to have been introduced in the fixes and assumes sections. ",
957
+ "bbox": [
958
+ 174,
959
+ 756,
960
+ 825,
961
+ 825
962
+ ],
963
+ "page_idx": 7
964
+ },
965
+ {
966
+ "type": "text",
967
+ "text": "6.2 Informalization: from Isabelle to Natural Language ",
968
+ "text_level": 1,
969
+ "bbox": [
970
+ 173,
971
+ 843,
972
+ 573,
973
+ 858
974
+ ],
975
+ "page_idx": 7
976
+ },
977
+ {
978
+ "type": "text",
979
+ "text": "So far, we explored one direction of translation: from natural language statement to formal statement in Isabelle. The other direction, informalization, is also of great importance for two reasons: (1) the informal texts are much easier for humans to comprehend and communicate, and (2) we can ",
980
+ "bbox": [
981
+ 174,
982
+ 869,
983
+ 825,
984
+ 911
985
+ ],
986
+ "page_idx": 7
987
+ },
988
+ {
989
+ "type": "text",
990
+ "text": "Question: An arbitrary product of compact spaces is compact. ",
991
+ "bbox": [
992
+ 199,
993
+ 101,
994
+ 611,
995
+ 114
996
+ ],
997
+ "page_idx": 8
998
+ },
999
+ {
1000
+ "type": "text",
1001
+ "text": "Codex Output: ",
1002
+ "text_level": 1,
1003
+ "bbox": [
1004
+ 200,
1005
+ 128,
1006
+ 305,
1007
+ 142
1008
+ ],
1009
+ "page_idx": 8
1010
+ },
1011
+ {
1012
+ "type": "text",
1013
+ "text": "theorem ",
1014
+ "bbox": [
1015
+ 200,
1016
+ 145,
1017
+ 261,
1018
+ 155
1019
+ ],
1020
+ "page_idx": 8
1021
+ },
1022
+ {
1023
+ "type": "text",
1024
+ "text": "fixes X :: \"’a set set\" assumes \"\\<forall>x \\<in>X. compact x\" shows \"compact (\\<Prod> x \\<in> X. x)\" ",
1025
+ "bbox": [
1026
+ 218,
1027
+ 159,
1028
+ 527,
1029
+ 204
1030
+ ],
1031
+ "page_idx": 8
1032
+ },
1033
+ {
1034
+ "type": "text",
1035
+ "text": "Figure 3: A formalization for an advanced mathematical statement by Codex. ",
1036
+ "bbox": [
1037
+ 245,
1038
+ 239,
1039
+ 751,
1040
+ 255
1041
+ ],
1042
+ "page_idx": 8
1043
+ },
1044
+ {
1045
+ "type": "text",
1046
+ "text": "lemma topologyI: ",
1047
+ "bbox": [
1048
+ 444,
1049
+ 270,
1050
+ 573,
1051
+ 281
1052
+ ],
1053
+ "page_idx": 8
1054
+ },
1055
+ {
1056
+ "type": "text",
1057
+ "text": "lemma seteqI: \"[[Vx. x∈A =⇒ x∈B; \nVx. x∈B =⇒ x∈A ]] \n=⇒ A = B\" \"[[ V x y. [[ is_open T x; is_open T y ]] =⇒ \nis_open T (x ∩ y); V M. ∀ m ∈ M. is_open T ${ \\textbf { \\em m } } \\implies$ \nis_open T (S M) $\\mathbb { I } \\Longrightarrow$ topology T\" ",
1058
+ "bbox": [
1059
+ 212,
1060
+ 267,
1061
+ 385,
1062
+ 318
1063
+ ],
1064
+ "page_idx": 8
1065
+ },
1066
+ {
1067
+ "type": "text",
1068
+ "text": "",
1069
+ "bbox": [
1070
+ 444,
1071
+ 281,
1072
+ 781,
1073
+ 347
1074
+ ],
1075
+ "page_idx": 8
1076
+ },
1077
+ {
1078
+ "type": "text",
1079
+ "text": "Translate the Isabelle version to a natural language version: ",
1080
+ "bbox": [
1081
+ 214,
1082
+ 324,
1083
+ 393,
1084
+ 366
1085
+ ],
1086
+ "page_idx": 8
1087
+ },
1088
+ {
1089
+ "type": "text",
1090
+ "text": "Translate the Isabelle version to a natural language version: ",
1091
+ "bbox": [
1092
+ 444,
1093
+ 352,
1094
+ 784,
1095
+ 378
1096
+ ],
1097
+ "page_idx": 8
1098
+ },
1099
+ {
1100
+ "type": "text",
1101
+ "text": "Codex Output: ",
1102
+ "text_level": 1,
1103
+ "bbox": [
1104
+ 214,
1105
+ 381,
1106
+ 320,
1107
+ 392
1108
+ ],
1109
+ "page_idx": 8
1110
+ },
1111
+ {
1112
+ "type": "text",
1113
+ "text": "Codex Output: ",
1114
+ "text_level": 1,
1115
+ "bbox": [
1116
+ 444,
1117
+ 393,
1118
+ 550,
1119
+ 406
1120
+ ],
1121
+ "page_idx": 8
1122
+ },
1123
+ {
1124
+ "type": "text",
1125
+ "text": "\"If $A$ and $B$ are sets such that $A \\subseteq B$ and $B \\subseteq A$ then $A = B$ .\" ",
1126
+ "bbox": [
1127
+ 214,
1128
+ 393,
1129
+ 392,
1130
+ 438
1131
+ ],
1132
+ "page_idx": 8
1133
+ },
1134
+ {
1135
+ "type": "text",
1136
+ "text": "\"If $T$ is a set and $T$ is closed under finite intersections and arbitrary unions, then $T$ is a topology.\" ",
1137
+ "bbox": [
1138
+ 444,
1139
+ 407,
1140
+ 784,
1141
+ 436
1142
+ ],
1143
+ "page_idx": 8
1144
+ },
1145
+ {
1146
+ "type": "text",
1147
+ "text": "Figure 4: Two perfect translations from Isabelle code to natural language by Codex. ",
1148
+ "bbox": [
1149
+ 223,
1150
+ 459,
1151
+ 772,
1152
+ 474
1153
+ ],
1154
+ "page_idx": 8
1155
+ },
1156
+ {
1157
+ "type": "text",
1158
+ "text": "align translated informal statements with formal ones to create data, and use the back-translation techniques [41] to potentially boost the translator’s performance further. In this section, we explore Codex’s capability of translating formal Isabelle statement to natural language. ",
1159
+ "bbox": [
1160
+ 174,
1161
+ 487,
1162
+ 825,
1163
+ 530
1164
+ ],
1165
+ "page_idx": 8
1166
+ },
1167
+ {
1168
+ "type": "text",
1169
+ "text": "A corpus of 38 formal-language theorems, lemmas, and definitions is selected by an Isabelle expert. These statements are automatically translated to informal mathematics using Codex; to see the prompt we used and the results for all 38 examples, see Appendix B.3 and E.2. We present two examples of informalization in Figure 4. Of the 38 examples, 36 were translated to a reasonably coherent statement, and 29 of these statements $( 7 6 \\% )$ were more-or-less correct, giving a vastly better success rate than the $25 \\%$ success rate of formalization (Section 4.4). Our main conclusion is that for advanced mathematics, the model is better at informalization than formalization, showing the prospect of backtranslation style algorithms. ",
1170
+ "bbox": [
1171
+ 174,
1172
+ 535,
1173
+ 825,
1174
+ 646
1175
+ ],
1176
+ "page_idx": 8
1177
+ },
1178
+ {
1179
+ "type": "text",
1180
+ "text": "Note that the standard is more relaxed here since we assume a human reader will supply the obvious context and correct mistakes when the intended meaning is obvious (intended by the hypothetical human writer of these sentences). To illustrate, an example of a minor “acceptable” error: assuming that “ $w , z$ are in the same connected component of the plane” when, in context, it is clear that $w , z$ should be assumed to be in the same connected component of the complement of a previously specified curve. (The assumption as originally stated is trivial.) For an example of a major error: almost-perfect translation of the Central Limit Theorem that omits the assumption of identical distributions. ",
1181
+ "bbox": [
1182
+ 173,
1183
+ 652,
1184
+ 825,
1185
+ 763
1186
+ ],
1187
+ "page_idx": 8
1188
+ },
1189
+ {
1190
+ "type": "text",
1191
+ "text": "7 Discussion ",
1192
+ "text_level": 1,
1193
+ "bbox": [
1194
+ 174,
1195
+ 782,
1196
+ 294,
1197
+ 799
1198
+ ],
1199
+ "page_idx": 8
1200
+ },
1201
+ {
1202
+ "type": "text",
1203
+ "text": "Promise of Autoformalization with LLMs We have seen that automated formalization of informally given natural language statements is generally possible, even with language models not trained for this particular task. Also, automatically formalized statements are useful for training and improving the reasoning capabilities of automated neural provers. Our hope is that improved versions of this methodology will be capable of enabling a positive feedback loop involving formalization and formal reasoning that has the potential of reaching human level capabilities in both respects, as was suggested by [42]. ",
1204
+ "bbox": [
1205
+ 174,
1206
+ 814,
1207
+ 825,
1208
+ 911
1209
+ ],
1210
+ "page_idx": 8
1211
+ },
1212
+ {
1213
+ "type": "text",
1214
+ "text": "Limitations and future directions We use a static model for the formalization process. For largescale autoformalization, we will need to formalize larger theories, preferably without fine tuning the model, as training it could be cumbersome and resource consuming. However, in order to utilize the newly added notions, the model would need to keep whole large theories in the current context window, which exceeds those of the current LLMs. This limits our approach to the generation of fairly small pieces of formal mathematics and the automatic formalization of entire theories including their definitions will require new research ideas. One path towards this goal might be the use of continuous training or expert iteration, cycle-consistency-based training [30, 46], or novel uses of in-context learning. To generate larger theories we will also need neural networks that can recall longer sequences (current LLMs are typically limited to a few thousand words). Retrieval-augmented language models, such as the memorizing transformer [51] offer one path to overcome this limitation. ",
1215
+ "bbox": [
1216
+ 174,
1217
+ 92,
1218
+ 825,
1219
+ 243
1220
+ ],
1221
+ "page_idx": 9
1222
+ },
1223
+ {
1224
+ "type": "text",
1225
+ "text": "Societal Impact While the potential of creating negative societal impact through formalizations is small, the use of LLMs always comes with risks. For example, for deploying an autoformalization tool using LLMs we would need to consider the inclusivity of variable and lemma names, and of the attribution of scientific ideas. ",
1226
+ "bbox": [
1227
+ 176,
1228
+ 257,
1229
+ 823,
1230
+ 313
1231
+ ],
1232
+ "page_idx": 9
1233
+ },
1234
+ {
1235
+ "type": "text",
1236
+ "text": "Acknowledgement ",
1237
+ "text_level": 1,
1238
+ "bbox": [
1239
+ 176,
1240
+ 332,
1241
+ 330,
1242
+ 349
1243
+ ],
1244
+ "page_idx": 9
1245
+ },
1246
+ {
1247
+ "type": "text",
1248
+ "text": "AQJ is supported by a Peterhouse Graduate Research Studentship. WL is supported by the ERC Advanced Grant ALEXANDRIA (Project GA 742178). ",
1249
+ "bbox": [
1250
+ 174,
1251
+ 362,
1252
+ 821,
1253
+ 390
1254
+ ],
1255
+ "page_idx": 9
1256
+ },
1257
+ {
1258
+ "type": "text",
1259
+ "text": "References ",
1260
+ "text_level": 1,
1261
+ "bbox": [
1262
+ 174,
1263
+ 410,
1264
+ 266,
1265
+ 425
1266
+ ],
1267
+ "page_idx": 9
1268
+ },
1269
+ {
1270
+ "type": "text",
1271
+ "text": "[1] Alexander A. Alemi, François Chollet, Niklas Eén, Geoffrey Irving, Christian Szegedy, and Josef Urban. Deepmath - deep sequence models for premise selection. In Daniel D. Lee, Masashi Sugiyama, Ulrike von Luxburg, Isabelle Guyon, and Roman Garnett (eds.), Advances in Neural Information Processing Systems 29: Annual Conference on Neural Information Processing Systems 2016, December 5-10, 2016, Barcelona, Spain, pp. 2235–2243, 2016. URL http://papers.nips.cc/paper/ 6280-deepmath-deep-sequence-models-for-premise-selection. \n[2] Marcin Andrychowicz, Filip Wolski, Alex Ray, Jonas Schneider, Rachel Fong, Peter Welinder, Bob McGrew, Josh Tobin, Pieter Abbeel, and Wojciech Zaremba. Hindsight experience replay. CoRR, abs/1707.01495, 2017. URL http://arxiv.org/abs/1707.01495. \n[3] Anon Anonymous. Thor: Wielding hammers to integrate language models and automated theorem provers. 2022. \n[4] Thomas Anthony, Zheng Tian, and David Barber. Thinking fast and slow with deep learning and tree search. In Isabelle Guyon, Ulrike von Luxburg, Samy Bengio, Hanna M. Wallach, Rob Fergus, S. V. N. Vishwanathan, and Roman Garnett (eds.), Advances in Neural Information Processing Systems 30: Annual Conference on Neural Information Processing Systems 2017, December 4-9, 2017, Long Beach, CA, USA, pp. 5360–5370, 2017. URL https://proceedings.neurips.cc/paper/2017/hash/ d8e1344e27a5b08cdfd5d027d9b8d6de-Abstract.html. \n[5] Eser Aygün, Laurent Orseau, Ankit Anand, Xavier Glorot, Vlad Firoiu, Lei M. Zhang, Doina Precup, and Shibl Mourad. Proving theorems using incremental learning and hindsight experience replay. CoRR, abs/2112.10664, 2021. URL https://arxiv.org/abs/2112.10664. \n[6] Kshitij Bansal, Sarah M. Loos, Markus N. Rabe, and Christian Szegedy. Learning to reason in large theories without imitation. CoRR, abs/1905.10501, 2019. URL http://arxiv.org/ abs/1905.10501. \n[7] Kshitij Bansal, Sarah M. Loos, Markus N. Rabe, Christian Szegedy, and Stewart Wilcox. Holist: An environment for machine learning of higher order logic theorem proving. In Kamalika Chaudhuri and Ruslan Salakhutdinov (eds.), Proceedings of the 36th International Conference on Machine Learning, ICML 2019, 9-15 June 2019, Long Beach, California, USA, volume 97 of Proceedings of Machine Learning Research, pp. 454–463. PMLR, 2019. URL http://proceedings.mlr.press/v97/bansal19a.html. ",
1272
+ "bbox": [
1273
+ 179,
1274
+ 429,
1275
+ 826,
1276
+ 912
1277
+ ],
1278
+ "page_idx": 9
1279
+ },
1280
+ {
1281
+ "type": "text",
1282
+ "text": "[8] Tom B. Brown, Benjamin Mann, Nick Ryder, Melanie Subbiah, Jared Kaplan, Prafulla Dhariwal, Arvind Neelakantan, Pranav Shyam, Girish Sastry, Amanda Askell, Sandhini Agarwal, Ariel Herbert-Voss, Gretchen Krueger, Tom Henighan, Rewon Child, Aditya Ramesh, Daniel M. Ziegler, Jeffrey Wu, Clemens Winter, Christopher Hesse, Mark Chen, Eric Sigler, Mateusz Litwin, Scott Gray, Benjamin Chess, Jack Clark, Christopher Berner, Sam McCandlish, Alec Radford, Ilya Sutskever, and Dario Amodei. Language models are few-shot learners. In NeurIPS, 2020. ",
1283
+ "bbox": [
1284
+ 183,
1285
+ 92,
1286
+ 826,
1287
+ 188
1288
+ ],
1289
+ "page_idx": 10
1290
+ },
1291
+ {
1292
+ "type": "text",
1293
+ "text": "[9] Mark Chen, Jerry Tworek, Heewoo Jun, Qiming Yuan, Henrique Ponde de Oliveira Pinto, Jared Kaplan, Harrison Edwards, Yuri Burda, Nicholas Joseph, Greg Brockman, Alex Ray, Raul Puri, Gretchen Krueger, Michael Petrov, Heidy Khlaaf, Girish Sastry, Pamela Mishkin, Brooke Chan, Scott Gray, Nick Ryder, Mikhail Pavlov, Alethea Power, Lukasz Kaiser, Mohammad Bavarian, Clemens Winter, Philippe Tillet, Felipe Petroski Such, Dave Cummings, Matthias Plappert, Fotios Chantzis, Elizabeth Barnes, Ariel Herbert-Voss, William Hebgen Guss, Alex Nichol, Alex Paino, Nikolas Tezak, Jie Tang, Igor Babuschkin, Suchir Balaji, Shantanu Jain, William Saunders, Christopher Hesse, Andrew N. Carr, Jan Leike, Joshua Achiam, Vedant Misra, Evan Morikawa, Alec Radford, Matthew Knight, Miles Brundage, Mira Murati, Katie Mayer, Peter Welinder, Bob McGrew, Dario Amodei, Sam McCandlish, Ilya Sutskever, and Wojciech Zaremba. Evaluating large language models trained on code. CoRR, abs/2107.03374, 2021. URL https://arxiv.org/abs/2107.03374. ",
1294
+ "bbox": [
1295
+ 179,
1296
+ 196,
1297
+ 825,
1298
+ 363
1299
+ ],
1300
+ "page_idx": 10
1301
+ },
1302
+ {
1303
+ "type": "text",
1304
+ "text": "[10] Aakanksha Chowdhery, Sharan Narang, Jacob Devlin, Maarten Bosma, Gaurav Mishra, Adam Roberts, Paul Barham, Hyung Won Chung, Charles Sutton, Sebastian Gehrmann, Parker Schuh, Kensen Shi, Sasha Tsvyashchenko, Joshua Maynez, Abhishek Rao, Parker Barnes, Yi Tay, Noam Shazeer, Vinodkumar Prabhakaran, Emily Reif, Nan Du, Ben Hutchinson, Reiner Pope, James Bradbury, Jacob Austin, Michael Isard, Guy Gur-Ari, Pengcheng Yin, Toju Duke, Anselm Levskaya, Sanjay Ghemawat, Sunipa Dev, Henryk Michalewski, Xavier Garcia, Vedant Misra, Kevin Robinson, Liam Fedus, Denny Zhou, Daphne Ippolito, David Luan, Hyeontaek Lim, Barret Zoph, Alexander Spiridonov, Ryan Sepassi, David Dohan, Shivani Agrawal, Mark Omernick, Andrew M. Dai, Thanumalayan Sankaranarayana Pillai, Marie Pellat, Aitor Lewkowycz, Erica Moreira, Rewon Child, Oleksandr Polozov, Katherine Lee, Zongwei Zhou, Xuezhi Wang, Brennan Saeta, Mark Diaz, Orhan Firat, Michele Catasta, Jason Wei, Kathy Meier-Hellstern, Douglas Eck, Jeff Dean, Slav Petrov, and Noah Fiedel. PaLM: Scaling language modeling with pathways. CoRR, abs/2204.02311, 2022. doi: 10.48550/arXiv.2204.02311. URL https://doi.org/10.48550/arXiv.2204.02311. ",
1305
+ "bbox": [
1306
+ 176,
1307
+ 372,
1308
+ 826,
1309
+ 565
1310
+ ],
1311
+ "page_idx": 10
1312
+ },
1313
+ {
1314
+ "type": "text",
1315
+ "text": "[11] Karl Cobbe, Vineet Kosaraju, Mohammad Bavarian, Jacob Hilton, Reiichiro Nakano, Christopher Hesse, and John Schulman. Training verifiers to solve math word problems. CoRR, abs/2110.14168, 2021. URL https://arxiv.org/abs/2110.14168. ",
1316
+ "bbox": [
1317
+ 171,
1318
+ 574,
1319
+ 825,
1320
+ 617
1321
+ ],
1322
+ "page_idx": 10
1323
+ },
1324
+ {
1325
+ "type": "text",
1326
+ "text": "[12] Coq. The Coq Proof Assistant. http://coq.inria.fr. URL http://coq.inria.fr. ",
1327
+ "bbox": [
1328
+ 169,
1329
+ 625,
1330
+ 794,
1331
+ 640
1332
+ ],
1333
+ "page_idx": 10
1334
+ },
1335
+ {
1336
+ "type": "text",
1337
+ "text": "[13] Leonardo Mendonça de Moura, Soonho Kong, Jeremy Avigad, Floris van Doorn, and Jakob von Raumer. The lean theorem prover (system description). In Amy P. Felty and Aart Middeldorp (eds.), Automated Deduction - CADE-25 - 25th International Conference on Automated Deduction, Berlin, Germany, August 1-7, 2015, Proceedings, volume 9195 of Lecture Notes in Computer Science, pp. 378–388. Springer, 2015. doi: 10.1007/978-3-319-21401-6\\_26. URL https://doi.org/10.1007/978-3-319-21401-6_26. ",
1338
+ "bbox": [
1339
+ 174,
1340
+ 647,
1341
+ 826,
1342
+ 732
1343
+ ],
1344
+ "page_idx": 10
1345
+ },
1346
+ {
1347
+ "type": "text",
1348
+ "text": "[14] Leo Gao, Stella Biderman, Sid Black, Laurence Golding, Travis Hoppe, Charles Foster, Jason Phang, Horace He, Anish Thite, Noa Nabeshima, Shawn Presser, and Connor Leahy. The Pile: An 800gb dataset of diverse text for language modeling. arXiv preprint arXiv:2101.00027, 2020. ",
1349
+ "bbox": [
1350
+ 174,
1351
+ 739,
1352
+ 826,
1353
+ 795
1354
+ ],
1355
+ "page_idx": 10
1356
+ },
1357
+ {
1358
+ "type": "text",
1359
+ "text": "[15] Thibault Gauthier, Cezary Kaliszyk, Josef Urban, Ramana Kumar, and Michael Norrish. Tactictoe: Learning to prove with tactics. J. Autom. Reason., 65(2):257–286, 2021. doi: 10.1007/s10817-020-09580-x. URL https://doi.org/10.1007/s10817-020-09580-x. ",
1360
+ "bbox": [
1361
+ 173,
1362
+ 804,
1363
+ 825,
1364
+ 847
1365
+ ],
1366
+ "page_idx": 10
1367
+ },
1368
+ {
1369
+ "type": "text",
1370
+ "text": "[16] Georges Gonthier. The four colour theorem: Engineering of a formal proof. In Deepak Kapur (ed.), Computer Mathematics, 8th Asian Symposium, ASCM 2007, Singapore, December 15-17, 2007. Revised and Invited Papers, volume 5081 of Lecture Notes in Computer Science, pp. 333. Springer, 2007. doi: 10.1007/978-3-540-87827-8\\_28. ",
1371
+ "bbox": [
1372
+ 174,
1373
+ 856,
1374
+ 826,
1375
+ 911
1376
+ ],
1377
+ "page_idx": 10
1378
+ },
1379
+ {
1380
+ "type": "text",
1381
+ "text": "[17] Georges Gonthier, Andrea Asperti, Jeremy Avigad, Yves Bertot, Cyril Cohen, François Garillot, Stéphane Le Roux, Assia Mahboubi, Russell O’Connor, Sidi Ould Biha, Ioana Pasca, Laurence Rideau, Alexey Solovyev, Enrico Tassi, and Laurent Théry. A machine-checked proof of the odd order theorem. In Sandrine Blazy, Christine Paulin-Mohring, and David Pichardie (eds.), Interactive Theorem Proving - 4th International Conference, ITP 2013, Rennes, France, July 22-26, 2013. Proceedings, volume 7998 of Lecture Notes in Computer Science, pp. 163–179. Springer, 2013. doi: 10.1007/978-3-642-39634-2\\_14. ",
1382
+ "bbox": [
1383
+ 174,
1384
+ 90,
1385
+ 826,
1386
+ 188
1387
+ ],
1388
+ "page_idx": 11
1389
+ },
1390
+ {
1391
+ "type": "text",
1392
+ "text": "[18] Priya Goyal, Piotr Dollár, Ross Girshick, Pieter Noordhuis, Lukasz Wesolowski, Aapo Kyrola, Andrew Tulloch, Yangqing Jia, and Kaiming He. Accurate, large minibatch sgd: Training imagenet in 1 hour. arXiv preprint arXiv:1706.02677, 2017. ",
1393
+ "bbox": [
1394
+ 171,
1395
+ 199,
1396
+ 823,
1397
+ 242
1398
+ ],
1399
+ "page_idx": 11
1400
+ },
1401
+ {
1402
+ "type": "text",
1403
+ "text": "[19] Christopher Hahn, Frederik Schmitt, Jens U. Kreber, Markus N. Rabe, and Bernd Finkbeiner. Teaching temporal logics to neural networks. In ICLR, 2021. ",
1404
+ "bbox": [
1405
+ 169,
1406
+ 252,
1407
+ 825,
1408
+ 281
1409
+ ],
1410
+ "page_idx": 11
1411
+ },
1412
+ {
1413
+ "type": "text",
1414
+ "text": "[20] Thomas Hales, Mark Adams, Gertrud Bauer, Tat Dat Dang, John Harrison, Hoang Le Truong, Cezary Kaliszyk, Victor Magron, Sean McLaughlin, Tat Thang Nguyen, et al. A formal proof of the Kepler conjecture. In Forum of Mathematics, $P i$ , volume 5, pp. e2. Cambridge University Press, 2017. ",
1415
+ "bbox": [
1416
+ 174,
1417
+ 292,
1418
+ 826,
1419
+ 348
1420
+ ],
1421
+ "page_idx": 11
1422
+ },
1423
+ {
1424
+ "type": "text",
1425
+ "text": "[21] Jesse Michael Han, Igor Babuschkin, Harrison Edwards, Arvind Neelakantan, Tao Xu, Stanislas Polu, Alex Ray, Pranav Shyam, Aditya Ramesh, Alec Radford, and Ilya Sutskever. Unsupervised neural machine translation with generative language models only. CoRR, abs/2110.05448, 2021. URL https://arxiv.org/abs/2110.05448. ",
1426
+ "bbox": [
1427
+ 174,
1428
+ 359,
1429
+ 826,
1430
+ 415
1431
+ ],
1432
+ "page_idx": 11
1433
+ },
1434
+ {
1435
+ "type": "text",
1436
+ "text": "[22] Jesse Michael Han, Jason Rute, Yuhuai Wu, Edward Ayers, and Stanislas Polu. Proof artifact co-training for theorem proving with language models. In International Conference on Learning Representations, 2022. URL https://openreview.net/forum?id=rpxJc9j04U. ",
1437
+ "bbox": [
1438
+ 173,
1439
+ 426,
1440
+ 823,
1441
+ 469
1442
+ ],
1443
+ "page_idx": 11
1444
+ },
1445
+ {
1446
+ "type": "text",
1447
+ "text": "[23] John Harrison. HOL Light: A tutorial introduction. In Mandayam K. Srivas and Albert John Camilleri (eds.), Formal Methods in Computer-Aided Design, First International Conference, FMCAD ’96, Palo Alto, California, USA, November 6-8, 1996, Proceedings, volume 1166 of Lecture Notes in Computer Science, pp. 265–269. Springer, 1996. ",
1448
+ "bbox": [
1449
+ 174,
1450
+ 479,
1451
+ 825,
1452
+ 536
1453
+ ],
1454
+ "page_idx": 11
1455
+ },
1456
+ {
1457
+ "type": "text",
1458
+ "text": "[24] Dan Hendrycks, Collin Burns, Saurav Kadavath, Akul Arora, Steven Basart, Eric Tang, Dawn Song, and Jacob Steinhardt. Measuring mathematical problem solving with the MATH dataset. CoRR, abs/2103.03874, 2021. URL https://arxiv.org/abs/2103.03874. ",
1459
+ "bbox": [
1460
+ 173,
1461
+ 547,
1462
+ 823,
1463
+ 590
1464
+ ],
1465
+ "page_idx": 11
1466
+ },
1467
+ {
1468
+ "type": "text",
1469
+ "text": "[25] Jordan Hoffmann, Sebastian Borgeaud, Arthur Mensch, Elena Buchatskaya, Trevor Cai, Eliza Rutherford, Diego de Las Casas, Lisa Anne Hendricks, Johannes Welbl, Aidan Clark, Tom Hennigan, Eric Noland, Katie Millican, George van den Driessche, Bogdan Damoc, Aurelia Guy, Simon Osindero, Karen Simonyan, Erich Elsen, Jack W. Rae, Oriol Vinyals, and Laurent Sifre. Training compute-optimal large language models. CoRR, abs/2203.15556, 2022. doi: 10.48550/arXiv.2203.15556. URL https://doi.org/10.48550/arXiv.2203.15556. ",
1470
+ "bbox": [
1471
+ 174,
1472
+ 601,
1473
+ 826,
1474
+ 684
1475
+ ],
1476
+ "page_idx": 11
1477
+ },
1478
+ {
1479
+ "type": "text",
1480
+ "text": "[26] Albert Q. Jiang, Wenda Li, Jesse Michael Han, and Yuhuai Wu. Lisa: Language models of isabelle proofs. 6th Conference on Artificial Intelligence and Theorem Proving, 2021. ",
1481
+ "bbox": [
1482
+ 171,
1483
+ 695,
1484
+ 825,
1485
+ 724
1486
+ ],
1487
+ "page_idx": 11
1488
+ },
1489
+ {
1490
+ "type": "text",
1491
+ "text": "[27] Gerwin Klein, Kevin Elphinstone, Gernot Heiser, June Andronick, David Cock, Philip Derrin, Dhammika Elkaduwe, Kai Engelhardt, Rafal Kolanski, Michael Norrish, Thomas Sewell, Harvey Tuch, and Simon Winwood. seL4: formal verification of an OS kernel. In Jeanna Neefe Matthews and Thomas E. Anderson (eds.), Proceedings of the 22nd ACM Symposium on Operating Systems Principles 2009, SOSP 2009, Big Sky, Montana, USA, October 11-14, 2009, pp. 207–220. ACM, 2009. doi: 10.1145/1629575.1629596. ",
1492
+ "bbox": [
1493
+ 174,
1494
+ 734,
1495
+ 826,
1496
+ 819
1497
+ ],
1498
+ "page_idx": 11
1499
+ },
1500
+ {
1501
+ "type": "text",
1502
+ "text": "[28] Gerwin Klein, June Andronick, Matthew Fernandez, Ihor Kuz, Toby C. Murray, and Gernot Heiser. Formally verified software in the real world. Commun. ACM, 61(10):68–77, 2018. doi: 10.1145/3230627. URL https://doi.org/10.1145/3230627. ",
1503
+ "bbox": [
1504
+ 173,
1505
+ 829,
1506
+ 823,
1507
+ 872
1508
+ ],
1509
+ "page_idx": 11
1510
+ },
1511
+ {
1512
+ "type": "text",
1513
+ "text": "[29] Jens U. Kreber and Christopher Hahn. Generating symbolic reasoning problems with transformer GANs. CoRR, abs/2110.10054, 2021. URL https://arxiv.org/abs/2110.10054. ",
1514
+ "bbox": [
1515
+ 173,
1516
+ 883,
1517
+ 823,
1518
+ 911
1519
+ ],
1520
+ "page_idx": 11
1521
+ },
1522
+ {
1523
+ "type": "text",
1524
+ "text": "[30] Guillaume Lample, Alexis Conneau, Ludovic Denoyer, and Marc’Aurelio Ranzato. Unsupervised machine translation using monolingual corpora only. In 6th International Conference on Learning Representations, ICLR 2018, Vancouver, BC, Canada, April 30 - May 3, 2018, Conference Track Proceedings. OpenReview.net, 2018. URL https://openreview.net/ forum?id=rkYTTf-AZ. ",
1525
+ "bbox": [
1526
+ 174,
1527
+ 92,
1528
+ 826,
1529
+ 160
1530
+ ],
1531
+ "page_idx": 12
1532
+ },
1533
+ {
1534
+ "type": "text",
1535
+ "text": "[31] Gil Lederman, Markus N. Rabe, Sanjit Seshia, and Edward A. Lee. Learning heuristics for quantified boolean formulas through reinforcement learning. In 8th International Conference on Learning Representations, ICLR 2020, Addis Ababa, Ethiopia, April 26-30, 2020. OpenReview.net, 2020. URL https://openreview.net/forum?id=BJluxREKDB. ",
1536
+ "bbox": [
1537
+ 174,
1538
+ 170,
1539
+ 826,
1540
+ 227
1541
+ ],
1542
+ "page_idx": 12
1543
+ },
1544
+ {
1545
+ "type": "text",
1546
+ "text": "[32] Yujia Li, David Choi, Junyoung Chung, Nate Kushman, Julian Schrittwieser, Rémi Leblond, Tom Eccles, James Keeling, Felix Gimeno, Agustin Dal Lago, Thomas Hubert, Peter Choy, Cyprien de Masson d’Autume, Igor Babuschkin, Xinyun Chen, Po-Sen Huang, Johannes Welbl, Sven Gowal, Alexey Cherepanov, James Molloy, Daniel J. Mankowitz, Esme Sutherland Robson, Pushmeet Kohli, Nando de Freitas, Koray Kavukcuoglu, and Oriol Vinyals. Competition-level code generation with alphacode. DeepMind, 2022. ",
1547
+ "bbox": [
1548
+ 173,
1549
+ 234,
1550
+ 826,
1551
+ 319
1552
+ ],
1553
+ "page_idx": 12
1554
+ },
1555
+ {
1556
+ "type": "text",
1557
+ "text": "[33] Sarah M. Loos, Geoffrey Irving, Christian Szegedy, and Cezary Kaliszyk. Deep network guided proof search. In Thomas Eiter and David Sands (eds.), LPAR-21, 21st International Conference on Logic for Programming, Artificial Intelligence and Reasoning, Maun, Botswana, May 7-12, 2017, volume 46 of EPiC Series in Computing, pp. 85–105. EasyChair, 2017. doi: 10.29007/8mwc. URL https://doi.org/10.29007/8mwc. ",
1558
+ "bbox": [
1559
+ 174,
1560
+ 327,
1561
+ 825,
1562
+ 397
1563
+ ],
1564
+ "page_idx": 12
1565
+ },
1566
+ {
1567
+ "type": "text",
1568
+ "text": "[34] Ilya Loshchilov and Frank Hutter. SGDR: Stochastic gradient descent with warm restarts. arXiv preprint arXiv:1608.03983, 2016. ",
1569
+ "bbox": [
1570
+ 169,
1571
+ 405,
1572
+ 823,
1573
+ 434
1574
+ ],
1575
+ "page_idx": 12
1576
+ },
1577
+ {
1578
+ "type": "text",
1579
+ "text": "[35] Stanislas Polu and Ilya Sutskever. Generative language modeling for automated theorem proving. CoRR, abs/2009.03393, 2020. URL https://arxiv.org/abs/2009.03393. ",
1580
+ "bbox": [
1581
+ 171,
1582
+ 443,
1583
+ 825,
1584
+ 472
1585
+ ],
1586
+ "page_idx": 12
1587
+ },
1588
+ {
1589
+ "type": "text",
1590
+ "text": "[36] Stanislas Polu, Jesse Michael Han, Kunhao Zheng, Mantas Baksys, Igor Babuschkin, and Ilya Sutskever. Formal mathematics statement curriculum learning, 2022. URL https://arxiv. org/abs/2202.01344. ",
1591
+ "bbox": [
1592
+ 176,
1593
+ 479,
1594
+ 823,
1595
+ 522
1596
+ ],
1597
+ "page_idx": 12
1598
+ },
1599
+ {
1600
+ "type": "text",
1601
+ "text": "[37] Markus N. Rabe, Dennis Lee, Kshitij Bansal, and Christian Szegedy. Mathematical reasoning via self-supervised skip-tree training. In ICLR, 2021. ",
1602
+ "bbox": [
1603
+ 171,
1604
+ 531,
1605
+ 825,
1606
+ 560
1607
+ ],
1608
+ "page_idx": 12
1609
+ },
1610
+ {
1611
+ "type": "text",
1612
+ "text": "[38] Alec Radford, Jeffrey Wu, Rewon Child, David Luan, Dario Amodei, Ilya Sutskever, et al. Language models are unsupervised multitask learners. OpenAI blog, 1(8):9, 2019. ",
1613
+ "bbox": [
1614
+ 171,
1615
+ 568,
1616
+ 825,
1617
+ 597
1618
+ ],
1619
+ "page_idx": 12
1620
+ },
1621
+ {
1622
+ "type": "text",
1623
+ "text": "[39] Frederik Schmitt, Christopher Hahn, Markus N. Rabe, and Bernd Finkbeiner. Neural circuit synthesis from specification patterns. In Marc’Aurelio Ranzato, Alina Beygelzimer, Yann N. Dauphin, Percy Liang, and Jennifer Wortman Vaughan (eds.), Advances in Neural Information Processing Systems 34: Annual Conference on Neural Information Processing Systems 2021, NeurIPS 2021, December 6-14, 2021, virtual, pp. 15408–15420, 2021. URL https://proceedings.neurips.cc/paper/2021/hash/ 8230bea7d54bcdf99cdfe85cb07313d5-Abstract.html. ",
1624
+ "bbox": [
1625
+ 174,
1626
+ 606,
1627
+ 826,
1628
+ 703
1629
+ ],
1630
+ "page_idx": 12
1631
+ },
1632
+ {
1633
+ "type": "text",
1634
+ "text": "[40] Stephan Schulz. Learning search control knowledge for equational theorem proving. In Franz Baader, Gerhard Brewka, and Thomas Eiter (eds.), KI 2001: Advances in Artificial Intelligence, Joint German/Austrian Conference on AI, Vienna, Austria, September 19-21, 2001, Proceedings, volume 2174 of Lecture Notes in Computer Science, pp. 320–334. Springer, 2001. doi: 10.1007/3-540-45422-5\\_23. ",
1635
+ "bbox": [
1636
+ 174,
1637
+ 712,
1638
+ 826,
1639
+ 781
1640
+ ],
1641
+ "page_idx": 12
1642
+ },
1643
+ {
1644
+ "type": "text",
1645
+ "text": "[41] Rico Sennrich, Barry Haddow, and Alexandra Birch. Improving neural machine translation models with monolingual data. In Proceedings of the 54th Annual Meeting of the Association for Computational Linguistics, ACL 2016, August 7-12, 2016, Berlin, Germany, Volume 1: Long Papers. The Association for Computer Linguistics, 2016. doi: 10.18653/v1/p16-1009. URL https://doi.org/10.18653/v1/p16-1009. ",
1646
+ "bbox": [
1647
+ 174,
1648
+ 790,
1649
+ 826,
1650
+ 861
1651
+ ],
1652
+ "page_idx": 12
1653
+ },
1654
+ {
1655
+ "type": "text",
1656
+ "text": "[42] Christian Szegedy. A promising path towards autoformalization and general artificial intelligence. In Christoph Benzmüller and Bruce R. Miller (eds.), Intelligent Computer Mathematics - 13th International Conference, CICM 2020, Bertinoro, Italy, July 26-31, 2020, Proceedings, volume 12236 of Lecture Notes in Computer Science, pp. 3–20. Springer, 2020. doi: 10.1007/ 978-3-030-53518-6\\_1. URL https://doi.org/10.1007/978-3-030-53518-6_1. ",
1657
+ "bbox": [
1658
+ 174,
1659
+ 869,
1660
+ 826,
1661
+ 911
1662
+ ],
1663
+ "page_idx": 12
1664
+ },
1665
+ {
1666
+ "type": "text",
1667
+ "text": "",
1668
+ "bbox": [
1669
+ 202,
1670
+ 90,
1671
+ 826,
1672
+ 121
1673
+ ],
1674
+ "page_idx": 13
1675
+ },
1676
+ {
1677
+ "type": "text",
1678
+ "text": "[43] Josef Urban. MPTP - motivation, implementation, first experiments. J. Autom. Reason., 33 (3-4):319–339, 2004. doi: 10.1007/s10817-004-6245-1. ",
1679
+ "bbox": [
1680
+ 171,
1681
+ 128,
1682
+ 823,
1683
+ 157
1684
+ ],
1685
+ "page_idx": 13
1686
+ },
1687
+ {
1688
+ "type": "text",
1689
+ "text": "[44] Ashish Vaswani, Noam Shazeer, Niki Parmar, Jakob Uszkoreit, Llion Jones, Aidan N Gomez, Łukasz Kaiser, and Illia Polosukhin. Attention is all you need. In NeurIPS, 2017. ",
1690
+ "bbox": [
1691
+ 171,
1692
+ 166,
1693
+ 825,
1694
+ 195
1695
+ ],
1696
+ "page_idx": 13
1697
+ },
1698
+ {
1699
+ "type": "text",
1700
+ "text": "[45] Ben Wang. Mesh-Transformer-JAX: Model-Parallel Implementation of Transformer Language Model with JAX. https://github.com/kingoflolz/mesh-transformer-jax, May 2021. ",
1701
+ "bbox": [
1702
+ 174,
1703
+ 204,
1704
+ 826,
1705
+ 246
1706
+ ],
1707
+ "page_idx": 13
1708
+ },
1709
+ {
1710
+ "type": "text",
1711
+ "text": "[46] Qingxiang Wang, Cezary Kaliszyk, and Josef Urban. First experiments with neural translation of informal to formal mathematics. In Florian Rabe, William M. Farmer, Grant O. Passmore, and Abdou Youssef (eds.), Intelligent Computer Mathematics - 11th International Conference, CICM 2018, Hagenberg, Austria, August 13-17, 2018, Proceedings, volume 11006 of Lecture Notes in Computer Science, pp. 255–270. Springer, 2018. doi: 10.1007/978-3-319-96812-4\\_22. URL https://doi.org/10.1007/978-3-319-96812-4_22. ",
1712
+ "bbox": [
1713
+ 174,
1714
+ 255,
1715
+ 826,
1716
+ 339
1717
+ ],
1718
+ "page_idx": 13
1719
+ },
1720
+ {
1721
+ "type": "text",
1722
+ "text": "[47] Qingxiang Wang, Chad Brown, Cezary Kaliszyk, and Josef Urban. Exploration of neural machine translation in autoformalization of mathematics in mizar. In International Conference on Certified Programs and Proofs, 2020. ",
1723
+ "bbox": [
1724
+ 173,
1725
+ 348,
1726
+ 823,
1727
+ 391
1728
+ ],
1729
+ "page_idx": 13
1730
+ },
1731
+ {
1732
+ "type": "text",
1733
+ "text": "[48] Makarius Wenzel, Lawrence C. Paulson, and Tobias Nipkow. The Isabelle framework. In Otmane Aït Mohamed, César A. Muñoz, and Sofiène Tahar (eds.), Theorem Proving in Higher Order Logics, 21st International Conference, TPHOLs 2008, Montreal, Canada, August 18-21, 2008. Proceedings, volume 5170 of Lecture Notes in Computer Science, pp. 33–38. Springer, 2008. doi: 10.1007/978-3-540-71067-7\\_7. ",
1734
+ "bbox": [
1735
+ 173,
1736
+ 398,
1737
+ 826,
1738
+ 469
1739
+ ],
1740
+ "page_idx": 13
1741
+ },
1742
+ {
1743
+ "type": "text",
1744
+ "text": "[49] Minchao Wu, Michael Norrish, Christian Walder, and Amir Dezfouli. TacticZero: Learning to prove theorems from scratch with deep reinforcement learning. CoRR, abs/2102.09756, 2021. URL https://arxiv.org/abs/2102.09756. ",
1745
+ "bbox": [
1746
+ 173,
1747
+ 478,
1748
+ 825,
1749
+ 521
1750
+ ],
1751
+ "page_idx": 13
1752
+ },
1753
+ {
1754
+ "type": "text",
1755
+ "text": "[50] Yuhuai Wu, Albert Jiang, Jimmy Ba, and Roger Baker Grosse. INT: an inequality benchmark for evaluating generalization in theorem proving. In 9th International Conference on Learning Representations, ICLR 2021, Virtual Event, Austria, May 3-7, 2021. OpenReview.net, 2021. URL https://openreview.net/forum?id $\\cdot ^ { = }$ O6LPudowNQm. ",
1756
+ "bbox": [
1757
+ 173,
1758
+ 530,
1759
+ 826,
1760
+ 587
1761
+ ],
1762
+ "page_idx": 13
1763
+ },
1764
+ {
1765
+ "type": "text",
1766
+ "text": "[51] Yuhuai Wu, Markus N Rabe, DeLesley Hutchins, and Christian Szegedy. Memorizing transformers. arXiv preprint arXiv:2203.08913, 2022. ",
1767
+ "bbox": [
1768
+ 171,
1769
+ 594,
1770
+ 821,
1771
+ 623
1772
+ ],
1773
+ "page_idx": 13
1774
+ },
1775
+ {
1776
+ "type": "text",
1777
+ "text": "[52] Kunhao Zheng, Jesse Michael Han, and Stanislas Polu. MiniF2F: a cross-system benchmark for formal olympiad-level mathematics. arXiv preprint arXiv:2109.00110, 2021. ",
1778
+ "bbox": [
1779
+ 173,
1780
+ 632,
1781
+ 821,
1782
+ 661
1783
+ ],
1784
+ "page_idx": 13
1785
+ },
1786
+ {
1787
+ "type": "text",
1788
+ "text": "Checklist ",
1789
+ "text_level": 1,
1790
+ "bbox": [
1791
+ 174,
1792
+ 89,
1793
+ 254,
1794
+ 106
1795
+ ],
1796
+ "page_idx": 14
1797
+ },
1798
+ {
1799
+ "type": "text",
1800
+ "text": "The checklist follows the references. Please read the checklist guidelines carefully for information on how to answer these questions. For each question, change the default [TODO] to [Yes] , [No] , or [N/A] . You are strongly encouraged to include a justification to your answer, either by referencing the appropriate section of your paper or providing a brief inline description. For example: ",
1801
+ "bbox": [
1802
+ 176,
1803
+ 121,
1804
+ 825,
1805
+ 178
1806
+ ],
1807
+ "page_idx": 14
1808
+ },
1809
+ {
1810
+ "type": "text",
1811
+ "text": "• Did you include the license to the code and datasets? [Yes] See Section ??. \n• Did you include the license to the code and datasets? [No] The code and the data are proprietary. \n• Did you include the license to the code and datasets? [N/A] ",
1812
+ "bbox": [
1813
+ 215,
1814
+ 188,
1815
+ 825,
1816
+ 256
1817
+ ],
1818
+ "page_idx": 14
1819
+ },
1820
+ {
1821
+ "type": "text",
1822
+ "text": "Please do not modify the questions and only use the provided macros for your answers. Note that the Checklist section does not count towards the page limit. In your paper, please delete this instructions block and only keep the Checklist section heading above along with the questions/answers below. ",
1823
+ "bbox": [
1824
+ 178,
1825
+ 267,
1826
+ 825,
1827
+ 310
1828
+ ],
1829
+ "page_idx": 14
1830
+ },
1831
+ {
1832
+ "type": "text",
1833
+ "text": "1. For all authors... ",
1834
+ "bbox": [
1835
+ 214,
1836
+ 323,
1837
+ 339,
1838
+ 337
1839
+ ],
1840
+ "page_idx": 14
1841
+ },
1842
+ {
1843
+ "type": "text",
1844
+ "text": "(a) Do the main claims made in the abstract and introduction accurately reflect the paper’s contributions and scope? [Yes] \n(b) Did you describe the limitations of your work? [Yes] See discussion section. \n(c) Did you discuss any potential negative societal impacts of your work? [Yes] See discussion section. \n(d) Have you read the ethics review guidelines and ensured that your paper conforms to them? [Yes] ",
1845
+ "bbox": [
1846
+ 238,
1847
+ 343,
1848
+ 825,
1849
+ 449
1850
+ ],
1851
+ "page_idx": 14
1852
+ },
1853
+ {
1854
+ "type": "text",
1855
+ "text": "2. If you are including theoretical results... ",
1856
+ "bbox": [
1857
+ 214,
1858
+ 454,
1859
+ 493,
1860
+ 468
1861
+ ],
1862
+ "page_idx": 14
1863
+ },
1864
+ {
1865
+ "type": "text",
1866
+ "text": "(a) Did you state the full set of assumptions of all theoretical results? [N/A] (b) Did you include complete proofs of all theoretical results? [N/A] ",
1867
+ "bbox": [
1868
+ 238,
1869
+ 473,
1870
+ 738,
1871
+ 503
1872
+ ],
1873
+ "page_idx": 14
1874
+ },
1875
+ {
1876
+ "type": "text",
1877
+ "text": "3. If you ran experiments... ",
1878
+ "bbox": [
1879
+ 212,
1880
+ 510,
1881
+ 393,
1882
+ 523
1883
+ ],
1884
+ "page_idx": 14
1885
+ },
1886
+ {
1887
+ "type": "text",
1888
+ "text": "(a) Did you include the code, data, and instructions needed to reproduce the main experimental results (either in the supplemental material or as a URL)? [Yes] \n(b) Did you specify all the training details (e.g., data splits, hyperparameters, how they were chosen)? [Yes] \n(c) Did you report error bars (e.g., with respect to the random seed after running experiments multiple times)? [No] It is expensive to run multiple times, and we believe the results are significant. \n(d) Did you include the total amount of compute and the type of resources used (e.g., type of GPUs, internal cluster, or cloud provider)? [Yes] See Section 5.2. ",
1889
+ "bbox": [
1890
+ 238,
1891
+ 529,
1892
+ 825,
1893
+ 662
1894
+ ],
1895
+ "page_idx": 14
1896
+ },
1897
+ {
1898
+ "type": "text",
1899
+ "text": "4. If you are using existing assets (e.g., code, data, models) or curating/releasing new assets... ",
1900
+ "bbox": [
1901
+ 218,
1902
+ 667,
1903
+ 823,
1904
+ 681
1905
+ ],
1906
+ "page_idx": 14
1907
+ },
1908
+ {
1909
+ "type": "text",
1910
+ "text": "(a) If your work uses existing assets, did you cite the creators? [Yes] We cited the creators of the assets when we first mentioned them. \n(b) Did you mention the license of the assets? [Yes] We included the links to the licenses of the assets when we first mentioned them in Section 5. \n(c) Did you include any new assets either in the supplemental material or as a URL? [Yes] We include the code we used to train the models in the supplemental material. The data we used are all under open-source licenses. \n(d) Did you discuss whether and how consent was obtained from people whose data you’re using/curating? [Yes] The assets we used mostly have open-sourced licenses as mentioned previously. \n(e) Did you discuss whether the data you are using/curating contains personally identifiable information or offensive content? [No] The data we used are mathematical proofs so we think it is apparent that they do not contain personally identifiable information or any offensive content. ",
1911
+ "bbox": [
1912
+ 238,
1913
+ 686,
1914
+ 825,
1915
+ 891
1916
+ ],
1917
+ "page_idx": 14
1918
+ },
1919
+ {
1920
+ "type": "text",
1921
+ "text": "5. If you used crowdsourcing or conducted research with human subjects... ",
1922
+ "bbox": [
1923
+ 212,
1924
+ 897,
1925
+ 705,
1926
+ 911
1927
+ ],
1928
+ "page_idx": 14
1929
+ },
1930
+ {
1931
+ "type": "text",
1932
+ "text": "(a) Did you include the full text of instructions given to participants and screenshots, if applicable? [N/A] \n(b) Did you describe any potential participant risks, with links to Institutional Review Board (IRB) approvals, if applicable? [N/A] \n(c) Did you include the estimated hourly wage paid to participants and the total amount spent on participant compensation? [N/A] ",
1933
+ "bbox": [
1934
+ 238,
1935
+ 90,
1936
+ 826,
1937
+ 180
1938
+ ],
1939
+ "page_idx": 15
1940
+ }
1941
+ ]
parse/dev/IUikebJ1Bf0/IUikebJ1Bf0_middle.json ADDED
The diff for this file is too large to render. See raw diff
 
parse/dev/IUikebJ1Bf0/IUikebJ1Bf0_model.json ADDED
The diff for this file is too large to render. See raw diff
 
parse/dev/WBhqzpF6KYH/WBhqzpF6KYH.md ADDED
@@ -0,0 +1,342 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ # SatMAE: Pre-training Transformers for Temporal and Multi-Spectral Satellite Imagery
2
+
3
+ Yezhen Cong⇤ yzcong@stanford.edu
4
+
5
+ Chenlin Meng Patrick Liu
6
+
7
+ Samar Khanna⇤ samar.khanna@stanford.edu
8
+
9
+ # Erik Rozi Yutong He Marshall Burke David B. Lobell Stefano Ermon
10
+
11
+ Stanford University
12
+
13
+ # Abstract
14
+
15
+ Unsupervised pre-training methods for large vision models have shown to enhance performance on downstream supervised tasks. Developing similar techniques for satellite imagery presents significant opportunities as unlabelled data is plentiful and the inherent temporal and multi-spectral structure provides avenues to further improve existing pre-training strategies. In this paper, we present SatMAE, a pre-training framework for temporal or multi-spectral satellite imagery based on Masked Autoencoder (MAE). To leverage temporal information, we include a temporal embedding along with independently masking image patches across time. In addition, we demonstrate that encoding multi-spectral data as groups of bands with distinct spectral positional encodings is beneficial. Our approach yields strong improvements over previous state-of-the-art techniques, both in terms of supervised learning performance on benchmark datasets (up to $\uparrow 7 \% )$ ), and transfer learning performance on downstream remote sensing tasks, including land cover classification (up to $\uparrow 1 4 \% )$ and semantic segmentation. Code and data are available on the project website: https://sustainlab-group.github.io/SatMAE/
16
+
17
+ # 1 Introduction
18
+
19
+ In recent years, self-supervised learning techniques have quickly become the norm for pre-training models on large-scale natural image datasets [1, 2, 3, 4, 5, 6, 7, 8], and have demonstrated strong performance on downstream tasks including image classification [3, 4, 9, 10], image segmentation $\bar { \bigtriangledown } ,$ 11], representation learning [12, 13, 14], image compression [12, 15], image reconstruction $\mathbb { n }$ , and image generation $[ \overline { { 1 6 } } ]$ . Unlike supervised learning approaches, self-supervised learning techniques do not require human labeling, making them appealing in settings where unlabeled data are abundant but labeled data are scarce, such as remote sensing data (e.g., satellite imagery). While several large-scale satellite image datasets have been carefully curated in the past few years, including Functional Map of the World (fMoW) [17], BigEarthNet [18], xView [19], SpaceNet $\mathbb { \ m }$ , annotating these datasets requires specialized skills and is more expensive than traditional computer vision datasets. Moreover, automatic analysis of satellite imagery is often needed for tasks with large societal impact such as poverty or crop yield prediction [21, 22, 23, 24, 25, 26, 27, 28, 29, 30], where acquiring large amounts of labeled data through surveys is impossible or prohibitively expensive. This suggests that self-supervised learning approaches for satellite imagery could be especially valuable.
20
+
21
+ However, existing self-supervised learning approaches [1, 2, 3, 4, 5, 6] are mainly designed for natural images. As opposed to natural images such as ImageNet [31], satellite imagery is usually associated with meaningful geographical and temporal information, and can consist of multiple spectral bands representing sensor readings besides visible light (i.e., RGB channels typical in natural images). Depending on the data source, satellite imagery can also vary significantly in resolution [32, 33]. While self-supervised learning methods for satellite imagery exist [34, 35], these approaches cannot learn general representations for both temporal and multi-spectral remote sensing data.
22
+
23
+ ![](images/735f582f0f88215b4d3a2f370722d5431ab35c25d949ae49652c896875ef705d.jpg)
24
+ Figure 1: With carefully-designed masking strategies across mutli-spectral and temporal images, and temporal and spectral positional encodings, our SatMAE serves as a powerful SSL vision learner for remote sensing tasks.
25
+
26
+ To address this issue we propose SatMAE, a self-supervised learning framework based on masked autoencoders (MAEs) [1] which naturally handles temporal and multi-spectral input data. We show that introducing a positional encoding for the temporal/spectral dimension and independently masking patches across the temporal/spectral dimension benefits pre-training, allowing the model to learn representations of the data that are more conducive to finetuning. Specifically, our contributions are:
27
+
28
+ 1. We propose a novel method to leverage temporal or multi-spectral information in satellite imagery to improve self-supervised pre-training with masked autoencoders (see 4).
29
+ 2. We introduce fMoW-Sentinel, a new Sentinel-2 dataset cross-referenced with fMoW, as a benchmark for training models on multi-spectral satellite imagery (see 5.1).
30
+ 3. We demonstrate the effectiveness of pre-training transformers $\pmb { \Vert 3 6 \Vert }$ on satellite imagery, achieving significant improvement over previous state-of-the-art methods on benchmark datasets as well as downstream remote sensing tasks (see 5)
31
+
32
+ # 2 Related Work
33
+
34
+ ML for SITS Deep learning has been used for many Satellite Image Time Series (SITS) supervisedlearning tasks such as crop-type mapping [29, 28, 37, 38], yield prediction [39, 40], understanding the economy [41, 42, 43, 44], precipitation forcasting $\lVert \boldsymbol { \mathsf { E } } \boldsymbol { \mathsf { 5 } } \rVert$ , and land-cover classification $\boxed { 4 6 } \boxed { 4 7 } \boxed { 4 8 } \boxed { 2 7 }$ . These works establish the usefulness of tailoring architectures such as LSTMs, self-attention, and transformers to temporal data. However, outside of their specific task, they are often not directly applicable to other remote-sensing datasets.
35
+
36
+ SSL for Satellite Imagery Self-supervised learning [2, 3, 4, 5, 6] has emerged as a promising approach in remote sensing domains. For instance, [34] and [35] propose incorporating spatially aligned images over time for contrastive self-supervised learning. Despite promising results, these two contrastive learning approaches rely heavily on the quality of positive pairs, which is often hard to control. $\textcircled { \lVert { 4 9 } \rVert }$ combines different sensor channels to generate co-located images that serve as positive pairs. [50, 51, 52] apply off-the-shelf contrastive learning algorithms to satellite images. [52] utilizes image inpainting and transformation prediction as additional pretext tasks. $\mathbb { \lVert 5 3 \rVert }$ leverages geographical knowledge to aid SSL, which, however, can be difficult to obtain as annotations.
37
+
38
+ Masked Autoencoder MAE [1] is a recent powerful self-supervised learning method. Instead of constructing a contrastive objective, it proposes the pretext task of reconstructing masked patches of the input, and largely avoids the need for designing specific data augmentation. Inspired by MAE’s state-of-the-art performance on a wide collection of vision benchmarks $\mathbb { I I }$ , many follow-up works extend MAE to different data modalities. VideoMAE $\textcircled { | 5 4 | }$ proposes video tube masking and reconstruction as a pretext task for video analysis. GMAE [55] adapts MAE to the domain of graphs. MultiMAE [56] takes optional inputs of different modalities and accordingly includes other training objectives to facilitate multi-modality learning. However, these works fail to optimally handle temporal and multi-spectral input. VideoMAE requires equally-spaced image frames in the temporal dimension, which is not the case for satellite data given the temporal irregularity and discontinuity in sampling images of a location. In this work, we incorporate temporal and spectral information into a masked autoencoder architecture, and propose a novel self-supervised framework for satellite data.
39
+
40
+ # 3 Background
41
+
42
+ Masked Autoencoder The MAE is an autoencoder with asymmetrical encoding and decoding stages $\mathbb { M }$ . It operates on images $I \in \mathbb { R } ^ { C \times H \times W }$ , where $H , W$ are the height and width of the image, respectively, and $C$ is the number of channels. The input image $I$ is resized to a sequence of non-overlapping patches, $S \in \mathbb { R } ^ { L \times P ^ { 2 } C }$ , where $P$ is the height and width of the patch, and $L = ( H / P ) \cdot \bar { ( W / P ) }$ is the number of patches. Each patch is passed through a patch embedding $f _ { p } : \mathbb { R } ^ { P ^ { 2 } C } \mapsto \mathbb { R } ^ { D }$ to create a sequence $S ^ { \prime } \in \mathbb { R } ^ { L \times D }$ of embedded patch “tokens”. A fraction $p _ { m }$ of the $L$ tokens are masked and only the remaining $( 1 - p _ { m } ) L$ “visible" patch tokens are fed to the encoder, a Vision Transformer (ViT) $\begin{array} { r l r } { { \bigl [ \bigl | 3 6 \bigr | \bigr ] } } \end{array}$ with positional embeddings to capture the spatial location of the patch in the image. The decoder is a series of transformer blocks that operates on all $L$ tokens (with positional embeddings added), where the $p _ { m } L$ encoded visible patches are placed in their original sequence position among $( 1 - p _ { m } ) L$ masked patches represented by a learnable mask token. The decoder outputs a reconstructed image $\hat { I } \in \mathbb { R } ^ { C \times H \times W }$ , which is compared to the original image using the mean-squared error (MSE) loss, computed per-pixel only on the masked patches $\mathbb { M }$ .
43
+
44
+ Positional encoding Positional encoding allows transformers to make their learned representations position-aware. In MAE $\mathbb { M }$ and in many transformers $ { \mathbb { B } } 7 { \vert 5 8 \vert }$ , the positional encoding is:
45
+
46
+ $$
47
+ \mathtt { E n c o d e } ( k , 2 i ) = \sin { \frac { k } { \Omega ^ { \frac { 2 i } { d } } } } , \mathtt { E n c o d e } ( k , 2 i + 1 ) = \cos { \frac { k } { \Omega ^ { \frac { 2 i } { d } } } }
48
+ $$
49
+
50
+ Here, $k$ is the position, $i$ is the index of feature dimension in the encoding, $d$ is the number of possible positions, and $\Omega$ is a large constant (normally set to 10000). In MAE, position is defined as the index of the patch along the $\mathbf { X }$ or y axes. Therefore, $k$ ranges from 0 to $H / P$ (or $W / P$ ). The final encoding is generated by concatenating the encodings of the $\mathbf { X }$ and y coordinates.
51
+
52
+ # 4 Method
53
+
54
+ In this section, we describe SatMAE with temporal $( 4 . 1 )$ and multi-spectral $\textcircled { \sharp . 2 }$ satellite images.
55
+
56
+ # 4.1 Temporal SatMAE
57
+
58
+ We now consider input tensors $I _ { T } \in \mathbb { R } ^ { T \times C \times H \times W }$ , where $T$ denotes the number of images in a temporal sequence. In video data, $T$ frames are usually equally spaced. However, temporal satellite imagery rarely has images at regular intervals. More commonly, several snapshots, or versions, of a given location are taken at irregular times. The length and sample frequency of these sequences of satellite images vary drastically over years and across different regions.
59
+
60
+ Naïvely, one could reshape $I _ { T }$ to $I _ { T } ^ { \prime } \in \mathbb { R } ^ { T C \times H \times W }$ , effectively concatenating the temporal sequence of images along the spectral (i.e. channel) dimension, and then apply the MAE machinery verbatim. This method poses a few difficulties: (i) the model may be unable to generalise to a temporal ordering different to the one used in pre-training, since it can only understand order through the position of images in the stacked-timeseries (ii) the model cannot reason about the length of time separating two consecutive images in a time sequence, which may be variable when images of a location are sampled at irregular intervals (iii) the model loses access to temporal fine-grained information in deeper layers, as its only direct exposure to encode temporal information is through the initial patch embedding $f _ { p }$ (iv) the model is not temporally-shift invariant (i.e. the model would need to separately learn to detect the same event in two different segments of a temporal sequence).
61
+
62
+ To address these challenges and to avoid losing temporal information, we resize the temporal sequence $I _ { T }$ to $S _ { T } \in \mathbb { R } ^ { L _ { T } \times P _ { T } P ^ { 2 } \bar { C } }$ , where $L _ { T } = L { \cdot } ( T / P _ { T } ) = ( H / P ) { \cdot } ( W / P ) { \cdot } ( T / P _ { T } ) .$ , $P _ { T }$ is the “patch size” in the temporal dimension, and $L$ and $P$ are defined in $\textcircled { 3 }$ Prior works using transformers for video data suggest using $P _ { T } = 2$ , where each “patch” is a cube of shape $2 \times 1 6 \times 1 6$ [54, 59, $\boxed { 6 0 }$ . Since our data has much shorter temporal sequence lengths $\mathbb { \lVert 1 7 \rVert }$ , we let $P _ { T } = 1$ such that $L _ { T } = L \cdot T$ . In order to operate on inputs of any temporal order, we re-use the same patch embedding $f _ { p } : \mathbb { R } ^ { P ^ { 2 } C } \mapsto \mathbb { R } ^ { D }$ for each image in the time series, giving us an embedded sequence of tokens $S _ { T } ^ { \prime } \in \mathbb { R } ^ { L _ { T } \times D }$ .
63
+
64
+ # 4.1.1 Temporal Encoding
65
+
66
+ For each embedded token in the $L _ { T }$ length sequence, we need to ensure the model retains information about its spatial and temporal position. As shown in many prior works [34, 35], the timestamp of a satellite image is useful for many pre-training or downstream vision tasks. We propose a temporal encoding scheme compatible with the masked autoencoder architecture by treating the temporal dimension similarly to the positional dimensions (see 3).
67
+
68
+ ![](images/cb0f9e60034b1e532ce7d6f68d0f0bab0b21a88d8131c623c5ba4fe982e598b3.jpg)
69
+ Figure 2: Top: Encoding each temporal patch with a shared patch embedding $f _ { p }$ . Bottom: Encoding each spectral patch with a different patch embedding $f _ { p _ { j } }$ for each group $j$ .
70
+
71
+ The timestamp of a satellite image is represented as “yearmonth-day-hour-minute-second”. Instead of passing the entire numerized timestamp into a feature encoder, we propose only keeping the useful parts. Intuitively, the day, minute, and second should be unrelated to the visual appearance of a region. Thus, including these components in the temporal encoding may not be beneficial, and can even be detrimental. In contrast, a landscape may evolve over years due to weather, geology, and human activity. The month reflects season and climate, and the hour reflects daylight and temperature.
72
+
73
+ Then, the temporal encoding is formulated as:
74
+
75
+ $$
76
+ t _ { k , i } = \mathrm { C O N C A T } [ \mathrm { E n c o d e } ( k _ { \mathrm { y e a r } } , i ) , \mathrm { E n c o d e } ( k _ { \mathrm { m o n t h } } , i ) , \mathrm { E n c o d e } ( k _ { \mathrm { h o u r } } , i ) ]
77
+ $$
78
+
79
+ And the final encoding is generated by concatenating the temporal encoding to the positional encoding defined in $3$ such that the total length of the encoding is $D$ .
80
+
81
+ # 4.1.2 Masking Strategies
82
+
83
+ With an additional temporal dimension, masking a subset of the $L _ { T }$ tokens needs to be treated with care. As seen in figure ${ \bar { 3 } } ,$ there are different ways to mask a temporal series of satellite images.
84
+
85
+ Consistent Masking Each image is “patchified” separately, but the masked regions are consistent across all images (fig. 3a). This approach is also used in VideoMAE $\pmb { \Vert 5 4 \Vert }$ , with video input.
86
+
87
+ Independent Masking Each image is “patchified” separately, and masked regions may not be the same across every image. Instead, a fraction $p _ { m }$ of the full sequence of all patch tokens are masked. Another variant is to independently mask the regions of each image, but keep the ratio $p _ { m }$ of masked regions fixed per image. Both variants are equivalent in expectation. Effectively, the model may look at unmasked values of a region that is masked in one image but not in others. This setting may lead to an easier task for video data since the model can “cheat” and exploit temporal redundancy in videos with high framerates [54]. However, we argue that this form of “cheating” is less feasible in temporal satellite imagery, given the strong impact of seasonal variation and changing human activity over periods of time and the much larger time deltas between temporally consecutive images (see fig. 3a).
88
+
89
+ ![](images/d608cfc2e0783e553d8c8494f39903170d00a320f6eb1394aa05d96ed583a8e8.jpg)
90
+ Figure 3: 3a Temporal masking: For images in a timeseries, we can choose to keep a patch fully visible or fully masked across time (consistent masking), or independently mask all patches (independent masking). In both cases, a fraction $p _ { m }$ patches are masked. Here, $T = 3$ , and the leftmost column orders the temporal sequence according to the timestamp features. For example, “y-12, m-12, h-15” is 12 years from the minimum year (2002), the zero-indexed month 2, and the 15th hour of the day; i.e., roughly 2014, March, 15:00. 3b Spectral Masking: The same masking strategies are adapted to groups of the 13 spectral bands in Sentinel-2 images.
91
+
92
+ Independent Masking $^ +$ Inconsistent Cropping During data pre-processing, we can crop square regions for input inconsistently so that images in the same temporal sequence may be spatiallyunaligned. This strategy may help the model learn better representations as it may learn to align images in the sequence across the spatial and temporal dimensions.
93
+
94
+ # 4.2 Multi-spectral SatMAE
95
+
96
+ While MAE does operate on images $I \in \mathbb { R } ^ { C \times H \times W }$ , usually $C = 3$ for RGB images. Satellite data, on the other hand, can often have multiple spectral bands. For example, Sentinel-2 imagery has $C = 1 3$ bands of $1 0 \mathrm { m }$ , $2 0 \mathrm { m }$ and $6 0 \mathrm { m }$ spatial resolution, each of different wavelengths (see A.2.2) Below, we discuss and later experimentally compare various ways to encode spectral information.
97
+
98
+ Stack Channels The sequence of patches $S \in \mathbb { R } ^ { L \times P ^ { 2 } C }$ is embedded to a sequence of tokens $S ^ { \prime } \in \mathbb { R } ^ { L \times D }$ , thus treating the multi-band image as is. We denote this method SatMAE $^ +$ Stack.
99
+
100
+ Group Channels There are limitations to naively stacking the spectral information, especially that a single convolutional patch embedding may be insufficient to fully capture fine-grained information present in multiple bands of different wavelengths and spatial resolution. We would like the model to preserve information about the different bands through the encoding and decoding stages.
101
+
102
+ To address this limitation, we propose grouping subsets of spectral bands. Given $C$ channels, we form $G$ groups $g _ { 1 } , g _ { 2 } , \dotsc , g _ { G }$ such that $g _ { 1 } + g _ { 2 } + \cdot \cdot \cdot + g _ { G } = C$ . This is analogous to slicing the image $I$ in the channel dimension, creating images $I _ { 1 } , \ldots , I _ { G }$ , where $I _ { j } \in \mathbb { R } ^ { g _ { j } \times H \times W }$ . We use a separate patch embedding $f _ { p _ { j } } : \mathbb { R } ^ { P ^ { 2 } g _ { j } } \mapsto \mathbb { R } ^ { D }$ for each group $j$ , thus allowing the model to best represent each possibly different group of channels as token embeddings. Therefore, each group $j$ is first resized from $I _ { j } \in \mathbb { R } ^ { g _ { j } \times H \times W }$ to $\overline { { S } } _ { j } \in \mathbb { R } ^ { L \times P ^ { 2 } g _ { j } }$ , and then each patch is embedded with $f _ { p _ { j } }$ to produce a sequence of embedded tokens $S _ { j } ^ { \prime } \in \mathbb { R } ^ { L \times D }$ . The sequences $S _ { 1 } ^ { \prime } , \ldots , S _ { G } ^ { \prime }$ are concatenated to produce the final set of tokens S0 RGL⇥D.
103
+
104
+ Spectral Encoding Since the tokens in $S ^ { \prime }$ correspond to a patch location $( m , n )$ in the input image and a group of channels $g _ { j }$ , we include an encoding for the group index $k _ { g }$ similar to $\underline { { \mathsf { R . 1 . 1 } } }$
105
+
106
+ $$
107
+ g _ { k _ { g } , i } = { \tt E n c o d e } ( k _ { g } , i )
108
+ $$
109
+
110
+ Note that this encoding simply depends on a user-devised channel grouping, and differs from eq. $( 2 )$ since additional metadata for the imagery, like its date, is not needed. The final encoding is a
111
+
112
+ concatenation of the positional $x _ { k , i } , y _ { k , i }$ and the spectral encoding ${ g } _ { k , i }$ such that the total dimension is $D$ (see fig. $2 )$ . This positional encoding is added to $S ^ { \prime }$ before inputting it to the encoder. We denote the combined setting of grouping channels and using a group encoding as SatMAE $+$ Group.
113
+
114
+ Masking Strategies We consider consistent masking (denoted SatMAE $^ +$ Group+CM) and independent masking (SatMAE $^ +$ Group+IM) as defined in section 4.1.2 and as visualized in fig. 3b.
115
+
116
+ # 5 Experiments
117
+
118
+ In this section, we first introduce the datasets we considered, including a new multi-spectral remote sensing image dataset for downstream task evaluation $( 5 . 1 )$ . We then present our results on benchmark datasets $( 5 . { \overset { \smile } { 2 } } , 5 . 3 , 5 . 4 )$ and various remote sensing transfer-learning and downstream tasks $\underline { { \boldsymbol { \left. 5 . 5 \right. } } }$ For all experiments, we compare with the current state-of-the-art methods $\mathbb { 1 3 4 } , \bigstar \bigstar \bigstar \bigstar$ and with supervised learning from scratch using the ViT backbone of SatMAE. In summary, our approach demonstrates strong performance on all the tasks we considered, yielding improvements over previous state-of-theart techniques by up to $6 \%$ on supervised learning benchmarks, and up to $14 \%$ on remote sensing transfer-learning downstream remote sensing tasks.
119
+
120
+ # 5.1 Datasets for Pre-training
121
+
122
+ fMoW RGB Functional Map of the World (fMoW) $ { \mathbb { I } } ^ { [ 1 2 ] }$ is a dataset of high-resolution satellite image time series across the world, with a task of classification among 62 categories.
123
+
124
+ fMoW Sentinel We create a new dataset based on the fMoW RGB dataset. We collect all 13 frequency bands provided by Sentinel-2 (B1-12 and B8A) for the original fMoW locations, at some of the same times as fMoW images plus some extra times, for a total of 712,874 training images, 84,939 validation images, and 84,966 test images. More details are included in appendix A.1.
125
+
126
+ # 5.2 fMoW RGB (non-temporal)
127
+
128
+ Table 1: Top 1 Accuracy on fMoW classification. Frozen: only performing linear classification on frozen features of the pre-trained model. Finetune: end-to-end finetuning the whole model. \* is training from scratch, and $\dagger$ is using supervised-learning ImageNet weights, and $^ \ddag$ is SSL MAE ImageNet weights.
129
+
130
+ <table><tr><td>Method</td><td>Backbone</td><td>Frozen/Finetune</td></tr><tr><td>Sup.*</td><td>ResNet50</td><td>-/69.05</td></tr><tr><td>Sup.t</td><td>ResNet50</td><td>-/69.07</td></tr><tr><td>GASSL [B4]</td><td>ResNet50</td><td>68.32/71.55</td></tr><tr><td>Sup.*</td><td>ViT-Large</td><td>-/62.48</td></tr><tr><td>Sup.t</td><td>ViT-Large</td><td>-/75.70</td></tr><tr><td>Sup.t</td><td>ViT-Large</td><td>-/76.91</td></tr><tr><td>SatMAE</td><td>ViT-Large</td><td>65.94/77.84</td></tr></table>
131
+
132
+ In this section, we perform experiments on fMoW single image classification task. Following $\bar { \big [ } \bar { 3 4 } \bar { \big ] }$ , we report both the performance of linear probing and finetuning setting. Table 1 shows that compared to the previous stateof-the-art self-supervised method using a contrastive momentum encoding approach [34, 3], our SatMAE achieved a $6 . 2 9 \%$ improvement in top 1 classification accuracy. Interestingly, without SatMAE pre-training the ViT-large model could only reach $6 2 . 4 8 \%$ at convergence after 50 epochs of finetuning compared to $6 9 . 0 5 \%$ achieved by training a ResNet-50 model from scratch. This is likely because the ViT $[ \beta 6 ]$ backbone is harder to finetune from scratch than ResNet50 [61], which makes the pre-trained model more valuable.
133
+
134
+ # 5.3 fMoW RGB (temporal)
135
+
136
+ Main experiments We perform image-sequence classification on the temporal version of fMoW RGB to evaluate our temporal SatMAE. The temporal fMoW consists of co-located image sequences with a length of 3. As seen in table 2, SatMAE surpasses the previous state-of-the-art by $4 . 4 8 \%$ and improves the non-temporal result by $2 . 0 6 \%$ in top 1 classification accuracy. We also outperform UTAE [48], a SITS state-of-the-art, by $18 \%$ . We can observe from rows 5-8 that this gain is not from the larger model to handle sequences of data. Naively stacking the image sequences in the channel dimension performs even worse than the non-temporal SatMAE. Again, SatMAE pre-training is crucial for ViT to outperform ResNet50. Training details are in appendix A.3.2.
137
+
138
+ Table 2: Classification results on the temporal fMoW RGB dataset. \* means finetuning from scratch. $\parallel$ means copying the input image 3 times instead of using temporal sequences as input. SatMAE $^ +$ Stack here means stacking the image sequence along the channel space.
139
+
140
+ <table><tr><td>Method</td><td>Backbone</td><td>Top Acc. (1/5)</td></tr><tr><td>Sup.*</td><td>ResNet50</td><td>73.24/-</td></tr><tr><td>SeCo [5</td><td>ResNet50</td><td>66.80/-</td></tr><tr><td>GASSL [34]</td><td>ResNet50</td><td>74.11/-</td></tr><tr><td>UTAE [48]</td><td>U-Net</td><td>61.59/86.45</td></tr><tr><td>Sup.*</td><td>ViT-Large</td><td>61.89/84.23</td></tr><tr><td>SatMAE+Stack</td><td>ViT-Large</td><td>75.85/88.68</td></tr><tr><td>MAE+Test Aug.</td><td>ViT-Large</td><td>78.90/93.31</td></tr><tr><td>MAE|</td><td>ViT-Large</td><td>76.78/92.01</td></tr><tr><td>SatMAE</td><td>ViT-Large</td><td>81.49/93.26</td></tr></table>
141
+
142
+ Table 3: Top 1 & Top 5 Accuracy on the fMoW Sentinel validation set. The different initializations are: \* from scratch, $\dagger$ MAE ImageNet weights, $^ \ddag$ supervised ImageNet weights, $\ S$ SatMAE fMoW RGB weights. Other rows use fMoW Sentinel for pre-training. The last row includes additional data augmentations (5.4).
143
+
144
+ <table><tr><td>Method</td><td>Backbone</td><td>Top Acc. (1/5)</td></tr><tr><td>Sup. Learning*</td><td>ResNet152</td><td>49.12/75.73</td></tr><tr><td>Sup. Learningt</td><td>ResNet152</td><td>54.46/78.99</td></tr><tr><td>MoCo-v3</td><td>ViT-Base</td><td>50.45/76.37</td></tr><tr><td>MoCo-v3+Group</td><td>ViT-Base</td><td>51.33/75.68</td></tr><tr><td>SatMAE+Group*</td><td>ViT-Large</td><td>53.03/77.14</td></tr><tr><td>SatMAE+Groupt</td><td>ViT-Large</td><td>51.61/77.26</td></tr><tr><td>SatMAE+Groupt</td><td>ViT-Large</td><td>47.57/72.26</td></tr><tr><td>SatMAE+GroupS</td><td>ViT-Large</td><td>49.49/76.30</td></tr><tr><td>SatMAE+Stack</td><td>ViT-Large</td><td>57.37/81.63</td></tr><tr><td>SatMAE+Group+IM</td><td>ViT-Large</td><td>59.30/82.81</td></tr><tr><td>SatMAE+Group+IM</td><td>ViT-Large</td><td>61.48/85.17</td></tr></table>
145
+
146
+ Table 4: Ablation studies on different components of temporal SatMAE on the temporal fMoW classification task. The first column is whether using temporal encoding, the second is whether using independent masking, the third is whether cropping consistently, and the last one is whether applying test-time augmentation.
147
+
148
+ <table><tr><td>Temp. Enc.</td><td>Indep. Mask.</td><td>Cons. Crop.</td><td>Test Aug.</td><td>Top 1 Acc.</td></tr><tr><td></td><td>√</td><td>√</td><td></td><td>78.07</td></tr><tr><td>√</td><td></td><td>√</td><td></td><td>78.45</td></tr><tr><td>√</td><td>√</td><td></td><td></td><td>79.90</td></tr><tr><td>√</td><td>√</td><td>√</td><td></td><td>79.69</td></tr><tr><td>√</td><td>√</td><td>√</td><td>√</td><td>81.49</td></tr></table>
149
+
150
+ Table 5: Ablation studies on spectral SatMAE on fMoW-Sentinel. The first column denotes using ViTBase or ViT-Large. The second column is the grouping strategy (see 5.4). The third column denotes independent or consistent masking. The last column is whether the spectral group encoding 3 is used.
151
+
152
+ <table><tr><td>Back.</td><td>Group Strat.</td><td>Indp. Mask.</td><td>Spec. Enc.</td><td>Top 1 Acc.</td></tr><tr><td>Base</td><td>X</td><td>√</td><td>√</td><td>59.11</td></tr><tr><td>Large</td><td>X</td><td>√</td><td></td><td>58.87</td></tr><tr><td>Large</td><td>X</td><td></td><td>√</td><td>57.76</td></tr><tr><td>Large</td><td>H</td><td>√</td><td>√</td><td>57.78</td></tr><tr><td>Large</td><td>R</td><td>√</td><td>√</td><td>58.76</td></tr><tr><td>Large</td><td>X</td><td>√</td><td>√</td><td>59.30</td></tr></table>
153
+
154
+ Ablation studies Table 4 provides a comprehensive ablation study on the components of temporal SatMAE. We see that improved performance is mainly due to the temporal encoding and adopting independent masking rather than the consistent masking strategy suggested in VideoMAE $\pmb { \| \overbrace { 5 4 } } \big |$ . Interestingly, consistent cropping slightly decreases performance, indicating that the model does not rely on perfectly spatially-aligned image sequences. In addition, using test-time augmentations similar to $\textcircled { 1 3 4 } ]$ is beneficial. Further ablations on mask ratio $p _ { m }$ and patch size $P$ are in appendix A.4.
155
+
156
+ # 5.4 fMoW Sentinel (Multi-spectral)
157
+
158
+ In this section, we pre-train and finetune SatMAE on the image classification task of the fMoWSentinel dataset. We pre-train SatMAE $^ +$ Stack $4 . 2$ and investigate SatMAE+Group+CM 4.1.2 and $\mathrm { S a t M A E + G r o u p + I M \bar { 4 } . 1 . 2 } ,$ (see 4.2, 4.2). The full models are then finetuned on the fMoW-Sentinel image classification task. For comparison, we also finetune the ResNet-152 model [61] from scratch and from a supervised ImageNet initialization. We pick the largest model, ResNet-152, for fairer comparison with ViTs. We also include MoCo-v3 [62, 3], a popular SSL method. Given the differences in applying RGB-image augmentations to satellite imagery, we implement two versions: (i) MoCo-v3: we apply all of the same augmentations, except random grayscale and solarize, to create 2 views of the 10-channel image. (ii) MoCo-v3+Group: we split the 10 bands into two groups suggested by $\pmb { \mathbb { D } } \mathbf { l }$ , and apply augmentations to each to create a positive pair of two 5-channel images.
159
+
160
+ Model configuration As not all of the 13 Sentinel-2 bands may be useful, in our experiments we drop bands B1, B9 and B10, which correspond to a spatial resolution of $6 0 \mathrm { m }$ . Of the remaining 10 bands, we form three groups: (i) RGB $^ +$ NIR: B2, B3, B4, B8 (ii) Red Edge: B5, B6, B7, B8A (iii) SWIR: B11, B12. We choose this grouping to ensure each group has bands of the same spatial resolution and similar wavelength (see A.2.2, A.6) Only the last row of table $\textcircled { 3 }$ includes additional data augmentations used during finetuning as in [1] See A.3.3 for pre-training and finetuning details.
161
+
162
+ <table><tr><td>Method</td><td>Backbone</td><td>Top 1 Acc.</td></tr><tr><td>Sup. (Scratch)</td><td>ResNet50</td><td>54.46</td></tr><tr><td>GASSL B4]</td><td>ResNet50</td><td>57.63</td></tr><tr><td>Sup. (Scratch)</td><td>ViT-Large</td><td>69.65</td></tr><tr><td>SatMAE</td><td>ViT-Large</td><td>71.77</td></tr></table>
163
+
164
+ Table 6: NAIP land cover classification results.
165
+
166
+ <table><tr><td>Method</td><td>Backbone mIoU</td></tr><tr><td>Sup. (Scratch)</td><td>ResNet50 75.57</td></tr><tr><td>GASSL [B4]</td><td>ResNet50 78.51</td></tr><tr><td>Sup. (Scratch)</td><td>ViT-Large 74.71</td></tr><tr><td>SatMAE</td><td>ViT-Large 78.07</td></tr></table>
167
+
168
+ Table 7: SpaceNet v1 building segmentation results.
169
+
170
+ <table><tr><td>Method</td><td>Backbone</td><td>Top1 Acc.</td></tr><tr><td>Sup. (Scratch)</td><td>ResNet18</td><td>63.21</td></tr><tr><td>Sup. (IN init.)</td><td>ResNet18</td><td>86.44</td></tr><tr><td>GASSL [34]</td><td>ResNet18</td><td>89.51</td></tr><tr><td>SeCo [35]</td><td>ResNet18</td><td>93.14</td></tr><tr><td>SatMAE*</td><td>ViT-Large</td><td>95.74</td></tr><tr><td>SatMAE</td><td>ViT-Large</td><td>98.94</td></tr><tr><td>SatMAE+Group+IM</td><td>ViT-Large</td><td>98.98</td></tr></table>
171
+
172
+ Table 8: EuroSAT land cover classification results. \* means we only use the RGB channels of the data.
173
+
174
+ <table><tr><td>Method</td><td>Backbone</td><td>mAP</td></tr><tr><td>Sup. (Scratch)</td><td>ResNet50</td><td>69.49</td></tr><tr><td>Sup. (IN init.)</td><td>ResNet50</td><td>80.04</td></tr><tr><td>GASSL [34</td><td>ResNet50</td><td>80.20</td></tr><tr><td>SeCo[ B5</td><td>ResNet50</td><td>82.62</td></tr><tr><td>Sup. (Scratch)</td><td>ViT-Large</td><td>80.07</td></tr><tr><td>SatMAE</td><td>ViT-Large</td><td>82.13</td></tr></table>
175
+
176
+ Table 9: BigEarthNet multi-label classification results. Following [35], we use mean Average Precision (mAP) as the metric, and use a newer set of class labels.
177
+
178
+ Results We present results in table $3 .$ Our method SatMAE $+$ Group $\mathbf { \Gamma } + \mathrm { I M }$ achieves the highest accuracy, outperforming supervised training from scratch $( \uparrow 6 . 2 7 \% )$ and ImageNet-initialized backbones $( \uparrow 4 . 8 4 \% )$ . ImageNet initializations may be less useful than in fMoW-RGB given the larger distributional shift to multi-spectral input data. We also note the effectiveness of grouping channels over processing all bands only at the patch embedding level (i.e. SatMAE $^ +$ Stack).
179
+
180
+ Ablation Studies We investigate the design of SatMAE for multi-spectral data in table $\underline { { \boldsymbol { \mathsf { F } } } } ,$ For grouping strategy, we implement alternate band groups to test the hypothesis that grouping bands based on wavelength and resolution is beneficial. X represents the band groups in ${ 5 . 4 } .$ H represents splitting the 10 bands into two halves, {(2,3,4,5,6), (7,8,8A,11,12)}. R represents a random split into three groups {(6,5,11,12), (8A,4,8,3), (7,2)}, reflecting the same group sizes as X. As seen, the choice of band groups does influence performance, yielding a gain of about $0 . 6 \%$ . Moreover, ViT-Base performs strongly, suggesting that SatMAE is the reason for improved performance rather than the number of parameters in ViT. Interestingly, independent masking performs the best, which prompts the model to “peek” at unmasked band groups to reconstruct the same region in a masked band group.
181
+
182
+ We also include further experiments on the length of pre-training $( \mathrm { s e e } \mathbf { A } . 3 . 3 )$ , the impact of mask ratio $p _ { m }$ and patch size $P$ (see A.5), and the usefulness of the 13 Sentinel-2 spectral bands (see A.6).
183
+
184
+ # 5.5 Transfer Learning Experiments
185
+
186
+ Now, we finetune our pre-trained SatMAE on downstream tasks on remote-sensing datasets, including land cover classification $\underline { { \boldsymbol { \mathfrak { S . 5 } } } } \flat$ , multi-label classification $( 5 . 5 )$ and building segmentation $\underline { { \widehat { ( 5 . 5 ) } } }$ Finetuning details are included in A.7, A.8, A.9, A.10.
187
+
188
+ Land Cover Classification We perform transfer learning experiments on land cover classification using the NAIP and EuroSAT $\pmb { \mathbb { \left| \overline { { 6 3 } } \right\| } }$ dataset. NAIP consists of $\mathrm { R G B + C I R }$ images of 66 land cover classes obtained by the USDA’s National Agricultural Imagery Program, which are split into 244,471 training and 55,529 validation images. EuroSAT is a small dataset containing 27,000 13-band satellite images of 10 classes based on Sentinel-2. We follow $\textcircled { 1 3 5 } , \textcircled { 6 4 } \textcircled { 1 }$ for the train/val splits on EuroSAT.
189
+
190
+ Table $\boxed { 6 }$ and table 8 shows the remarkable improvement of our SatMAE over the state-of-the-arts. Although using the ViT-Large backbone already achieved good results, initializing the model with SAT-MAE pre-trained weights further increased the accuracy by $2 \% - 3 \%$ .
191
+
192
+ Multi-label Classification We also use the BigEarthNet $\mathbb { \lVert 1 8 \rVert }$ dataset for multi-label classification, which consists of 13-band Sentinel-2 images of 19 classes in total. There are 354,196 images for training and 118,065 images for validation. Following $\pmb { \Vert 3 5 \Vert }$ , we use a $10 \%$ subset of the train set.
193
+
194
+ Table 9 shows SatMAE pre-training improves upon the model trained from scratch by over $2 \%$ , and achieves comparable results to the state-of-the-art. GASSL and SeCo were actually trained on a larger pre-train dataset (1M Sentinel-2 images v.s. 713k) and with all 13 bands than our fMoW Sentinel. Therefore we expect further improvement when we pre-train SatMAE with more data and for longer.
195
+
196
+ Building Segmentation In this section, we evaluate SatMAE on the semantic segmentation downstream task of the SpaceNet v1 dataset $\pmb { \mathbb { Z } } 0 \|$ . The SpaceNet v1 dataset consists of 6940 high resolution satellite images with segmentation masks for buildings, which are divided into train and test sets of 5000 and 1940 images, respectively.
197
+
198
+ The results in table $^ { 7 }$ show that our method achieves a larger performance gain from supervised learning from scratch compared to $\textcircled { 1 3 4 } \textcircled { 1 }$ . The incompatibility of the ViT backbone with PSANet could explain why the baseline performance is not as strong as that of using a ResNet50 backbone.
199
+
200
+ # 5.6 Visualizing reconstruction quality for SatMAE
201
+
202
+ ![](images/70f40cdf40ced9b4e9f795b92389ebf598941824c7c178a2d89c7d0f6d4c604a.jpg)
203
+ Figure 4: Reconstruction quality of SatMAE $+ \mathrm { I M }$ (left) vs. SatMAE $\mathbf { \Gamma } _ { + \mathrm { C M } }$ (right). Further results in appendix C.
204
+
205
+ We show the visualization of the reconstruction quality of two different SatMAE masking strategies in fig. 4. SatMAE+IM successfully reconstructs all the airplanes even though their number varies across time. In contrast, the SatMAE with Consistent Masking missed some airplanes in the reconstruction.
206
+
207
+ # 6 Conclusion
208
+
209
+ In this paper, we propose a new SSL framework based on the MAE architecture [1] tailored to remotesensing data (satellite imagery). Our novel masking strategy in a joint positional, temporal/spectral space, along with the temporal and spectral encoding, enables our model to handle temporal and multi-spectral satellite images as input and learn useful representations. Experiments on the datasets for pre-training and multiple downstream datasets demonstrate the effectiveness of our pre-trained SatMAE model, outperforming previous state-of-the-art results by large margins.
210
+
211
+ In the future, it would be useful to design more efficient transformer architectures. While SatMAE has a similar number of parameters for both the temporal and multi-spectral setting as a regular ViT, the increased length of token sequences can strain computational resources. Moreover, it is also worth exploring optimal positional encodings for spectral and temporal data, as well as optimal groups of spectral bands, either by neural-based search methods, or using prior knowledge. Lastly, investigating better architectures for object detection and semantic segmentation using ViTs will be important in generalising SatMAE to further downstream tasks.
212
+
213
+ # Broader Impact
214
+
215
+ Accurate measurements of economic, social, and environmental phenomena are key inputs into policy decisions made around the world, but the sparsity of labelled data on many outcomes means that such decisions are often not guided by timely or accurate data. We demonstrate how a pre-training framework could relieve the dependence on labelled data for many downstream tasks that use satellite imagery as input. We hope our SatMAE method will help close the gap between SSL performance on natural imagery and on the more challenging satellite imagery, and prompt further attention from the ML community on the usefulness of SSL in satellite-imagery-related tasks.
216
+
217
+ Better extraction of information from satellite imagery has profound implications for our ability to measure and understand a broad array of social, economic and environmental phenomena that are critical for decision making. Our approach further amplifies the usefulness of the sparse amount of labelled data that exist on key human outcomes, and could enable rapid and accurate extraction of imagery features relevant for critical downstream tasks, including poverty prediction, infrastructure development, and population estimation. Such information could aid governments in more rapid and data-informed decision making and ultimately bring large societal benefits.
218
+
219
+ # 7 Acknowledgements
220
+
221
+ This research is based upon work supported in part by the Office of the Director of National Intelligence (ODNI), Intelligence Advanced Research Projects Activity (IARPA), via 2021-2011000004, HAI, NSF(#1651565), AFOSR (FA95501910024), ARO (W911NF-21-1-0125) and Sloan Fellowship. The views and conclusions contained herein are those of the authors and should not be interpreted as necessarily representing the official policies, either expressed or implied, of ODNI, IARPA, or the U.S. Government. The U.S. Government is authorized to reproduce and distribute reprints for governmental purposes not-withstanding any copyright annotation therein.
222
+
223
+ # Checklist
224
+
225
+ 1. For all authors...
226
+
227
+ (a) Do the main claims made in the abstract and introduction accurately reflect the paper’s contributions and scope? [Yes] We tried our best to be precise.
228
+ (b) Did you describe the limitations of your work? [Yes] We described the limitations in the conclusion section.
229
+ (c) Did you discuss any potential negative societal impacts of your work? [Yes] We discussed in Appendix B
230
+ (d) Have you read the ethics review guidelines and ensured that your paper conforms to them? [Yes]
231
+
232
+ 2. If you are including theoretical results...
233
+
234
+ (a) Did you state the full set of assumptions of all theoretical results? [N/A] (b) Did you include complete proofs of all theoretical results? [N/A]
235
+
236
+ 3. If you ran experiments...
237
+
238
+ (a) Did you include the code, data, and instructions needed to reproduce the main experimental results (either in the supplemental material or as a URL)? [Yes] We list the url to our project website in the abstract. The website will contain links to the code and data on Github.
239
+ (b) Did you specify all the training details (e.g., data splits, hyperparameters, how they were chosen)? [Yes] We list part of them in the experiments section and part of them in Appendix A.
240
+ (c) Did you report error bars (e.g., with respect to the random seed after running experiments multiple times)? [No] We trained on large datasets with small variation across different runs expected. Limited by computation resources, we only ran each experiment once.
241
+ (d) Did you include the total amount of compute and the type of resources used (e.g., type of GPUs, internal cluster, or cloud provider)? [Yes] We list that in Appendix A.
242
+
243
+ 4. If you are using existing assets (e.g., code, data, models) or curating/releasing new assets...
244
+
245
+ (a) If your work uses existing assets, did you cite the creators? [Yes] Yes, we do that by citing creators of datasets and authors of prior works.
246
+ (b) Did you mention the license of the assets? [Yes] We do that in Appendix A
247
+ (c) Did you include any new assets either in the supplemental material or as a URL? [Yes] We are releasing a new dataset. The instructions and links will be released in our codebase mentioned above.
248
+ (d) Did you discuss whether and how consent was obtained from people whose data you’re using/curating? [Yes] All data we used are released publicly.
249
+ (e) Did you discuss whether the data you are using/curating contains personally identifiable information or offensive content? [Yes] We concluded that no data we are using has such concerns.
250
+
251
+ 5. If you used crowdsourcing or conducted research with human subjects...
252
+
253
+ (a) Did you include the full text of instructions given to participants and screenshots, if applicable? [N/A]
254
+ (b) Did you describe any potential participant risks, with links to Institutional Review Board (IRB) approvals, if applicable? [N/A]
255
+ (c) Did you include the estimated hourly wage paid to participants and the total amount spent on participant compensation? [N/A]
256
+
257
+ # References
258
+
259
+ [1] Kaiming He, Xinlei Chen, Saining Xie, Yanghao Li, Piotr Dollár, and Ross Girshick. Masked autoencoders are scalable vision learners. In Proceedings of the IEEE/CVF Conference on Computer Vision and Pattern Recognition, pages 16000–16009, 2022.
260
+
261
+ [2] Yonglong Tian, Dilip Krishnan, and Phillip Isola. Contrastive multiview coding. In European conference on computer vision, pages 776–794. Springer, 2020.
262
+ [3] Kaiming He, Haoqi Fan, Yuxin Wu, Saining Xie, and Ross Girshick. Momentum contrast for unsupervised visual representation learning. In Proceedings of the IEEE/CVF conference on computer vision and pattern recognition, pages 9729–9738, 2020.
263
+ [4] Ting Chen, Simon Kornblith, Mohammad Norouzi, and Geoffrey Hinton. A simple framework for contrastive learning of visual representations. In International conference on machine learning, pages 1597–1607. PMLR, 2020.
264
+ [5] Jean-Bastien Grill, Florian Strub, Florent Altché, Corentin Tallec, Pierre Richemond, Elena Buchatskaya, Carl Doersch, Bernardo Avila Pires, Zhaohan Guo, Mohammad Gheshlaghi Azar, et al. Bootstrap your own latent-a new approach to self-supervised learning. Advances in Neural Information Processing Systems, 33:21271–21284, 2020.
265
+ [6] Xinlei Chen and Kaiming He. Exploring simple siamese representation learning. In Proceedings of the IEEE/CVF Conference on Computer Vision and Pattern Recognition, pages 15750–15758, 2021.
266
+ [7] Ashish Jaiswal, Ashwin Ramesh Babu, Mohammad Zaki Zadeh, Debapriya Banerjee, and Fillia Makedon. A survey on contrastive self-supervised learning. CoRR, abs/2011.00362, 2020.
267
+ [8] Longlong Jing and Yingli Tian. Self-supervised visual feature learning with deep neural networks: A survey. IEEE transactions on pattern analysis and machine intelligence, 43(11):4037– 4058, 2020.
268
+ [9] Ishan Misra and Laurens van der Maaten. Self-supervised learning of pretext-invariant representations. In Proceedings of the IEEE/CVF Conference on Computer Vision and Pattern Recognition, pages 6707–6717, 2020.
269
+ [10] Mathilde Caron, Ishan Misra, Julien Mairal, Priya Goyal, Piotr Bojanowski, and Armand Joulin. Unsupervised learning of visual features by contrasting cluster assignments. Advances in Neural Information Processing Systems, 33:9912–9924, 2020.
270
+ [11] Yude Wang, Jie Zhang, Meina Kan, Shiguang Shan, and Xilin Chen. Self-supervised equivariant attention mechanism for weakly supervised semantic segmentation. In Proceedings of the IEEE/CVF Conference on Computer Vision and Pattern Recognition, pages 12275–12284, 2020.
271
+ [12] Yann Dubois, Benjamin Bloem-Reddy, Karen Ullrich, and Chris J Maddison. Lossy compression for lossless prediction. Advances in Neural Information Processing Systems, 34, 2021.
272
+ [13] Alexander Kolesnikov, Xiaohua Zhai, and Lucas Beyer. Revisiting self-supervised visual representation learning. In Proceedings of the IEEE/CVF conference on computer vision and pattern recognition, pages 1920–1929, 2019.
273
+ [14] Zeyu Feng, Chang Xu, and Dacheng Tao. Self-supervised representation learning by rotation feature decoupling. In Proceedings of the IEEE/CVF Conference on Computer Vision and Pattern Recognition, pages 10364–10374, 2019.
274
+ [15] Soroush Abbasi Koohpayegani, Ajinkya Tejankar, and Hamed Pirsiavash. Compress: Selfsupervised learning by compressing representations. Advances in Neural Information Processing Systems, 33:12980–12992, 2020.
275
+ [16] Abhishek Sinha, Jiaming Song, Chenlin Meng, and Stefano Ermon. D2c: Diffusion-decoding models for few-shot conditional generation. Advances in Neural Information Processing Systems, 34:12533–12548, 2021.
276
+ [17] Gordon Christie, Neil Fendley, James Wilson, and Ryan Mukherjee. Functional map of the world. In CVPR, 2018.
277
+ [18] Gencer Sumbul, Marcela Charfuelan, Begüm Demir, and Volker Markl. Bigearthnet: A largescale benchmark archive for remote sensing image understanding. In IGARSS 2019-2019 IEEE International Geoscience and Remote Sensing Symposium, pages 5901–5904. IEEE, 2019.
278
+ [19] Darius Lam, Richard Kuzma, Kevin McGee, Samuel Dooley, Michael Laielli, Matthew Klaric, Yaroslav Bulatov, and Brendan McCord. xview: Objects in context in overhead imagery. arXiv preprint arXiv:1802.07856, 2018.
279
+ [20] Adam Van Etten, Dave Lindenbaum, and Todd M Bacastow. Spacenet: A remote sensing dataset and challenge series. arXiv preprint arXiv:1807.01232, 2018.
280
+ [21] Marshall Burke, Anne Driscoll, David B Lobell, and Stefano Ermon. Using satellite imagery to understand and promote sustainable development. Science, 371(6535):eabe8628, 2021.
281
+ [22] Kumar Ayush, Burak Uzkent, Kumar Tanmay, Marshall Burke, David Lobell, and Stefano Ermon. Efficient poverty mapping from high resolution remote sensing images. In Proc. AAAI Conf. Artif. Intell, volume 35, pages 12–20, 2021.
282
+ [23] Kumar Ayush, Burak Uzkent, Marshall Burke, David Lobell, and Stefano Ermon. Generating interpretable poverty maps using object detection in satellite images. arXiv preprint arXiv:2002.01612, 2020.
283
+ [24] Neal Jean, Marshall Burke, Michael Xie, W Matthew Davis, David B Lobell, and Stefano Ermon. Combining satellite imagery and machine learning to predict poverty. Science, 353(6301):790– 794, 2016.
284
+ [25] Jiaxuan You, Xiaocheng Li, Melvin Low, David Lobell, and Stefano Ermon. Deep gaussian process for crop yield prediction based on remote sensing data. In Thirty-First AAAI conference on artificial intelligence, 2017.
285
+ [26] Anna X Wang, Caelin Tran, Nikhil Desai, David Lobell, and Stefano Ermon. Deep transfer learning for crop yield prediction with remote sensing data. In Proceedings of the 1st ACM SIGCAS Conference on Computing and Sustainable Societies, pages 1–5, 2018.
286
+ [27] Marc Rußwurm and Marco Körner. Self-attention for raw optical satellite time series classification. ISPRS journal of photogrammetry and remote sensing, 169:421–435, 2020.
287
+ [28] Jorge Andres Chamorro Martinez, Laura Elena Cué La Rosa, Raul Queiroz Feitosa, Ieda Del’Arco Sanches, and Patrick Nigri Happ. Fully convolutional recurrent networks for multidate crop recognition from multitemporal image sequences. ISPRS Journal of Photogrammetry and Remote Sensing, 171:188–201, 2021.
288
+ [29] Rose M Rustowicz, Robin Cheong, Lijing Wang, Stefano Ermon, Marshall Burke, and David Lobell. Semantic segmentation of crop type in africa: A novel dataset and analysis of deep learning methods. In Proceedings of the IEEE/CVF Conference on Computer Vision and Pattern Recognition Workshops, pages 75–82, 2019.
289
+ [30] Christopher Yeh, Chenlin Meng, Sherrie Wang, Anne Driscoll, Erik Rozi, Patrick Liu, Jihyeon Lee, Marshall Burke, David B Lobell, and Stefano Ermon. Sustainbench: Benchmarks for monitoring the sustainable development goals with machine learning. arXiv preprint arXiv:2111.04724, 2021.
290
+ [31] Jia Deng, Wei Dong, Richard Socher, Li-Jia Li, Kai Li, and Li Fei-Fei. Imagenet: A largescale hierarchical image database. In 2009 IEEE Conference on Computer Vision and Pattern Recognition, pages 248–255, 2009.
291
+ [32] Yutong He, Dingjie Wang, Nicholas Lai, William Zhang, Chenlin Meng, Marshall Burke, David Lobell, and Stefano Ermon. Spatial-temporal super-resolution of satellite imagery via conditional pixel synthesis. Advances in Neural Information Processing Systems, 34:27903– 27915, 2021.
292
+ [33] Yutong He, William Zhang, Chenlin Meng, Marshall Burke, David B Lobell, and Stefano Ermon. Tracking urbanization in developing regions with remote sensing spatial-temporal super-resolution. arXiv preprint arXiv:2204.01736, 2022.
293
+ [34] Kumar Ayush, Burak Uzkent, Chenlin Meng, Kumar Tanmay, Marshall Burke, David Lobell, and Stefano Ermon. Geography-aware self-supervised learning. In Proceedings of the IEEE/CVF International Conference on Computer Vision, pages 10181–10190, 2021.
294
+
295
+ [35] Oscar Mañas, Alexandre Lacoste, Xavier Giro-i Nieto, David Vazquez, and Pau Rodriguez. Seasonal contrast: Unsupervised pre-training from uncurated remote sensing data. In Proceedings of the IEEE/CVF International Conference on Computer Vision, pages 9414–9423, 2021.
296
+
297
+ [36] Alexey Dosovitskiy, Lucas Beyer, Alexander Kolesnikov, Dirk Weissenborn, Xiaohua Zhai, Thomas Unterthiner, Mostafa Dehghani, Matthias Minderer, Georg Heigold, Sylvain Gelly, Jakob Uszkoreit, and Neil Houlsby. An image is worth 16x16 words: Transformers for image recognition at scale. ICLR, 2021.
298
+
299
+ [37] Marc Rußwurm and Marco Körner. Convolutional lstms for cloud-robust segmentation of remote sensing imagery. arXiv preprint arXiv:1811.02471, 2018.
300
+
301
+ [38] Charlotte Pelletier, Geoffrey I Webb, and François Petitjean. Temporal convolutional neural network for the classification of satellite image time series. Remote Sensing, 11(5):523, 2019.
302
+
303
+ [39] Elisa Kamir, François Waldner, and Zvi Hochman. Estimating wheat yields in australia using climate records, satellite image time series and machine learning methods. ISPRS Journal of Photogrammetry and Remote Sensing, 160:124–135, 2020.
304
+
305
+ [40] Raí A Schwalbert, Telmo Amado, Geomar Corassa, Luan Pierre Pott, PV Vara Prasad, and Ignacio A Ciampitti. Satellite-based soybean yield forecast: Integrating machine learning and weather data for improving crop yield prediction in southern brazil. Agricultural and Forest Meteorology, 284:107886, 2020.
306
+
307
+ [41] Chenlin Meng, Enci Liu, Willie Neiswanger, Jiaming Song, Marshall Burke, David Lobell, and Stefano Ermon. Is-count: Large-scale object counting from satellite images with covariatebased importance sampling. In Proceedings of the AAAI Conference on Artificial Intelligence, volume 36, pages 12034–12042, 2022.
308
+
309
+ [42] Evan Sheehan, Chenlin Meng, Matthew Tan, Burak Uzkent, Neal Jean, Marshall Burke, David Lobell, and Stefano Ermon. Predicting economic development using geolocated wikipedia articles. In Proceedings of the 25th ACM SIGKDD international conference on knowledge discovery & data mining, pages 2698–2706, 2019.
310
+
311
+ [43] Enci Liu, Chenlin Meng, Matthew Kolodner, Eun Jee Sung, Sihang Chen, Marshall Burke, David Lobell, and Stefano Ermon. Building coverage estimation with low-resolution remote sensing imagery. arXiv preprint arXiv:2301.01449, 2023.
312
+
313
+ [44] Burak Uzkent, Evan Sheehan, Chenlin Meng, Zhongyi Tang, Marshall Burke, David Lobell, and Stefano Ermon. Learning to interpret satellite images using wikipedia. In Proceedings of the Twenty-Eighth International Joint Conference on Artificial Intelligence, 2019.
314
+
315
+ [45] Xingjian Shi, Zhourong Chen, Hao Wang, Dit-Yan Yeung, Wai-Kin Wong, and Wang-chun Woo. Convolutional lstm network: A machine learning approach for precipitation nowcasting. Advances in neural information processing systems, 28, 2015.
316
+
317
+ [46] Andrei Stoian, Vincent Poulain, Jordi Inglada, Victor Poughon, and Dawa Derksen. Land cover maps production with high resolution satellite image time series and convolutional neural networks: Adaptations and limits for operational systems. Remote Sensing, 11(17):1986, 2019.
318
+
319
+ [47] Xin Yang and CP Lo. Using a time series of satellite imagery to detect land use and land cover changes in the atlanta, georgia metropolitan area. International Journal of Remote Sensing, 23(9):1775–1798, 2002.
320
+
321
+ [48] Vivien Sainte Fare Garnot and Loic Landrieu. Panoptic segmentation of satellite image time series with convolutional temporal attention networks. In Proceedings of the IEEE/CVF International Conference on Computer Vision, pages 4872–4881, 2021.
322
+
323
+ [49] Aidan M Swope, Xander H Rudelis, and Kyle T Story. Representation learning for remote sensing: An unsupervised sensor fusion approach. arXiv preprint arXiv:2108.05094, 2021.
324
+
325
+ [50] Vladan Stojnic and Vladimir Risojevic. Self-supervised learning of remote sensing scene representations using contrastive multiview coding. In Proceedings of the IEEE/CVF Conference on Computer Vision and Pattern Recognition, pages 1182–1191, 2021.
326
+
327
+ [51] Pallavi Jain, Bianca Schoen-Phelan, and Robert Ross. Multi-modal self-supervised representation learning for earth observation. In 2021 IEEE International Geoscience and Remote Sensing Symposium IGARSS, pages 3241–3244. IEEE, 2021.
328
+ [52] Wenyuan Li, Hao Chen, and Zhenwei Shi. Semantic segmentation of remote sensing images with self-supervised multitask representation learning. IEEE Journal of Selected Topics in Applied Earth Observations and Remote Sensing, 14:6438–6450, 2021.
329
+ [53] Wenyuan Li, Keyan Chen, Hao Chen, and Zhenwei Shi. Geographical knowledge-driven representation learning for remote sensing images. IEEE Transactions on Geoscience and Remote Sensing, 2021.
330
+ [54] Zhan Tong, Yibing Song, Jue Wang, and Limin Wang. Videomae: Masked autoencoders are data-efficient learners for self-supervised video pre-training. arXiv preprint arXiv:2203.12602, 2022.
331
+ [55] Hongxu Chen, Sixiao Zhang, and Guandong Xu. Graph masked autoencoder. arXiv preprint arXiv:2202.08391, 2022.
332
+ [56] Roman Bachmann, David Mizrahi, Andrei Atanov, and Amir Zamir. Multimae: Multi-modal multi-task masked autoencoders. arXiv preprint arXiv:2204.01678, 2022.
333
+ [57] Ashish Vaswani, Noam Shazeer, Niki Parmar, Jakob Uszkoreit, Llion Jones, Aidan N Gomez, Łukasz Kaiser, and Illia Polosukhin. Attention is all you need. Advances in neural information processing systems, 30, 2017.
334
+ [58] Hugo Touvron, Matthieu Cord, Matthijs Douze, Francisco Massa, Alexandre Sablayrolles, and Hervé Jégou. Training data-efficient image transformers & distillation through attention. In International Conference on Machine Learning, pages 10347–10357. PMLR, 2021.
335
+ [59] Anurag Arnab, Mostafa Dehghani, Georg Heigold, Chen Sun, Mario Luciˇ c, and Cordelia ´ Schmid. Vivit: A video vision transformer. In International Conference on Computer Vision (ICCV), 2021.
336
+ [60] Ze Liu, Jia Ning, Yue Cao, Yixuan Wei, Zheng Zhang, Stephen Lin, and Han Hu. Video swin transformer. arXiv preprint arXiv:2106.13230, 2021.
337
+ [61] Kaiming He, Xiangyu Zhang, Shaoqing Ren, and Jian Sun. Deep residual learning for image recognition. In Proceedings of the IEEE conference on computer vision and pattern recognition, pages 770–778, 2016.
338
+ [62] Xinlei Chen\*, Saining Xie\*, and Kaiming He. An empirical study of training self-supervised vision transformers. arXiv preprint arXiv:2104.02057, 2021.
339
+ [63] Patrick Helber, Benjamin Bischke, Andreas Dengel, and Damian Borth. Eurosat: A novel dataset and deep learning benchmark for land use and land cover classification. IEEE Journal of Selected Topics in Applied Earth Observations and Remote Sensing, 12(7):2217–2226, 2019.
340
+ [64] Maxim Neumann, Andre Susano Pinto, Xiaohua Zhai, and Neil Houlsby. In-domain representation learning for remote sensing. arXiv preprint arXiv:1911.06721, 2019.
341
+ [65] Hengshuang Zhao, Yi Zhang, Shu Liu, Jianping Shi, Chen Change Loy, Dahua Lin, and Jiaya Jia. Psanet: Point-wise spatial attention network for scene parsing. In Proceedings of the European conference on computer vision (ECCV), pages 267–283, 2018.
342
+ [66] Alexandre Lacoste, Alexandra Luccioni, Victor Schmidt, and Thomas Dandres. Quantifying the carbon emissions of machine learning. CoRR, abs/1910.09700, 2019.
parse/dev/WBhqzpF6KYH/WBhqzpF6KYH_content_list.json ADDED
@@ -0,0 +1,1522 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ [
2
+ {
3
+ "type": "text",
4
+ "text": "SatMAE: Pre-training Transformers for Temporal and Multi-Spectral Satellite Imagery ",
5
+ "text_level": 1,
6
+ "bbox": [
7
+ 192,
8
+ 122,
9
+ 805,
10
+ 172
11
+ ],
12
+ "page_idx": 0
13
+ },
14
+ {
15
+ "type": "text",
16
+ "text": "Yezhen Cong⇤ yzcong@stanford.edu ",
17
+ "bbox": [
18
+ 187,
19
+ 226,
20
+ 349,
21
+ 255
22
+ ],
23
+ "page_idx": 0
24
+ },
25
+ {
26
+ "type": "text",
27
+ "text": "Chenlin Meng Patrick Liu ",
28
+ "bbox": [
29
+ 609,
30
+ 226,
31
+ 812,
32
+ 241
33
+ ],
34
+ "page_idx": 0
35
+ },
36
+ {
37
+ "type": "text",
38
+ "text": "Samar Khanna⇤ samar.khanna@stanford.edu ",
39
+ "bbox": [
40
+ 374,
41
+ 226,
42
+ 586,
43
+ 253
44
+ ],
45
+ "page_idx": 0
46
+ },
47
+ {
48
+ "type": "text",
49
+ "text": "Erik Rozi Yutong He Marshall Burke David B. Lobell Stefano Ermon ",
50
+ "text_level": 1,
51
+ "bbox": [
52
+ 196,
53
+ 275,
54
+ 799,
55
+ 290
56
+ ],
57
+ "page_idx": 0
58
+ },
59
+ {
60
+ "type": "text",
61
+ "text": "Stanford University ",
62
+ "bbox": [
63
+ 434,
64
+ 310,
65
+ 562,
66
+ 325
67
+ ],
68
+ "page_idx": 0
69
+ },
70
+ {
71
+ "type": "text",
72
+ "text": "Abstract ",
73
+ "text_level": 1,
74
+ "bbox": [
75
+ 462,
76
+ 361,
77
+ 535,
78
+ 377
79
+ ],
80
+ "page_idx": 0
81
+ },
82
+ {
83
+ "type": "text",
84
+ "text": "Unsupervised pre-training methods for large vision models have shown to enhance performance on downstream supervised tasks. Developing similar techniques for satellite imagery presents significant opportunities as unlabelled data is plentiful and the inherent temporal and multi-spectral structure provides avenues to further improve existing pre-training strategies. In this paper, we present SatMAE, a pre-training framework for temporal or multi-spectral satellite imagery based on Masked Autoencoder (MAE). To leverage temporal information, we include a temporal embedding along with independently masking image patches across time. In addition, we demonstrate that encoding multi-spectral data as groups of bands with distinct spectral positional encodings is beneficial. Our approach yields strong improvements over previous state-of-the-art techniques, both in terms of supervised learning performance on benchmark datasets (up to $\\uparrow 7 \\% )$ ), and transfer learning performance on downstream remote sensing tasks, including land cover classification (up to $\\uparrow 1 4 \\% )$ and semantic segmentation. Code and data are available on the project website: https://sustainlab-group.github.io/SatMAE/ ",
85
+ "bbox": [
86
+ 233,
87
+ 391,
88
+ 766,
89
+ 599
90
+ ],
91
+ "page_idx": 0
92
+ },
93
+ {
94
+ "type": "text",
95
+ "text": "1 Introduction ",
96
+ "text_level": 1,
97
+ "bbox": [
98
+ 174,
99
+ 621,
100
+ 310,
101
+ 638
102
+ ],
103
+ "page_idx": 0
104
+ },
105
+ {
106
+ "type": "text",
107
+ "text": "In recent years, self-supervised learning techniques have quickly become the norm for pre-training models on large-scale natural image datasets [1, 2, 3, 4, 5, 6, 7, 8], and have demonstrated strong performance on downstream tasks including image classification [3, 4, 9, 10], image segmentation $\\bar { \\bigtriangledown } ,$ 11], representation learning [12, 13, 14], image compression [12, 15], image reconstruction $\\mathbb { n }$ , and image generation $[ \\overline { { 1 6 } } ]$ . Unlike supervised learning approaches, self-supervised learning techniques do not require human labeling, making them appealing in settings where unlabeled data are abundant but labeled data are scarce, such as remote sensing data (e.g., satellite imagery). While several large-scale satellite image datasets have been carefully curated in the past few years, including Functional Map of the World (fMoW) [17], BigEarthNet [18], xView [19], SpaceNet $\\mathbb { \\ m }$ , annotating these datasets requires specialized skills and is more expensive than traditional computer vision datasets. Moreover, automatic analysis of satellite imagery is often needed for tasks with large societal impact such as poverty or crop yield prediction [21, 22, 23, 24, 25, 26, 27, 28, 29, 30], where acquiring large amounts of labeled data through surveys is impossible or prohibitively expensive. This suggests that self-supervised learning approaches for satellite imagery could be especially valuable. ",
108
+ "bbox": [
109
+ 173,
110
+ 654,
111
+ 825,
112
+ 847
113
+ ],
114
+ "page_idx": 0
115
+ },
116
+ {
117
+ "type": "text",
118
+ "text": "However, existing self-supervised learning approaches [1, 2, 3, 4, 5, 6] are mainly designed for natural images. As opposed to natural images such as ImageNet [31], satellite imagery is usually associated with meaningful geographical and temporal information, and can consist of multiple spectral bands representing sensor readings besides visible light (i.e., RGB channels typical in natural images). Depending on the data source, satellite imagery can also vary significantly in resolution [32, 33]. While self-supervised learning methods for satellite imagery exist [34, 35], these approaches cannot learn general representations for both temporal and multi-spectral remote sensing data. ",
119
+ "bbox": [
120
+ 176,
121
+ 852,
122
+ 821,
123
+ 881
124
+ ],
125
+ "page_idx": 0
126
+ },
127
+ {
128
+ "type": "image",
129
+ "img_path": "images/735f582f0f88215b4d3a2f370722d5431ab35c25d949ae49652c896875ef705d.jpg",
130
+ "image_caption": [
131
+ "Figure 1: With carefully-designed masking strategies across mutli-spectral and temporal images, and temporal and spectral positional encodings, our SatMAE serves as a powerful SSL vision learner for remote sensing tasks. "
132
+ ],
133
+ "image_footnote": [],
134
+ "bbox": [
135
+ 209,
136
+ 92,
137
+ 784,
138
+ 335
139
+ ],
140
+ "page_idx": 1
141
+ },
142
+ {
143
+ "type": "text",
144
+ "text": "",
145
+ "bbox": [
146
+ 174,
147
+ 392,
148
+ 825,
149
+ 463
150
+ ],
151
+ "page_idx": 1
152
+ },
153
+ {
154
+ "type": "text",
155
+ "text": "To address this issue we propose SatMAE, a self-supervised learning framework based on masked autoencoders (MAEs) [1] which naturally handles temporal and multi-spectral input data. We show that introducing a positional encoding for the temporal/spectral dimension and independently masking patches across the temporal/spectral dimension benefits pre-training, allowing the model to learn representations of the data that are more conducive to finetuning. Specifically, our contributions are: ",
156
+ "bbox": [
157
+ 176,
158
+ 468,
159
+ 825,
160
+ 537
161
+ ],
162
+ "page_idx": 1
163
+ },
164
+ {
165
+ "type": "text",
166
+ "text": "1. We propose a novel method to leverage temporal or multi-spectral information in satellite imagery to improve self-supervised pre-training with masked autoencoders (see 4). \n2. We introduce fMoW-Sentinel, a new Sentinel-2 dataset cross-referenced with fMoW, as a benchmark for training models on multi-spectral satellite imagery (see 5.1). \n3. We demonstrate the effectiveness of pre-training transformers $\\pmb { \\Vert 3 6 \\Vert }$ on satellite imagery, achieving significant improvement over previous state-of-the-art methods on benchmark datasets as well as downstream remote sensing tasks (see 5) ",
167
+ "bbox": [
168
+ 212,
169
+ 547,
170
+ 825,
171
+ 655
172
+ ],
173
+ "page_idx": 1
174
+ },
175
+ {
176
+ "type": "text",
177
+ "text": "2 Related Work ",
178
+ "text_level": 1,
179
+ "bbox": [
180
+ 174,
181
+ 672,
182
+ 321,
183
+ 689
184
+ ],
185
+ "page_idx": 1
186
+ },
187
+ {
188
+ "type": "text",
189
+ "text": "ML for SITS Deep learning has been used for many Satellite Image Time Series (SITS) supervisedlearning tasks such as crop-type mapping [29, 28, 37, 38], yield prediction [39, 40], understanding the economy [41, 42, 43, 44], precipitation forcasting $\\lVert \\boldsymbol { \\mathsf { E } } \\boldsymbol { \\mathsf { 5 } } \\rVert$ , and land-cover classification $\\boxed { 4 6 } \\boxed { 4 7 } \\boxed { 4 8 } \\boxed { 2 7 }$ . These works establish the usefulness of tailoring architectures such as LSTMs, self-attention, and transformers to temporal data. However, outside of their specific task, they are often not directly applicable to other remote-sensing datasets. ",
190
+ "bbox": [
191
+ 174,
192
+ 703,
193
+ 825,
194
+ 786
195
+ ],
196
+ "page_idx": 1
197
+ },
198
+ {
199
+ "type": "text",
200
+ "text": "SSL for Satellite Imagery Self-supervised learning [2, 3, 4, 5, 6] has emerged as a promising approach in remote sensing domains. For instance, [34] and [35] propose incorporating spatially aligned images over time for contrastive self-supervised learning. Despite promising results, these two contrastive learning approaches rely heavily on the quality of positive pairs, which is often hard to control. $\\textcircled { \\lVert { 4 9 } \\rVert }$ combines different sensor channels to generate co-located images that serve as positive pairs. [50, 51, 52] apply off-the-shelf contrastive learning algorithms to satellite images. [52] utilizes image inpainting and transformation prediction as additional pretext tasks. $\\mathbb { \\lVert 5 3 \\rVert }$ leverages geographical knowledge to aid SSL, which, however, can be difficult to obtain as annotations. ",
201
+ "bbox": [
202
+ 173,
203
+ 799,
204
+ 825,
205
+ 911
206
+ ],
207
+ "page_idx": 1
208
+ },
209
+ {
210
+ "type": "text",
211
+ "text": "Masked Autoencoder MAE [1] is a recent powerful self-supervised learning method. Instead of constructing a contrastive objective, it proposes the pretext task of reconstructing masked patches of the input, and largely avoids the need for designing specific data augmentation. Inspired by MAE’s state-of-the-art performance on a wide collection of vision benchmarks $\\mathbb { I I }$ , many follow-up works extend MAE to different data modalities. VideoMAE $\\textcircled { | 5 4 | }$ proposes video tube masking and reconstruction as a pretext task for video analysis. GMAE [55] adapts MAE to the domain of graphs. MultiMAE [56] takes optional inputs of different modalities and accordingly includes other training objectives to facilitate multi-modality learning. However, these works fail to optimally handle temporal and multi-spectral input. VideoMAE requires equally-spaced image frames in the temporal dimension, which is not the case for satellite data given the temporal irregularity and discontinuity in sampling images of a location. In this work, we incorporate temporal and spectral information into a masked autoencoder architecture, and propose a novel self-supervised framework for satellite data. ",
212
+ "bbox": [
213
+ 173,
214
+ 90,
215
+ 826,
216
+ 257
217
+ ],
218
+ "page_idx": 2
219
+ },
220
+ {
221
+ "type": "text",
222
+ "text": "3 Background ",
223
+ "text_level": 1,
224
+ "bbox": [
225
+ 174,
226
+ 277,
227
+ 308,
228
+ 295
229
+ ],
230
+ "page_idx": 2
231
+ },
232
+ {
233
+ "type": "text",
234
+ "text": "Masked Autoencoder The MAE is an autoencoder with asymmetrical encoding and decoding stages $\\mathbb { M }$ . It operates on images $I \\in \\mathbb { R } ^ { C \\times H \\times W }$ , where $H , W$ are the height and width of the image, respectively, and $C$ is the number of channels. The input image $I$ is resized to a sequence of non-overlapping patches, $S \\in \\mathbb { R } ^ { L \\times P ^ { 2 } C }$ , where $P$ is the height and width of the patch, and $L = ( H / P ) \\cdot \\bar { ( W / P ) }$ is the number of patches. Each patch is passed through a patch embedding $f _ { p } : \\mathbb { R } ^ { P ^ { 2 } C } \\mapsto \\mathbb { R } ^ { D }$ to create a sequence $S ^ { \\prime } \\in \\mathbb { R } ^ { L \\times D }$ of embedded patch “tokens”. A fraction $p _ { m }$ of the $L$ tokens are masked and only the remaining $( 1 - p _ { m } ) L$ “visible\" patch tokens are fed to the encoder, a Vision Transformer (ViT) $\\begin{array} { r l r } { { \\bigl [ \\bigl | 3 6 \\bigr | \\bigr ] } } \\end{array}$ with positional embeddings to capture the spatial location of the patch in the image. The decoder is a series of transformer blocks that operates on all $L$ tokens (with positional embeddings added), where the $p _ { m } L$ encoded visible patches are placed in their original sequence position among $( 1 - p _ { m } ) L$ masked patches represented by a learnable mask token. The decoder outputs a reconstructed image $\\hat { I } \\in \\mathbb { R } ^ { C \\times H \\times W }$ , which is compared to the original image using the mean-squared error (MSE) loss, computed per-pixel only on the masked patches $\\mathbb { M }$ . ",
235
+ "bbox": [
236
+ 173,
237
+ 309,
238
+ 825,
239
+ 497
240
+ ],
241
+ "page_idx": 2
242
+ },
243
+ {
244
+ "type": "text",
245
+ "text": "Positional encoding Positional encoding allows transformers to make their learned representations position-aware. In MAE $\\mathbb { M }$ and in many transformers $ { \\mathbb { B } } 7 { \\vert 5 8 \\vert }$ , the positional encoding is: ",
246
+ "bbox": [
247
+ 173,
248
+ 512,
249
+ 823,
250
+ 541
251
+ ],
252
+ "page_idx": 2
253
+ },
254
+ {
255
+ "type": "equation",
256
+ "img_path": "images/ef8d9de2cac7a8c6d9b50121afe1ce8f6b75ea11cd40ce8b117790027e9db5bb.jpg",
257
+ "text": "$$\n\\mathtt { E n c o d e } ( k , 2 i ) = \\sin { \\frac { k } { \\Omega ^ { \\frac { 2 i } { d } } } } , \\mathtt { E n c o d e } ( k , 2 i + 1 ) = \\cos { \\frac { k } { \\Omega ^ { \\frac { 2 i } { d } } } }\n$$",
258
+ "text_format": "latex",
259
+ "bbox": [
260
+ 305,
261
+ 547,
262
+ 691,
263
+ 580
264
+ ],
265
+ "page_idx": 2
266
+ },
267
+ {
268
+ "type": "text",
269
+ "text": "Here, $k$ is the position, $i$ is the index of feature dimension in the encoding, $d$ is the number of possible positions, and $\\Omega$ is a large constant (normally set to 10000). In MAE, position is defined as the index of the patch along the $\\mathbf { X }$ or y axes. Therefore, $k$ ranges from 0 to $H / P$ (or $W / P$ ). The final encoding is generated by concatenating the encodings of the $\\mathbf { X }$ and y coordinates. ",
270
+ "bbox": [
271
+ 174,
272
+ 587,
273
+ 825,
274
+ 643
275
+ ],
276
+ "page_idx": 2
277
+ },
278
+ {
279
+ "type": "text",
280
+ "text": "4 Method ",
281
+ "text_level": 1,
282
+ "bbox": [
283
+ 174,
284
+ 662,
285
+ 271,
286
+ 679
287
+ ],
288
+ "page_idx": 2
289
+ },
290
+ {
291
+ "type": "text",
292
+ "text": "In this section, we describe SatMAE with temporal $( 4 . 1 )$ and multi-spectral $\\textcircled { \\sharp . 2 }$ satellite images. ",
293
+ "bbox": [
294
+ 171,
295
+ 694,
296
+ 810,
297
+ 710
298
+ ],
299
+ "page_idx": 2
300
+ },
301
+ {
302
+ "type": "text",
303
+ "text": "4.1 Temporal SatMAE ",
304
+ "text_level": 1,
305
+ "bbox": [
306
+ 174,
307
+ 726,
308
+ 346,
309
+ 742
310
+ ],
311
+ "page_idx": 2
312
+ },
313
+ {
314
+ "type": "text",
315
+ "text": "We now consider input tensors $I _ { T } \\in \\mathbb { R } ^ { T \\times C \\times H \\times W }$ , where $T$ denotes the number of images in a temporal sequence. In video data, $T$ frames are usually equally spaced. However, temporal satellite imagery rarely has images at regular intervals. More commonly, several snapshots, or versions, of a given location are taken at irregular times. The length and sample frequency of these sequences of satellite images vary drastically over years and across different regions. ",
316
+ "bbox": [
317
+ 173,
318
+ 750,
319
+ 825,
320
+ 821
321
+ ],
322
+ "page_idx": 2
323
+ },
324
+ {
325
+ "type": "text",
326
+ "text": "Naïvely, one could reshape $I _ { T }$ to $I _ { T } ^ { \\prime } \\in \\mathbb { R } ^ { T C \\times H \\times W }$ , effectively concatenating the temporal sequence of images along the spectral (i.e. channel) dimension, and then apply the MAE machinery verbatim. This method poses a few difficulties: (i) the model may be unable to generalise to a temporal ordering different to the one used in pre-training, since it can only understand order through the position of images in the stacked-timeseries (ii) the model cannot reason about the length of time separating two consecutive images in a time sequence, which may be variable when images of a location are sampled at irregular intervals (iii) the model loses access to temporal fine-grained information in deeper layers, as its only direct exposure to encode temporal information is through the initial patch embedding $f _ { p }$ (iv) the model is not temporally-shift invariant (i.e. the model would need to separately learn to detect the same event in two different segments of a temporal sequence). ",
327
+ "bbox": [
328
+ 174,
329
+ 825,
330
+ 825,
331
+ 911
332
+ ],
333
+ "page_idx": 2
334
+ },
335
+ {
336
+ "type": "text",
337
+ "text": "",
338
+ "bbox": [
339
+ 174,
340
+ 90,
341
+ 825,
342
+ 147
343
+ ],
344
+ "page_idx": 3
345
+ },
346
+ {
347
+ "type": "text",
348
+ "text": "To address these challenges and to avoid losing temporal information, we resize the temporal sequence $I _ { T }$ to $S _ { T } \\in \\mathbb { R } ^ { L _ { T } \\times P _ { T } P ^ { 2 } \\bar { C } }$ , where $L _ { T } = L { \\cdot } ( T / P _ { T } ) = ( H / P ) { \\cdot } ( W / P ) { \\cdot } ( T / P _ { T } ) .$ , $P _ { T }$ is the “patch size” in the temporal dimension, and $L$ and $P$ are defined in $\\textcircled { 3 }$ Prior works using transformers for video data suggest using $P _ { T } = 2$ , where each “patch” is a cube of shape $2 \\times 1 6 \\times 1 6$ [54, 59, $\\boxed { 6 0 }$ . Since our data has much shorter temporal sequence lengths $\\mathbb { \\lVert 1 7 \\rVert }$ , we let $P _ { T } = 1$ such that $L _ { T } = L \\cdot T$ . In order to operate on inputs of any temporal order, we re-use the same patch embedding $f _ { p } : \\mathbb { R } ^ { P ^ { 2 } C } \\mapsto \\mathbb { R } ^ { D }$ for each image in the time series, giving us an embedded sequence of tokens $S _ { T } ^ { \\prime } \\in \\mathbb { R } ^ { L _ { T } \\times D }$ . ",
349
+ "bbox": [
350
+ 173,
351
+ 152,
352
+ 826,
353
+ 257
354
+ ],
355
+ "page_idx": 3
356
+ },
357
+ {
358
+ "type": "text",
359
+ "text": "4.1.1 Temporal Encoding ",
360
+ "text_level": 1,
361
+ "bbox": [
362
+ 174,
363
+ 273,
364
+ 362,
365
+ 290
366
+ ],
367
+ "page_idx": 3
368
+ },
369
+ {
370
+ "type": "text",
371
+ "text": "For each embedded token in the $L _ { T }$ length sequence, we need to ensure the model retains information about its spatial and temporal position. As shown in many prior works [34, 35], the timestamp of a satellite image is useful for many pre-training or downstream vision tasks. We propose a temporal encoding scheme compatible with the masked autoencoder architecture by treating the temporal dimension similarly to the positional dimensions (see 3). ",
372
+ "bbox": [
373
+ 449,
374
+ 299,
375
+ 825,
376
+ 411
377
+ ],
378
+ "page_idx": 3
379
+ },
380
+ {
381
+ "type": "image",
382
+ "img_path": "images/cb0f9e60034b1e532ce7d6f68d0f0bab0b21a88d8131c623c5ba4fe982e598b3.jpg",
383
+ "image_caption": [
384
+ "Figure 2: Top: Encoding each temporal patch with a shared patch embedding $f _ { p }$ . Bottom: Encoding each spectral patch with a different patch embedding $f _ { p _ { j } }$ for each group $j$ . "
385
+ ],
386
+ "image_footnote": [],
387
+ "bbox": [
388
+ 179,
389
+ 320,
390
+ 426,
391
+ 507
392
+ ],
393
+ "page_idx": 3
394
+ },
395
+ {
396
+ "type": "text",
397
+ "text": "The timestamp of a satellite image is represented as “yearmonth-day-hour-minute-second”. Instead of passing the entire numerized timestamp into a feature encoder, we propose only keeping the useful parts. Intuitively, the day, minute, and second should be unrelated to the visual appearance of a region. Thus, including these components in the temporal encoding may not be beneficial, and can even be detrimental. In contrast, a landscape may evolve over years due to weather, geology, and human activity. The month reflects season and climate, and the hour reflects daylight and temperature. ",
398
+ "bbox": [
399
+ 449,
400
+ 416,
401
+ 825,
402
+ 569
403
+ ],
404
+ "page_idx": 3
405
+ },
406
+ {
407
+ "type": "text",
408
+ "text": "Then, the temporal encoding is formulated as: ",
409
+ "bbox": [
410
+ 450,
411
+ 575,
412
+ 750,
413
+ 589
414
+ ],
415
+ "page_idx": 3
416
+ },
417
+ {
418
+ "type": "equation",
419
+ "img_path": "images/a77e8a526efb24f9dd9df6930aa967471dda3dffa1ddf7d55e601270680a3af9.jpg",
420
+ "text": "$$\nt _ { k , i } = \\mathrm { C O N C A T } [ \\mathrm { E n c o d e } ( k _ { \\mathrm { y e a r } } , i ) , \\mathrm { E n c o d e } ( k _ { \\mathrm { m o n t h } } , i ) , \\mathrm { E n c o d e } ( k _ { \\mathrm { h o u r } } , i ) ]\n$$",
421
+ "text_format": "latex",
422
+ "bbox": [
423
+ 263,
424
+ 598,
425
+ 735,
426
+ 616
427
+ ],
428
+ "page_idx": 3
429
+ },
430
+ {
431
+ "type": "text",
432
+ "text": "And the final encoding is generated by concatenating the temporal encoding to the positional encoding defined in $3$ such that the total length of the encoding is $D$ . ",
433
+ "bbox": [
434
+ 173,
435
+ 625,
436
+ 826,
437
+ 654
438
+ ],
439
+ "page_idx": 3
440
+ },
441
+ {
442
+ "type": "text",
443
+ "text": "4.1.2 Masking Strategies ",
444
+ "text_level": 1,
445
+ "bbox": [
446
+ 174,
447
+ 670,
448
+ 357,
449
+ 685
450
+ ],
451
+ "page_idx": 3
452
+ },
453
+ {
454
+ "type": "text",
455
+ "text": "With an additional temporal dimension, masking a subset of the $L _ { T }$ tokens needs to be treated with care. As seen in figure ${ \\bar { 3 } } ,$ there are different ways to mask a temporal series of satellite images. ",
456
+ "bbox": [
457
+ 176,
458
+ 694,
459
+ 823,
460
+ 724
461
+ ],
462
+ "page_idx": 3
463
+ },
464
+ {
465
+ "type": "text",
466
+ "text": "Consistent Masking Each image is “patchified” separately, but the masked regions are consistent across all images (fig. 3a). This approach is also used in VideoMAE $\\pmb { \\Vert 5 4 \\Vert }$ , with video input. ",
467
+ "bbox": [
468
+ 176,
469
+ 741,
470
+ 823,
471
+ 770
472
+ ],
473
+ "page_idx": 3
474
+ },
475
+ {
476
+ "type": "text",
477
+ "text": "Independent Masking Each image is “patchified” separately, and masked regions may not be the same across every image. Instead, a fraction $p _ { m }$ of the full sequence of all patch tokens are masked. Another variant is to independently mask the regions of each image, but keep the ratio $p _ { m }$ of masked regions fixed per image. Both variants are equivalent in expectation. Effectively, the model may look at unmasked values of a region that is masked in one image but not in others. This setting may lead to an easier task for video data since the model can “cheat” and exploit temporal redundancy in videos with high framerates [54]. However, we argue that this form of “cheating” is less feasible in temporal satellite imagery, given the strong impact of seasonal variation and changing human activity over periods of time and the much larger time deltas between temporally consecutive images (see fig. 3a). ",
478
+ "bbox": [
479
+ 174,
480
+ 786,
481
+ 825,
482
+ 911
483
+ ],
484
+ "page_idx": 3
485
+ },
486
+ {
487
+ "type": "image",
488
+ "img_path": "images/d608cfc2e0783e553d8c8494f39903170d00a320f6eb1394aa05d96ed583a8e8.jpg",
489
+ "image_caption": [
490
+ "Figure 3: 3a Temporal masking: For images in a timeseries, we can choose to keep a patch fully visible or fully masked across time (consistent masking), or independently mask all patches (independent masking). In both cases, a fraction $p _ { m }$ patches are masked. Here, $T = 3$ , and the leftmost column orders the temporal sequence according to the timestamp features. For example, “y-12, m-12, h-15” is 12 years from the minimum year (2002), the zero-indexed month 2, and the 15th hour of the day; i.e., roughly 2014, March, 15:00. 3b Spectral Masking: The same masking strategies are adapted to groups of the 13 spectral bands in Sentinel-2 images. "
491
+ ],
492
+ "image_footnote": [],
493
+ "bbox": [
494
+ 200,
495
+ 90,
496
+ 794,
497
+ 303
498
+ ],
499
+ "page_idx": 4
500
+ },
501
+ {
502
+ "type": "text",
503
+ "text": "Independent Masking $^ +$ Inconsistent Cropping During data pre-processing, we can crop square regions for input inconsistently so that images in the same temporal sequence may be spatiallyunaligned. This strategy may help the model learn better representations as it may learn to align images in the sequence across the spatial and temporal dimensions. ",
504
+ "bbox": [
505
+ 174,
506
+ 414,
507
+ 825,
508
+ 469
509
+ ],
510
+ "page_idx": 4
511
+ },
512
+ {
513
+ "type": "text",
514
+ "text": "4.2 Multi-spectral SatMAE ",
515
+ "text_level": 1,
516
+ "bbox": [
517
+ 174,
518
+ 486,
519
+ 379,
520
+ 501
521
+ ],
522
+ "page_idx": 4
523
+ },
524
+ {
525
+ "type": "text",
526
+ "text": "While MAE does operate on images $I \\in \\mathbb { R } ^ { C \\times H \\times W }$ , usually $C = 3$ for RGB images. Satellite data, on the other hand, can often have multiple spectral bands. For example, Sentinel-2 imagery has $C = 1 3$ bands of $1 0 \\mathrm { m }$ , $2 0 \\mathrm { m }$ and $6 0 \\mathrm { m }$ spatial resolution, each of different wavelengths (see A.2.2) Below, we discuss and later experimentally compare various ways to encode spectral information. ",
527
+ "bbox": [
528
+ 174,
529
+ 510,
530
+ 825,
531
+ 568
532
+ ],
533
+ "page_idx": 4
534
+ },
535
+ {
536
+ "type": "text",
537
+ "text": "Stack Channels The sequence of patches $S \\in \\mathbb { R } ^ { L \\times P ^ { 2 } C }$ is embedded to a sequence of tokens $S ^ { \\prime } \\in \\mathbb { R } ^ { L \\times D }$ , thus treating the multi-band image as is. We denote this method SatMAE $^ +$ Stack. ",
538
+ "bbox": [
539
+ 174,
540
+ 582,
541
+ 820,
542
+ 613
543
+ ],
544
+ "page_idx": 4
545
+ },
546
+ {
547
+ "type": "text",
548
+ "text": "Group Channels There are limitations to naively stacking the spectral information, especially that a single convolutional patch embedding may be insufficient to fully capture fine-grained information present in multiple bands of different wavelengths and spatial resolution. We would like the model to preserve information about the different bands through the encoding and decoding stages. ",
549
+ "bbox": [
550
+ 174,
551
+ 626,
552
+ 825,
553
+ 683
554
+ ],
555
+ "page_idx": 4
556
+ },
557
+ {
558
+ "type": "text",
559
+ "text": "To address this limitation, we propose grouping subsets of spectral bands. Given $C$ channels, we form $G$ groups $g _ { 1 } , g _ { 2 } , \\dotsc , g _ { G }$ such that $g _ { 1 } + g _ { 2 } + \\cdot \\cdot \\cdot + g _ { G } = C$ . This is analogous to slicing the image $I$ in the channel dimension, creating images $I _ { 1 } , \\ldots , I _ { G }$ , where $I _ { j } \\in \\mathbb { R } ^ { g _ { j } \\times H \\times W }$ . We use a separate patch embedding $f _ { p _ { j } } : \\mathbb { R } ^ { P ^ { 2 } g _ { j } } \\mapsto \\mathbb { R } ^ { D }$ for each group $j$ , thus allowing the model to best represent each possibly different group of channels as token embeddings. Therefore, each group $j$ is first resized from $I _ { j } \\in \\mathbb { R } ^ { g _ { j } \\times H \\times W }$ to $\\overline { { S } } _ { j } \\in \\mathbb { R } ^ { L \\times P ^ { 2 } g _ { j } }$ , and then each patch is embedded with $f _ { p _ { j } }$ to produce a sequence of embedded tokens $S _ { j } ^ { \\prime } \\in \\mathbb { R } ^ { L \\times D }$ . The sequences $S _ { 1 } ^ { \\prime } , \\ldots , S _ { G } ^ { \\prime }$ are concatenated to produce the final set of tokens S0 RGL⇥D. ",
560
+ "bbox": [
561
+ 173,
562
+ 689,
563
+ 825,
564
+ 811
565
+ ],
566
+ "page_idx": 4
567
+ },
568
+ {
569
+ "type": "text",
570
+ "text": "Spectral Encoding Since the tokens in $S ^ { \\prime }$ correspond to a patch location $( m , n )$ in the input image and a group of channels $g _ { j }$ , we include an encoding for the group index $k _ { g }$ similar to $\\underline { { \\mathsf { R . 1 . 1 } } }$ ",
571
+ "bbox": [
572
+ 173,
573
+ 825,
574
+ 823,
575
+ 854
576
+ ],
577
+ "page_idx": 4
578
+ },
579
+ {
580
+ "type": "equation",
581
+ "img_path": "images/46a3ce435e64eca90852c300db140687a96c32f4e4b1e703a0481332e45453e4.jpg",
582
+ "text": "$$\ng _ { k _ { g } , i } = { \\tt E n c o d e } ( k _ { g } , i )\n$$",
583
+ "text_format": "latex",
584
+ "bbox": [
585
+ 424,
586
+ 861,
587
+ 573,
588
+ 878
589
+ ],
590
+ "page_idx": 4
591
+ },
592
+ {
593
+ "type": "text",
594
+ "text": "Note that this encoding simply depends on a user-devised channel grouping, and differs from eq. $( 2 )$ since additional metadata for the imagery, like its date, is not needed. The final encoding is a ",
595
+ "bbox": [
596
+ 173,
597
+ 883,
598
+ 825,
599
+ 911
600
+ ],
601
+ "page_idx": 4
602
+ },
603
+ {
604
+ "type": "text",
605
+ "text": "concatenation of the positional $x _ { k , i } , y _ { k , i }$ and the spectral encoding ${ g } _ { k , i }$ such that the total dimension is $D$ (see fig. $2 )$ . This positional encoding is added to $S ^ { \\prime }$ before inputting it to the encoder. We denote the combined setting of grouping channels and using a group encoding as SatMAE $+$ Group. ",
606
+ "bbox": [
607
+ 173,
608
+ 92,
609
+ 825,
610
+ 133
611
+ ],
612
+ "page_idx": 5
613
+ },
614
+ {
615
+ "type": "text",
616
+ "text": "Masking Strategies We consider consistent masking (denoted SatMAE $^ +$ Group+CM) and independent masking (SatMAE $^ +$ Group+IM) as defined in section 4.1.2 and as visualized in fig. 3b. ",
617
+ "bbox": [
618
+ 173,
619
+ 148,
620
+ 825,
621
+ 178
622
+ ],
623
+ "page_idx": 5
624
+ },
625
+ {
626
+ "type": "text",
627
+ "text": "5 Experiments ",
628
+ "text_level": 1,
629
+ "bbox": [
630
+ 174,
631
+ 196,
632
+ 312,
633
+ 213
634
+ ],
635
+ "page_idx": 5
636
+ },
637
+ {
638
+ "type": "text",
639
+ "text": "In this section, we first introduce the datasets we considered, including a new multi-spectral remote sensing image dataset for downstream task evaluation $( 5 . 1 )$ . We then present our results on benchmark datasets $( 5 . { \\overset { \\smile } { 2 } } , 5 . 3 , 5 . 4 )$ and various remote sensing transfer-learning and downstream tasks $\\underline { { \\boldsymbol { \\left. 5 . 5 \\right. } } }$ For all experiments, we compare with the current state-of-the-art methods $\\mathbb { 1 3 4 } , \\bigstar \\bigstar \\bigstar \\bigstar$ and with supervised learning from scratch using the ViT backbone of SatMAE. In summary, our approach demonstrates strong performance on all the tasks we considered, yielding improvements over previous state-of-theart techniques by up to $6 \\%$ on supervised learning benchmarks, and up to $14 \\%$ on remote sensing transfer-learning downstream remote sensing tasks. ",
640
+ "bbox": [
641
+ 174,
642
+ 228,
643
+ 825,
644
+ 339
645
+ ],
646
+ "page_idx": 5
647
+ },
648
+ {
649
+ "type": "text",
650
+ "text": "5.1 Datasets for Pre-training ",
651
+ "text_level": 1,
652
+ "bbox": [
653
+ 174,
654
+ 356,
655
+ 387,
656
+ 371
657
+ ],
658
+ "page_idx": 5
659
+ },
660
+ {
661
+ "type": "text",
662
+ "text": "fMoW RGB Functional Map of the World (fMoW) $ { \\mathbb { I } } ^ { [ 1 2 ] }$ is a dataset of high-resolution satellite image time series across the world, with a task of classification among 62 categories. ",
663
+ "bbox": [
664
+ 173,
665
+ 381,
666
+ 823,
667
+ 410
668
+ ],
669
+ "page_idx": 5
670
+ },
671
+ {
672
+ "type": "text",
673
+ "text": "fMoW Sentinel We create a new dataset based on the fMoW RGB dataset. We collect all 13 frequency bands provided by Sentinel-2 (B1-12 and B8A) for the original fMoW locations, at some of the same times as fMoW images plus some extra times, for a total of 712,874 training images, 84,939 validation images, and 84,966 test images. More details are included in appendix A.1. ",
674
+ "bbox": [
675
+ 174,
676
+ 424,
677
+ 825,
678
+ 481
679
+ ],
680
+ "page_idx": 5
681
+ },
682
+ {
683
+ "type": "text",
684
+ "text": "5.2 fMoW RGB (non-temporal) ",
685
+ "text_level": 1,
686
+ "bbox": [
687
+ 176,
688
+ 497,
689
+ 406,
690
+ 512
691
+ ],
692
+ "page_idx": 5
693
+ },
694
+ {
695
+ "type": "table",
696
+ "img_path": "images/af04b44c0b811cf62e5d4870dc054766b8e429538b0bcf615850aebdec3a56b3.jpg",
697
+ "table_caption": [
698
+ "Table 1: Top 1 Accuracy on fMoW classification. Frozen: only performing linear classification on frozen features of the pre-trained model. Finetune: end-to-end finetuning the whole model. \\* is training from scratch, and $\\dagger$ is using supervised-learning ImageNet weights, and $^ \\ddag$ is SSL MAE ImageNet weights. "
699
+ ],
700
+ "table_footnote": [],
701
+ "table_body": "<table><tr><td>Method</td><td>Backbone</td><td>Frozen/Finetune</td></tr><tr><td>Sup.*</td><td>ResNet50</td><td>-/69.05</td></tr><tr><td>Sup.t</td><td>ResNet50</td><td>-/69.07</td></tr><tr><td>GASSL [B4]</td><td>ResNet50</td><td>68.32/71.55</td></tr><tr><td>Sup.*</td><td>ViT-Large</td><td>-/62.48</td></tr><tr><td>Sup.t</td><td>ViT-Large</td><td>-/75.70</td></tr><tr><td>Sup.t</td><td>ViT-Large</td><td>-/76.91</td></tr><tr><td>SatMAE</td><td>ViT-Large</td><td>65.94/77.84</td></tr></table>",
702
+ "bbox": [
703
+ 178,
704
+ 540,
705
+ 496,
706
+ 661
707
+ ],
708
+ "page_idx": 5
709
+ },
710
+ {
711
+ "type": "text",
712
+ "text": "In this section, we perform experiments on fMoW single image classification task. Following $\\bar { \\big [ } \\bar { 3 4 } \\bar { \\big ] }$ , we report both the performance of linear probing and finetuning setting. Table 1 shows that compared to the previous stateof-the-art self-supervised method using a contrastive momentum encoding approach [34, 3], our SatMAE achieved a $6 . 2 9 \\%$ improvement in top 1 classification accuracy. Interestingly, without SatMAE pre-training the ViT-large model could only reach $6 2 . 4 8 \\%$ at convergence after 50 epochs of finetuning compared to $6 9 . 0 5 \\%$ achieved by training a ResNet-50 model from scratch. This is likely because the ViT $[ \\beta 6 ]$ backbone is harder to finetune from scratch than ResNet50 [61], which makes the pre-trained model more valuable. ",
713
+ "bbox": [
714
+ 513,
715
+ 523,
716
+ 825,
717
+ 757
718
+ ],
719
+ "page_idx": 5
720
+ },
721
+ {
722
+ "type": "text",
723
+ "text": "5.3 fMoW RGB (temporal) ",
724
+ "text_level": 1,
725
+ "bbox": [
726
+ 176,
727
+ 775,
728
+ 375,
729
+ 790
730
+ ],
731
+ "page_idx": 5
732
+ },
733
+ {
734
+ "type": "text",
735
+ "text": "Main experiments We perform image-sequence classification on the temporal version of fMoW RGB to evaluate our temporal SatMAE. The temporal fMoW consists of co-located image sequences with a length of 3. As seen in table 2, SatMAE surpasses the previous state-of-the-art by $4 . 4 8 \\%$ and improves the non-temporal result by $2 . 0 6 \\%$ in top 1 classification accuracy. We also outperform UTAE [48], a SITS state-of-the-art, by $18 \\%$ . We can observe from rows 5-8 that this gain is not from the larger model to handle sequences of data. Naively stacking the image sequences in the channel dimension performs even worse than the non-temporal SatMAE. Again, SatMAE pre-training is crucial for ViT to outperform ResNet50. Training details are in appendix A.3.2. ",
736
+ "bbox": [
737
+ 173,
738
+ 800,
739
+ 825,
740
+ 911
741
+ ],
742
+ "page_idx": 5
743
+ },
744
+ {
745
+ "type": "table",
746
+ "img_path": "images/cc22ba5a436c0f5dc12fca930307f22ab51c7259944bbfa4ec393f23fdc7ebce.jpg",
747
+ "table_caption": [
748
+ "Table 2: Classification results on the temporal fMoW RGB dataset. \\* means finetuning from scratch. $\\parallel$ means copying the input image 3 times instead of using temporal sequences as input. SatMAE $^ +$ Stack here means stacking the image sequence along the channel space. "
749
+ ],
750
+ "table_footnote": [],
751
+ "table_body": "<table><tr><td>Method</td><td>Backbone</td><td>Top Acc. (1/5)</td></tr><tr><td>Sup.*</td><td>ResNet50</td><td>73.24/-</td></tr><tr><td>SeCo [5</td><td>ResNet50</td><td>66.80/-</td></tr><tr><td>GASSL [34]</td><td>ResNet50</td><td>74.11/-</td></tr><tr><td>UTAE [48]</td><td>U-Net</td><td>61.59/86.45</td></tr><tr><td>Sup.*</td><td>ViT-Large</td><td>61.89/84.23</td></tr><tr><td>SatMAE+Stack</td><td>ViT-Large</td><td>75.85/88.68</td></tr><tr><td>MAE+Test Aug.</td><td>ViT-Large</td><td>78.90/93.31</td></tr><tr><td>MAE|</td><td>ViT-Large</td><td>76.78/92.01</td></tr><tr><td>SatMAE</td><td>ViT-Large</td><td>81.49/93.26</td></tr></table>",
752
+ "bbox": [
753
+ 178,
754
+ 101,
755
+ 490,
756
+ 239
757
+ ],
758
+ "page_idx": 6
759
+ },
760
+ {
761
+ "type": "table",
762
+ "img_path": "images/bb61632460a944ff09f615c6410585e2f0de9d90ac5f22ea47bf29f791ebfe33.jpg",
763
+ "table_caption": [
764
+ "Table 3: Top 1 & Top 5 Accuracy on the fMoW Sentinel validation set. The different initializations are: \\* from scratch, $\\dagger$ MAE ImageNet weights, $^ \\ddag$ supervised ImageNet weights, $\\ S$ SatMAE fMoW RGB weights. Other rows use fMoW Sentinel for pre-training. The last row includes additional data augmentations (5.4). "
765
+ ],
766
+ "table_footnote": [],
767
+ "table_body": "<table><tr><td>Method</td><td>Backbone</td><td>Top Acc. (1/5)</td></tr><tr><td>Sup. Learning*</td><td>ResNet152</td><td>49.12/75.73</td></tr><tr><td>Sup. Learningt</td><td>ResNet152</td><td>54.46/78.99</td></tr><tr><td>MoCo-v3</td><td>ViT-Base</td><td>50.45/76.37</td></tr><tr><td>MoCo-v3+Group</td><td>ViT-Base</td><td>51.33/75.68</td></tr><tr><td>SatMAE+Group*</td><td>ViT-Large</td><td>53.03/77.14</td></tr><tr><td>SatMAE+Groupt</td><td>ViT-Large</td><td>51.61/77.26</td></tr><tr><td>SatMAE+Groupt</td><td>ViT-Large</td><td>47.57/72.26</td></tr><tr><td>SatMAE+GroupS</td><td>ViT-Large</td><td>49.49/76.30</td></tr><tr><td>SatMAE+Stack</td><td>ViT-Large</td><td>57.37/81.63</td></tr><tr><td>SatMAE+Group+IM</td><td>ViT-Large</td><td>59.30/82.81</td></tr><tr><td>SatMAE+Group+IM</td><td>ViT-Large</td><td>61.48/85.17</td></tr></table>",
768
+ "bbox": [
769
+ 506,
770
+ 88,
771
+ 820,
772
+ 238
773
+ ],
774
+ "page_idx": 6
775
+ },
776
+ {
777
+ "type": "table",
778
+ "img_path": "images/00b6b3da154c875948e91871e6a287ec80c7fb21d24585d46d9e3819f6d51d7f.jpg",
779
+ "table_caption": [
780
+ "Table 4: Ablation studies on different components of temporal SatMAE on the temporal fMoW classification task. The first column is whether using temporal encoding, the second is whether using independent masking, the third is whether cropping consistently, and the last one is whether applying test-time augmentation. "
781
+ ],
782
+ "table_footnote": [],
783
+ "table_body": "<table><tr><td>Temp. Enc.</td><td>Indep. Mask.</td><td>Cons. Crop.</td><td>Test Aug.</td><td>Top 1 Acc.</td></tr><tr><td></td><td>√</td><td>√</td><td></td><td>78.07</td></tr><tr><td>√</td><td></td><td>√</td><td></td><td>78.45</td></tr><tr><td>√</td><td>√</td><td></td><td></td><td>79.90</td></tr><tr><td>√</td><td>√</td><td>√</td><td></td><td>79.69</td></tr><tr><td>√</td><td>√</td><td>√</td><td>√</td><td>81.49</td></tr></table>",
784
+ "bbox": [
785
+ 178,
786
+ 332,
787
+ 491,
788
+ 434
789
+ ],
790
+ "page_idx": 6
791
+ },
792
+ {
793
+ "type": "table",
794
+ "img_path": "images/4c57e38e9b41956dd760a26667cd8d6d89f3f52d850b4e2a4a2edd27ba0457ce.jpg",
795
+ "table_caption": [
796
+ "Table 5: Ablation studies on spectral SatMAE on fMoW-Sentinel. The first column denotes using ViTBase or ViT-Large. The second column is the grouping strategy (see 5.4). The third column denotes independent or consistent masking. The last column is whether the spectral group encoding 3 is used. "
797
+ ],
798
+ "table_footnote": [],
799
+ "table_body": "<table><tr><td>Back.</td><td>Group Strat.</td><td>Indp. Mask.</td><td>Spec. Enc.</td><td>Top 1 Acc.</td></tr><tr><td>Base</td><td>X</td><td>√</td><td>√</td><td>59.11</td></tr><tr><td>Large</td><td>X</td><td>√</td><td></td><td>58.87</td></tr><tr><td>Large</td><td>X</td><td></td><td>√</td><td>57.76</td></tr><tr><td>Large</td><td>H</td><td>√</td><td>√</td><td>57.78</td></tr><tr><td>Large</td><td>R</td><td>√</td><td>√</td><td>58.76</td></tr><tr><td>Large</td><td>X</td><td>√</td><td>√</td><td>59.30</td></tr></table>",
800
+ "bbox": [
801
+ 503,
802
+ 327,
803
+ 816,
804
+ 439
805
+ ],
806
+ "page_idx": 6
807
+ },
808
+ {
809
+ "type": "text",
810
+ "text": "Ablation studies Table 4 provides a comprehensive ablation study on the components of temporal SatMAE. We see that improved performance is mainly due to the temporal encoding and adopting independent masking rather than the consistent masking strategy suggested in VideoMAE $\\pmb { \\| \\overbrace { 5 4 } } \\big |$ . Interestingly, consistent cropping slightly decreases performance, indicating that the model does not rely on perfectly spatially-aligned image sequences. In addition, using test-time augmentations similar to $\\textcircled { 1 3 4 } ]$ is beneficial. Further ablations on mask ratio $p _ { m }$ and patch size $P$ are in appendix A.4. ",
811
+ "bbox": [
812
+ 174,
813
+ 550,
814
+ 825,
815
+ 635
816
+ ],
817
+ "page_idx": 6
818
+ },
819
+ {
820
+ "type": "text",
821
+ "text": "5.4 fMoW Sentinel (Multi-spectral) ",
822
+ "text_level": 1,
823
+ "bbox": [
824
+ 176,
825
+ 650,
826
+ 431,
827
+ 665
828
+ ],
829
+ "page_idx": 6
830
+ },
831
+ {
832
+ "type": "text",
833
+ "text": "In this section, we pre-train and finetune SatMAE on the image classification task of the fMoWSentinel dataset. We pre-train SatMAE $^ +$ Stack $4 . 2$ and investigate SatMAE+Group+CM 4.1.2 and $\\mathrm { S a t M A E + G r o u p + I M \\bar { 4 } . 1 . 2 } ,$ (see 4.2, 4.2). The full models are then finetuned on the fMoW-Sentinel image classification task. For comparison, we also finetune the ResNet-152 model [61] from scratch and from a supervised ImageNet initialization. We pick the largest model, ResNet-152, for fairer comparison with ViTs. We also include MoCo-v3 [62, 3], a popular SSL method. Given the differences in applying RGB-image augmentations to satellite imagery, we implement two versions: (i) MoCo-v3: we apply all of the same augmentations, except random grayscale and solarize, to create 2 views of the 10-channel image. (ii) MoCo-v3+Group: we split the 10 bands into two groups suggested by $\\pmb { \\mathbb { D } } \\mathbf { l }$ , and apply augmentations to each to create a positive pair of two 5-channel images. ",
834
+ "bbox": [
835
+ 173,
836
+ 674,
837
+ 826,
838
+ 814
839
+ ],
840
+ "page_idx": 6
841
+ },
842
+ {
843
+ "type": "text",
844
+ "text": "Model configuration As not all of the 13 Sentinel-2 bands may be useful, in our experiments we drop bands B1, B9 and B10, which correspond to a spatial resolution of $6 0 \\mathrm { m }$ . Of the remaining 10 bands, we form three groups: (i) RGB $^ +$ NIR: B2, B3, B4, B8 (ii) Red Edge: B5, B6, B7, B8A (iii) SWIR: B11, B12. We choose this grouping to ensure each group has bands of the same spatial resolution and similar wavelength (see A.2.2, A.6) Only the last row of table $\\textcircled { 3 }$ includes additional data augmentations used during finetuning as in [1] See A.3.3 for pre-training and finetuning details. ",
845
+ "bbox": [
846
+ 174,
847
+ 827,
848
+ 825,
849
+ 912
850
+ ],
851
+ "page_idx": 6
852
+ },
853
+ {
854
+ "type": "table",
855
+ "img_path": "images/73d2668701c8eb85db7305d53a6bdee18a1647f4324e644063d023605bd69723.jpg",
856
+ "table_caption": [],
857
+ "table_footnote": [
858
+ "Table 6: NAIP land cover classification results. "
859
+ ],
860
+ "table_body": "<table><tr><td>Method</td><td>Backbone</td><td>Top 1 Acc.</td></tr><tr><td>Sup. (Scratch)</td><td>ResNet50</td><td>54.46</td></tr><tr><td>GASSL B4]</td><td>ResNet50</td><td>57.63</td></tr><tr><td>Sup. (Scratch)</td><td>ViT-Large</td><td>69.65</td></tr><tr><td>SatMAE</td><td>ViT-Large</td><td>71.77</td></tr></table>",
861
+ "bbox": [
862
+ 178,
863
+ 88,
864
+ 490,
865
+ 170
866
+ ],
867
+ "page_idx": 7
868
+ },
869
+ {
870
+ "type": "table",
871
+ "img_path": "images/d73b7a324e6167a542d0010d94ded991cb35004b4d9dc9489283cc638b8b4b18.jpg",
872
+ "table_caption": [],
873
+ "table_footnote": [
874
+ "Table 7: SpaceNet v1 building segmentation results. "
875
+ ],
876
+ "table_body": "<table><tr><td>Method</td><td>Backbone mIoU</td></tr><tr><td>Sup. (Scratch)</td><td>ResNet50 75.57</td></tr><tr><td>GASSL [B4]</td><td>ResNet50 78.51</td></tr><tr><td>Sup. (Scratch)</td><td>ViT-Large 74.71</td></tr><tr><td>SatMAE</td><td>ViT-Large 78.07</td></tr></table>",
877
+ "bbox": [
878
+ 508,
879
+ 90,
880
+ 820,
881
+ 169
882
+ ],
883
+ "page_idx": 7
884
+ },
885
+ {
886
+ "type": "table",
887
+ "img_path": "images/11d7d4a718c1a1d1df931f7caa300c7b7c85f21a9a3c4fa1cf4aada502ed334e.jpg",
888
+ "table_caption": [],
889
+ "table_footnote": [
890
+ "Table 8: EuroSAT land cover classification results. \\* means we only use the RGB channels of the data. "
891
+ ],
892
+ "table_body": "<table><tr><td>Method</td><td>Backbone</td><td>Top1 Acc.</td></tr><tr><td>Sup. (Scratch)</td><td>ResNet18</td><td>63.21</td></tr><tr><td>Sup. (IN init.)</td><td>ResNet18</td><td>86.44</td></tr><tr><td>GASSL [34]</td><td>ResNet18</td><td>89.51</td></tr><tr><td>SeCo [35]</td><td>ResNet18</td><td>93.14</td></tr><tr><td>SatMAE*</td><td>ViT-Large</td><td>95.74</td></tr><tr><td>SatMAE</td><td>ViT-Large</td><td>98.94</td></tr><tr><td>SatMAE+Group+IM</td><td>ViT-Large</td><td>98.98</td></tr></table>",
893
+ "bbox": [
894
+ 178,
895
+ 198,
896
+ 490,
897
+ 310
898
+ ],
899
+ "page_idx": 7
900
+ },
901
+ {
902
+ "type": "table",
903
+ "img_path": "images/71c9c94aa2a70ee8054a8ae9964af353e8fb290e4603881f7e59abd1003156a3.jpg",
904
+ "table_caption": [],
905
+ "table_footnote": [
906
+ "Table 9: BigEarthNet multi-label classification results. Following [35], we use mean Average Precision (mAP) as the metric, and use a newer set of class labels. "
907
+ ],
908
+ "table_body": "<table><tr><td>Method</td><td>Backbone</td><td>mAP</td></tr><tr><td>Sup. (Scratch)</td><td>ResNet50</td><td>69.49</td></tr><tr><td>Sup. (IN init.)</td><td>ResNet50</td><td>80.04</td></tr><tr><td>GASSL [34</td><td>ResNet50</td><td>80.20</td></tr><tr><td>SeCo[ B5</td><td>ResNet50</td><td>82.62</td></tr><tr><td>Sup. (Scratch)</td><td>ViT-Large</td><td>80.07</td></tr><tr><td>SatMAE</td><td>ViT-Large</td><td>82.13</td></tr></table>",
909
+ "bbox": [
910
+ 508,
911
+ 194,
912
+ 820,
913
+ 301
914
+ ],
915
+ "page_idx": 7
916
+ },
917
+ {
918
+ "type": "text",
919
+ "text": "Results We present results in table $3 .$ Our method SatMAE $+$ Group $\\mathbf { \\Gamma } + \\mathrm { I M }$ achieves the highest accuracy, outperforming supervised training from scratch $( \\uparrow 6 . 2 7 \\% )$ and ImageNet-initialized backbones $( \\uparrow 4 . 8 4 \\% )$ . ImageNet initializations may be less useful than in fMoW-RGB given the larger distributional shift to multi-spectral input data. We also note the effectiveness of grouping channels over processing all bands only at the patch embedding level (i.e. SatMAE $^ +$ Stack). ",
920
+ "bbox": [
921
+ 173,
922
+ 378,
923
+ 825,
924
+ 449
925
+ ],
926
+ "page_idx": 7
927
+ },
928
+ {
929
+ "type": "text",
930
+ "text": "Ablation Studies We investigate the design of SatMAE for multi-spectral data in table $\\underline { { \\boldsymbol { \\mathsf { F } } } } ,$ For grouping strategy, we implement alternate band groups to test the hypothesis that grouping bands based on wavelength and resolution is beneficial. X represents the band groups in ${ 5 . 4 } .$ H represents splitting the 10 bands into two halves, {(2,3,4,5,6), (7,8,8A,11,12)}. R represents a random split into three groups {(6,5,11,12), (8A,4,8,3), (7,2)}, reflecting the same group sizes as X. As seen, the choice of band groups does influence performance, yielding a gain of about $0 . 6 \\%$ . Moreover, ViT-Base performs strongly, suggesting that SatMAE is the reason for improved performance rather than the number of parameters in ViT. Interestingly, independent masking performs the best, which prompts the model to “peek” at unmasked band groups to reconstruct the same region in a masked band group. ",
931
+ "bbox": [
932
+ 173,
933
+ 467,
934
+ 825,
935
+ 592
936
+ ],
937
+ "page_idx": 7
938
+ },
939
+ {
940
+ "type": "text",
941
+ "text": "We also include further experiments on the length of pre-training $( \\mathrm { s e e } \\mathbf { A } . 3 . 3 )$ , the impact of mask ratio $p _ { m }$ and patch size $P$ (see A.5), and the usefulness of the 13 Sentinel-2 spectral bands (see A.6). ",
942
+ "bbox": [
943
+ 174,
944
+ 598,
945
+ 825,
946
+ 627
947
+ ],
948
+ "page_idx": 7
949
+ },
950
+ {
951
+ "type": "text",
952
+ "text": "5.5 Transfer Learning Experiments ",
953
+ "text_level": 1,
954
+ "bbox": [
955
+ 174,
956
+ 646,
957
+ 434,
958
+ 661
959
+ ],
960
+ "page_idx": 7
961
+ },
962
+ {
963
+ "type": "text",
964
+ "text": "Now, we finetune our pre-trained SatMAE on downstream tasks on remote-sensing datasets, including land cover classification $\\underline { { \\boldsymbol { \\mathfrak { S . 5 } } } } \\flat$ , multi-label classification $( 5 . 5 )$ and building segmentation $\\underline { { \\widehat { ( 5 . 5 ) } } }$ Finetuning details are included in A.7, A.8, A.9, A.10. ",
965
+ "bbox": [
966
+ 174,
967
+ 672,
968
+ 825,
969
+ 717
970
+ ],
971
+ "page_idx": 7
972
+ },
973
+ {
974
+ "type": "text",
975
+ "text": "Land Cover Classification We perform transfer learning experiments on land cover classification using the NAIP and EuroSAT $\\pmb { \\mathbb { \\left| \\overline { { 6 3 } } \\right\\| } }$ dataset. NAIP consists of $\\mathrm { R G B + C I R }$ images of 66 land cover classes obtained by the USDA’s National Agricultural Imagery Program, which are split into 244,471 training and 55,529 validation images. EuroSAT is a small dataset containing 27,000 13-band satellite images of 10 classes based on Sentinel-2. We follow $\\textcircled { 1 3 5 } , \\textcircled { 6 4 } \\textcircled { 1 }$ for the train/val splits on EuroSAT. ",
976
+ "bbox": [
977
+ 174,
978
+ 733,
979
+ 825,
980
+ 803
981
+ ],
982
+ "page_idx": 7
983
+ },
984
+ {
985
+ "type": "text",
986
+ "text": "Table $\\boxed { 6 }$ and table 8 shows the remarkable improvement of our SatMAE over the state-of-the-arts. Although using the ViT-Large backbone already achieved good results, initializing the model with SAT-MAE pre-trained weights further increased the accuracy by $2 \\% - 3 \\%$ . ",
987
+ "bbox": [
988
+ 174,
989
+ 809,
990
+ 825,
991
+ 851
992
+ ],
993
+ "page_idx": 7
994
+ },
995
+ {
996
+ "type": "text",
997
+ "text": "Multi-label Classification We also use the BigEarthNet $\\mathbb { \\lVert 1 8 \\rVert }$ dataset for multi-label classification, which consists of 13-band Sentinel-2 images of 19 classes in total. There are 354,196 images for training and 118,065 images for validation. Following $\\pmb { \\Vert 3 5 \\Vert }$ , we use a $10 \\%$ subset of the train set. ",
998
+ "bbox": [
999
+ 174,
1000
+ 868,
1001
+ 825,
1002
+ 911
1003
+ ],
1004
+ "page_idx": 7
1005
+ },
1006
+ {
1007
+ "type": "text",
1008
+ "text": "Table 9 shows SatMAE pre-training improves upon the model trained from scratch by over $2 \\%$ , and achieves comparable results to the state-of-the-art. GASSL and SeCo were actually trained on a larger pre-train dataset (1M Sentinel-2 images v.s. 713k) and with all 13 bands than our fMoW Sentinel. Therefore we expect further improvement when we pre-train SatMAE with more data and for longer. ",
1009
+ "bbox": [
1010
+ 174,
1011
+ 92,
1012
+ 825,
1013
+ 147
1014
+ ],
1015
+ "page_idx": 8
1016
+ },
1017
+ {
1018
+ "type": "text",
1019
+ "text": "Building Segmentation In this section, we evaluate SatMAE on the semantic segmentation downstream task of the SpaceNet v1 dataset $\\pmb { \\mathbb { Z } } 0 \\|$ . The SpaceNet v1 dataset consists of 6940 high resolution satellite images with segmentation masks for buildings, which are divided into train and test sets of 5000 and 1940 images, respectively. ",
1020
+ "bbox": [
1021
+ 174,
1022
+ 166,
1023
+ 825,
1024
+ 223
1025
+ ],
1026
+ "page_idx": 8
1027
+ },
1028
+ {
1029
+ "type": "text",
1030
+ "text": "The results in table $^ { 7 }$ show that our method achieves a larger performance gain from supervised learning from scratch compared to $\\textcircled { 1 3 4 } \\textcircled { 1 }$ . The incompatibility of the ViT backbone with PSANet could explain why the baseline performance is not as strong as that of using a ResNet50 backbone. ",
1031
+ "bbox": [
1032
+ 176,
1033
+ 228,
1034
+ 823,
1035
+ 271
1036
+ ],
1037
+ "page_idx": 8
1038
+ },
1039
+ {
1040
+ "type": "text",
1041
+ "text": "5.6 Visualizing reconstruction quality for SatMAE ",
1042
+ "text_level": 1,
1043
+ "bbox": [
1044
+ 174,
1045
+ 292,
1046
+ 539,
1047
+ 308
1048
+ ],
1049
+ "page_idx": 8
1050
+ },
1051
+ {
1052
+ "type": "image",
1053
+ "img_path": "images/70f40cdf40ced9b4e9f795b92389ebf598941824c7c178a2d89c7d0f6d4c604a.jpg",
1054
+ "image_caption": [
1055
+ "Figure 4: Reconstruction quality of SatMAE $+ \\mathrm { I M }$ (left) vs. SatMAE $\\mathbf { \\Gamma } _ { + \\mathrm { C M } }$ (right). Further results in appendix C. "
1056
+ ],
1057
+ "image_footnote": [],
1058
+ "bbox": [
1059
+ 176,
1060
+ 333,
1061
+ 816,
1062
+ 578
1063
+ ],
1064
+ "page_idx": 8
1065
+ },
1066
+ {
1067
+ "type": "text",
1068
+ "text": "We show the visualization of the reconstruction quality of two different SatMAE masking strategies in fig. 4. SatMAE+IM successfully reconstructs all the airplanes even though their number varies across time. In contrast, the SatMAE with Consistent Masking missed some airplanes in the reconstruction. ",
1069
+ "bbox": [
1070
+ 174,
1071
+ 623,
1072
+ 825,
1073
+ 665
1074
+ ],
1075
+ "page_idx": 8
1076
+ },
1077
+ {
1078
+ "type": "text",
1079
+ "text": "6 Conclusion ",
1080
+ "text_level": 1,
1081
+ "bbox": [
1082
+ 174,
1083
+ 690,
1084
+ 299,
1085
+ 707
1086
+ ],
1087
+ "page_idx": 8
1088
+ },
1089
+ {
1090
+ "type": "text",
1091
+ "text": "In this paper, we propose a new SSL framework based on the MAE architecture [1] tailored to remotesensing data (satellite imagery). Our novel masking strategy in a joint positional, temporal/spectral space, along with the temporal and spectral encoding, enables our model to handle temporal and multi-spectral satellite images as input and learn useful representations. Experiments on the datasets for pre-training and multiple downstream datasets demonstrate the effectiveness of our pre-trained SatMAE model, outperforming previous state-of-the-art results by large margins. ",
1092
+ "bbox": [
1093
+ 174,
1094
+ 724,
1095
+ 825,
1096
+ 809
1097
+ ],
1098
+ "page_idx": 8
1099
+ },
1100
+ {
1101
+ "type": "text",
1102
+ "text": "In the future, it would be useful to design more efficient transformer architectures. While SatMAE has a similar number of parameters for both the temporal and multi-spectral setting as a regular ViT, the increased length of token sequences can strain computational resources. Moreover, it is also worth exploring optimal positional encodings for spectral and temporal data, as well as optimal groups of spectral bands, either by neural-based search methods, or using prior knowledge. Lastly, investigating better architectures for object detection and semantic segmentation using ViTs will be important in generalising SatMAE to further downstream tasks. ",
1103
+ "bbox": [
1104
+ 174,
1105
+ 814,
1106
+ 825,
1107
+ 911
1108
+ ],
1109
+ "page_idx": 8
1110
+ },
1111
+ {
1112
+ "type": "text",
1113
+ "text": "Broader Impact ",
1114
+ "text_level": 1,
1115
+ "bbox": [
1116
+ 174,
1117
+ 89,
1118
+ 310,
1119
+ 106
1120
+ ],
1121
+ "page_idx": 9
1122
+ },
1123
+ {
1124
+ "type": "text",
1125
+ "text": "Accurate measurements of economic, social, and environmental phenomena are key inputs into policy decisions made around the world, but the sparsity of labelled data on many outcomes means that such decisions are often not guided by timely or accurate data. We demonstrate how a pre-training framework could relieve the dependence on labelled data for many downstream tasks that use satellite imagery as input. We hope our SatMAE method will help close the gap between SSL performance on natural imagery and on the more challenging satellite imagery, and prompt further attention from the ML community on the usefulness of SSL in satellite-imagery-related tasks. ",
1126
+ "bbox": [
1127
+ 174,
1128
+ 121,
1129
+ 825,
1130
+ 218
1131
+ ],
1132
+ "page_idx": 9
1133
+ },
1134
+ {
1135
+ "type": "text",
1136
+ "text": "Better extraction of information from satellite imagery has profound implications for our ability to measure and understand a broad array of social, economic and environmental phenomena that are critical for decision making. Our approach further amplifies the usefulness of the sparse amount of labelled data that exist on key human outcomes, and could enable rapid and accurate extraction of imagery features relevant for critical downstream tasks, including poverty prediction, infrastructure development, and population estimation. Such information could aid governments in more rapid and data-informed decision making and ultimately bring large societal benefits. ",
1137
+ "bbox": [
1138
+ 174,
1139
+ 223,
1140
+ 825,
1141
+ 321
1142
+ ],
1143
+ "page_idx": 9
1144
+ },
1145
+ {
1146
+ "type": "text",
1147
+ "text": "7 Acknowledgements ",
1148
+ "text_level": 1,
1149
+ "bbox": [
1150
+ 176,
1151
+ 340,
1152
+ 367,
1153
+ 357
1154
+ ],
1155
+ "page_idx": 9
1156
+ },
1157
+ {
1158
+ "type": "text",
1159
+ "text": "This research is based upon work supported in part by the Office of the Director of National Intelligence (ODNI), Intelligence Advanced Research Projects Activity (IARPA), via 2021-2011000004, HAI, NSF(#1651565), AFOSR (FA95501910024), ARO (W911NF-21-1-0125) and Sloan Fellowship. The views and conclusions contained herein are those of the authors and should not be interpreted as necessarily representing the official policies, either expressed or implied, of ODNI, IARPA, or the U.S. Government. The U.S. Government is authorized to reproduce and distribute reprints for governmental purposes not-withstanding any copyright annotation therein. ",
1160
+ "bbox": [
1161
+ 174,
1162
+ 371,
1163
+ 826,
1164
+ 469
1165
+ ],
1166
+ "page_idx": 9
1167
+ },
1168
+ {
1169
+ "type": "text",
1170
+ "text": "Checklist ",
1171
+ "text_level": 1,
1172
+ "bbox": [
1173
+ 174,
1174
+ 89,
1175
+ 254,
1176
+ 106
1177
+ ],
1178
+ "page_idx": 10
1179
+ },
1180
+ {
1181
+ "type": "text",
1182
+ "text": "1. For all authors... ",
1183
+ "bbox": [
1184
+ 214,
1185
+ 117,
1186
+ 339,
1187
+ 131
1188
+ ],
1189
+ "page_idx": 10
1190
+ },
1191
+ {
1192
+ "type": "text",
1193
+ "text": "(a) Do the main claims made in the abstract and introduction accurately reflect the paper’s contributions and scope? [Yes] We tried our best to be precise. \n(b) Did you describe the limitations of your work? [Yes] We described the limitations in the conclusion section. \n(c) Did you discuss any potential negative societal impacts of your work? [Yes] We discussed in Appendix B \n(d) Have you read the ethics review guidelines and ensured that your paper conforms to them? [Yes] ",
1194
+ "bbox": [
1195
+ 238,
1196
+ 136,
1197
+ 825,
1198
+ 256
1199
+ ],
1200
+ "page_idx": 10
1201
+ },
1202
+ {
1203
+ "type": "text",
1204
+ "text": "2. If you are including theoretical results... ",
1205
+ "bbox": [
1206
+ 215,
1207
+ 261,
1208
+ 493,
1209
+ 275
1210
+ ],
1211
+ "page_idx": 10
1212
+ },
1213
+ {
1214
+ "type": "text",
1215
+ "text": "(a) Did you state the full set of assumptions of all theoretical results? [N/A] (b) Did you include complete proofs of all theoretical results? [N/A] ",
1216
+ "bbox": [
1217
+ 236,
1218
+ 280,
1219
+ 738,
1220
+ 311
1221
+ ],
1222
+ "page_idx": 10
1223
+ },
1224
+ {
1225
+ "type": "text",
1226
+ "text": "3. If you ran experiments... ",
1227
+ "bbox": [
1228
+ 214,
1229
+ 316,
1230
+ 393,
1231
+ 330
1232
+ ],
1233
+ "page_idx": 10
1234
+ },
1235
+ {
1236
+ "type": "text",
1237
+ "text": "(a) Did you include the code, data, and instructions needed to reproduce the main experimental results (either in the supplemental material or as a URL)? [Yes] We list the url to our project website in the abstract. The website will contain links to the code and data on Github. \n(b) Did you specify all the training details (e.g., data splits, hyperparameters, how they were chosen)? [Yes] We list part of them in the experiments section and part of them in Appendix A. \n(c) Did you report error bars (e.g., with respect to the random seed after running experiments multiple times)? [No] We trained on large datasets with small variation across different runs expected. Limited by computation resources, we only ran each experiment once. \n(d) Did you include the total amount of compute and the type of resources used (e.g., type of GPUs, internal cluster, or cloud provider)? [Yes] We list that in Appendix A. ",
1238
+ "bbox": [
1239
+ 238,
1240
+ 335,
1241
+ 825,
1242
+ 523
1243
+ ],
1244
+ "page_idx": 10
1245
+ },
1246
+ {
1247
+ "type": "text",
1248
+ "text": "4. If you are using existing assets (e.g., code, data, models) or curating/releasing new assets... ",
1249
+ "bbox": [
1250
+ 220,
1251
+ 529,
1252
+ 823,
1253
+ 544
1254
+ ],
1255
+ "page_idx": 10
1256
+ },
1257
+ {
1258
+ "type": "text",
1259
+ "text": "(a) If your work uses existing assets, did you cite the creators? [Yes] Yes, we do that by citing creators of datasets and authors of prior works. \n(b) Did you mention the license of the assets? [Yes] We do that in Appendix A \n(c) Did you include any new assets either in the supplemental material or as a URL? [Yes] We are releasing a new dataset. The instructions and links will be released in our codebase mentioned above. \n(d) Did you discuss whether and how consent was obtained from people whose data you’re using/curating? [Yes] All data we used are released publicly. \n(e) Did you discuss whether the data you are using/curating contains personally identifiable information or offensive content? [Yes] We concluded that no data we are using has such concerns. ",
1260
+ "bbox": [
1261
+ 238,
1262
+ 547,
1263
+ 825,
1264
+ 710
1265
+ ],
1266
+ "page_idx": 10
1267
+ },
1268
+ {
1269
+ "type": "text",
1270
+ "text": "5. If you used crowdsourcing or conducted research with human subjects... ",
1271
+ "bbox": [
1272
+ 214,
1273
+ 717,
1274
+ 705,
1275
+ 731
1276
+ ],
1277
+ "page_idx": 10
1278
+ },
1279
+ {
1280
+ "type": "text",
1281
+ "text": "(a) Did you include the full text of instructions given to participants and screenshots, if applicable? [N/A] \n(b) Did you describe any potential participant risks, with links to Institutional Review Board (IRB) approvals, if applicable? [N/A] \n(c) Did you include the estimated hourly wage paid to participants and the total amount spent on participant compensation? [N/A] ",
1282
+ "bbox": [
1283
+ 238,
1284
+ 736,
1285
+ 825,
1286
+ 825
1287
+ ],
1288
+ "page_idx": 10
1289
+ },
1290
+ {
1291
+ "type": "text",
1292
+ "text": "References ",
1293
+ "text_level": 1,
1294
+ "bbox": [
1295
+ 174,
1296
+ 845,
1297
+ 267,
1298
+ 861
1299
+ ],
1300
+ "page_idx": 10
1301
+ },
1302
+ {
1303
+ "type": "text",
1304
+ "text": "[1] Kaiming He, Xinlei Chen, Saining Xie, Yanghao Li, Piotr Dollár, and Ross Girshick. Masked autoencoders are scalable vision learners. In Proceedings of the IEEE/CVF Conference on Computer Vision and Pattern Recognition, pages 16000–16009, 2022. ",
1305
+ "bbox": [
1306
+ 183,
1307
+ 869,
1308
+ 825,
1309
+ 911
1310
+ ],
1311
+ "page_idx": 10
1312
+ },
1313
+ {
1314
+ "type": "text",
1315
+ "text": "[2] Yonglong Tian, Dilip Krishnan, and Phillip Isola. Contrastive multiview coding. In European conference on computer vision, pages 776–794. Springer, 2020. \n[3] Kaiming He, Haoqi Fan, Yuxin Wu, Saining Xie, and Ross Girshick. Momentum contrast for unsupervised visual representation learning. In Proceedings of the IEEE/CVF conference on computer vision and pattern recognition, pages 9729–9738, 2020. \n[4] Ting Chen, Simon Kornblith, Mohammad Norouzi, and Geoffrey Hinton. A simple framework for contrastive learning of visual representations. In International conference on machine learning, pages 1597–1607. PMLR, 2020. \n[5] Jean-Bastien Grill, Florian Strub, Florent Altché, Corentin Tallec, Pierre Richemond, Elena Buchatskaya, Carl Doersch, Bernardo Avila Pires, Zhaohan Guo, Mohammad Gheshlaghi Azar, et al. Bootstrap your own latent-a new approach to self-supervised learning. Advances in Neural Information Processing Systems, 33:21271–21284, 2020. \n[6] Xinlei Chen and Kaiming He. Exploring simple siamese representation learning. In Proceedings of the IEEE/CVF Conference on Computer Vision and Pattern Recognition, pages 15750–15758, 2021. \n[7] Ashish Jaiswal, Ashwin Ramesh Babu, Mohammad Zaki Zadeh, Debapriya Banerjee, and Fillia Makedon. A survey on contrastive self-supervised learning. CoRR, abs/2011.00362, 2020. \n[8] Longlong Jing and Yingli Tian. Self-supervised visual feature learning with deep neural networks: A survey. IEEE transactions on pattern analysis and machine intelligence, 43(11):4037– 4058, 2020. \n[9] Ishan Misra and Laurens van der Maaten. Self-supervised learning of pretext-invariant representations. In Proceedings of the IEEE/CVF Conference on Computer Vision and Pattern Recognition, pages 6707–6717, 2020. \n[10] Mathilde Caron, Ishan Misra, Julien Mairal, Priya Goyal, Piotr Bojanowski, and Armand Joulin. Unsupervised learning of visual features by contrasting cluster assignments. Advances in Neural Information Processing Systems, 33:9912–9924, 2020. \n[11] Yude Wang, Jie Zhang, Meina Kan, Shiguang Shan, and Xilin Chen. Self-supervised equivariant attention mechanism for weakly supervised semantic segmentation. In Proceedings of the IEEE/CVF Conference on Computer Vision and Pattern Recognition, pages 12275–12284, 2020. \n[12] Yann Dubois, Benjamin Bloem-Reddy, Karen Ullrich, and Chris J Maddison. Lossy compression for lossless prediction. Advances in Neural Information Processing Systems, 34, 2021. \n[13] Alexander Kolesnikov, Xiaohua Zhai, and Lucas Beyer. Revisiting self-supervised visual representation learning. In Proceedings of the IEEE/CVF conference on computer vision and pattern recognition, pages 1920–1929, 2019. \n[14] Zeyu Feng, Chang Xu, and Dacheng Tao. Self-supervised representation learning by rotation feature decoupling. In Proceedings of the IEEE/CVF Conference on Computer Vision and Pattern Recognition, pages 10364–10374, 2019. \n[15] Soroush Abbasi Koohpayegani, Ajinkya Tejankar, and Hamed Pirsiavash. Compress: Selfsupervised learning by compressing representations. Advances in Neural Information Processing Systems, 33:12980–12992, 2020. \n[16] Abhishek Sinha, Jiaming Song, Chenlin Meng, and Stefano Ermon. D2c: Diffusion-decoding models for few-shot conditional generation. Advances in Neural Information Processing Systems, 34:12533–12548, 2021. \n[17] Gordon Christie, Neil Fendley, James Wilson, and Ryan Mukherjee. Functional map of the world. In CVPR, 2018. \n[18] Gencer Sumbul, Marcela Charfuelan, Begüm Demir, and Volker Markl. Bigearthnet: A largescale benchmark archive for remote sensing image understanding. In IGARSS 2019-2019 IEEE International Geoscience and Remote Sensing Symposium, pages 5901–5904. IEEE, 2019. \n[19] Darius Lam, Richard Kuzma, Kevin McGee, Samuel Dooley, Michael Laielli, Matthew Klaric, Yaroslav Bulatov, and Brendan McCord. xview: Objects in context in overhead imagery. arXiv preprint arXiv:1802.07856, 2018. \n[20] Adam Van Etten, Dave Lindenbaum, and Todd M Bacastow. Spacenet: A remote sensing dataset and challenge series. arXiv preprint arXiv:1807.01232, 2018. \n[21] Marshall Burke, Anne Driscoll, David B Lobell, and Stefano Ermon. Using satellite imagery to understand and promote sustainable development. Science, 371(6535):eabe8628, 2021. \n[22] Kumar Ayush, Burak Uzkent, Kumar Tanmay, Marshall Burke, David Lobell, and Stefano Ermon. Efficient poverty mapping from high resolution remote sensing images. In Proc. AAAI Conf. Artif. Intell, volume 35, pages 12–20, 2021. \n[23] Kumar Ayush, Burak Uzkent, Marshall Burke, David Lobell, and Stefano Ermon. Generating interpretable poverty maps using object detection in satellite images. arXiv preprint arXiv:2002.01612, 2020. \n[24] Neal Jean, Marshall Burke, Michael Xie, W Matthew Davis, David B Lobell, and Stefano Ermon. Combining satellite imagery and machine learning to predict poverty. Science, 353(6301):790– 794, 2016. \n[25] Jiaxuan You, Xiaocheng Li, Melvin Low, David Lobell, and Stefano Ermon. Deep gaussian process for crop yield prediction based on remote sensing data. In Thirty-First AAAI conference on artificial intelligence, 2017. \n[26] Anna X Wang, Caelin Tran, Nikhil Desai, David Lobell, and Stefano Ermon. Deep transfer learning for crop yield prediction with remote sensing data. In Proceedings of the 1st ACM SIGCAS Conference on Computing and Sustainable Societies, pages 1–5, 2018. \n[27] Marc Rußwurm and Marco Körner. Self-attention for raw optical satellite time series classification. ISPRS journal of photogrammetry and remote sensing, 169:421–435, 2020. \n[28] Jorge Andres Chamorro Martinez, Laura Elena Cué La Rosa, Raul Queiroz Feitosa, Ieda Del’Arco Sanches, and Patrick Nigri Happ. Fully convolutional recurrent networks for multidate crop recognition from multitemporal image sequences. ISPRS Journal of Photogrammetry and Remote Sensing, 171:188–201, 2021. \n[29] Rose M Rustowicz, Robin Cheong, Lijing Wang, Stefano Ermon, Marshall Burke, and David Lobell. Semantic segmentation of crop type in africa: A novel dataset and analysis of deep learning methods. In Proceedings of the IEEE/CVF Conference on Computer Vision and Pattern Recognition Workshops, pages 75–82, 2019. \n[30] Christopher Yeh, Chenlin Meng, Sherrie Wang, Anne Driscoll, Erik Rozi, Patrick Liu, Jihyeon Lee, Marshall Burke, David B Lobell, and Stefano Ermon. Sustainbench: Benchmarks for monitoring the sustainable development goals with machine learning. arXiv preprint arXiv:2111.04724, 2021. \n[31] Jia Deng, Wei Dong, Richard Socher, Li-Jia Li, Kai Li, and Li Fei-Fei. Imagenet: A largescale hierarchical image database. In 2009 IEEE Conference on Computer Vision and Pattern Recognition, pages 248–255, 2009. \n[32] Yutong He, Dingjie Wang, Nicholas Lai, William Zhang, Chenlin Meng, Marshall Burke, David Lobell, and Stefano Ermon. Spatial-temporal super-resolution of satellite imagery via conditional pixel synthesis. Advances in Neural Information Processing Systems, 34:27903– 27915, 2021. \n[33] Yutong He, William Zhang, Chenlin Meng, Marshall Burke, David B Lobell, and Stefano Ermon. Tracking urbanization in developing regions with remote sensing spatial-temporal super-resolution. arXiv preprint arXiv:2204.01736, 2022. \n[34] Kumar Ayush, Burak Uzkent, Chenlin Meng, Kumar Tanmay, Marshall Burke, David Lobell, and Stefano Ermon. Geography-aware self-supervised learning. In Proceedings of the IEEE/CVF International Conference on Computer Vision, pages 10181–10190, 2021. ",
1316
+ "bbox": [
1317
+ 169,
1318
+ 70,
1319
+ 828,
1320
+ 917
1321
+ ],
1322
+ "page_idx": 11
1323
+ },
1324
+ {
1325
+ "type": "text",
1326
+ "text": "",
1327
+ "bbox": [
1328
+ 169,
1329
+ 85,
1330
+ 826,
1331
+ 917
1332
+ ],
1333
+ "page_idx": 12
1334
+ },
1335
+ {
1336
+ "type": "text",
1337
+ "text": "[35] Oscar Mañas, Alexandre Lacoste, Xavier Giro-i Nieto, David Vazquez, and Pau Rodriguez. Seasonal contrast: Unsupervised pre-training from uncurated remote sensing data. In Proceedings of the IEEE/CVF International Conference on Computer Vision, pages 9414–9423, 2021. ",
1338
+ "bbox": [
1339
+ 171,
1340
+ 90,
1341
+ 823,
1342
+ 133
1343
+ ],
1344
+ "page_idx": 13
1345
+ },
1346
+ {
1347
+ "type": "text",
1348
+ "text": "[36] Alexey Dosovitskiy, Lucas Beyer, Alexander Kolesnikov, Dirk Weissenborn, Xiaohua Zhai, Thomas Unterthiner, Mostafa Dehghani, Matthias Minderer, Georg Heigold, Sylvain Gelly, Jakob Uszkoreit, and Neil Houlsby. An image is worth 16x16 words: Transformers for image recognition at scale. ICLR, 2021. ",
1349
+ "bbox": [
1350
+ 174,
1351
+ 142,
1352
+ 825,
1353
+ 198
1354
+ ],
1355
+ "page_idx": 13
1356
+ },
1357
+ {
1358
+ "type": "text",
1359
+ "text": "[37] Marc Rußwurm and Marco Körner. Convolutional lstms for cloud-robust segmentation of remote sensing imagery. arXiv preprint arXiv:1811.02471, 2018. ",
1360
+ "bbox": [
1361
+ 173,
1362
+ 205,
1363
+ 821,
1364
+ 236
1365
+ ],
1366
+ "page_idx": 13
1367
+ },
1368
+ {
1369
+ "type": "text",
1370
+ "text": "[38] Charlotte Pelletier, Geoffrey I Webb, and François Petitjean. Temporal convolutional neural network for the classification of satellite image time series. Remote Sensing, 11(5):523, 2019. ",
1371
+ "bbox": [
1372
+ 174,
1373
+ 243,
1374
+ 823,
1375
+ 273
1376
+ ],
1377
+ "page_idx": 13
1378
+ },
1379
+ {
1380
+ "type": "text",
1381
+ "text": "[39] Elisa Kamir, François Waldner, and Zvi Hochman. Estimating wheat yields in australia using climate records, satellite image time series and machine learning methods. ISPRS Journal of Photogrammetry and Remote Sensing, 160:124–135, 2020. ",
1382
+ "bbox": [
1383
+ 174,
1384
+ 281,
1385
+ 823,
1386
+ 324
1387
+ ],
1388
+ "page_idx": 13
1389
+ },
1390
+ {
1391
+ "type": "text",
1392
+ "text": "[40] Raí A Schwalbert, Telmo Amado, Geomar Corassa, Luan Pierre Pott, PV Vara Prasad, and Ignacio A Ciampitti. Satellite-based soybean yield forecast: Integrating machine learning and weather data for improving crop yield prediction in southern brazil. Agricultural and Forest Meteorology, 284:107886, 2020. ",
1393
+ "bbox": [
1394
+ 173,
1395
+ 332,
1396
+ 826,
1397
+ 388
1398
+ ],
1399
+ "page_idx": 13
1400
+ },
1401
+ {
1402
+ "type": "text",
1403
+ "text": "[41] Chenlin Meng, Enci Liu, Willie Neiswanger, Jiaming Song, Marshall Burke, David Lobell, and Stefano Ermon. Is-count: Large-scale object counting from satellite images with covariatebased importance sampling. In Proceedings of the AAAI Conference on Artificial Intelligence, volume 36, pages 12034–12042, 2022. ",
1404
+ "bbox": [
1405
+ 174,
1406
+ 396,
1407
+ 826,
1408
+ 453
1409
+ ],
1410
+ "page_idx": 13
1411
+ },
1412
+ {
1413
+ "type": "text",
1414
+ "text": "[42] Evan Sheehan, Chenlin Meng, Matthew Tan, Burak Uzkent, Neal Jean, Marshall Burke, David Lobell, and Stefano Ermon. Predicting economic development using geolocated wikipedia articles. In Proceedings of the 25th ACM SIGKDD international conference on knowledge discovery & data mining, pages 2698–2706, 2019. ",
1415
+ "bbox": [
1416
+ 173,
1417
+ 462,
1418
+ 825,
1419
+ 518
1420
+ ],
1421
+ "page_idx": 13
1422
+ },
1423
+ {
1424
+ "type": "text",
1425
+ "text": "[43] Enci Liu, Chenlin Meng, Matthew Kolodner, Eun Jee Sung, Sihang Chen, Marshall Burke, David Lobell, and Stefano Ermon. Building coverage estimation with low-resolution remote sensing imagery. arXiv preprint arXiv:2301.01449, 2023. ",
1426
+ "bbox": [
1427
+ 173,
1428
+ 525,
1429
+ 823,
1430
+ 569
1431
+ ],
1432
+ "page_idx": 13
1433
+ },
1434
+ {
1435
+ "type": "text",
1436
+ "text": "[44] Burak Uzkent, Evan Sheehan, Chenlin Meng, Zhongyi Tang, Marshall Burke, David Lobell, and Stefano Ermon. Learning to interpret satellite images using wikipedia. In Proceedings of the Twenty-Eighth International Joint Conference on Artificial Intelligence, 2019. ",
1437
+ "bbox": [
1438
+ 173,
1439
+ 577,
1440
+ 825,
1441
+ 621
1442
+ ],
1443
+ "page_idx": 13
1444
+ },
1445
+ {
1446
+ "type": "text",
1447
+ "text": "[45] Xingjian Shi, Zhourong Chen, Hao Wang, Dit-Yan Yeung, Wai-Kin Wong, and Wang-chun Woo. Convolutional lstm network: A machine learning approach for precipitation nowcasting. Advances in neural information processing systems, 28, 2015. ",
1448
+ "bbox": [
1449
+ 173,
1450
+ 627,
1451
+ 823,
1452
+ 671
1453
+ ],
1454
+ "page_idx": 13
1455
+ },
1456
+ {
1457
+ "type": "text",
1458
+ "text": "[46] Andrei Stoian, Vincent Poulain, Jordi Inglada, Victor Poughon, and Dawa Derksen. Land cover maps production with high resolution satellite image time series and convolutional neural networks: Adaptations and limits for operational systems. Remote Sensing, 11(17):1986, 2019. ",
1459
+ "bbox": [
1460
+ 173,
1461
+ 679,
1462
+ 825,
1463
+ 722
1464
+ ],
1465
+ "page_idx": 13
1466
+ },
1467
+ {
1468
+ "type": "text",
1469
+ "text": "[47] Xin Yang and CP Lo. Using a time series of satellite imagery to detect land use and land cover changes in the atlanta, georgia metropolitan area. International Journal of Remote Sensing, 23(9):1775–1798, 2002. ",
1470
+ "bbox": [
1471
+ 174,
1472
+ 729,
1473
+ 825,
1474
+ 772
1475
+ ],
1476
+ "page_idx": 13
1477
+ },
1478
+ {
1479
+ "type": "text",
1480
+ "text": "[48] Vivien Sainte Fare Garnot and Loic Landrieu. Panoptic segmentation of satellite image time series with convolutional temporal attention networks. In Proceedings of the IEEE/CVF International Conference on Computer Vision, pages 4872–4881, 2021. ",
1481
+ "bbox": [
1482
+ 173,
1483
+ 781,
1484
+ 823,
1485
+ 824
1486
+ ],
1487
+ "page_idx": 13
1488
+ },
1489
+ {
1490
+ "type": "text",
1491
+ "text": "[49] Aidan M Swope, Xander H Rudelis, and Kyle T Story. Representation learning for remote sensing: An unsupervised sensor fusion approach. arXiv preprint arXiv:2108.05094, 2021. ",
1492
+ "bbox": [
1493
+ 173,
1494
+ 832,
1495
+ 820,
1496
+ 861
1497
+ ],
1498
+ "page_idx": 13
1499
+ },
1500
+ {
1501
+ "type": "text",
1502
+ "text": "[50] Vladan Stojnic and Vladimir Risojevic. Self-supervised learning of remote sensing scene representations using contrastive multiview coding. In Proceedings of the IEEE/CVF Conference on Computer Vision and Pattern Recognition, pages 1182–1191, 2021. ",
1503
+ "bbox": [
1504
+ 174,
1505
+ 869,
1506
+ 826,
1507
+ 911
1508
+ ],
1509
+ "page_idx": 13
1510
+ },
1511
+ {
1512
+ "type": "text",
1513
+ "text": "[51] Pallavi Jain, Bianca Schoen-Phelan, and Robert Ross. Multi-modal self-supervised representation learning for earth observation. In 2021 IEEE International Geoscience and Remote Sensing Symposium IGARSS, pages 3241–3244. IEEE, 2021. \n[52] Wenyuan Li, Hao Chen, and Zhenwei Shi. Semantic segmentation of remote sensing images with self-supervised multitask representation learning. IEEE Journal of Selected Topics in Applied Earth Observations and Remote Sensing, 14:6438–6450, 2021. \n[53] Wenyuan Li, Keyan Chen, Hao Chen, and Zhenwei Shi. Geographical knowledge-driven representation learning for remote sensing images. IEEE Transactions on Geoscience and Remote Sensing, 2021. \n[54] Zhan Tong, Yibing Song, Jue Wang, and Limin Wang. Videomae: Masked autoencoders are data-efficient learners for self-supervised video pre-training. arXiv preprint arXiv:2203.12602, 2022. \n[55] Hongxu Chen, Sixiao Zhang, and Guandong Xu. Graph masked autoencoder. arXiv preprint arXiv:2202.08391, 2022. \n[56] Roman Bachmann, David Mizrahi, Andrei Atanov, and Amir Zamir. Multimae: Multi-modal multi-task masked autoencoders. arXiv preprint arXiv:2204.01678, 2022. \n[57] Ashish Vaswani, Noam Shazeer, Niki Parmar, Jakob Uszkoreit, Llion Jones, Aidan N Gomez, Łukasz Kaiser, and Illia Polosukhin. Attention is all you need. Advances in neural information processing systems, 30, 2017. \n[58] Hugo Touvron, Matthieu Cord, Matthijs Douze, Francisco Massa, Alexandre Sablayrolles, and Hervé Jégou. Training data-efficient image transformers & distillation through attention. In International Conference on Machine Learning, pages 10347–10357. PMLR, 2021. \n[59] Anurag Arnab, Mostafa Dehghani, Georg Heigold, Chen Sun, Mario Luciˇ c, and Cordelia ´ Schmid. Vivit: A video vision transformer. In International Conference on Computer Vision (ICCV), 2021. \n[60] Ze Liu, Jia Ning, Yue Cao, Yixuan Wei, Zheng Zhang, Stephen Lin, and Han Hu. Video swin transformer. arXiv preprint arXiv:2106.13230, 2021. \n[61] Kaiming He, Xiangyu Zhang, Shaoqing Ren, and Jian Sun. Deep residual learning for image recognition. In Proceedings of the IEEE conference on computer vision and pattern recognition, pages 770–778, 2016. \n[62] Xinlei Chen\\*, Saining Xie\\*, and Kaiming He. An empirical study of training self-supervised vision transformers. arXiv preprint arXiv:2104.02057, 2021. \n[63] Patrick Helber, Benjamin Bischke, Andreas Dengel, and Damian Borth. Eurosat: A novel dataset and deep learning benchmark for land use and land cover classification. IEEE Journal of Selected Topics in Applied Earth Observations and Remote Sensing, 12(7):2217–2226, 2019. \n[64] Maxim Neumann, Andre Susano Pinto, Xiaohua Zhai, and Neil Houlsby. In-domain representation learning for remote sensing. arXiv preprint arXiv:1911.06721, 2019. \n[65] Hengshuang Zhao, Yi Zhang, Shu Liu, Jianping Shi, Chen Change Loy, Dahua Lin, and Jiaya Jia. Psanet: Point-wise spatial attention network for scene parsing. In Proceedings of the European conference on computer vision (ECCV), pages 267–283, 2018. \n[66] Alexandre Lacoste, Alexandra Luccioni, Victor Schmidt, and Thomas Dandres. Quantifying the carbon emissions of machine learning. CoRR, abs/1910.09700, 2019. ",
1514
+ "bbox": [
1515
+ 169,
1516
+ 44,
1517
+ 828,
1518
+ 825
1519
+ ],
1520
+ "page_idx": 14
1521
+ }
1522
+ ]
parse/dev/WIJ2SfPTj8c/WIJ2SfPTj8c.md ADDED
@@ -0,0 +1,639 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ # ISAAC Newton: Input-based Approximate Curvature for Newton’s Method
2
+
3
+ Anonymous Author(s)
4
+ Affiliation
5
+ Address
6
+ email
7
+
8
+ # Abstract
9
+
10
+ 1 We present ISAAC (Input-baSed ApproximAte Curvature), a novel method that
11
+ 2 conditions the gradient using selected second-order information and has an asymp
12
+ 3 totically vanishing computational overhead, assuming a batch size smaller than
13
+ 4 the number of neurons. We show that it is possible to compute a good conditioner
14
+ 5 based on only the input to a respective layer without a substantial computational
15
+ 6 overhead. The proposed method allows effective training even in small-batch
16
+ 7 stochastic regimes, which makes it competitive to first-order as well as quasi
17
+ 8 Newton methods.
18
+
19
+ # 9 1 Introduction
20
+
21
+ 10 While second-order optimization methods are traditionally much less explored than first-order
22
+ 11 methods in large-scale machine learning (ML) applications due to their memory requirements and
23
+ 12 prohibitive computational cost per iteration, they have recently become more popular in ML mainly
24
+ 13 due to their fast convergence properties when compared to first-order methods [1]. The expensive
25
+ 14 computation of an inverse Hessian (also known as pre-conditioning matrix) in the Newton step has
26
+ 15 also been tackled via estimating the curvature from the change in gradients. Loosely speaking, these
27
+ 16 algorithms are known as quasi-Newton methods and a comprehensive treatment can be found in
28
+ 17 the textbook [2]. In addition, various new approximations to the pre-conditioning matrix have been
29
+ 18 proposed in the recent literature [3]–[6]. From a theoretical perspective, second-order optimization
30
+ 19 methods are not nearly as well understood as first-order methods. It is an active research direction to
31
+ 20 fill this gap [7], [8].
32
+ 21 Motivated by the task of training neural networks, and the observation that invoking local curvature
33
+ 22 information associated with neural network objective functions can achieve much faster progress
34
+ 23 per iteration than standard first-order methods [9]–[11], several methods have been proposed. One
35
+ 24 of these methods, that received significant attention, is known as Kronecker-factored Approximate
36
+ 25 Curvature (K-FAC) [12], whose main ingredient is a sophisticated approximation to the generalized
37
+ 26 Gauss-Newton matrix and the Fisher information matrix quantifying the curvature of the underlying
38
+ 27 neural network objective function, which then can be inverted efficiently.
39
+ 28 Inspired by the K-FAC approximation and the Tikhonov regularization of the Newton method, we
40
+ 29 introduce a novel two parameter regularized Kronecker-factorized Newton update step. The proposed
41
+ 30 scheme disentangles the classical Tikhonov regularization and allows us to condition the gradient
42
+ 31 using selected second-order information and has an asymptotically vanishing computational overhead.
43
+ 32 While this property makes the presented method highly attractive from the computational complexity
44
+ 33 perspective, we show that its achieved empirical performance on complicated high-dimensional
45
+ 34 Machine Learning problems remains comparable to existing state-of-the-art methods.
46
+ 35 The contributions of this paper can be summarized as follows: (i) we propose a novel two parameter
47
+ 36 regularized K-FAC approximated Gauss-Newton update step; (ii) we show that asymptotically—as
48
+ 37 both regularization parameters vanish—our method recovers the classical K-FAC scheme and in
49
+ 38 the opposite setting—as both regularization parameters grow—our method asymptotically reduces
50
+ 39 to classical gradient descent; (iii) we prove that for an arbitrary pair of regularization parameters,
51
+ 40 the proposed update direction is always a direction of decreasing loss; (iv) in the limit, as one
52
+ 41 regularization parameter grows, we obtain an efficient and effective conditioning of the gradient with
53
+ 42 an asymptotically vanishing overhead; (v) we empirically analyze the presented method and find that
54
+ 43 our efficient conditioning method maintains the performance of its more expensive counterpart; (vi)
55
+ 44 we demonstrate the effectiveness of the presented method in the setting of small-batch stochastic
56
+ 45 regimes and observe that it is competitive to first-order as well as quasi-Newton methods.
57
+
58
+ # 46 2 Preliminaries
59
+
60
+ 47 In this section, we review aspects of second-order optimization, with a focus on generalized Gauss
61
+ 48 Newton methods. In combination with Kronecker factorization, this leads us to a new regularized
62
+ 49 update scheme. We consider the training of an $L$ -layer neural network $f ( x ; \theta )$ defined recursively as
63
+
64
+ $$
65
+ z _ { i } a _ { i - 1 } W ^ { ( i ) } \quad ( \mathrm { p r e - a c t i v a t i o n s } ) , \qquad \quad a _ { i } \phi ( z _ { i } ) \quad ( \mathrm { a c t i v a t i o n s } ) ,
66
+ $$
67
+
68
+ 50 where $a _ { 0 } = x$ is the vector of inputs and $a _ { L } = f ( x ; \theta )$ is the vector of outputs. Unless noted otherwise,
69
+ 51 we assume these vectors to be row vectors (i.e., in $\mathbb { R } ^ { 1 \times n }$ ) as this allows for a direct extension to the
70
+ 52 (batch) vectorized case (i.e., in $\mathbb { R } ^ { b \times n }$ ) introduced later. For any layer $i$ , let $W ^ { ( i ) } \in \mathbb { R } ^ { d _ { i - 1 } \times d _ { i } }$ be a
71
+ 53 weight matrix and let $\phi$ be an element-wise nonlinear function. We consider a convex loss function
72
+ 54 $\mathcal { L } ( y , y ^ { \prime } )$ that measures the discrepancy between $y$ and $y ^ { \prime }$ . The training optimization problem is then
73
+
74
+ $$
75
+ \arg \operatorname* { m i n } _ { \theta } \mathbb { E } _ { x , y } \left[ \mathcal { L } ( f ( x ; \theta ) , y ) \right] ,
76
+ $$
77
+
78
+ where 55 $\theta = \left[ \theta ^ { ( 1 ) } , \dots , \theta ^ { ( L ) } \right]$ with $\theta ^ { ( i ) } = \operatorname { v e c } ( W ^ { ( i ) } )$ .
79
+
80
+ 56 The classical Newton method for solving (2) is expressed as the update rule
81
+
82
+ $$
83
+ \begin{array} { r } { \theta ^ { \prime } = \theta - \eta \mathbf { H } _ { \theta } ^ { - 1 } \nabla _ { \theta } \mathcal { L } ( f ( x ; \theta ) , y ) , } \end{array}
84
+ $$
85
+
86
+ 57 where $\eta > 0$ denotes the learning rate and $\mathbf { H } _ { \theta }$ is the Hessian corresponding to the objective function
87
+ 58 in (2). The stability and efficiency of an estimation problem solved via the Newton method can be
88
+ 59 improved by adding a Tikhonov regularization term [13] leading to a regularized Newton method
89
+
90
+ $$
91
+ \boldsymbol { \theta } ^ { \prime } = \boldsymbol { \theta } - \eta ( \mathbf { H } _ { \boldsymbol { \theta } } + \lambda \mathbf { I } ) ^ { - 1 } \nabla _ { \boldsymbol { \theta } } \mathcal { L } ( f ( x ; \boldsymbol { \theta } ) , y ) ,
92
+ $$
93
+
94
+ 60 where $\lambda > 0$ is the so-called Tikhonov regularization parameter. It is well-known [14], [15], that
95
+ 61 under the assumption of approximating the model $f$ with its first-order Taylor expansion, the Hessian
96
+ 62 corresponds with the so-called generalized Gauss-Newton (GGN) matrix $\mathbf { G } _ { \theta }$ , and hence (4) can be
97
+ 63 expressed as
98
+
99
+ $$
100
+ \begin{array} { r } { \boldsymbol { \theta } ^ { \prime } = \boldsymbol { \theta } - \eta ( \mathbf G _ { \boldsymbol { \theta } } + \lambda \mathbf I ) ^ { - 1 } \nabla _ { \boldsymbol { \theta } } \mathcal { L } ( f ( \boldsymbol { x } ; \boldsymbol { \theta } ) , y ) . } \end{array}
101
+ $$
102
+
103
+ 64 A major practical limitation of (5) is the computation of the inverse term. A method that alleviates this
104
+ 65 difficulty is known as Kronecker-Factored Approximate Curvature (K-FAC) [12] which approximates
105
+ 66 the block-diagonal (i.e., layer-wise) empirical Hessian or GGN matrix. Inspired by K-FAC, there
106
+ 67 have been other works discussing approximations of $\mathbf { G } _ { \theta }$ and its inverse [15]. In the following, we
107
+ 68 discuss a popular approach that allows for (moderately) efficient computation.
108
+
109
+ 69 The generalized Gauss-Newton matrix $\mathbf { G } _ { \theta }$ is defined as
110
+
111
+ $$
112
+ \mathbf { G } _ { \theta } = \mathbb { E } \left[ ( \mathbf { J } _ { \theta } f ( x ; \theta ) ) ^ { \top } \nabla _ { f } ^ { 2 } \mathcal { L } ( f ( x ; \theta ) , y ) \mathbf { J } _ { \theta } f ( x ; \theta ) \right] ,
113
+ $$
114
+
115
+ 70 where $\mathbf { J }$ and $\mathbf { H }$ denote the Jacobian and Hessian matrices, respectively. Correspondingly, the diagonal block of 71 $\mathbf { G } _ { \theta }$ corresponding to the weights of the ith layer $W ^ { ( i ) }$ is
116
+
117
+ $$
118
+ \mathbf { G } _ { W ^ { ( i ) } } = \mathbb { E } \left[ \left( \mathbf { J } _ { W ^ { ( i ) } } f ( x ; \theta ) \right) ^ { \top } \nabla _ { f } ^ { 2 } \mathcal { L } ( f ( x ; \theta ) , y ) \mathbf { J } _ { W ^ { ( i ) } } f ( x ; \theta ) \right] .
119
+ $$
120
+
121
+ According to the backpropagation rule 72 ${ \bf J } _ { \theta ^ { ( i ) } } f ( x ; \theta ) = { \bf J } _ { z _ { i } } f ( x ; \theta ) a _ { i - 1 }$ , $a ^ { \top } b \ : = \ : a \otimes b$ , and the 73 mixed-product property, we can rewrite $\mathbf { G } _ { W ^ { ( i ) } }$ as
122
+
123
+ $$
124
+ \begin{array} { r l r } & { } & { \mathbf { G } _ { W ^ { ( i ) } } = \mathbb { E } \Big [ \big ( ( \mathbf { J } _ { z i } f ( x ; \theta ) a _ { i - 1 } ) ^ { \top } ( \nabla _ { f } ^ { 2 } \mathcal { L } ( f ( x ; \theta ) , y ) ) ^ { 1 / 2 } \big ) \big ( ( \nabla _ { f } ^ { 2 } \mathcal { L } ( f ( x ; \theta ) , y ) ) ^ { 1 / 2 } \mathbf { J } _ { z i } f ( x ; \theta ) a _ { i - 1 } \big ) \Big ] } \\ & { } & { = \mathbb { E } \big [ \big ( \bar { g } ^ { \top } a _ { i - 1 } \big ) ^ { \top } \big ( \bar { g } ^ { \top } a _ { i - 1 } \big ) \big ] = \mathbb { E } \big [ \big ( \bar { g } \otimes a _ { i - 1 } \big ) ^ { \top } \big ( \bar { g } \otimes a _ { i - 1 } \big ) \big ] = \mathbb { E } \big [ \big ( \bar { g } ^ { \top } \bar { g } \big ) \otimes \big ( a _ { i - 1 } ^ { \top } \otimes a _ { i - 1 } \big ) \big ] , } \end{array}
125
+ $$
126
+
127
+ 74 where
128
+
129
+ $$
130
+ \bar { g } = ( \mathbf { J } _ { z _ { i } } f ( x ; \theta ) ) ^ { \top } ( \nabla _ { f } ^ { 2 } \mathcal { L } ( f ( x ; \theta ) , y ) ) ^ { 1 / 2 } .
131
+ $$
132
+
133
+ 75 Remark 1 (Monte-Carlo Low-Rank Approximation for $\bar { g } ^ { \top } \bar { g }$ ). As $g$ is a matrix of shape $m \times d _ { i }$
134
+ 76 where m is the dimension of the output of $f$ , $g$ is generally expensive to compute. Therefore, $I I 2 J$ use
135
+ 77 a low-rank Monte-Carlo approximation to estimate ${ \bf H } _ { f } \mathcal { L } ( f ( x ; \theta ) , y )$ and thereby $\bar { g } ^ { \mathrm { ~ l ~ } } \bar { g }$ . For this, we
136
+ 78 need to use the distribution underlying the probabilistic model of our loss $\mathcal { L }$ (e.g., Gaussian for MSE
137
+ 79 loss, or a categorical distribution for cross entropy). Specifically, by sampling from this distribution
138
+ 80 $p _ { f } ( x )$ defined by the network output $f ( x ; \theta )$ , we can get an estimator of ${ \bf H } _ { f } \mathcal { L } ( f ( x ; \theta ) , y )$ via the
139
+ 81 identity
140
+
141
+ $$
142
+ \begin{array} { r } { \mathbf { H } _ { f } \mathcal { L } \big ( f ( x ; \theta ) , y \big ) = \mathbb { E } _ { \hat { y } \sim p _ { f } ( x ) } \big [ \nabla _ { f } \mathcal { L } \big ( f ( x ; \theta ) , \hat { y } \big ) ^ { \top } \nabla _ { f } \mathcal { L } \big ( f ( x ; \theta ) , \hat { y } \big ) \big ] . } \end{array}
143
+ $$
144
+
145
+ 82 An extensive reference for this (as well as alternatives) can be found in Appendix A.2 of Dangel et
146
+ 83 al. [15]. The respective rank-1 approximation (denoted by $\triangleq$ ) of ${ \mathbf { H } } _ { f } \mathcal { L } ( f ( x ; \theta ) )$ is
147
+
148
+ $$
149
+ \begin{array} { r } { \mathbf { H } _ { f } \boldsymbol { \mathcal { L } } ( f ( \boldsymbol { x } ; \boldsymbol { \theta } ) , y ) \triangleq \nabla _ { f } \boldsymbol { \mathcal { L } } ( f ( \boldsymbol { x } ; \boldsymbol { \theta } ) , \boldsymbol { \hat { y } } ) ^ { \top } \nabla _ { f } \boldsymbol { \mathcal { L } } ( f ( \boldsymbol { x } ; \boldsymbol { \theta } ) , \boldsymbol { \hat { y } } ) , } \end{array}
150
+ $$
151
+
152
+ where 84 $\hat { y } \sim p _ { f } ( x )$ . Respectively, we can estimate $\bar { g } ^ { \top } \bar { g }$ using this rank-1 approximation with
153
+
154
+ $$
155
+ \begin{array} { r } { \bar { g } \triangleq ( \mathbf { J } _ { z _ { i } } f ( x ; \theta ) ) ^ { \top } \nabla _ { f } \mathcal { L } ( f ( x ; \theta ) , \hat { y } ) = \nabla _ { z _ { i } } \mathcal { L } ( f ( x ; \theta ) , \hat { y } ) . } \end{array}
156
+ $$
157
+
158
+ 85 In analogy to $\bar { g }$ , we introduce the gradient of training objective with respect to pre-activations $z _ { i }$ as
159
+
160
+ $$
161
+ \begin{array} { r } { \mathrm { g } _ { i } = ( \mathbf { J } _ { z _ { i } } f ( { \boldsymbol { { x } } } ; \theta ) ) ^ { \top } \nabla _ { f } \mathcal { L } ( f ( { \boldsymbol { { x } } } ; \theta ) , y ) = \nabla _ { z _ { i } } \mathcal { L } ( f ( { \boldsymbol { { x } } } ; \theta ) , y ) . } \end{array}
162
+ $$
163
+
164
+ 86 In other words, for a given layer, let $\mathrm { g } \in \mathbb { R } ^ { 1 \times d _ { i } }$ denote the gradient of the loss between an output and
165
+ 87 the ground truth and let $\bar { g } \in \mathbf { \mathbb { R } } ^ { m \times d _ { i } }$ denote the derivative of the network $f$ times the square root of
166
+ 88 the Hessian of the loss function (which may be approximated according to Remark 1), each of them
167
+ 89 with respect to the output $z _ { i }$ of the given layer $i$ . Note that $\bar { g }$ is not equal to $\mathrm { g }$ and that they require one
168
+ 90 backpropagation pass each (or potentially many for the case of $\bar { g }$ ). This makes computing $\bar { g }$ costly.
169
+ 91 Applying the K-FAC [12] approximation to (8) the expectation of Kronecker products can be
170
+ 92 approximated as the Kronecker product of expectations as
171
+
172
+ $$
173
+ \mathbf G = \mathbb { E } ( ( { \bar { g } } ^ { \top } { \bar { g } } ) \otimes ( \mathbf { a } ^ { \top } \mathbf { a } ) ) \approx \mathbb { E } ( { \bar { g } } ^ { \top } { \bar { g } } ) \otimes \mathbb { E } ( \mathbf { a } ^ { \top } \mathbf { a } ) ,
174
+ $$
175
+
176
+ 93 where, for clarity, we drop the index of $\mathrm { a } _ { i - 1 }$ in (8) and denote it with a; similarly we denote $\mathbf { G } _ { W ^ { ( i ) } }$
177
+ 94 as G. While the expectation of Kronecker products is generally not equal to the Kronecker product
178
+ 95 of expectations, this K-FAC approximation (13) has been shown to be fairly accurate in practice
179
+ 96 and to preserve the “coarse structure” of the GGN matrix [12]. The K-FAC decomposition in (13)
180
+ 97 is convenient as the Kronecker product has the favorable property that for two matrices $A , B$ the
181
+ 98 identity $( A \otimes B ) ^ { - 1 } = A ^ { - 1 } \otimes \dot { B ^ { - 1 } }$ which significantly simplifies the computation of an inverse.
182
+
183
+ In practice, 99 $\mathbb { E } ( \bar { g } ^ { \top } \bar { g } )$ and $\mathbb { E } ( \mathrm { a } ^ { \top } \mathrm { a } )$ can be computed by averaging over a batch of size $b$ as
184
+
185
+ $$
186
+ \begin{array} { r } { \mathbb { E } ( \bar { g } ^ { \top } \bar { g } ) \simeq \bar { g } ^ { \top } \bar { \pmb { g } } / b , \qquad \quad \mathbb { E } ( \mathbf { a } ^ { \top } \mathbf { a } ) \simeq \mathbf { a } ^ { \top } \mathbf { a } / b , } \end{array}
187
+ $$
188
+
189
+ 100 where we denote batches of $\mathrm { g } , \bar { g }$ and a, as $\mathbf { g } \in \mathbb { R } ^ { b \times d _ { i } }$ , $\pmb { \bar { g } } \in \mathbb { R } ^ { r b \times d _ { i } }$ and $\mathbf { a } \in \mathbb { R } ^ { b \times d _ { i - 1 } }$ , where our layer
190
+ 101 has $d _ { i - 1 }$ inputs, $d _ { i }$ outputs, $b$ is the batch size, and $r$ is either the number of outputs $m$ or the rank of
191
+ 102 an approximation according to Remark 1. Correspondingly, the K-FAC approximation of the GGN
192
+ 103 matrix and its inverse are concisely expressed as
193
+
194
+ $$
195
+ \begin{array} { r } { \mathbf { G } \approx ( \bar { \pmb { g } } ^ { \top } \bar { \pmb { g } } ) \otimes ( \mathbf { a } ^ { \top } \mathbf { a } ) / b ^ { 2 } \qquad \mathbf { G } ^ { - 1 } \approx \left( \bar { \pmb { g } } ^ { \top } \bar { \pmb { g } } \right) ^ { - 1 } \otimes \left( \mathbf { a } ^ { \top } \mathbf { a } \right) ^ { - 1 } \cdot b ^ { 2 } . } \end{array}
196
+ $$
197
+
198
+ 104 Equipped with the standard terminology and setting, we now introduce the novel, regularized update
199
+ 105 step. First, inspired by the K-FAC approximation (13), the Tikhonov regularized Gauss-Newton
200
+ 106 method (5) can be approximated by
201
+
202
+ $$
203
+ \begin{array} { r } { \boldsymbol { \theta } ^ { ( i ) \prime } = \boldsymbol { \theta } ^ { ( i ) } - \eta ( \bar { \boldsymbol { g } } ^ { \top } \bar { \boldsymbol { g } } / b + \lambda \mathbf { I } ) ^ { - 1 } \otimes ( \mathbf { a } ^ { \top } \mathbf { a } / b + \lambda \mathbf { I } ) ^ { - 1 } { \nabla } _ { \boldsymbol { \theta } ^ { ( i ) } } \mathcal { L } ( f ( x ; \boldsymbol { \theta } ) ) , } \end{array}
204
+ $$
205
+
206
+ 107 with regularization parameter $\lambda > 0$ . A key observation, which is motivated by the structure of
207
+ 108 the above update, is to disentangle the two occurrences of $\lambda$ into two independent regularization
208
+ 109 parameters $\lambda _ { \mathbf { g } } , \lambda _ { \mathbf { a } } > 0$ . By defining the Kronecker-factorized Gauss-Newton update step as
209
+
210
+ $$
211
+ \zeta = \lambda _ { \bf g } \lambda _ { \bf a } ( \bar { g } ^ { \top } \bar { g } / b + \lambda _ { \bf g } { \bf I } ) ^ { - 1 } \otimes ( { \bf a } ^ { \top } { \bf a } / b + \lambda _ { \bf a } { \bf I } ) ^ { - 1 } \nabla _ { \theta ^ { ( i ) } } \mathcal { L } ( f ( x ; \theta ) ) ,
212
+ $$
213
+
214
+ 110 we obtain the concise update equation θ(i)′ = θ(i) − η∗ζ .
215
+
216
+ 111 This update (18) is equivalent to update (16) when in the case of $\begin{array} { r } { \eta ^ { * } = \frac { \eta } { \lambda _ { \mathbf { g } } \lambda _ { \mathbf { a } } } } \end{array}$ and $\lambda = \lambda _ { \mathbf { g } } = \lambda _ { \mathbf { a } }$ . This
217
+ 112 equivalence does not restrict $\eta ^ { * } , \lambda _ { \mathbf { g } } , \lambda _ { \mathbf { a } }$ in any way, and changing $\lambda _ { \mathbf { g } }$ or $\lambda _ { \mathbf { a } }$ does not mean that we
218
+ 113 change our learning rate or step size $\eta ^ { * }$ . Parameterizing $\zeta$ in (17) with the multiplicative terms $\lambda _ { \mathbf { g } } \lambda _ { \mathbf { a } }$
219
+ 114 makes the formulation more convenient for analysis.
220
+ 115 In this paper, we investigate the theoretical and empirical properties of the iterative update rule (18)
221
+ 116 and in particular show how the regularization parameters $\lambda _ { \mathbf { g } } , \lambda _ { \mathbf { a } }$ affect the Kronecker-factorized
222
+ 117 Gauss-Newton update step $\zeta$ . When analyzing the Kronecker-factorized Gauss-Newton update step
223
+ 118 $\zeta$ , a particularly useful tool is the vector product identity,
224
+
225
+ $$
226
+ \left( \left( \bar { \pmb g } ^ { \top } \bar { \pmb g } \right) ^ { - 1 } \otimes \left( { \mathbf a } ^ { \top } { \mathbf a } \right) ^ { - 1 } \right) \mathrm { v e c } ( { \mathbf { g } } ^ { \top } { \mathbf a } ) = \mathrm { v e c } \left( \left( \bar { \pmb g } ^ { \top } \bar { \pmb g } \right) ^ { - 1 } { \mathbf g } ^ { \top } { \mathbf a } \left( { \mathbf a } ^ { \top } { \mathbf a } \right) ^ { - 1 } \right) ,
227
+ $$
228
+
229
+ where the gradient with respect to the weight matrix is 119 $\mathbf { g } ^ { \top } \mathbf { a }$ .
230
+
231
+ # 120 3 Theoretical Guarantees
232
+
233
+ 121 In this section, we investigate the theoretical properties of the Kronecker-factorized Gauss-Newton
234
+ 122 update direction $\zeta$ as defined in (17). We recall that $\zeta$ introduces a Tikonov regularization, as it is
235
+ 123 commonly done in implementations of second order-based methods. Not surprisingly, we show that
236
+ 124 by decreasing the regularization parameters $\lambda _ { \mathbf { g } } , \lambda _ { \mathbf { a } }$ the update rule (18) collapses (in the limit) to the
237
+ 125 classical Gauss-Newton method, and hence in the regime of small $\lambda _ { \mathbf { g } } , \lambda _ { \mathbf { a } }$ the variable $\zeta$ describes the
238
+ 126 Gauss-Newton direction. Moreover, by increasing the regularization strength, we converge (in the
239
+ 127 limit) to the conventional gradient descent update step.
240
+ 128 The key observation is that, as we disentangle the regularization of the two Kronecker factors $\bar { \pmb { g } } ^ { \top } \bar { \pmb { g } }$
241
+ 129 and $\mathbf { a } ^ { \top } \mathbf { a }$ , and consider the setting where only one regularizer is large $\mathbf { \lambda } _ { \mathbf { \lambda } } ^ { \prime } \lambda _ { \mathbf { g } } \mathbf { \lambda } \to \infty$ to be precise),
242
+ 130 we obtain an update direction that can be computed highly efficiently. We show that this setting
243
+ 131 describes an approximated Gauss-Newton update scheme, whose superior numerical performance is
244
+ 132 then empirically demonstrated in Section 4.
245
+
246
+ 133 Theorem 1 (Properties of $\zeta$ ). The $K$ -FAC based update step $\zeta$ as defined in (17) can be expressed as
247
+
248
+ $$
249
+ \boldsymbol { \zeta } = \left( \mathbf { I } _ { m } - \frac { 1 } { b \lambda _ { \mathbf { g } } } \bar { \mathbf { g } } ^ { \top } \left( \mathbf { I } _ { b } + \frac { 1 } { b \lambda _ { \mathbf { g } } } \bar { \mathbf { g } } \bar { \mathbf { g } } ^ { \top } \right) ^ { - 1 } \bar { \mathbf { g } } \right) \cdot \mathbf { g } ^ { \top } \cdot \left( \mathbf { I } _ { b } - \frac { 1 } { b \lambda _ { \mathbf { a } } } \mathbf { a } \mathbf { a } ^ { \top } \left( \mathbf { I } _ { b } + \frac { 1 } { b \lambda _ { \mathbf { a } } } \mathbf { a } ^ { \top } \right) ^ { - 1 } \right) \cdot \mathbf { a } .
250
+ $$
251
+
252
+ 134 Moreover, $\zeta$ admits the following asymptotic properties:
253
+
254
+ (i) In the limit of $\lambda _ { \mathbf { g } } , \lambda _ { \mathbf { a } } 0 ,$ , $\frac { 1 } { \lambda _ { \mathbf { g } } \lambda _ { \mathbf { a } } } \zeta$ is the $K -$ -FAC approximation of the Gauss-Newton step, i.e., $\begin{array} { r } { \operatorname* { l i m } _ { \lambda _ { \mathbf { g } } , \lambda _ { \mathbf { a } } 0 } \frac { 1 } { \lambda _ { \mathbf { g } } \lambda _ { \mathbf { a } } } \zeta \approx \mathbf { G } ^ { - 1 } \bigtriangledown _ { \theta ^ { ( i ) } } \mathcal { L } \big ( f ( x ; \theta ) \big ) } \end{array}$ , where $\approx$ denotes the K-FAC approximation (15).
255
+
256
+ (ii) In the limit of $\lambda _ { \mathbf { g } } , \lambda _ { \mathbf { a } } \to \infty$ , $\zeta$ is the gradient, i.e., $\begin{array} { r } { \operatorname* { l i m } _ { \lambda _ { \mathbf { g } } , \lambda _ { \mathbf { a } } \infty } \zeta = \nabla _ { \theta ^ { ( i ) } } \mathcal { L } ( f ( x ; \theta ) ) } \end{array}$
257
+
258
+ The Proof is deferred to the Supplementary Material.
259
+
260
+ 139 We want to show that $\zeta$ is well-defined and points in the correct direction, not only for $\lambda _ { \mathbf { g } }$ and $\lambda _ { \mathbf { a } }$
261
+ 140 numerically close to zero because we want to explore the full spectrum of settings for $\lambda _ { \mathbf { g } }$ and $\lambda _ { \mathbf { a } }$ .
262
+ 141 Thus, we prove that $\zeta$ is a direction of increasing loss, independent of the choices of $\lambda _ { \mathbf { g } }$ and $\lambda _ { \mathbf { a } }$ .
263
+ 42 Theorem 2 (Correctness of $\zeta$ is independent of $\lambda _ { \mathbf { g } }$ and $\lambda _ { \mathbf { a } , \mathbf { \lambda } }$ ). $\zeta$ is a direction of increasing loss,
264
+ 43 independent of the choices of $\lambda _ { \mathbf { g } }$ and $\lambda _ { \mathbf { a } }$ .
265
+ 144 Proof. Recall that $( \lambda _ { \mathbf { g } } \mathbf { I } _ { m } + \bar { \pmb { g } } ^ { \top } \bar { \pmb { g } } / b )$ and $\left( \lambda _ { \mathbf { a } } \mathbf { I } _ { n } + \mathbf { a } ^ { \top } \mathbf { a } / b \right)$ are positive semi-definite (PSD) matrices by
266
+ 145 definition. Their inverses $( \lambda _ { \mathbf { g } } \mathbf { I } _ { m } + \bar { \pmb { g } } ^ { \top } \bar { \pmb { g } } / b ) ^ { - 1 }$ and $( \lambda _ { \mathbf { a } } \mathbf { I } _ { n } + \mathbf { a } ^ { \top } \mathbf { a } / b ) ^ { - 1 }$ are therefore also PSD. As the
267
+ 146 Kronecker product of PSD matrices is PSD, the conditioning matrix $( ( \lambda _ { \bf g } { \bf I } _ { m } + { \pmb { \bar { g } } } ^ { \top } { \pmb { \bar { g } } } / b ) ^ { - 1 } \otimes ( \lambda _ { \bf a } { \bf I } _ { n } +$
268
+ 147 $\mathbf { a } ^ { \top } \mathbf { a } / b ) ^ { - 1 } \approx \mathbf { G } ^ { - 1 } )$ is PSD, and therefore the direction of the update step remains correct. □
269
+ 148 From our formulation of $\zeta$ , we can find that, in the limit for $\lambda _ { \mathbf { g } } \to \infty$ , Equation (21) does not depend
270
+ 149 on $\bar { \pmb g }$ . This is computationally very beneficial as computing $\bar { \pmb g }$ is costly as it requires one or even
271
+ 150 many additional backpropagation passes. In addition, it allows conditioning the gradient update by
272
+ 151 multiplying a $b \times b$ matrix between $\mathbf { g } ^ { \top }$ and a, which can be done very fast.
273
+ 152 Theorem 3 (Efficient Update Direction). In the limit of $\lambda _ { \mathbf { g } } \infty$ , the update step $\zeta$ converges to
274
+ 153 $\scriptstyle \operatorname* { l i m } _ { \lambda _ { \mathbf { g } } \to \infty } \zeta = \zeta ^ { * }$ , where
275
+
276
+ $$
277
+ \boldsymbol { \zeta } ^ { * } = \mathbf { g } ^ { \top } \cdot \left( \mathbf { I } _ { b } - \frac { 1 } { b \lambda _ { \mathbf { a } } } \mathbf { a } \mathbf { a } ^ { \top } \left( \mathbf { I } _ { b } + \frac { 1 } { b \lambda _ { \mathbf { a } } } \mathbf { a } \mathbf { a } ^ { \top } \right) ^ { - 1 } \right) \cdot \mathbf { a } .
278
+ $$
279
+
280
+ 154 (i) Here, the update direction $\zeta ^ { * }$ is based only on the inputs and does not require computing $\bar { \pmb g }$
281
+ 155 (which would require a second backpropagation pass), making it efficient.
282
+
283
+ (ii) The computational cost of computing the update $\zeta ^ { * }$ lies in $\mathcal { O } ( b n ^ { 2 } + b ^ { 2 } n + b ^ { 3 } )$ , where $n$ is the number of neurons in each layer. This comprises the conventional cost of computing the gradient $\nabla = \mathbf { g } ^ { \intercal } \mathbf { \check { x } }$ lying in $\mathcal { O } ( b n ^ { 2 } )$ , and the overhead of computing $\zeta ^ { * }$ instead of $\nabla$ lying in $\mathcal { O } ( b ^ { 2 } n + b ^ { 3 } )$ . The overhead is vanishing, assuming $n \gg b$ . For $b > n$ the complexity lies in $O ( b n ^ { 2 } + n ^ { 3 } )$ .
284
+
285
+ Proof. We first show the property (21). Note that according to (22), 160 $\lambda _ { \mathbf { g } } \cdot \left( \lambda _ { \mathbf { g } } \mathbf { I } _ { m } + \bar { \pmb { g } } ^ { \top } \bar { \pmb { g } } / b \right) ^ { - 1 }$ con161 verges in the limit of $\lambda _ { \mathbf { g } } \to \infty$ to ${ \mathbf I } _ { m }$ , and therefore (21) holds.
286
+
287
+ 162 (i) The statement follows from the fact that the term $\bar { \pmb g }$ does not appear in the equivalent characterization (21) of 163 $\zeta ^ { * }$ .
288
+
289
+ (ii) We first note that the matrix 164 $\mathbf { a } \mathbf { a } ^ { \top }$ is of dimension $b \times b$ , and can be computed in $\mathcal { O } ( b ^ { 2 } n )$ time. 165 Next, the matrix
290
+
291
+ $$
292
+ \left( \mathbf { I } _ { b } - { \frac { 1 } { b \lambda _ { \mathbf { a } } } } \mathbf { a } \mathbf { a } ^ { \top } \left( \mathbf { I } _ { b } + { \frac { 1 } { b \lambda _ { \mathbf { a } } } } \mathbf { a } \mathbf { a } ^ { \top } \right) ^ { - 1 } \right)
293
+ $$
294
+
295
+ is of shape 166 $b \times b$ and can be multiplied with a in $\mathcal { O } ( b ^ { 2 } n )$ time.
296
+
297
+ 167 Notably, (21) can be computed with a vanishing computational overhead and with only minor
298
+ 168 modifications to the implementation. Specifically, only the $\mathbf { g } ^ { \top } \mathbf { a }$ expression has to be replaced by (21)
299
+ 169 in the backpropagation step. As this can be done independently for each layer, this lends itself also to
300
+ 170 applying it only to individual layers.
301
+ 171 As we see in the experimental section, in many cases in the mini-batch regime (i.e., $b < n$ ), the
302
+ 172 optimal (or a good) choice for $\lambda _ { \mathbf { g } }$ actually lies in the limit to $\infty$ . This is a surprising result, leading to
303
+ 173 the efficient and effective $\zeta ^ { * } = \breve { \zeta } _ { \lambda _ { \bf g } \to \infty }$ optimizer.
304
+ 174 Remark 2 (Relation between Update Direction $\zeta$ and $\zeta ^ { * }$ ). When comparing the update direction
305
+ 175 $\zeta$ in (20) without regularization (i.e., $\lambda _ { \mathbf { g } } 0 , \lambda _ { \mathbf { a } } 0 ,$ ) with $\zeta ^ { * }$ (i.e., $\lambda _ { \mathbf { g } } \infty ,$ ) as given in (21), it
306
+ 176 can be directly seen that $\zeta ^ { * }$ corresponds to a particular pre-conditioning of $\zeta$ , since $\zeta ^ { * } = M \zeta$ for
307
+ 177 $\begin{array} { r } { M = \frac { 1 } { b \lambda _ { \mathbf { g } } } \bar { \pmb { g } } ^ { \top } \dot { \pmb { g } } } \end{array}$ .
308
+
309
+ As the last theoretical property of our proposed update direction 78 $\zeta ^ { * }$ , we show that in specific networks 79 $\zeta ^ { * }$ coincides with the Gauss-Newton update direction.
310
+
311
+ 80 Theorem 4 0 $\zeta ^ { * }$ is Exact for the Last Layer). For the case of linear regression or, more generally, the last layer of networks, with the mean squared error, 1 $\zeta ^ { * }$ is the Gauss-Newton update direction.
312
+
313
+ 2 Proof. The Hessian matrix of the mean squared error loss is the identity matrix. Correspondingly, the expectation value of 3 $\bar { \pmb { g } } ^ { \top } \bar { \pmb { g } }$ is $\mathbf { I }$ . Thus, ${ \zeta } ^ { * } = \zeta$ . □
314
+
315
+ Remark 3. The direction $\zeta ^ { * }$ corresponds to the Gauss-Newton update direction with an approximation of G that can be expressed as $\begin{array} { r } { \dot { \mathbf { G } } \approx \mathbb { E } \left[ \mathbf { I } \otimes ( \mathrm { a } ^ { \top } \mathrm { a } ) \right] } \end{array}$ .
316
+
317
+ 86 Remark 4 (Extension to the Natural Gradient). In some cases, it might be more desirable to use the
318
+ 87 Fisher-based natural gradient instead of the Gauss-Newton method. The difference to this setting is
319
+ 88 that in (5) the GGN matrix $\mathbf { G }$ is replaced by the empirical Fisher information matrix $\mathbf { F }$ .
320
+ 189 We note that our theory also applies to $\mathbf { F }$ , and that $\zeta ^ { * }$ also efficiently approximates the natural
321
+ 190 gradient update step $\mathbf { F } ^ { - 1 } \nabla$ . The $i$ -th diagonal block of $\mathbf { F } ( \mathbf { F } _ { \theta ^ { ( i ) } } = \mathbb { E } \left[ ( \mathbf { g } _ { i } ^ { \top } \mathbf { g } _ { i } ) \otimes \left( a _ { i - 1 } ^ { \top } \otimes a _ { i - 1 } \right) \right] ,$ ),
322
+ 191 has the same form as a block of the GGN matrix $\mathbf { G }$ $( \mathbf { G } _ { \theta ( i ) } = \mathbb { E } \left[ \left( \bar { g } _ { i } ^ { \top } \bar { g } _ { i } \right) \otimes \left( a _ { i - 1 } ^ { \top } \otimes a _ { i - 1 } \right) \right] ,$ .
323
+ 192 Thus, we can replace $\bar { \pmb g }$ with $\mathbf { g }$ in our theoretical results to obtain their counterparts for $\mathbf { F }$ .
324
+
325
+ ![](images/2b30a38057bd906af92f0b317b1e6de9a7c85b0e36a5e5a500d46f6103ab9903.jpg)
326
+ Figure 1: Logarithmic training loss (top) and test accuracy (bottom) on the MNIST classification task. The axes are the regularization parameters $\lambda _ { \mathbf { g } }$ and $\lambda _ { \mathbf { a } }$ in logarithmic scale with base 10. Training with a 5-layer ReLU activated network with 100 (left, a, e), 400 (center, b, c, f, g), and 1 600 (right, d, h) neurons per layer. The optimizer is SGD except for (c, g) where the optimizer is SGD with momentum. The top-left sector is $\zeta$ , the top-right column is $\zeta ^ { * }$ , and the bottom-right corner is $\nabla$ (gradient descent). For each experiment and each of the three sectors, we use one learning rate, i.e., ζ , $\zeta ^ { * }$ , $\nabla$ have their own learning rate to make a fair comparison between the methods; within each sector the learning rate is constant. We can observe that in the limit of $\lambda _ { \mathbf { g } } \to \infty$ (i.e., in the limit to the right) the performance remains good, showing the utility of $\zeta ^ { * }$ .
327
+
328
+ # 193 4 Experiments
329
+
330
+ 194 In the previous section, we discussed the theoretical properties of the proposed update directions
331
+ 195 $\zeta$ and $\bar { \zeta } ^ { * }$ with the aspect that $\zeta ^ { * }$ would actually be “free” to compute in the mini-batch regime. In
332
+ 196 this section, we provide empirical evidence that $\zeta ^ { * }$ is a good update direction, even in deep learning.
333
+ 197 Specifically, we demonstrate that
334
+
335
+ (E1) $\zeta ^ { * }$ achieves similar performance to K-FAC, while being substantially cheaper to compute.
336
+ (E2) The performance of our proposed method can be empirically maintained in the mini-batch regime $( n \gg b$ ).
337
+ (E3) $\zeta ^ { * }$ may be used for individual layers, while for other layers only the gradient $\nabla$ is used. This still leads to improved performance.
338
+ (E4) $\zeta ^ { * }$ also improves the performance for training larger models such as BERT and ResNet.
339
+ (E5) The runtime and memory requirements of $\zeta ^ { * }$ are comparable to those of gradient descent.
340
+
341
+ # E1: Impact of Regularization Parameters
342
+
343
+ 206 For (E1), we study the dependence of the model’s performance on the regularization parameters $\lambda _ { \mathbf { g } }$
344
+ 207 and $\lambda _ { \mathbf { a } }$ . Here, we train a 5-layer deep neural network on the MNIST classification task [16] with a
345
+ 208 batch size of 60 for a total of 40 epochs or 40 000 steps.
346
+ 209 The plots in Figure 1 demonstrate that the advantage of training by conditioning with curvature
347
+ 210 information can be achieved by considering both layer inputs a and gradients with respect to random
348
+ 211 samples $\bar { \pmb g }$ , but also using only layer inputs a. In the plot, we show the performance of $\zeta$ for different
349
+ 212 choices of $\lambda _ { \mathbf { g } }$ and $\lambda _ { \mathbf { a } }$ , each in the range from $1 0 ^ { - 6 }$ to $1 0 ^ { 6 }$ . The right column shows $\zeta ^ { * }$ , i.e., $\lambda _ { \mathbf { g } } = \infty$
350
+ 213 for different $\lambda _ { \mathbf { a } }$ . The bottom-right corner is gradient descent, which corresponds to $\lambda _ { \mathbf { g } } = \infty$ and
351
+ 214 $\lambda _ { \mathbf { a } } = \infty$ .
352
+ 215 Newton’s method or the general K-FAC approximation corresponds to the area with small $\lambda _ { \mathbf { g } }$ and $\lambda _ { \mathbf { a } }$ .
353
+ 216 The interesting finding here is that the performance does not suffer by increasing $\lambda _ { \mathbf { g } }$ toward $\infty$ , i.e.,
354
+ 217 from left to right in the plot.
355
+ 218 In addition, in Figure 3, we consider the case of regression with an auto-encoder trained with the
356
+ 219 MSE loss on MNIST [16] and Fashion-MNIST [17]. Here, we follow the same principle as above
357
+ 220 and also find that $\zeta ^ { * }$ performs well.
358
+
359
+ ![](images/c7cf54c4d8999d9b96f020e4d4718ca41150d9a79264135a0259836bb14ee44c.jpg)
360
+ Figure 2: Training loss of the MNIST auto-encoder trained with gradient descent, K-FAC, $\zeta$ , and $\zeta ^ { * }$ . Comparing the performance per real-time (left) and per number of update steps (right). Runtimes are for a CPU core.
361
+
362
+ In Figure 7, we compare the loss for different methods. Here, we distinguish between loss per time (left) and loss per number of steps (right). We can observe that, for $\lambda = 0 . 1$ , K-FAC, $\zeta$ , and $\zeta ^ { * }$ are almost identical per update step (right), while $\zeta ^ { * }$ is by a large margin the fastest, followed by $\zeta$ , and the conventional K-FAC implementation is the slowest (left). On the other hand, for $\lambda = 0 . 0 1$ we can achieve a faster convergence than with $\lambda = 0 . 1$ , but here only the K-FAC and $\zeta$ methods are numerically stable, while $\zeta ^ { * }$ is unstable in this case. This means in the regime of very small $\lambda$ , $\zeta ^ { * }$ is not as robust as KFAC and $\zeta$ , however, it achieves good performance with small but moderate $\lambda$ like $\lambda = 0 . 1$ . For $\lambda < 0 . 0 1$ , also K-FAC and $\zeta$ become numerically unstable in this setting and, in general, we observed that the smallest valid $\lambda$ for K-FAC is 0.01 or 0.001 depending on model and task. Under consideration of the runtime, $\zeta ^ { * }$ performs best as it is almost as fast as gradient descent while performing equivalent to K-FAC and $\zeta$ Specifically, a gradient descent step is only about $1 0 \%$ faster than $\zeta ^ { * }$ .
363
+
364
+ ![](images/c5de3ca8281be8eb8237a8cdd010a2dcca9bd0a9aa1f72e320611c72e02b8c24.jpg)
365
+ Figure 3: Training an auto-encoder on MNIST (left) and FashionMNIST (right). The model is the same as used by Botev et al. [18], i.e., it is a ReLU-activated 6-layer fully connected model with dimensions $7 8 4 - 1 0 0 0 - 5 0 0 - \ 3 0 - 5 0 0 - 1 0 0 0 - 7 8 4$ . Displayed is the logarithmic training loss.
366
+
367
+ ![](images/7564d7daabb05b74421abf4e21adb180f1c0fc64f7e598c37fc2393a7143a8b1.jpg)
368
+ Figure 4: Training a 5-layer ReLU network with 400 neurons per layer on the MNIST classification task (as in Figure 1) but with the Adam optimizer [19].
369
+
370
+ # E2: Minibatch Regime
371
+
372
+ For (E2), in Figure 1, we can see that training performs well for $n \in \{ 1 0 0 , 4 0 0 , 1 6 0 0 \}$ neurons per layer at a batch size of only 60. Also, in all other experiments, we use small batch sizes of between 8 and 100.
373
+
374
+ # E3: $\zeta ^ { * }$ in Individual Layers
375
+
376
+ In Figure 5, we train the 5-layer fully connected model with 400 neurons per layer. Here, we consider the setting that we use $\zeta ^ { * }$ in some of the layers while using the default gradient $\nabla$ in other layers. Specifically, we consider the
377
+
378
+ ![](images/f4ef58eb0309da21b357064a667fb3ec1afd5d6e7ebde9372f4b310ca4a78822.jpg)
379
+ Figure 5: Training on the MNIST classification task using $\zeta ^ { * }$ only in selected layers. Runtimes are for CPU.
380
+
381
+ Table 1: BERT results for fine-tuning pre-trained BERT-Base (B-B) and BERT-Mini (B-M) models on the COLA, MRPC, and STSB text classification tasks. Larger values are better for all metrics. MCC is the Matthews correlation. Results averaged over 10 runs.
382
+
383
+ <table><tr><td>Method /Setting</td><td>CoLA (B-B)</td><td>CoLA (B-M)</td><td colspan="2">MRPC (B-B)</td><td colspan="2">STS-B (B-M)</td></tr><tr><td>Metric</td><td>MCC</td><td>MCC</td><td>Acc.</td><td>F1</td><td>Pearson</td><td>Spearman</td></tr><tr><td>Gradient baseline</td><td>54.20 ± 7.56</td><td>21.08 ± 2.88</td><td>82.52 ±1.22</td><td>87.88 ±0.74</td><td>76.98 ± 1.10</td><td>76.88 ±0.79</td></tr><tr><td>s*</td><td>57.62 ± 1.59</td><td>24.67 ± 2.62</td><td>83.28±0.89</td><td>88.28±0.70</td><td>81.09 ± 1.58</td><td>80.82 ±1.57</td></tr></table>
384
+
385
+ settings, where all, the first, the final, the first three, the final three, the odd numbered, and the even numbered layers are updated by $\zeta ^ { * }$ . We observe that all settings with $\zeta ^ { * }$ perform better than plain gradient descent, except for $^ { 6 6 } \zeta ^ { * }$ for layers $3 , 4 , 5 '$ which performs approximately equivalent to gradient descent.
386
+
387
+ # E4: Large-scale Models
388
+
389
+ BERT To demonstrate the utility of $\zeta ^ { * }$ also in large-scale models, we evaluate it for fine-tuning BERT [20] on three natural language tasks. In Table 1, we summarize the results for the BERT fine-tuning task. For the “Corpus of Linguistic Acceptability” (CoLA) [21] data set, we fine-tune both the BERT-Base and the BERT-Mini models and find that we outperform the gradient descent baseline in both cases. For the “Microsoft Research Paraphrase Corpus” (MRPC) [22] data set, we fine-tune the BERT-Base model and find that we outperform the baseline both in terms of accuracy and F1-score. Finally, on the “Semantic Textual Similarity Benchmark” (STS-B) [23] data set, we fine-tune the BERT-Mini model and achieve higher Pearson and Spearman correlations than the baseline. While for training with CoLA and MRPC, we were able to use the Adam optimizer [19] (which is recommended for this task and model) in conjunction with $\zeta ^ { * }$ in place of the gradient, for STS-B Adam did not work well. Therefore, for STS-B, we evaluated it using the SGD with momentum optimizer. For each method, we performed a grid search over the hyperparameters. We note that we use a batch size of 8 in all BERT experiments.
390
+
391
+ ResNet In addition, we conduct an experiment where we train the last layer of a ResNet with $\zeta ^ { * }$ , while the remainder of the model is updated using the gradient $\nabla$ . Here, we train a ResNet-18 [24] on CIFAR-10 [25] using SGD with a batch size of 100 in a vanilla setting, i.e., without additional tricks employed in by He et al. [24] and others. Specifically, we use (i) a constant learning rate for each training (optimal from $( 1 , 0 . 3 , 0 . \bar { 1 } , 0 . 0 3 , 0 . 0 1 ) )$ and (ii) vanilla SGD and not momentum-based SGD. The reason behind this is that we want a vanilla experiment and with aspects such as extensively tuning multiple parameters of learning rate scheduler would make the evaluation less transparent; how
392
+
393
+ ![](images/bac99832df68cbd0b592c8da2d1c14c846e72daa38864257b2bb886360647fd5.jpg)
394
+ Figure 6: ResNet-18 trained on CIFAR-10. Runtimes are for a GPU. Results are averaged over 5 runs.
395
+
396
+ ever, therefore, all accuracies are naturally lower than SOTA. In Figure 6, we plot the test accuracy against time. The results show that the proposed method outperforms vanilla SGD when applied to the last layer of a ResNet-18. To validate that the learning rate is not the cause for the better performance, we also plot the neighboring learning rates and find that even with a too small or too large learning rate $\zeta ^ { * }$ outperforms gradient descent with the optimal learning rate.
397
+
398
+ # E5: Runtime and Memory
399
+
400
+ Finally, we also evaluate the runtime and memory requirements of each method. The runtime evaluation is displayed in Table 2. We report both CPU and GPU runtime using PyTorch [26] and (for K-FAC) the backpack library [15]. Note that the CPU runtime is more representative of the pure computational cost, as for the first rows of the GPU runtime the overhead of calling the GPU is dominant. When comparing runtimes between the gradient and $\zeta ^ { * }$ on the GPU, we can observe that we have an overhead of around $2 . 5 s$ independent of the model size. The overhead for CPU time is also very small at less than $1 \%$ for the largest model, and only $1 . 3 s$ for the smallest model. In
401
+
402
+ 08 contrast, the runtime of $\zeta ^ { * }$ is around 4 times the runtime of the gradient, and K-FAC has an even
403
+ 09 substantially larger runtime. Regarding memory, $\zeta ^ { * }$ (contrasting the other approaches) also requires
404
+ 10 only a small additional footprint.
405
+ 311 Remark 5 (Implementation). The implementation of $\zeta ^ { * }$ can be done by replacing the backpropagation
406
+ 312 step of a respective layer by (21). As all “ingredients” are already available in popular deep learning
407
+ 313 frameworks, it requires only little modification (contrasting $K$ -FAC and $\zeta$ , which require at least one
408
+ 314 additional backpropagation.)
409
+
410
+ Table 2: Runtimes and memory requirements for different models. Runtime is the training time per epoch on MNIST at a batch size of 60, i.e., for 1 000 training steps. The K-FAC implementation is from the backpack library [15]. The GPU is an Nvidia A6000.
411
+
412
+ <table><tr><td>Model</td><td colspan="3">Gradient</td><td colspan="3">K-FAC</td><td colspan="3">s</td><td colspan="3">S*</td></tr><tr><td></td><td>CPU time GPU time</td><td></td><td>Memory</td><td>CPU time</td><td>GPU t.</td><td>Memory</td><td>CPU time</td><td>GPU t.</td><td>Memory</td><td>CPU t.</td><td>GPU t.</td><td>Memory</td></tr><tr><td>5 layers w/100 n.</td><td>2.05 s</td><td>1.79 s</td><td>1.0MB</td><td>62.78 s</td><td>17.63 s</td><td>11.5 MB</td><td></td><td>8.65 s 11.76 s</td><td>1.6 MB</td><td>3.34s</td><td>4.07 s</td><td>1.0MB</td></tr><tr><td>5 layers w/400 n.</td><td>23.74 s</td><td>1.84 s</td><td>4.8MB</td><td>218.48 s</td><td>32.00 s</td><td>22.4MB</td><td>38.67 s 12.62 s</td><td></td><td>7.7MB</td><td>13.62 s</td><td>4.19 s</td><td>4.9 MB</td></tr><tr><td>5 layers w/1600 n.</td><td>187.87 s</td><td>1.93 s</td><td></td><td>51.0MB 6985.48 s</td><td>156.48 s</td><td>212.2MB</td><td>665.80s12.53 s</td><td></td><td>85.8MB</td><td>291.01 s</td><td>4.49 s</td><td>51.4MB</td></tr><tr><td>5 layers w/6 400 n. 3439.59 s</td><td></td><td>8.22s</td><td>691.0MB</td><td></td><td></td><td>1320.81s3155.3MB</td><td></td><td></td><td>9673s 31.87s 1197.8 MB 3451.61s 10.24 s 692.5 MB</td><td></td><td></td><td></td></tr><tr><td>Auto-Encoder</td><td>78.61 s</td><td>2.20 s</td><td>16.2MB</td><td>1207.58 s</td><td>74.09 s</td><td>70.7MB</td><td>193.25 s 14.19 s</td><td></td><td>33.8MB</td><td>87.39 s</td><td>4.93 s</td><td>16.5MB</td></tr></table>
413
+
414
+ 315 We will publish the source code of our implementation. In the appendix, we give a PyTorch [26] implementation of the proposed method16 $( \zeta ^ { \bar { * } } )$ .
415
+
416
+ # 7 5 Related Work
417
+
418
+ 18 Our methods are related to K-FAC by Martens and Grosse [12]. K-FAC uses the approximation
419
+ 19 (13) to approximate the blocks of the Hessian of the empirical risk of neural networks. In most
420
+ 20 implementations of K-FAC, the off-diagonal blocks of the Hessian are also set to zero. One of the
421
+ 1 main claimed benefits of K-FAC is its speed (compared to stochastic gradient descent) for large-batch
422
+ 22 size training. That said, recent empirical work has shown that this advantage of K-FAC disappears
423
+ 23 once the additional computational costs of hyperparameter tuning for large batch training is accounted
424
+ 24 for. There is a line of work that extends the basic idea of K-FAC to convolutional layers [27]. Botev et
425
+ 25 al. [18] further extend these ideas to present KFLR, a Kronecker factored low-rank approximation,
426
+ 26 and KFRA, a Kronecker factored recursive approximation of the Gauss-Newton step. Singh and
427
+ 7 Alistarh [28] propose WoodFisher, a Woodbury matrix inverse-based estimate of the inverse Hessian,
428
+ 28 and apply it to neural network compression. Yao et al. [29] propose AdaHessian, a second-order
429
+ 29 optimizer that incorporates the curvature of the loss function via an adaptive estimation of the Hessian.
430
+ 0 Frantar et al. [6] propose M-FAC, a matrix-free approximation of the natural gradient through a queue
431
+ of the (e.g., 1 000) recent gradients. These works fundamentally differ from our approach in that their
432
+ 32 objective is to approximate the Fisher or Gauss-Newton matrix inverse vector products. In contrast,
433
+ 33 this work proposes to approximate the Gauss-Newton matrix by only one of its Kronecker factors,
434
+ 34 which we find to achieve good performance at a substantial computational speedup and reduction of
435
+ 5 memory footprint. For an overview of this area, we refer to Kunstner et al. [30] and Martens [31].
436
+ 36 For an overview of the technical aspects of backpropagation of second-order quantities, we refer to
437
+ 7 Dangel et al. [15], [32]
438
+ 338 Taking a step back, K-FAC is one of many Newton-type methods for training neural networks.
439
+ 339 Other prominent examples of such methods include subsampled Newton methods [33], [34] (which
440
+ 340 approximate the Hessian by subsampling the terms in the empirical risk function and evaluating the
441
+ 341 Hessian of the subsampled terms) and sketched Newton methods [3]–[5] (which approximate the
442
+ 342 Hessian by sketching, e.g., by projecting the Hessian to a lower-dimensional space by multiplying it
443
+ 343 with a random matrix). The main features that distinguish K-FAC from this group of methods are
444
+ 344 K-FAC’s superior empirical performance and K-FAC’s lack of theoretical justification.
445
+
446
+ # 6 Conclusion
447
+
448
+ In this work, we presented ISAAC Newton, a novel approximate curvature method based on layerinputs. We demonstrated it to be a special case of the regularization-generalized Gauss-Newton method and empirically demonstrate its utility. Specifically, our method features an asymptotically vanishing computational overhead in the mini-batch regime, while achieving competitive empirical performance on various benchmark problems.
449
+
450
+ 353 learning in linear time,” Journal on Machine Learning Research, vol. 18, no. 1, pp. 4148–4187,
451
+ 354 2017.
452
+ 355 [2] J. Nocedal and S. J. Wright, Numerical Optimization, 2e. New York, NY, USA: Springer, 2006.
453
+ 356 [3] A. Gonen and S. Shalev-Shwartz, “Faster SGD using sketched conditioning,” arXiv preprint,
454
+ 357 arXiv:1506.02649, 2015.
455
+ 358 [4] M. Pilanci and M. J. Wainwright, “Newton sketch: A near linear-time optimization algorithm
456
+ 359 with linear-quadratic convergence,” SIAM Journal on Optimization, vol. 27, 2017.
457
+ 360 [5] M. A. Erdogdu and A. Montanari, “Convergence rates of sub-sampled Newton methods,” in
458
+ 361 Proc. Neural Information Processing Systems (NeurIPS), 2015.
459
+ 362 [6] E. Frantar, E. Kurtic, and D. Alistarh, “M-FAC: Efficient matrix-free approximations of
460
+ 363 second-order information,” in Proc. Neural Information Processing Systems (NeurIPS), 2021.
461
+ 364 [7] N. Doikov and Y. Nesterov, “Convex Optimization based on Global Lower Second-order
462
+ 365 Models,” in Proc. Neural Information Processing Systems (NeurIPS), Curran Associates, Inc.,
463
+ 366 2020.
464
+ 367 [8] Y. Nesterov and B. T. Polyak, “Cubic regularization of Newton method and its global perfor
465
+ 368 mance,” Mathematical Programming, vol. 108, 2006.
466
+ 369 [9] S. Becker and Y. Lecun, “Improving the convergence of back-propagation learning with
467
+ 370 second-order methods,” 1989.
468
+ 371 [10] T. Schaul, S. Zhang, and Y. LeCun, “No more pesky learning rates,” in International Conference
469
+ 372 on Machine Learning (ICML), 2013.
470
+ 373 [11] Y. Ollivier, “Riemannian metrics for neural networks i: Feedforward networks,” Information
471
+ 374 and Inference, vol. 4, pp. 108–153, Jun. 2015.
472
+ 375 [12] J. Martens and R. Grosse, “Optimizing neural networks with Kronecker-factored approximate
473
+ 376 curvature,” in International Conference on Machine Learning (ICML), 2015.
474
+ 377 [13] A. N. Tikhonov and V. Y. Arsenin, Solutions of Ill-posed problems. W.H. Winston, 1977.
475
+ 378 [14] P. Chen, “Hessian matrix vs. Gauss—Newton Hessian matrix,” SIAM Journal on Numerical
476
+ 379 Analysis, 2011.
477
+ 380 [15] F. Dangel, F. Kunstner, and P. Hennig, “Backpack: Packing more into backprop,” in Interna
478
+ 381 tional Conference on Learning Representations, 2020.
479
+ 382 [16] Y. LeCun, C. Cortes, and C. Burges, “MNIST Handwritten Digit Database,” ATT Labs, 2010.
480
+ 383 [17] H. Xiao, K. Rasul, and R. Vollgraf, “Fashion-MNIST: A novel image dataset for benchmarking
481
+ 384 machine learning algorithms,” arXiv, 2017.
482
+ 385 [18] A. Botev, H. Ritter, and D. Barber, “Practical Gauss-Newton optimisation for deep learning,”
483
+ 386 in International Conference on Machine Learning (ICML), 2017.
484
+ 387 [19] D. Kingma and J. Ba, “Adam: A method for stochastic optimization,” in International Confer
485
+ 388 ence on Learning Representations (ICLR), 2015.
486
+ 389 [20] J. Devlin, M.-W. Chang, K. Lee, and K. Toutanova, “Bert: Pre-training of deep bidirectional
487
+ 390 transformers for language understanding,” in North American Chapter of the Association for
488
+ 391 Computational Linguistics: Human Language Technologies (NAACL-HLT), 2018.
489
+ 392 [21] A. Warstadt, A. Singh, and S. R. Bowman, “Neural network acceptability judgments,” Trans
490
+ 393 actions of the Association for Computational Linguistics, vol. 7, 2019.
491
+ 394 [22] W. B. Dolan and C. Brockett, “Automatically constructing a corpus of sentential paraphrases,”
492
+ 395 in Proceedings of the Third International Workshop on Paraphrasing (IWP2005), 2005.
493
+ 396 [23] D. Cer, M. Diab, E. Agirre, I. Lopez-Gazpio, and L. Specia, “SemEval-2017 task 1: Semantic
494
+ 397 textual similarity multilingual and crosslingual focused evaluation,” in Proceedings of the
495
+ 398 11th International Workshop on Semantic Evaluation (SemEval-2017), Vancouver, Canada:
496
+ 399 Association for Computational Linguistics, 2017.
497
+ 400 [24] K. He, X. Zhang, S. Ren, and J. Sun, “Deep residual learning for image recognition,” in
498
+ 401 Proc. International Conference on Computer Vision and Pattern Recognition (CVPR), 2016.
499
+ 402 [25] A. Krizhevsky, V. Nair, and G. Hinton, “Cifar-10 (Canadian Institute for Advanced Research),”
500
+ 403 2009.
501
+ 404 [26] A. Paszke, S. Gross, F. Massa, et al., “Pytorch: An imperative style, high-performance deep
502
+ 405 learning library,” in Proc. Neural Information Processing Systems (NeurIPS), 2019.
503
+ 406 [27] R. Grosse and J. Martens, “A Kronecker-factored approximate Fisher matrix for convolution
504
+ 407 layers,” in International Conference on Machine Learning (ICML), 2016.
505
+ 408 [28] S. P. Singh and D. Alistarh, “Woodfisher: Efficient second-order approximation for neural
506
+ 409 network compression,” in Proc. Neural Information Processing Systems (NeurIPS), 2020.
507
+ 410 [29] Z. Yao, A. Gholami, S. Shen, M. Mustafa, K. Keutzer, and M. W. Mahoney, “Adahessian:
508
+ 411 An adaptive second order optimizer for machine learning,” in AAAI Conference on Artificial
509
+ 412 Intelligence, 2021.
510
+ 413 [30] F. Kunstner, L. Balles, and P. Hennig, “Limitations of the empirical Fisher approximation for
511
+ 414 natural gradient descent,” in Proc. Neural Information Processing Systems (NeurIPS), 2019.
512
+ 415 [31] J. Martens, “New insights and perspectives on the natural gradient method,” Journal of Machine
513
+ 416 Learning Research, 2020.
514
+ 417 [32] F. Dangel, S. Harmeling, and P. Hennig, “Modular block-diagonal curvature approximations
515
+ 418 for feedforward architectures,” in International Conference on Artificial Intelligence and
516
+ 419 Statistics (AISTATS), 2020.
517
+ 420 [33] F. Roosta-Khorasani and M. W. Mahoney, “Sub-Sampled Newton Methods I: Globally Con
518
+ 421 vergent Algorithms,” arXiv: 1601.04737, 2016.
519
+ 422 [34] P. Xu, J. Yang, F. Roosta, C. Re, and M. W. Mahoney, “Sub-sampled Newton Methods with ´
520
+ 423 Non-uniform Sampling,” in Proc. Neural Information Processing Systems (NeurIPS), 2016.
521
+
522
+ 1. For all authors...
523
+
524
+ (a) Do the main claims made in the abstract and introduction accurately reflect the paper’s contributions and scope? [Yes]
525
+ (b) Did you describe the limitations of your work? [Yes]
526
+ (c) Did you discuss any potential negative societal impacts of your work? [N/A]
527
+ (d) Have you read the ethics review guidelines and ensured that your paper conforms to them? [Yes]
528
+
529
+ 2. If you are including theoretical results...
530
+
531
+ (a) Did you state the full set of assumptions of all theoretical results? [Yes] (b) Did you include complete proofs of all theoretical results? [Yes]
532
+
533
+ 3. If you ran experiments...
534
+
535
+ (a) Did you include the code, data, and instructions needed to reproduce the main experimental results (either in the supplemental material or as a URL)? [Yes] / [No] We include a Python / PyTorch implementation of the method in the supplementary material. We will publicly release full source code for the experiments.
536
+ (b) Did you specify all the training details (e.g., data splits, hyperparameters, how they were chosen)? [Yes]
537
+ (c) Did you report error bars (e.g., with respect to the random seed after running experiments multiple times)? [Yes]
538
+ (d) Did you include the total amount of compute and the type of resources used (e.g., type of GPUs, internal cluster, or cloud provider)? [Yes]
539
+
540
+ 4. If you are using existing assets (e.g., code, data, models) or curating/releasing new assets...
541
+
542
+ (a) If your work uses existing assets, did you cite the creators? [Yes]
543
+ (b) Did you mention the license of the assets? [N/A]
544
+ (c) Did you include any new assets either in the supplemental material or as a URL? [N/A]
545
+ (d) Did you discuss whether and how consent was obtained from people whose data you’re using/curating? [N/A]
546
+ (e) Did you discuss whether the data you are using/curating contains personally identifiable information or offensive content? [N/A]
547
+
548
+ 5. If you used crowdsourcing or conducted research with human subjects...
549
+
550
+ (a) Did you include the full text of instructions given to participants and screenshots, if applicable? [N/A]
551
+ (b) Did you describe any potential participant risks, with links to Institutional Review Board (IRB) approvals, if applicable? [N/A]
552
+ (c) Did you include the estimated hourly wage paid to participants and the total amount spent on participant compensation? [N/A]
553
+
554
+ # 461 A PyTorch Implementation
555
+
556
+ 462 We display a PyTorch [26] implementation of ISAAC for a fully-connected layer below. Here, we
557
+ 463 mark the important part (i.e., the part beyond the boilerplate) with a red rectangle.
558
+
559
+ import torch
560
+
561
+ class ISAACLinearFunction(torch.autograd.Function): @staticmethod def forward(ctx, input, weight, bias, la, inv_type): ctx.save_for_backward(input, weight, bias) ctx. $\mathtt { \Delta } \mathtt { l a } ~ = ~ \mathtt { 1 a }$ if inv_type $\scriptstyle = = \quad$ cholesky_inverse': ctx.inverse $=$ torch.cholesky_inverse elif inv_type $= =$ 'inverse': ctx.inverse $=$ torch.inverse else: raise NotImplementedError(inv_type) return input $\circledcirc$ weight.T $^ +$ (bias if bias is not None else 0)
562
+
563
+ # @staticmethod
564
+
565
+ ef backward(ctx, grad_output): input, weight, bias $=$ ctx.saved_tensors if ctx.needs_input_grad[0]: grad_ $. 0 \ =$ grad_output $\circledcirc$ weight else: grad_0 $=$ None
566
+
567
+ if ctx.needs_input_grad[1]:
568
+
569
+ aaT $=$ input $\circledcirc$ input.T / grad_output.shape[0]
570
+ I_b $=$ torch.eye(aaT.shape[0], device $=$ aaT.device, dtype aaT.dtype)
571
+ aaT_IaaT_inv $=$ aaT @ ctx.inverse(aaT / ctx.la $^ +$ I_b)
572
+ grad_1 $=$ grad_output.T $\circledcirc$ ( I_b - 1. / ctx.la $^ *$ aaT_IaaT_inv
573
+ ) $\circledcirc$ input
574
+
575
+ else: grad_1 $=$ None
576
+
577
+ return ( grad_0, grad_1, grad_output.mean(0, keepdim $\cdot ^ { = }$ True) if bias is not None else None, None, None, None,
578
+ )
579
+
580
+ class ISAACLinear(torch.nn.Linear): def __init__(self, in_features, out_features, la, inv_type $= ^ { 1 }$ inverse', $^ { \ast \ast }$ kwargs): super(ISAACLinear, self).__init__( in_features $=$ in_features, out_features $=$ out_features, \*\*kwargs ) self. $1 \mathsf { a } \ = \ 1 \mathsf { a }$ self.inv_type $=$ inv_type def forward(self, input: torch.Tensor) -> torch.Tensor: return ISAACLinearFunction.apply( input, self.weight,
581
+
582
+ self.bias.unsqueeze(0) if self.bias is not None else None, self.la, self.inv_type )
583
+
584
+ # 464 B Implementation Details
585
+
586
+ Unless noted differently, for all experiments, we tune the learning rate on a grid of $( 1 , 0 . 3 , 0 . 1 , 0 . 0 3 , 0 . 0 1 , 0 . \dot { 0 } 0 3 , 0 . 0 0 1 )$ . We verified this range to cover the full reasonable range of learning rates. Specifically, for every single experiment, we made sure that there is no learning rate outside this range which performs better.
587
+
588
+ For all language model experiments, we used the respective Huggingface PyTorch implementation.
589
+
590
+ 70 All other hyperparameter details are given in the main paper.
591
+
592
+ 71 The code will be made publicly available.
593
+
594
+ # 472 C Additional Proofs
595
+
596
+ 473 Proof of Theorem 1. We first show, that $\zeta$ as defined in (17) can be expressed as in (20). Indeed by
597
+ 474 using (19), the Woodbury matrix identity and by regularizing the inverses, we can see that
598
+
599
+ $$
600
+ \begin{array} { r l } & { \quad = - \lambda _ { 2 , 3 , 4 } \lambda _ { 3 } \nabla \tilde { \lambda } ^ { 2 } \nabla \tilde { \lambda } ^ { 3 } \nabla \lambda _ { 1 } ^ { 3 } \nabla \lambda _ { 2 } ^ { 3 } \nabla \lambda _ { 3 } ^ { 3 } \nabla \lambda _ { 3 } ^ { 3 } \nabla \tilde { \lambda } ^ { 3 } \nabla \tilde { \lambda } ^ { 3 } \nabla \tilde { \lambda } ^ { 3 } } \\ & { \quad = \tilde { \lambda } _ { 2 , 3 } \lambda _ { 4 } - \tilde { \lambda } _ { 2 , 4 } \lambda _ { 5 } \tilde { \lambda } ^ { 2 } \nabla \tilde { \lambda } ^ { 3 } \nabla \tilde { \lambda } ^ { 3 } \nabla \tilde { \lambda } ^ { 3 } + \nabla \tilde { \lambda } ^ { 2 } \tilde { \lambda } ^ { 3 } \nabla \tilde { \lambda } ^ { 3 } \nabla \tilde { \lambda } ^ { 3 } } \\ & { \quad = \tilde { \lambda } _ { 3 } ^ { 2 } \nabla \tilde { \lambda } ^ { 3 } ( \frac { 1 } { \lambda _ { 1 } } \lambda _ { 1 } ^ { 2 } \nabla \tilde { \lambda } ^ { 3 } \nabla \tilde { \lambda } ^ { 2 } ) ^ { 2 } \tilde { \lambda } ^ { 3 } \nabla \tilde { \lambda } ^ { 3 } \nabla \tilde { \lambda } ^ { 3 } \nabla \tilde { \lambda } ^ { 3 } \nabla \tilde { \lambda } ^ { 3 } } \\ & { \quad \times \tilde { \lambda } ^ { 2 } ( \frac { 1 } { \lambda _ { 1 } } \lambda _ { 1 } ^ { 2 } \nabla \tilde { \lambda } ^ { 3 } \nabla \tilde { \lambda } ^ { 3 } ) ^ { 2 } \tilde { \lambda } ^ { 3 } } \\ & { \quad = \tilde { \lambda } _ { 3 } ^ { 2 } \nabla \tilde { \lambda } ^ { 3 } ( \frac { 1 } { \lambda _ { 1 } } \lambda _ { 1 } ^ { 2 } \nabla \tilde { \lambda } ^ { 3 } \nabla \tilde { \lambda } ^ { 3 } ) ^ { 2 } \tilde { \lambda } ^ { 3 } } \\ & { \quad \times \tilde { \lambda } ^ { 3 } \nabla \tilde { \lambda } ^ { 3 } \nabla \tilde { \lambda } ^ { 3 } ( \frac { 1 } { \lambda _ { 1 } } \lambda _ { 1 } ^ { 2 } \nabla \tilde { \lambda } ^ { 3 } \nabla \tilde { \lambda } ^ { 3 } ) ^ { 2 } \tilde { \lambda } ^ { 3 } } \\ & \quad \times ( \tilde { \lambda } ^ { 3 } - \frac { 1 } { \lambda _ { 2 } } \nabla \ \end{array}
601
+ $$
602
+
603
+ 475 To show Assertion (i), we note that according to (17)
604
+
605
+ $$
606
+ \begin{array} { r l } & { \underset { \boldsymbol { \lambda } _ { \mathbf { g } } , \boldsymbol { \lambda } _ { \mathbf { a } } 0 } { \mathrm { l i m } } \frac { 1 } { \boldsymbol { \lambda } _ { \mathbf { g } } \lambda _ { \mathbf { a } } } \boldsymbol { \zeta } } \\ & { \quad = \underset { \boldsymbol { \lambda } _ { \mathbf { g } } , \boldsymbol { \lambda } _ { \mathbf { a } } 0 } { \mathrm { l i m } } ( \bar { \mathbf { g } } ^ { \top } \bar { \mathbf { g } } / b + \lambda _ { \mathbf { g } } \mathbf { I } ) ^ { - 1 } \otimes ( \mathbf { a } ^ { \top } \mathbf { a } / b + \lambda _ { \mathbf { a } } \mathbf { I } ) ^ { - 1 } \mathbf { g } ^ { \top } \mathbf { a } } \\ & { \quad = ( \bar { \mathbf { g } } ^ { \top } \bar { \mathbf { g } } ) ^ { - 1 } \otimes ( \mathbf { a } ^ { \top } \mathbf { a } ) ^ { - 1 } \mathbf { g } ^ { \top } \mathbf { a } } \\ & { \quad \approx \mathbf { G } ^ { - 1 } \mathbf { g } ^ { \top } \mathbf { a } , } \end{array}
607
+ $$
608
+
609
+ 476 where the first equality uses the definition of $\zeta$ in (17). The second equality is due to the continuity of
610
+ 477 the matrix inversion and the last approximate equality follows from the K-FAC approximation (15).
611
+
612
+ 478 To show Assertion (ii), we consider $\operatorname* { l i m } _ { \lambda _ { \mathbf { g } } \to \infty }$ and $\operatorname* { l i m } _ { \lambda _ { \mathbf { a } } \to \infty }$ independently, that is
613
+
614
+ $$
615
+ \begin{array} { r l } & { \underset { \lambda _ { \mathbf { g } } \to \infty } { \operatorname* { l i m } } \lambda _ { \mathbf { g } } \cdot \left( \lambda _ { \mathbf { g } } \mathbf { I } _ { m } + \bar { \pmb { g } } ^ { \top } \bar { \pmb { g } } / b \right) ^ { - 1 } } \\ & { = \underset { \lambda _ { \mathbf { g } } \to \infty } { \operatorname* { l i m } } \left( \mathbf { I } _ { m } + \frac { 1 } { b \lambda _ { \mathbf { g } } } \bar { \pmb { g } } ^ { \top } \bar { \pmb { g } } \right) ^ { - 1 } = \mathbf { I } _ { m } , } \end{array}
616
+ $$
617
+
618
+ 479 and
619
+
620
+ $$
621
+ \begin{array} { r l } & { \underset { \lambda _ { \mathbf { a } } \to \infty } { \operatorname* { l i m } } \lambda _ { \mathbf { a } } \cdot \left( \lambda _ { \mathbf { a } } \mathbf { I } _ { n } + \mathbf { a } ^ { \top } \mathbf { a } / b \right) ^ { - 1 } } \\ & { = \underset { \lambda _ { \mathbf { a } } \to \infty } { \operatorname* { l i m } } \left( \mathbf { I } _ { n } + \frac { 1 } { b \lambda _ { \mathbf { a } } } \mathbf { a } ^ { \top } \mathbf { a } \right) ^ { - 1 } = \mathbf { I } _ { n } . } \end{array}
622
+ $$
623
+
624
+ 480 This then implies
625
+
626
+ $$
627
+ \begin{array} { c } { \displaystyle \operatorname* { l i m } _ { \lambda _ { \mathbf { g } } , \lambda _ { \mathbf { a } } \to \infty } \lambda _ { \mathbf { g } } \left( \lambda _ { \mathbf { g } } \mathbf { I } _ { m } + \bar { \pmb { g } } ^ { \top } \bar { \pmb { g } } / b \right) ^ { - 1 } \cdot \mathbf { g } ^ { \top } } \\ { \displaystyle \quad \cdot \mathbf { a } \cdot \lambda _ { \mathbf { a } } \left( \lambda _ { \mathbf { a } } \mathbf { I } _ { n } + \mathbf { a } ^ { \top } \mathbf { a } / b \right) ^ { - 1 } } \\ { \displaystyle = \mathbf { I } _ { m } \cdot \mathbf { g } ^ { \top } \mathbf { a } \cdot \mathbf { I } _ { n } = \mathbf { g } ^ { \top } \mathbf { a } , } \end{array}
628
+ $$
629
+
630
+ 481 which concludes the proof.
631
+
632
+ ![](images/48f5e2043b018718fb2e2af3309212e2a30dd94e19945123d607a39c9975f972.jpg)
633
+ Figure 7: Training loss of the MNIST auto-encoder trained with gradient descent, K-FAC, $\zeta , \zeta ^ { * }$ , as well as SGD w/ momentum, SGD with a $1 0 \times$ larger batch size (600), K-FAC with a $1 0 \times$ larger batch size (600), and Adam. Comparing the performance per real-time (left) and per number of epochs (right). We display both the training loss (top) as well as the test loss (bottom) Runtimes are for a CPU core.
634
+
635
+ ![](images/d3c92098df7ade5ef94ff2ca863d751443139b908a5c3de5bc4edf27532246e8.jpg)
636
+ Figure 8: ResNet-18 trained on CIFAR-10 with image augmentation and a cosine learning rate schedule. The first line (blue) uses the hyperparameters of a public implementation. To ablate the optimizer, two additional settings are added, specifically, without weight decay and without momentum. Results are averaged over 5 runs and the standard deviation is indicated with the colored areas.
637
+
638
+ ![](images/dace174bb4ea8dbf5819947744db1be535d2c87144370a7b87e2efcbcdaa6a34.jpg)
639
+ Figure 9: Test accuracy for training on the MNIST classification task using $\zeta ^ { * }$ only in selected layers. Runtimes are for CPU.
parse/dev/XdDl3bFUNn5/XdDl3bFUNn5.md ADDED
@@ -0,0 +1,307 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ # Towards Robust Blind Face Restoration with Codebook Lookup Transformer
2
+
3
+ Shangchen Zhou Kelvin C.K. Chan Chongyi Li Chen Change Loy
4
+
5
+ S-Lab, Nanyang Technological University {s200094, chan0899, chongyi.li, ccloy}@ntu.edu.sg https://shangchenzhou.com/projects/CodeFormer
6
+
7
+ # Abstract
8
+
9
+ Blind face restoration is a highly ill-posed problem that often requires auxiliary guidance to 1) improve the mapping from degraded inputs to desired outputs, or 2) complement high-quality details lost in the inputs. In this paper, we demonstrate that a learned discrete codebook prior in a small proxy space largely reduces the uncertainty and ambiguity of restoration mapping by casting blind face restoration as a code prediction task, while providing rich visual atoms for generating highquality faces. Under this paradigm, we propose a Transformer-based prediction network, named CodeFormer, to model the global composition and context of the low-quality faces for code prediction, enabling the discovery of natural faces that closely approximate the target faces even when the inputs are severely degraded. To enhance the adaptiveness for different degradation, we also propose a controllable feature transformation module that allows a flexible trade-off between fidelity and quality. Thanks to the expressive codebook prior and global modeling, CodeFormer outperforms the state of the arts in both quality and fidelity, showing superior robustness to degradation. Extensive experimental results on synthetic and realworld datasets verify the effectiveness of our method.
10
+
11
+ # 1 Introduction
12
+
13
+ Face images captured in the wild often suffer from various degradation, such as compression, blur, and noise. Restoring such images is highly ill-posed as the information loss induced by the degradation leads to infinite plausible high-quality (HQ) outputs given a low-quality (LQ) input. The ill-posedness is further elevated in blind restoration, where the specific degradation is unknown. Despite the progress made with the emergence of deep learning, learning a LQ-HQ mapping without additional guidance in the huge image space is still intractable, leading to the suboptimal restoration quality of earlier approaches. To improve the output quality, auxiliary information that 1) reduces the uncertainty of LQ-HQ mapping and 2) complements high-quality details is indispensable.
14
+
15
+ Various priors have been used to mitigate the ill-posedness of this problem, including geometric priors [5, 6, 30, 44], reference priors [24–26], and generative priors [2, 37, 43]. Although improved textures and details are observed, these approaches often suffer from high sensitivity to degradation or limited prior expressiveness. These priors provide insufficient guidance for face restoration, thus their networks essentially resort to the information of LQ input images that are usually highly corrupted. As a result, the LQ-HQ mapping uncertainty still exists, and the output quality is deteriorated by the degradation of the input images. Most recently, based on generative prior, some methods project the degraded faces into a continuous infinite space via iterative latent optimization [27] or direct latent encoding [29]. Despite great realness of outputs, it is difficult to find the accurate latent vectors in case of severe degradation, resulting in low-fidelity results (Fig. 1(d)). To enhance the fidelity, skip connections between encoder and decoder are usually required in this kind of methods [37, 43, 2], as illustrated in Fig. 1(a) (top), however, such designs meanwhile introduce artifacts in the results when inputs are severely degraded, as shown in Fig. 1(e).
16
+
17
+ ![](images/f6a5ba59ffcbf4e05f2f2c656f8beb6787252ca59ade651e0ba58658fe31ad31.jpg)
18
+ (a) Frameworks of continuous prior (top) and our discrete prior (bottom) (b) Distributions of HQ (left) / LQ (right) features and the codebook items
19
+
20
+ ![](images/7f1787e09fdd1b5bf7ebc117376a76fc40cf4e5e8a9c6203fc09f9ce25602f39.jpg)
21
+
22
+ ![](images/1da7f7a91603de648a5b4e8aadd0c599ced1952d43c2725fb234be4ea5ae36fd.jpg)
23
+
24
+ ![](images/afb6b5779423f7c9cf9852f43a07ba464a26fc0b34bc02f10175d78cc3000ffc.jpg)
25
+ (g) CodeFormer (discrete)
26
+
27
+ ![](images/9b428d201d77a74995f65025b3cd0df36ba9913698ee17ecf5af38bea3baf0b3.jpg)
28
+ (h) Code GT (discrete)
29
+
30
+ ![](images/bf9014c41bf3a0cfd55b18604dbb523fc2802cedb51fbae5ae170af88a880d8f.jpg)
31
+ Figure 1: An illustration of motivation. (a) Restoration frameworks of continuous generative prior (top) and our discrete codebook prior (bottom). (b) t-SNE [35] visualization for HQ/LQ face features and codebook items. (c) LQ input. (d-e) Results of existing methods with continuous prior (PULSE [27] and GFP-GAN [37]). (f-g) Results of discrete prior (Nearest Neighbor [11, 34] and CodeFormer). (h) Reconstruction results from the code sequence ground truth. (i) HQ ground truth. As shown, (d) PULSE without skip connection shows the low fidelity. (e) GFP-GAN with skip connection alleviates identity issues but introduces notable artifacts. (f) Utilizing nearest neighbor matching for code lookup recovers more accurate facial structure compared with (d-e), but some details such as glasses cannot be restored and some artifacts could be introduced. (g) Employing Transformer for code prediction, our CodeFormer generates best results with both high quality and fidelity.
32
+
33
+ Different from the aforementioned approaches, this work casts blind face restoration as a code prediction task in a small finite proxy space of the learned discrete codebook prior, which shows superior robustness to degradation as well as rich expressiveness. The codebook is learned by selfreconstruction of HQ faces using a vector-quantized autoencoder, which along with decoder stores the rich HQ details for face restoration. In contrast to continuous generative priors [11, 37, 43], the combinations of codebook items form a discrete prior space with only finite cardinality. Through mapping the LQ images to a much smaller proxy space (e.g., 1024 codes), the uncertainty of the LQ-HQ mapping is significantly attenuated, promoting robustness against the diverse degradation, as compared in Figs. 1(d-g). Besides, the codebook space possess greater expressiveness, which perceptually approximates the image space, as shown in Fig. 1(h). This nature allows the network to reduce the reliance on inputs and even be free of skip connections.
34
+
35
+ Though the discrete representation based on a codebook has been deployed for image generation [4, 11, 34], the accurate code composition for image restoration remains a non-trivial challenge. The existing works look up codebook via nearest-neighbor (NN) feature matching, which is less feasible for image restoration since the intrinsic textures of LQ inputs are usually corrupted. The information loss and diverse degradation in LQ images inevitably distort the feature distribution, prohibiting accurate feature matching. As depicted in Fig. 1(b) (right), even after fine-tuning the encoder on LQ images, the LQ features cannot cluster well to the exact code but spread into other nearby code clusters, thus the nearest-neighbor matching is unreliable in such cases.
36
+
37
+ Tailored for restoration, we propose a Transformer-based code prediction network, named CodeFormer, to exploit global compositions and long-range dependencies of LQ faces for better code prediction. Specifically, taking the LQ features as input, the Transformer module predicts the code token sequence which is treated as the discrete representation of the face images in the codebook space. Thanks to the global modeling for remedying the local information loss in LQ images, the proposed CodeFormer shows robustness to heavy degradation and keeps overall coherence. Comparing the results presented in Figs. 1(f-g), the proposed CodeFormer is able to recover more details than the nearest-neighbor matching, such as the glasses, improving both quality and fidelity of restoration.
38
+
39
+ Moreover, we propose a controllable feature transformation module with an adjustable coefficient to control the information flow from the LQ encoder to decoder. Such design allows a flexible trade-off between restoration quality and fidelity so that the continuous image transitions between them can be achieved. This module enhances the adaptiveness of CodeFormer under different degradations, e.g., in case of heavy degradation, one could manually reduce the information flow of LQ features carrying degradation to produce high-quality results.
40
+
41
+ Equipped with the above components, the proposed CodeFormer demonstrates superior performance in existing datasets and also our newly introduced WIDER-Test dataset that consists of 970 severely degraded faces collected from the WIDER-Face dataset [42]. In addition to face restoration, our method also demonstrates its effectiveness on other challenging tasks such as face inpainting, where long-range clues from other regions are required. Systematic studies and experiments are conducted to demonstrate the merits of our method over previous works.
42
+
43
+ # 2 Related Work
44
+
45
+ Blind Face Restoration. Since face is highly structured, geometric priors of faces are exploited for blind face restoration. Some methods introduce facial landmarks [6], face parsing maps [5, 30, 41], facial component heatmaps [44], or 3D shapes [16, 28, 48] in their designs. However, such prior information cannot be accurately acquired from degraded faces. Moreover, geometric priors are unable to provide rich details for high-quality face restoration.
46
+
47
+ Reference-based approaches [9, 24–26] have been proposed to circumvent the above limitations. These methods generally require the references to possess same identity as the input degraded face. For example, Li et al. [26] propose a guided face restoration network that consists of a warping subnetwork and a reconstruction subnetwork, and a high-quality guided image of the same identity as input is used for better restoring the facial details. However, such references are not always available. DFDNet [24] pre-constructs dictionaries composed of high-quality facial component features. However, the component-specific dictionary features are still insufficient for high-quality face restoration, especially for the regions out of the dictionary scope (e.g., skin, hair). To alleviate this issue, recent VQGAN-based methods [39, 46] explores a learned HQ dictionary, which contains more generic and rich details face restoration.
48
+
49
+ Recently, the generative facial priors from pre-trained generators, e.g., StyleGAN2 [21], have been widely explored for blind face restoration. It is utilized via different strategies of iterative latent optimization for effective GAN inversion [12, 27] or direct latent encoding of degraded faces [29]. However, preserving high fidelity of the restored faces is challenging when one projects the degraded faces into the continuous infinite latent space. To relieve this issue, GLEAN [2, 3], GPEN [43], and GFPGAN [37] embed the generative prior into encoder-decoder network structures, with additional structural information from input images as guidance. Despite the improvement of fidelity, these methods highly rely on inputs through the skip connections, which could introduce artifacts to results when inputs are severely corrupted.
50
+
51
+ Dictionary Learning. Sparse representation with learned dictionaries has demonstrated its superiority in image restoration tasks, such as super-resolution [13, 32, 33, 40] and denoising [10]. However, these methods usually require an iterative optimization to learn the dictionaries and sparse coding, suffering from high computational cost. Despite the inefficiency, their high-level insight into exploring a HQ dictionary has inspired reference-based restoration networks, e.g., LUT [18] and selfreference [47], as well as synthesis methods [11, 34]. Jo and Kim [18] construct a look-up table (LUT) by transferring the network output values to a LUT, so that only a simple value retrieval is needed during inference. However, storing HQ textures in the image domain usually requires a huge LUT, limiting its practicality. VQVAE [34] is first to introduce a highly compressed codebook learned by a vector-quantized autoencoder model. VQGAN [11] further adopts the adversarial loss and perceptual loss to enhance perceptual quality at a high compression rate, significantly reducing the codebook size without sacrificing its expressiveness. Unlike the large hand-crafted dictionary [18, 24], the learnable codebook automatically learns optimal elements for HQ image reconstruction, providing superior efficiency and expressiveness as well as circumventing the laborious dictionary design. Inspired by the codebook learning, this paper investigates a discrete proxy space for blind face restoration. Different from recent VQGAN-based approaches [39, 46], we exploit the discrete codebook prior by predicting code sequences via global modeling, and we secure prior effectiveness by fixing the encoder. Such designs allow our method to take full advantage of the codebook so that it does not depend on the feature fusion with LQ cues, significantly enhancing the robustness of face restoration.
52
+
53
+ ![](images/0d4e2a0f0c1216d1ca5d65c1b2a790b534ed76447c7dfad15b23882ac47eb820.jpg)
54
+ Figure 2: Framework of CodeFormer. (a) We first learn a discrete codebook and a decoder to store high-quality visual parts of face images via self-reconstruction learning. (b) With fixed codebook and decoder, we then introduce a Transformer module for code sequence prediction, modeling the global face composition of lowquality inputs. Besides, a controllable feature transformation module is used to control the information flow from LQ encoder to decoder. Note that this connection is optional, which can be disabled to avoid adverse effects when inputs are severely degraded, and one can adjust a scalar weight $w$ to trade between quality and fidelity.
55
+
56
+ # 3 Methodology
57
+
58
+ The main focus of this work is to exploit a discrete representation space that reduces the uncertainty of restoration mapping and complements high-quality details for the degraded inputs. Since local textures and details are lost and corrupted in low-quality inputs, we employ a Transformer module to model the global composition of natural faces, which remedies the local information loss, enabling high-quality restoration. The overall framework is illustrated in Fig. 2.
59
+
60
+ We first incorporate the idea of vector quantization [11, 34] and pre-train a quantized autoencoder through self-reconstruction to obtain a discrete codebook and the corresponding decoder (Sec. 3.1). The prior from the codebook combination and decoder is then used for face restoration. Based on this codebook prior, we then employ a Transformer for accurate prediction of code combination from the low-quality inputs (Sec. 3.2). In addition, a controllable feature transformation module is introduced to exploit a flexible trade-off between restoration quality and fidelity (Sec. 3.3). The training of our method is divided into three stages accordingly.
61
+
62
+ # 3.1 Codebook Learning (Stage I)
63
+
64
+ To reduce uncertainty of the LQ-HQ mapping and complement high-quality details for restoration, we first pre-train the quantized autoencoder to learn a context-rich codebook, which improves network expressiveness as well as robustness against degradation.
65
+
66
+ As shown in Fig. 2(a), the HQ face image $I _ { h } \in \mathbb { R } ^ { H \times W \times 3 }$ is first embeded as a compressed feature $Z _ { h } \in \mathbb { R } ^ { m \times n \times d }$ by an encoder $E _ { H }$ . Following VQVAE [34] and VQGAN [11], we replace each “pixel” in $Z _ { h }$ H with the nearest item in the learnable codebook $\mathcal { C } = \{ c _ { k } \in \mathbb { R } ^ { d } \} _ { k = 0 } ^ { \tilde { N } }$ to obtain the quantized feature $Z _ { c } \in \mathbb { R } ^ { m \times n \times d }$ and the corresponding code token sequence $s \in \{ 0 , \cdots , N - 1 \} ^ { m \cdot n }$ :
67
+
68
+ $$
69
+ Z _ { c } ^ { ( i , j ) } = \underset { c _ { k } \in \mathcal { C } } { \operatorname { a r g m i n } } \| Z _ { h } ^ { ( i , j ) } - c _ { k } \| _ { 2 } ; \quad s ^ { ( i , j ) } = \underset { k } { \operatorname { a r g m i n } } \| Z _ { h } ^ { ( i , j ) } - c _ { k } \| _ { 2 } .
70
+ $$
71
+
72
+ The decoder $D _ { H }$ then reconstructs the high-quality face image $I _ { r e c }$ given $Z _ { c }$ . The $m \cdot n$ code token sequence $s$ forms a new latent discrete representation that specifies the respective code index of the learned codebook, i.e., $Z _ { c } ^ { ( i , j ) } = c _ { k }$ when $s ^ { ( i , j ) } = k$ .
73
+
74
+ Training Objectives. To train the quantized autoencoder with a codebook, we adopt three image-level reconstruction losses: L1 loss $\mathcal { L } _ { 1 }$ , perceptual loss [19, 45] $\mathcal { L } _ { p e r }$ , and adversarial loss [11] $\mathcal { L } _ { a d v }$ :
75
+
76
+ $\mathcal { L } _ { 1 } = | | I _ { h } - I _ { r e c } | | _ { 1 } ; \quad \mathcal { L } _ { p e r } = | | \Phi ( I _ { h } ) - \Phi ( I _ { r e c } ) | | _ { 2 } ^ { 2 } ; \quad \mathcal { L } _ { a d v } = [ \log D ( I _ { h } ) + \log ( 1 - D ( I _ { r e c } ) ) ] ,$ (2) where $\Phi$ denotes the feature extractor of VGG19 [31]. Since, image-level losses are underconstrained when updating the codebook items, we lso adopt the intermediate cod vel loss [11, 34] $\mathcal { L } _ { c o d e } ^ { f e a t }$ to $\mathcal { C }$ $Z _ { h }$
77
+
78
+ $$
79
+ \mathcal { L } _ { c o d e } ^ { f e a t } = \Vert \mathbf { s g } ( Z _ { h } ) - Z _ { c } \Vert _ { 2 } ^ { 2 } + \beta \Vert Z _ { h } - \mathbf { s g } ( Z _ { c } ) \Vert _ { 2 } ^ { 2 } ,
80
+ $$
81
+
82
+ where $\operatorname { s g } ( \cdot )$ stands for the stop-gradient operator and $\beta = 0 . 2 5$ is a weight trade-off for the update rates of the encoder and codebook. Since the quantization operation in Eq. (1) is non-differentiable, we adopt straight-through gradient estimator [11, 34] to copy the gradients from the decoder to the encoder. The complete objective of codebook prior learning $\mathcal { L } _ { c o d e b o o k }$ is:
83
+
84
+ $$
85
+ \mathcal { L } _ { c o d e b o o k } = \mathcal { L } _ { 1 } + \mathcal { L } _ { p e r } + \mathcal { L } _ { c o d e } ^ { f e a t } + \lambda _ { a d v } \cdot \mathcal { L } _ { a d v } ,
86
+ $$
87
+
88
+ where $\lambda _ { a d v }$ is set to 0.8 in our experiments.
89
+
90
+ Codebook Settings. Our encoder $E _ { H }$ and decoder $D _ { H }$ consist of 12 residual blocks and 5 resize layers for downsampling and upsampling, respectively. Hence we obtain a large compression ratio of $r = H / n = W / \bar { m } = 3 2$ , which leads to a great robustness against degradation and a tractable computational cost for our global modeling in Stage II. Although more codebook items could ease reconstruction, the redundant elements could cause ambiguity in subsequent code predictions. Hence, we set the item number $N$ of codebook to 1024, which is sufficient for accurate face reconstruction. Besides, the code dimension $d$ is set to 256.
91
+
92
+ # 3.2 Codebook Lookup Transformer Learning (Stage II)
93
+
94
+ Due to corruptions of textures in LQ faces, the nearest-neighbour (NN) matching in Eq. (1) usually fails in finding accurate codes for face restoration. As depicted in Fig. 1(b), LQ features with diverse degradation could deviate from the correct code and be grouped into nearby clusters, resulting in undesirable restoration results, as shown in Fig. 1(f). To mitigate the problem, we employ a Transformer to model global interrelations for better code prediction.
95
+
96
+ Built upon the learned autoencoder presented in Sec. 3.1, as shown in Fig. 2(b), we insert a Transformer [36] module containing nine self-attention blocks following the encoder. We fix the codebook $\mathcal { C }$ and decoder $D _ { H }$ and finetune the encoder $E _ { H }$ for restoration. The finetuned encoder is denoted as $E _ { L }$ . To obtain the LQ features $Z _ { l } \in \mathbb { R } ^ { m \times n \times d }$ through $E _ { L }$ , we first unfold the features into $m \cdot n$ vectors $Z _ { l } ^ { v } \in \mathbb { R } ^ { ( m \cdot n ) \times d }$ , and then feed them to the Transformer module. The $s$ -th self-attention block of Transformer computes as the following:
97
+
98
+ $$
99
+ X _ { s + 1 } = \operatorname { S o f t m a x } ( Q _ { s } K _ { s } ) V _ { s } + X _ { s } ,
100
+ $$
101
+
102
+ where $X _ { 0 } = Z _ { l } ^ { v }$ . The query $Q$ , key $K$ , and value $V$ are obtained from $X _ { s }$ through linear layers. We add a sinusoidal positional embedding $\mathcal { P } \in \mathbb { R } ^ { ( m \cdot n ) \times d }$ [1, 7] on the queries $Q$ and the keys $K$ to increase the expressiveness of modeling sequential representation. Following the self-attention blocks, a Linear layer is adopted to project features to the dimension of $( m \cdot { \bar { n } } ) \times N$ . Overall, taking the encoding feature $Z _ { l } ^ { v }$ as an input, the Transformer predicts the $m \cdot n$ code sequence $\hat { s } \in \{ 0 , \cdot \cdot \cdot , | N | - 1 \} ^ { m \cdot n }$ in form of the probability of the $N$ code items. The predicted code sequence then retrieves the $m \cdot n$ respective code items from the learned codebook, forming the quantized feature $\hat { Z } _ { c } \in \mathbb { R } ^ { m \times n \times d }$ that produces a high-quality face image through the fixed decoder $D _ { H }$ . Thanks to our large compression ratio (i.e., 32), our Transformer is effective and efficient in modeling global correlations of LQ face images.
103
+
104
+ Training Objectives. We train Transformer module $T$ as well as finetune the encoder $E _ { L }$ for restoration, while the codebook $\mathcal { C }$ and decoder $D _ { H }$ are kept fixed. Instead of employing reconstruction loss and adversarial loss in the image-level, only code-level losses are required in this stage: 1) crossentropy loss $\mathcal { L } _ { c o d e } ^ { t o k e n }$ for code token prediction supervision, and 2) L2 loss $\mathcal { L } _ { c o d e } ^ { f e a t ^ { \prime } }$ to force the LQ to approach the quantized feature from codebook, which eases the difficulty of token prediction learning:
105
+
106
+ $$
107
+ \mathcal { L } _ { c o d e } ^ { t o k e n } = \sum _ { i = 0 } ^ { m n - 1 } - s _ { i } \log ( \hat { s _ { i } } ) ; \quad \mathcal { L } _ { c o d e } ^ { f e a t ^ { \prime } } = \| Z _ { l } - \mathrm { s g } ( Z _ { c } ) \| _ { 2 } ^ { 2 } ,
108
+ $$
109
+
110
+ where the ground truth of latent code $s$ is obtained from the pre-trained autoencoder in Stage I (Sec. 3.1), thus the quantized feature $Z _ { c }$ is then retrieved from codebook according to the $s$ . The final objective of Transformer learning is:
111
+
112
+ $$
113
+ \mathcal { L } _ { t f } = \lambda _ { t o k e n } \cdot \mathcal { L } _ { c o d e } ^ { t o k e n } + \mathcal { L } _ { c o d e } ^ { f e a t ^ { \prime } } ,
114
+ $$
115
+
116
+ where $\lambda _ { t o k e n }$ is set to 0.5 in our method. Note that our network after this stage has already equipped with superior robustness and effectiveness in face restoration, especially for severely degraded faces.
117
+
118
+ # 3.3 Controllable Feature Transformation (Stage III)
119
+
120
+ Despite our Stage $\mathrm { I I }$ has obtained a great face restoration model, we also investigate a flexible tradeoff between quality and fidelity of face restoration. Thus, we propose the controllable feature transformation (CFT) module to control information flow from LQ encoder $E _ { L }$ to decoder $D _ { H }$ Specifically, as shown in Fig. 2, the LQ features $F _ { e }$ are used to slightly tune the decoder features $F _ { d }$ through spatial feature transformation [38] with the affine parameters of $\alpha$ and $\beta$ . An adjustable coefficient $w \in [ 0 , 1 ]$ is then used to control the relative importance of the inputs:
121
+
122
+ $$
123
+ \begin{array} { r } { \hat { F } _ { d } = F _ { d } + ( \alpha \odot F _ { d } + \beta ) \times w ; \quad \alpha , \beta = \mathcal { P } _ { \theta } ( c ( F _ { d } , F _ { e } ) ) , } \end{array}
124
+ $$
125
+
126
+ where ${ \mathcal { P } } _ { \theta }$ denotes a stack of convolutions that predicts $\alpha$ and $\beta$ from the concatenated features of $c ( F _ { e } , F _ { d } )$ . We adopt the CFT modules at multiple scales $s \in \{ 3 2 , 6 4 , 1 2 8 , 2 5 6 \}$ between encoder and decoder. Such a design allows our network to remain high fidelity for mild degradation and high quality for heavy degradation. Specifically, one could use a small $w$ to reduce the reliance on input LQ images with heavy degradation, thus producing high-quality outputs. The larger $w$ will introduce more information from LQ images to enhance the fidelity in case of mild degradation.
127
+
128
+ Training Objectives. To train the controllable modules and finetune the encoder $E _ { L }$ in this stage, we keep the code-level losses of $\mathcal { L } _ { t f }$ in Stage II, and also add image-level losses of $\mathcal { L } _ { 1 }$ , $\mathcal { L } _ { p e r }$ , and $\mathcal { L } _ { a d v }$ , which are the same as that in Stage I except that $I _ { r e c }$ is replaced by restoration output $I _ { r e s }$ . The complete loss for this stage is the sum of above losses weighted with their original weight factors. We set the $w$ to 1 during training of this stage, which then allows network to achieve continuous transitions of results by adjusting $w$ in $[ 0 , 1 ]$ during inference. For inference, unless otherwise stated, we set the $w = 0 . 5$ by default to make a good balance between the quality and fidelity of outputs.
129
+
130
+ # 4 Experiments
131
+
132
+ # 4.1 Datasets
133
+
134
+ Training Dataset. We train our models on the FFHQ dataset [21], which contains 70,000 high-quality (HQ) images, and all images are resized to $5 1 2 \times 5 1 2$ for training. To form training pairs, we synthesize LQ images $I _ { l }$ from the HQ counterparts $I _ { h }$ with the following degradation model [24, 37, 43]:
135
+
136
+ $$
137
+ I _ { l } = \{ [ ( I _ { h } \otimes k _ { \sigma } ) _ { \downarrow r } + n _ { \delta } ] _ { \mathrm { J P E G } _ { q } } \} _ { \uparrow r } ,
138
+ $$
139
+
140
+ where the HQ image $I _ { h }$ is first convolved with a Gaussian kernel $k _ { \sigma }$ , followed by a downsampling of scale $r$ . After that, additive Gaussian noise $n _ { \delta }$ is added to the images, and then JPEG compression with quality factor $q$ is applied. Finally, the LQ image is resized back to $5 1 2 \times 5 1 2$ . We randomly sample $\sigma , r , \delta$ , and $q$ from [1, 15], [1, 30], [0, 20], and [30, 90], respectively.
141
+
142
+ Testing Datasets. We evaluate our method on a synthetic dataset CelebA-Test and three real-world datasets: LFW-Test, WebPhoto-Test, and our proposed WIDER-Test. CelebA-Test contains 3,000 images selected from the CelebA-HQ dataset [20], where LQ images are synthesized under the same degradation range as our training settings. The three real-world datasets respectively contain three different degrees of degradation, i.e., mild (LFW-Test), medium (WebPhoto-Test), and heavy (WIDER-Test). LFW-Test consists of the first image of each person in LFW dataset [17], containing 1,711 images. WebPhoto-Test [37] consists of 407 low-quality faces collected from the Internet. Our WIDER-Test comprises 970 severely degraded face images from the WIDER Face dataset [42], providing a more challenging dataset to evaluate the generalizability and robustness of blind face restoration methods.
143
+
144
+ # 4.2 Experimental Settings and Metrics
145
+
146
+ Settings. We represent a face image of $5 1 2 \times 5 1 2 \times 3$ as a $1 6 \times 1 6$ code sequence. For all stages of training, we use the Adam [23] optimizer with a batch size of 16. We set the learning rate to $\mathrm { 8 } \mathrm { \times } \mathrm { 1 0 ^ { - 5 } }$ for stages I and II, and adopt a smaller learning rate of $2 \times 1 0 ^ { - 5 }$ for stage III. The three stages are trained with 1.5M, 200K, and 20K iterations, respectively. Our method is implemented with the PyTorch framework and trained using four NVIDIA Tesla V100 GPUs.
147
+
148
+ Metrics. For the evaluation on CelebA-Test with ground truth, we adopt PSNR, SSIM, and LPIPS [45] as metrics. We also evaluate the identity preservation using the cosine similarity of features from
149
+
150
+ ![](images/7264dc8541b301c16c44949d364b383e15a5b278466f7677b3765b3045c564f0.jpg)
151
+ Figure 3: Qualitative comparison on the CelebA-Test. Even though input faces are severely degraded, our CodeFormer produces high-quality faces with faithful details. (Zoom in for details)
152
+
153
+ ![](images/0281a1cf817113ca48d655185c25002b625e40f3697324d4556fea773bb22ab4.jpg)
154
+ Figure 4: Qualitative comparison on real-world faces. Our CodeFormer is able to restore high-quality faces, showing robustness to the heavy degradation. (Zoom in for details)
155
+
156
+ ArcFace network [8], denoted as IDS. For the evaluation on real-world datasets without ground truth, we employ the widely-used non-reference perceptual metrics: FID [15] and MUSIQ (KonIQ) [22].
157
+
158
+ # 4.3 Comparisons with State-of-the-Art Methods
159
+
160
+ We compare the proposed CodeFormer with state-of-the-art methods, including PULSE [27], DFDNet [24], PSFRGAN [5], GLEAN [3], GFP-GAN [37], and GPEN [43]. We conduct extensive comparisons on both synthetic and real-world datasets.
161
+
162
+ Evaluation on Synthetic Dataset. We first show the quantitative comparison on the CelebA-Test in Table 1. In terms of the image quality metrics LPIPS, FID, and MUSIQ, our CodeFormer achieves the best scores than existing methods. Besides, it also faithfully preserves the identity, reflected by the highest IDS score and PSNR. Additionally, we present the qualitative comparison in Fig. 3. The compared methods fail to produce pleasant restoration results, e.g., DFDNet [24], PSFRGAN [5], GFP-GAN [37], and GPEN [43] introduce obvious artifacts and GLEAN [3] produces over-smoothed results that lack facial details. Moreover, all compared methods are unable to preserve the identity. Thanks to the expressive codebook prior and global modeling, CodeFormer not only produces high-quality faces but also preserves the identity well, even when inputs are highly degraded.
163
+
164
+ Table 1: Quantitative comparison on the CelebATest. Red and blue indicate the best and the second best performance, respectively. The result of Code GT is the upper bound of CodeFormer.
165
+
166
+ <table><tr><td>Methods</td><td>LPIPS↓</td><td>FID↓</td><td>MUSIQ↑</td><td>IDS↑</td><td></td><td>PSNR↑ SSIM↑</td></tr><tr><td>Input</td><td>0.712</td><td>295.73</td><td>15.16</td><td>0.32</td><td>21.53</td><td>0.623</td></tr><tr><td>PULSE [27]</td><td>0.406</td><td>72.94</td><td>67.39</td><td>0.30</td><td>21.38</td><td>0.571</td></tr><tr><td>DFDNet [24]</td><td>0.466</td><td>85.15</td><td>57.00</td><td>0.42</td><td>21.24</td><td>0.562</td></tr><tr><td>PSFRGAN [5]</td><td>0.395</td><td>62.05</td><td>65.93</td><td>0.43</td><td>20.91</td><td>0.549</td></tr><tr><td>GLEAN [3]</td><td>0.371</td><td>59.87</td><td>61.59</td><td>0.51</td><td>21.59</td><td>0.598</td></tr><tr><td>GFP-GAN [37]</td><td>0.391</td><td>58.36</td><td>67.84</td><td>0.42</td><td>20.37</td><td>0.545</td></tr><tr><td>GPEN [43]</td><td>0.349</td><td>59.70</td><td>71.53</td><td>0.54</td><td>21.26</td><td>0.565</td></tr><tr><td>CodeFormer (ours)</td><td>0.299</td><td>60.62</td><td>73.79</td><td>0.60</td><td>22.18</td><td>0.610</td></tr><tr><td>Code GT</td><td>0.124</td><td>54.31</td><td>71.94*</td><td>0.89</td><td>25.43</td><td>0.749</td></tr><tr><td>GT</td><td>0</td><td>51.40</td><td>72.02*</td><td>1</td><td>8</td><td>1</td></tr></table>
167
+
168
+ Table 2: Quantitative comparison on the real-world LFW-Test, WebPhoto-Test, and WIDER-Test. Red and blue indicate the best and the second best performance, respectively.
169
+
170
+ <table><tr><td>Dataset Degradation Methods</td><td colspan="2">LFW-Test mild FID↓ MUSIQ↑</td><td colspan="2">WebPhoto-Test medium FID↓ MUSIQ↑</td><td colspan="2">WIDER-Test heavy FID↓ MUSIQ↑</td></tr><tr><td>Input</td><td>137.56</td><td>25.05</td><td>170.11</td><td>19.24</td><td>202.06</td><td>15.57</td></tr><tr><td>PULSE [27]</td><td>64.86</td><td>66.98</td><td>86.45</td><td>66.57</td><td>73.59</td><td>65.36</td></tr><tr><td>DFDNet [24]</td><td>62.57</td><td>67.95</td><td>100.68</td><td>63.81</td><td>57.84</td><td>59.34</td></tr><tr><td>PSFRGAN [5]</td><td>51.89</td><td>69.21</td><td>88.45</td><td>67.09</td><td>51.16</td><td>67.27</td></tr><tr><td>GLEAN [3]</td><td>53.49</td><td>66.48</td><td>105.63</td><td>61.30</td><td>47.11</td><td>60.68</td></tr><tr><td>GFP-GAN [37]</td><td>49.96</td><td>68.95</td><td>87.35</td><td>68.04</td><td>40.59</td><td>68.26</td></tr><tr><td>GPEN [43]</td><td>57.58</td><td>73.59</td><td>81.77</td><td>73.41</td><td>46.99</td><td>72.36</td></tr><tr><td>CodeFormer (ours)</td><td>52.02</td><td>71.43</td><td>78.87</td><td>70.51</td><td>39.06</td><td>69.31</td></tr></table>
171
+
172
+ Table 3: Ablation studies of variant networks and code lookup methods on the CelebA-Test. Removing ‘Codebook’ means the network is a general encoder-decoder structure. $\cdot _ { w } ,$ is an adjustable coefficient of CFT modules that controls the information flow from encoder.
173
+
174
+ <table><tr><td>Exp.</td><td colspan="3">Networks Codebook Transformer Fix Decoder</td><td colspan="2">Code Lookup NN Code Pred.</td><td colspan="2">Metrics LPIPS↓ IDS↑</td></tr><tr><td>(a)</td><td></td><td></td><td>√</td><td></td><td></td><td>0.420</td><td>0.47</td></tr><tr><td>(b)</td><td>广</td><td></td><td>√</td><td></td><td></td><td>0.397</td><td>0.51</td></tr><tr><td>(c)</td><td></td><td></td><td></td><td>√</td><td>√</td><td>0.351</td><td>0.55</td></tr><tr><td>(e)</td><td>√</td><td>√</td><td></td><td></td><td>√</td><td>0.379</td><td>0.52</td></tr><tr><td>(f) (ours, w=1)</td><td>√</td><td>√</td><td></td><td></td><td>√</td><td>0.297</td><td>0.60</td></tr><tr><td>(g) (ours,w=0)</td><td>√</td><td></td><td></td><td>√</td><td>√</td><td>0.307</td><td>0.58</td></tr></table>
175
+
176
+ ![](images/12ad6d83d3126058496c7e558248c344d7a1a2a9dadb32f684900ec3ce39ccf6.jpg)
177
+ Figure 6: Curve comparison on code sequence prediction accuracy.
178
+
179
+ Evaluation on Real-world Datasets. As presented in Table 2, our CodeFormer achieves comparable perceptual quality of FID score with the compared methods on the real-world testing datasets with mild and medium degradation, and the best score on the testing dataset with heavy degradation. Although PULSE [27] also obtains good perceptual MUSIQ score, it cannot preserve the identity of input images, as the identity score of IDS and visual results respectively suggested in Table 1 and Fig. 4. From the visual comparisons in Fig. 4, it is observed that our method shows exceptional robustness to the real heavy degradation and produces most visually pleasing results. Notably, CodeFormer successfully preserves the identity and produces natural results with rich details.
180
+
181
+ # 4.4 Ablation Studies
182
+
183
+ Effectiveness of Codebook Space. We first investigate the effectiveness of the codebook space. As shown in Exp. (a) of Table 3, removing the codebook (i.e., directly feeding the encoder features $Z _ { l }$ to the decoder) results in worse LPIPS and IDS scores. The results suggest that the discrete space of codebook is the key to ensure the robustness and effectiveness of our model.
184
+
185
+ Superiority of Transformer-based Code Prediction. To verify the superiority of our Transformerbased code prediction for codebook lookup, we compare it with two different solutions, i.e., nearestneighbour (NN) matching, i.e., Exp. (b), and a CNN-based code prediction module, i.e., Exp. (c), that adopts a Linear layer for prediction following encoder $E _ { L }$ . As shown in Table 3, the comparison of Exps. (b) and (c) indicates that adopting code prediction for codebook lookup is more effective than NN feature matching. However, the local nature of convolution operation of CNNs restricts its modeling capability for long code sequence prediction. In comparison to the pure CNN-based method, i.e., Exp. (c), our Transformer-based solution produces better-fidelity results in terms of LPIPS and IDS scores, as well as higher accuracy of code prediction under all degradation degrees, as shown in Fig. 6. Besides, the superiority of CodeFormer is also demonstrated in visual comparisons shown in Fig. 5 and Fig. 9.
186
+
187
+ ![](images/239939d5f94ca03d5d3be70744eabf3047d84bb6d01be732be68128fe2babba2.jpg)
188
+ Figure 5: Qualitative comparisons of different codebook lookup methods.
189
+
190
+ Importance of Fixed Decoder. Unlike the large dictionary $( \sim 3 . 2 \mathrm { G } )$ in DFDNet [24], which aims to store a massive quantity of facial details, we deliberately adopt a compact codebook $\mathcal { C } \in \mathbb { R } ^ { N \times d }$ with $N { = } 1 0 2 4$ and $d { = } 2 5 6$ that only keeps the essential codes for face restoration, which then activate the detailed cues stored in the pre-trained decoder. Thus, the codebook must be used alongside the decoder to fully unleash its potential. To vindicate our design, we conduct two studies: 1) fixing both codebook and decoder, i.e., Exp. (g), and 2) fixing codebook but fine-tuning decoder, i.e., Exp. (e). Table 3 shows fine-tuning decoder deteriorates the performance, validating our statement. This is because fine-tuning the decoder destroys the learned prior that is held by the pre-trained codebook and decoder, resulting in suboptimal performance. Therefore, we keep the decoder fixed in our method.
191
+
192
+ ![](images/602139085815abb09b2367900deeab6eae7660199dba2c2802d27b8150e21942.jpg)
193
+ Figure 7: CFT module is capable to generate continuous transitions between image quality and fidelity.
194
+
195
+ Flexibility of Controllable Feature Transformation Module. Considering the diverse degradation in real-world LQ face images, we provide a controllable feature transformation module (CFT) to allow a flexible trade-off between quality and fidelity. As shown in Fig. 7, a smaller $w$ tends to produce a high-quality result while a larger $w$ improves the fidelity. While such a flexibility is rarely explored in previous work, here we show that it is an appealing strategy to improves the adaptiveness of our method for different scenarios. As shown in Table 3, Exp. (f), i.e., setting the coefficient $w$ to 1 increases the reconstruction and identity scores but decreases the visual quality. In this work, we trade between the quality and fidelity, and set the coefficient $w$ to 0.5 by default.
196
+
197
+ # 4.5 Running time
198
+
199
+ We compare the running time of state-of-the-art methods [27, 24, 5, 2, 37, 43] and the proposed CodeFormer. All existing methods are evaluated on $5 1 2 ^ { 2 }$ face images using their publicly available code. As shown in Table 5, the proposed CodeFormer has a similar running time as PSFRGAN [5] and GPEN [43] that can infer one image within 0.1s. Meanwhile, our method achieves the best performance in terms of LPIPS on the Celeb-Test dataset.
200
+
201
+ Table 5: Running time of different networks. All methods are evaluated on $5 1 2 ^ { 2 }$ input images using an NVIDIA Tesla V100 GPU. ‘ ’ indicates the running time is less than 0.1s per test image.
202
+
203
+ <table><tr><td></td><td>PULSE [27]</td><td>DFDNet [24]</td><td>PSFRGAN[5]</td><td>GLEAN [2]</td><td>GFP-GAN [37]</td><td>GPEN [43]</td><td>CodeFormer (Ours)</td></tr><tr><td>Time (sec)</td><td>48.955</td><td>0.179</td><td>0.065</td><td>0.132</td><td>0.126</td><td>0.055</td><td>0.070</td></tr><tr><td>LPIPS↓</td><td>0.406</td><td>0.466</td><td>0.395</td><td>0.371</td><td>0.391</td><td>0.349</td><td>0.299</td></tr></table>
204
+
205
+ # 4.6 Extensions
206
+
207
+ Face Color Enhancement. We finetune our model on face color enhancement using the same color augmentations (random color jitter and grayscale conversion) as GFP-GAN (v1) [37]. We compare our method with GFP-GAN (v1) [37] on the real-world old photos (from CelebChild-Test dataset [37]) with color loss. The proposed CodeFormer generates high-quality face images with more natural color and faithful details.
208
+
209
+ ![](images/8e1019f59cb5b029366f73982da328e7ef7b923f2585cfbf59a3e172bf836e35.jpg)
210
+ Figure 8: Visual comparison of face color enhancement on the real-world old face photos.
211
+
212
+ Face Inpainting. The proposed Codeformer can be easily extended to face inpainting, and it shows great performance even in large mask ratios. To build training pairs, we use a publicly available script [43] to randomly draw irregular polyline masks for generating masked faces. We compare our method with two state-of-the-art face inpainting methods CTSDG [14] and GPEN [43], as well as Nearest-Neighbor matching for codebook lookup. As shown in Fig. 9, CTSDG and GPEN struggle in cases with large masks. Using Nearest-Neighbor matching within our framework roughly reconstructs the face structures, but it also fails in restoring complete visual parts such as the glasses and the eyes. In contrast, our CodeFormer generates high-quality natural faces without strokes and artifacts.
213
+
214
+ ![](images/1bf345d14be320cad6e490700e84655b7289418c6560e9210cc87df2be0ce519.jpg)
215
+ Figure 9: Visual comparison with state-of-the-art face inpainting methods on the challenging cases.
216
+
217
+ # 4.7 Limitation
218
+
219
+ Our method is built on a pre-trained autoencoder with a codebook. Thus, the capability and expressiveness of the autoencoder could affect the performance of our method. 1) Though the identity inconsistency issue is significantly relieved by the Transformer’s global modeling, inconsistency still exists in some rare visual parts such as accessories, where the current codebook space cannot seamlessly represent the image space. Using multiple scales in the codebook space to explore more fine-grained visual quantization may be a solution. 2) Although CodeFormer exhibits great robustness in most cases, when it comes to side faces, CodeFormer offers limited superiority to other methods and also cannot produce good results, as failure cases shown in Fig. 10. This is expected because there are only few side faces in the FFHQ training dataset, thus, the codebook is unable to learn sufficient codes for this case, leading to less effectiveness in both reconstruction and restoration.
220
+
221
+ ![](images/c4cb9b43c69543ac02dcd3f008770131a727810a36ed2ca639a19802a7330ca6.jpg)
222
+ Figure 10: Failure cases tend to occur on side faces, which could be caused by the limited number of side face images in the training dataset of FFHQ.
223
+
224
+ # 5 Conclusion
225
+
226
+ This paper aims to address the fundamental challenges in blind face restoration. With a learned small discrete but expressive codebook space, we turn face restoration to code token prediction, significantly reducing the uncertainty of restoration mapping and easing the learning of restoration network. To remedy the local loss, we explore global composition and dependency from degraded faces via an expressive Transformer module for better code prediction. Benefiting from these designs, our method shows great expressiveness and strong robustness against heavy degradation. To enhance the adaptiveness of our method for different degradation, we also propose a controllable feature transformation module that allows a flexible trade-off between fidelity and quality. Experimental results suggest the superiority and effectiveness of our method.
227
+
228
+ # Acknowledgement
229
+
230
+ This study is supported under the RIE2020 Industry Alignment Fund – Industry Collaboration Projects (IAF-ICP) Funding Initiative, as well as cash and in-kind contribution from the industry partner(s). It is also partially supported by the NTU NAP grant.
231
+
232
+ # References
233
+
234
+ Gabriel Synnaeve Zagoruyko. End-to-end object detection with transformers. In ECCV, 2020. [2] Kelvin CK Chan, Xintao Wang, Xiangyu Xu, Jinwei Gu, and Chen Change Loy. GLEAN: Generative latent bank for large-factor image super-resolution. In CVPR, 2021. [3] Kelvin CK Chan, Xiangyu Xu, Xintao Wang, Jinwei Gu, and Chen Change Loy. GLEAN: Generative latent bank for image super-resolution and beyond. IEEE Transactions on Pattern Analysis and Machine Intelligence, 2022. [4] Huiwen Chang, Han Zhang, Lu Jiang, Ce Liu, and William T Freeman. MaskGIT: Masked generative image transformer. In CVPR, 2022. [5] Chaofeng Chen, Xiaoming Li, Lingbo Yang, Xianhui Lin, Lei Zhang, and Kwan-Yee K Wong. Progressive semantic-aware style transformation for blind face restoration. In CVPR, 2021. [6] Yu Chen, Ying Tai, Xiaoming Liu, Chunhua Shen, and Jian Yang. FSRNet: End-to-end learning face super-resolution with facial priors. In CVPR, 2018. [7] Bowen Cheng, Ishan Misra, Alexander G. Schwing, Alexander Kirillov, and Rohit Girdhar. Maskedattention mask transformer for universal image segmentation. In CVPR, 2022. [8] Jiankang Deng, Jia Guo, Niannan Xue, and Stefanos Zafeiriou. ArcFace: Additive angular margin loss for deep face recognition. In CVPR, 2019. [9] Berk Dogan, Shuhang Gu, and Radu Timofte. Exemplar guided face image super-resolution without facial landmarks. In CVPRW, 2019.
235
+ [10] Michael Elad and Michal Aharon. Image denoising via learned dictionaries and sparse representation. In CVPR, 2006.
236
+ [11] Patrick Esser, Robin Rombach, and Bjorn Ommer. Taming transformers for high-resolution image synthesis. In CVPR, 2021.
237
+ [12] Jinjin Gu, Yujun Shen, and Bolei Zhou. Image processing using multi-code gan prior. In CVPR, 2020.
238
+ [13] Shuhang Gu, Wangmeng Zuo, Qi Xie, Deyu Meng, Xiangchu Feng, and Lei Zhang. Convolutional sparse coding for image super-resolution. In ICCV, 2015.
239
+ [14] Xiefan Guo, Hongyu Yang, and Di Huang. Image inpainting via conditional texture and structure dual generation. In ICCV, 2021.
240
+ [15] Martin Heusel, Hubert Ramsauer, Thomas Unterthiner, Bernhard Nessler, and Sepp Hochreiter. Gans trained by a two time-scale update rule converge to a local nash equilibrium. In NeurIPS, 2017.
241
+ [16] Xiaobin Hu, Wenqi Ren, John LaMaster, Xiaochun Cao, Xiaoming Li, Zechao Li, Bjoern Menze, and Wei Liu. Face super-resolution guided by 3d facial priors. In ECCV, 2020.
242
+ [17] Gary B Huang, Marwan Mattar, Tamara Berg, and Eric Learned-Miller. Labeled faces in the wild: A database forstudying face recognition in unconstrained environments. In Workshop on faces in’RealLife’Images: detection, alignment, and recognition, 2008.
243
+ [18] Younghyun Jo and Seon Joo Kim. Practical single-image super-resolution using look-up table. In CVPR, 2021.
244
+ [19] Justin Johnson, Alexandre Alahi, and Li Fei-Fei. Perceptual losses for real-time style transfer and super-resolution. In ECCV, 2016.
245
+ [20] Tero Karras, Timo Aila, Samuli Laine, and Jaakko Lehtinen. Progressive growing of gans for improved quality, stability, and variation. In ICLR, 2018.
246
+ [21] Tero Karras, Samuli Laine, and Timo Aila. A style-based generator architecture for generative adversarial networks. In CVPR, 2019.
247
+ [22] Junjie Ke, Qifei Wang, Yilin Wang, Peyman Milanfar, and Feng Yang. MUSIQ: Multi-scale image quality transformer. In ICCV, 2021.
248
+ [23] Diederik P Kingma and Jimmy Ba. Adam: A method for stochastic optimization. In ICLR, 2014.
249
+ [24] Xiaoming Li, Chaofeng Chen, Shangchen Zhou, Xianhui Lin, Wangmeng Zuo, and Lei Zhang. Blind face restoration via deep multi-scale component dictionaries. In ECCV, 2020.
250
+ [25] Xiaoming Li, Wenyu Li, Dongwei Ren, Hongzhi Zhang, Meng Wang, and Wangmeng Zuo. Enhanced blind face restoration with multi-exemplar images and adaptive spatial feature fusion. In CVPR, 2020.
251
+ [26] Xiaoming Li, Ming Liu, Yuting Ye, Wangmeng Zuo, Liang Lin, and Ruigang Yang. Learning warped guidance for blind face restoration. In ECCV, 2018.
252
+ [27] Sachit Menon, Alexandru Damian, Shijia Hu, Nikhil Ravi, and Cynthia Rudin. PULSE: Self-supervised photo upsampling via latent space exploration of generative models. In CVPR, 2020.
253
+ [28] Wenqi Ren, Jiaolong Yang, Senyou Deng, David Wipf, Xiaochun Cao, and Xin Tong. Face video deblurring using 3d facial priors. In ICCV, 2019.
254
+ [29] Elad Richardson, Yuval Alaluf, Or Patashnik, Yotam Nitzan, Yaniv Azar, Stav Shapiro, and Daniel Cohen-Or. Encoding in style: a StyleGAN encoder for image-to-image translation. In CVPR, 2021.
255
+ [30] Ziyi Shen, Wei-Sheng Lai, Tingfa Xu, Jan Kautz, and Ming-Hsuan Yang. Deep semantic face deblurring. In CVPR, 2018.
256
+ [31] Karen Simonyan and Andrew Zisserman. Very deep convolutional networks for large-scale image recognition. In ICLR, 2015.
257
+ [32] Radu Timofte, Vincent De Smet, and Luc Van Gool. Anchored neighborhood regression for fast examplebased super-resolution. In ICCV, 2013.
258
+ [33] Radu Timofte, Vincent De Smet, and Luc Van Gool. $\mathbf { A } +$ : Adjusted anchored neighborhood regression for fast super-resolution. In ACCV, 2014.
259
+ [34] Aaron Van Den Oord, Oriol Vinyals, et al. Neural discrete representation learning. NeurIPS, 2017.
260
+ [35] Laurens Van Der Maaten. Accelerating t-sne using tree-based algorithms. The journal of machine learning research, 15(1):3221–3245, 2014.
261
+ [36] Ashish Vaswani, Noam Shazeer, Niki Parmar, Jakob Uszkoreit, Llion Jones, Aidan N Gomez, Łukasz Kaiser, and Illia Polosukhin. Attention is all you need. In NeurIPS, 2017.
262
+ [37] Xintao Wang, Yu Li, Honglun Zhang, and Ying Shan. Towards real-world blind face restoration with generative facial prior. In CVPR, 2021.
263
+ [38] Xintao Wang, Ke Yu, Chao Dong, and Chen Change Loy. Recovering realistic texture in image superresolution by deep spatial feature transform. In CVPR, 2018.
264
+ [39] Zhouxia Wang, Jiawei Zhang, Runjian Chen, Wenping Wang, and Ping Luo. RestoreFormer: High-quality blind face restoration from undegraded key-value pairs. In CVPR, 2022.
265
+ [40] Jianchao Yang, John Wright, Thomas S Huang, and Yi Ma. Image super-resolution via sparse representation. IEEE transactions on image processing, 19(11):2861–2873, 2010.
266
+ [41] Lingbo Yang, Shanshe Wang, Siwei Ma, Wen Gao, Chang Liu, Pan Wang, and Peiran Ren. HiFaceGAN: Face renovation via collaborative suppression and replenishment. In ACM MM, 2020.
267
+ [42] Shuo Yang, Ping Luo, Chen Change Loy, and Xiaoou Tang. WIDER FACE: A face detection benchmark. In CVPR, 2016.
268
+ [43] Tao Yang, Peiran Ren, Xuansong Xie, and Lei Zhang. GAN prior embedded network for blind face restoration in the wild. In CVPR, 2021.
269
+ [44] Xin Yu, Basura Fernando, Bernard Ghanem, Fatih Porikli, and Richard Hartley. Face super-resolution guided by facial component heatmaps. In ECCV, 2018.
270
+ [45] Richard Zhang, Phillip Isola, Alexei A Efros, Eli Shechtman, and Oliver Wang. The unreasonable effectiveness of deep features as a perceptual metric. In CVPR, 2018.
271
+ [46] Yang Zhao, Yu-Chuan Su, Chun-Te Chu, Yandong Li, Marius Renn, Yukun Zhu, Changyou Chen, and Xuhui Jia. Rethinking deep face restoration. In CVPR, 2022.
272
+ [47] Shangchen Zhou, Jiawei Zhang, Wangmeng Zuo, and Chen Change Loy. Cross-scale internal graph neural network for image super-resolution. In NeurIPS, 2020.
273
+ [48] Feida Zhu, Junwei Zhu, Wenqing Chu, Xinyi Zhang, Xiaozhong Ji, Chengjie Wang, and Ying Tai. Blind face restoration via integrating face shape and generative priors. In CVPR, 2022.
274
+
275
+ # Checklist
276
+
277
+ 1. For all authors...
278
+
279
+ (a) Do the main claims made in the abstract and introduction accurately reflect the paper’s contributions and scope? [Yes]
280
+ (b) Did you describe the limitations of your work? [Yes] See Sec. 4.7
281
+ (c) Did you discuss any potential negative societal impacts of your work? [N/A]
282
+ (d) Have you read the ethics review guidelines and ensured that your paper conforms to them? [Yes]
283
+
284
+ 2. If you are including theoretical results...
285
+
286
+ (a) Did you state the full set of assumptions of all theoretical results? [N/A] (b) Did you include complete proofs of all theoretical results? [N/A]
287
+
288
+ 3. If you ran experiments...
289
+
290
+ (a) Did you include the code, data, and instructions needed to reproduce the main experimental results (either in the supplemental material or as a URL)? [Yes] The code is publicly available at: https://github.com/sczhou/CodeFormer.
291
+ (b) Did you specify all the training details (e.g., data splits, hyperparameters, how they were chosen)? [Yes] See Sec. 4.2
292
+ (c) Did you report error bars (e.g., with respect to the random seed after running experiments multiple times)? [N/A]
293
+ (d) Did you include the total amount of compute and the type of resources used (e.g., type of GPUs, internal cluster, or cloud provider)? [Yes] See Sec. 4.2
294
+
295
+ 4. If you are using existing assets (e.g., code, data, models) or curating/releasing new assets...
296
+
297
+ (a) If your work uses existing assets, did you cite the creators? [Yes]
298
+ (b) Did you mention the license of the assets? [No] It is publicly available.
299
+ (c) Did you include any new assets either in the supplemental material or as a URL? [Yes] The code and dataset can be found on our project page.
300
+ (d) Did you discuss whether and how consent was obtained from people whose data you’re using/curating? [Yes]
301
+ (e) Did you discuss whether the data you are using/curating contains personally identifiable information or offensive content? [N/A]
302
+
303
+ 5. If you used crowdsourcing or conducted research with human subjects...
304
+
305
+ (a) Did you include the full text of instructions given to participants and screenshots, if applicable? [N/A]
306
+ (b) Did you describe any potential participant risks, with links to Institutional Review Board (IRB) approvals, if applicable? [N/A]
307
+ (c) Did you include the estimated hourly wage paid to participants and the total amount spent on participant compensation? [N/A]
parse/dev/XdDl3bFUNn5/XdDl3bFUNn5_content_list.json ADDED
@@ -0,0 +1,1379 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ [
2
+ {
3
+ "type": "text",
4
+ "text": "Towards Robust Blind Face Restoration with Codebook Lookup Transformer ",
5
+ "text_level": 1,
6
+ "bbox": [
7
+ 228,
8
+ 122,
9
+ 769,
10
+ 172
11
+ ],
12
+ "page_idx": 0
13
+ },
14
+ {
15
+ "type": "text",
16
+ "text": "Shangchen Zhou Kelvin C.K. Chan Chongyi Li Chen Change Loy ",
17
+ "bbox": [
18
+ 243,
19
+ 224,
20
+ 753,
21
+ 241
22
+ ],
23
+ "page_idx": 0
24
+ },
25
+ {
26
+ "type": "text",
27
+ "text": "S-Lab, Nanyang Technological University {s200094, chan0899, chongyi.li, ccloy}@ntu.edu.sg https://shangchenzhou.com/projects/CodeFormer ",
28
+ "bbox": [
29
+ 310,
30
+ 241,
31
+ 687,
32
+ 281
33
+ ],
34
+ "page_idx": 0
35
+ },
36
+ {
37
+ "type": "text",
38
+ "text": "Abstract ",
39
+ "text_level": 1,
40
+ "bbox": [
41
+ 462,
42
+ 324,
43
+ 535,
44
+ 340
45
+ ],
46
+ "page_idx": 0
47
+ },
48
+ {
49
+ "type": "text",
50
+ "text": "Blind face restoration is a highly ill-posed problem that often requires auxiliary guidance to 1) improve the mapping from degraded inputs to desired outputs, or 2) complement high-quality details lost in the inputs. In this paper, we demonstrate that a learned discrete codebook prior in a small proxy space largely reduces the uncertainty and ambiguity of restoration mapping by casting blind face restoration as a code prediction task, while providing rich visual atoms for generating highquality faces. Under this paradigm, we propose a Transformer-based prediction network, named CodeFormer, to model the global composition and context of the low-quality faces for code prediction, enabling the discovery of natural faces that closely approximate the target faces even when the inputs are severely degraded. To enhance the adaptiveness for different degradation, we also propose a controllable feature transformation module that allows a flexible trade-off between fidelity and quality. Thanks to the expressive codebook prior and global modeling, CodeFormer outperforms the state of the arts in both quality and fidelity, showing superior robustness to degradation. Extensive experimental results on synthetic and realworld datasets verify the effectiveness of our method. ",
51
+ "bbox": [
52
+ 233,
53
+ 356,
54
+ 766,
55
+ 575
56
+ ],
57
+ "page_idx": 0
58
+ },
59
+ {
60
+ "type": "text",
61
+ "text": "1 Introduction ",
62
+ "text_level": 1,
63
+ "bbox": [
64
+ 174,
65
+ 601,
66
+ 310,
67
+ 618
68
+ ],
69
+ "page_idx": 0
70
+ },
71
+ {
72
+ "type": "text",
73
+ "text": "Face images captured in the wild often suffer from various degradation, such as compression, blur, and noise. Restoring such images is highly ill-posed as the information loss induced by the degradation leads to infinite plausible high-quality (HQ) outputs given a low-quality (LQ) input. The ill-posedness is further elevated in blind restoration, where the specific degradation is unknown. Despite the progress made with the emergence of deep learning, learning a LQ-HQ mapping without additional guidance in the huge image space is still intractable, leading to the suboptimal restoration quality of earlier approaches. To improve the output quality, auxiliary information that 1) reduces the uncertainty of LQ-HQ mapping and 2) complements high-quality details is indispensable. ",
74
+ "bbox": [
75
+ 174,
76
+ 632,
77
+ 823,
78
+ 744
79
+ ],
80
+ "page_idx": 0
81
+ },
82
+ {
83
+ "type": "text",
84
+ "text": "Various priors have been used to mitigate the ill-posedness of this problem, including geometric priors [5, 6, 30, 44], reference priors [24–26], and generative priors [2, 37, 43]. Although improved textures and details are observed, these approaches often suffer from high sensitivity to degradation or limited prior expressiveness. These priors provide insufficient guidance for face restoration, thus their networks essentially resort to the information of LQ input images that are usually highly corrupted. As a result, the LQ-HQ mapping uncertainty still exists, and the output quality is deteriorated by the degradation of the input images. Most recently, based on generative prior, some methods project the degraded faces into a continuous infinite space via iterative latent optimization [27] or direct latent encoding [29]. Despite great realness of outputs, it is difficult to find the accurate latent vectors in case of severe degradation, resulting in low-fidelity results (Fig. 1(d)). To enhance the fidelity, skip connections between encoder and decoder are usually required in this kind of methods [37, 43, 2], as illustrated in Fig. 1(a) (top), however, such designs meanwhile introduce artifacts in the results when inputs are severely degraded, as shown in Fig. 1(e). ",
85
+ "bbox": [
86
+ 174,
87
+ 750,
88
+ 825,
89
+ 901
90
+ ],
91
+ "page_idx": 0
92
+ },
93
+ {
94
+ "type": "image",
95
+ "img_path": "images/f6a5ba59ffcbf4e05f2f2c656f8beb6787252ca59ade651e0ba58658fe31ad31.jpg",
96
+ "image_caption": [
97
+ "(a) Frameworks of continuous prior (top) and our discrete prior (bottom) (b) Distributions of HQ (left) / LQ (right) features and the codebook items "
98
+ ],
99
+ "image_footnote": [],
100
+ "bbox": [
101
+ 174,
102
+ 89,
103
+ 821,
104
+ 218
105
+ ],
106
+ "page_idx": 1
107
+ },
108
+ {
109
+ "type": "image",
110
+ "img_path": "images/7f1787e09fdd1b5bf7ebc117376a76fc40cf4e5e8a9c6203fc09f9ce25602f39.jpg",
111
+ "image_caption": [],
112
+ "image_footnote": [],
113
+ "bbox": [
114
+ 547,
115
+ 238,
116
+ 635,
117
+ 305
118
+ ],
119
+ "page_idx": 1
120
+ },
121
+ {
122
+ "type": "image",
123
+ "img_path": "images/1da7f7a91603de648a5b4e8aadd0c599ced1952d43c2725fb234be4ea5ae36fd.jpg",
124
+ "image_caption": [],
125
+ "image_footnote": [],
126
+ "bbox": [
127
+ 732,
128
+ 238,
129
+ 820,
130
+ 306
131
+ ],
132
+ "page_idx": 1
133
+ },
134
+ {
135
+ "type": "image",
136
+ "img_path": "images/afb6b5779423f7c9cf9852f43a07ba464a26fc0b34bc02f10175d78cc3000ffc.jpg",
137
+ "image_caption": [
138
+ "(g) CodeFormer (discrete) "
139
+ ],
140
+ "image_footnote": [],
141
+ "bbox": [
142
+ 452,
143
+ 238,
144
+ 544,
145
+ 306
146
+ ],
147
+ "page_idx": 1
148
+ },
149
+ {
150
+ "type": "image",
151
+ "img_path": "images/9b428d201d77a74995f65025b3cd0df36ba9913698ee17ecf5af38bea3baf0b3.jpg",
152
+ "image_caption": [
153
+ "(h) Code GT (discrete) "
154
+ ],
155
+ "image_footnote": [],
156
+ "bbox": [
157
+ 638,
158
+ 238,
159
+ 730,
160
+ 305
161
+ ],
162
+ "page_idx": 1
163
+ },
164
+ {
165
+ "type": "image",
166
+ "img_path": "images/bf9014c41bf3a0cfd55b18604dbb523fc2802cedb51fbae5ae170af88a880d8f.jpg",
167
+ "image_caption": [
168
+ "Figure 1: An illustration of motivation. (a) Restoration frameworks of continuous generative prior (top) and our discrete codebook prior (bottom). (b) t-SNE [35] visualization for HQ/LQ face features and codebook items. (c) LQ input. (d-e) Results of existing methods with continuous prior (PULSE [27] and GFP-GAN [37]). (f-g) Results of discrete prior (Nearest Neighbor [11, 34] and CodeFormer). (h) Reconstruction results from the code sequence ground truth. (i) HQ ground truth. As shown, (d) PULSE without skip connection shows the low fidelity. (e) GFP-GAN with skip connection alleviates identity issues but introduces notable artifacts. (f) Utilizing nearest neighbor matching for code lookup recovers more accurate facial structure compared with (d-e), but some details such as glasses cannot be restored and some artifacts could be introduced. (g) Employing Transformer for code prediction, our CodeFormer generates best results with both high quality and fidelity. "
169
+ ],
170
+ "image_footnote": [],
171
+ "bbox": [
172
+ 362,
173
+ 238,
174
+ 450,
175
+ 306
176
+ ],
177
+ "page_idx": 1
178
+ },
179
+ {
180
+ "type": "text",
181
+ "text": "",
182
+ "bbox": [
183
+ 173,
184
+ 455,
185
+ 823,
186
+ 484
187
+ ],
188
+ "page_idx": 1
189
+ },
190
+ {
191
+ "type": "text",
192
+ "text": "Different from the aforementioned approaches, this work casts blind face restoration as a code prediction task in a small finite proxy space of the learned discrete codebook prior, which shows superior robustness to degradation as well as rich expressiveness. The codebook is learned by selfreconstruction of HQ faces using a vector-quantized autoencoder, which along with decoder stores the rich HQ details for face restoration. In contrast to continuous generative priors [11, 37, 43], the combinations of codebook items form a discrete prior space with only finite cardinality. Through mapping the LQ images to a much smaller proxy space (e.g., 1024 codes), the uncertainty of the LQ-HQ mapping is significantly attenuated, promoting robustness against the diverse degradation, as compared in Figs. 1(d-g). Besides, the codebook space possess greater expressiveness, which perceptually approximates the image space, as shown in Fig. 1(h). This nature allows the network to reduce the reliance on inputs and even be free of skip connections. ",
193
+ "bbox": [
194
+ 174,
195
+ 491,
196
+ 825,
197
+ 642
198
+ ],
199
+ "page_idx": 1
200
+ },
201
+ {
202
+ "type": "text",
203
+ "text": "Though the discrete representation based on a codebook has been deployed for image generation [4, 11, 34], the accurate code composition for image restoration remains a non-trivial challenge. The existing works look up codebook via nearest-neighbor (NN) feature matching, which is less feasible for image restoration since the intrinsic textures of LQ inputs are usually corrupted. The information loss and diverse degradation in LQ images inevitably distort the feature distribution, prohibiting accurate feature matching. As depicted in Fig. 1(b) (right), even after fine-tuning the encoder on LQ images, the LQ features cannot cluster well to the exact code but spread into other nearby code clusters, thus the nearest-neighbor matching is unreliable in such cases. ",
204
+ "bbox": [
205
+ 173,
206
+ 648,
207
+ 825,
208
+ 760
209
+ ],
210
+ "page_idx": 1
211
+ },
212
+ {
213
+ "type": "text",
214
+ "text": "Tailored for restoration, we propose a Transformer-based code prediction network, named CodeFormer, to exploit global compositions and long-range dependencies of LQ faces for better code prediction. Specifically, taking the LQ features as input, the Transformer module predicts the code token sequence which is treated as the discrete representation of the face images in the codebook space. Thanks to the global modeling for remedying the local information loss in LQ images, the proposed CodeFormer shows robustness to heavy degradation and keeps overall coherence. Comparing the results presented in Figs. 1(f-g), the proposed CodeFormer is able to recover more details than the nearest-neighbor matching, such as the glasses, improving both quality and fidelity of restoration. ",
215
+ "bbox": [
216
+ 174,
217
+ 766,
218
+ 825,
219
+ 877
220
+ ],
221
+ "page_idx": 1
222
+ },
223
+ {
224
+ "type": "text",
225
+ "text": "Moreover, we propose a controllable feature transformation module with an adjustable coefficient to control the information flow from the LQ encoder to decoder. Such design allows a flexible trade-off between restoration quality and fidelity so that the continuous image transitions between them can be achieved. This module enhances the adaptiveness of CodeFormer under different degradations, e.g., in case of heavy degradation, one could manually reduce the information flow of LQ features carrying degradation to produce high-quality results. ",
226
+ "bbox": [
227
+ 174,
228
+ 883,
229
+ 820,
230
+ 911
231
+ ],
232
+ "page_idx": 1
233
+ },
234
+ {
235
+ "type": "text",
236
+ "text": "",
237
+ "bbox": [
238
+ 174,
239
+ 92,
240
+ 825,
241
+ 147
242
+ ],
243
+ "page_idx": 2
244
+ },
245
+ {
246
+ "type": "text",
247
+ "text": "Equipped with the above components, the proposed CodeFormer demonstrates superior performance in existing datasets and also our newly introduced WIDER-Test dataset that consists of 970 severely degraded faces collected from the WIDER-Face dataset [42]. In addition to face restoration, our method also demonstrates its effectiveness on other challenging tasks such as face inpainting, where long-range clues from other regions are required. Systematic studies and experiments are conducted to demonstrate the merits of our method over previous works. ",
248
+ "bbox": [
249
+ 174,
250
+ 154,
251
+ 825,
252
+ 237
253
+ ],
254
+ "page_idx": 2
255
+ },
256
+ {
257
+ "type": "text",
258
+ "text": "2 Related Work ",
259
+ "text_level": 1,
260
+ "bbox": [
261
+ 174,
262
+ 262,
263
+ 321,
264
+ 279
265
+ ],
266
+ "page_idx": 2
267
+ },
268
+ {
269
+ "type": "text",
270
+ "text": "Blind Face Restoration. Since face is highly structured, geometric priors of faces are exploited for blind face restoration. Some methods introduce facial landmarks [6], face parsing maps [5, 30, 41], facial component heatmaps [44], or 3D shapes [16, 28, 48] in their designs. However, such prior information cannot be accurately acquired from degraded faces. Moreover, geometric priors are unable to provide rich details for high-quality face restoration. ",
271
+ "bbox": [
272
+ 174,
273
+ 297,
274
+ 825,
275
+ 367
276
+ ],
277
+ "page_idx": 2
278
+ },
279
+ {
280
+ "type": "text",
281
+ "text": "Reference-based approaches [9, 24–26] have been proposed to circumvent the above limitations. These methods generally require the references to possess same identity as the input degraded face. For example, Li et al. [26] propose a guided face restoration network that consists of a warping subnetwork and a reconstruction subnetwork, and a high-quality guided image of the same identity as input is used for better restoring the facial details. However, such references are not always available. DFDNet [24] pre-constructs dictionaries composed of high-quality facial component features. However, the component-specific dictionary features are still insufficient for high-quality face restoration, especially for the regions out of the dictionary scope (e.g., skin, hair). To alleviate this issue, recent VQGAN-based methods [39, 46] explores a learned HQ dictionary, which contains more generic and rich details face restoration. ",
282
+ "bbox": [
283
+ 174,
284
+ 372,
285
+ 825,
286
+ 511
287
+ ],
288
+ "page_idx": 2
289
+ },
290
+ {
291
+ "type": "text",
292
+ "text": "Recently, the generative facial priors from pre-trained generators, e.g., StyleGAN2 [21], have been widely explored for blind face restoration. It is utilized via different strategies of iterative latent optimization for effective GAN inversion [12, 27] or direct latent encoding of degraded faces [29]. However, preserving high fidelity of the restored faces is challenging when one projects the degraded faces into the continuous infinite latent space. To relieve this issue, GLEAN [2, 3], GPEN [43], and GFPGAN [37] embed the generative prior into encoder-decoder network structures, with additional structural information from input images as guidance. Despite the improvement of fidelity, these methods highly rely on inputs through the skip connections, which could introduce artifacts to results when inputs are severely corrupted. ",
293
+ "bbox": [
294
+ 174,
295
+ 518,
296
+ 825,
297
+ 642
298
+ ],
299
+ "page_idx": 2
300
+ },
301
+ {
302
+ "type": "text",
303
+ "text": "Dictionary Learning. Sparse representation with learned dictionaries has demonstrated its superiority in image restoration tasks, such as super-resolution [13, 32, 33, 40] and denoising [10]. However, these methods usually require an iterative optimization to learn the dictionaries and sparse coding, suffering from high computational cost. Despite the inefficiency, their high-level insight into exploring a HQ dictionary has inspired reference-based restoration networks, e.g., LUT [18] and selfreference [47], as well as synthesis methods [11, 34]. Jo and Kim [18] construct a look-up table (LUT) by transferring the network output values to a LUT, so that only a simple value retrieval is needed during inference. However, storing HQ textures in the image domain usually requires a huge LUT, limiting its practicality. VQVAE [34] is first to introduce a highly compressed codebook learned by a vector-quantized autoencoder model. VQGAN [11] further adopts the adversarial loss and perceptual loss to enhance perceptual quality at a high compression rate, significantly reducing the codebook size without sacrificing its expressiveness. Unlike the large hand-crafted dictionary [18, 24], the learnable codebook automatically learns optimal elements for HQ image reconstruction, providing superior efficiency and expressiveness as well as circumventing the laborious dictionary design. Inspired by the codebook learning, this paper investigates a discrete proxy space for blind face restoration. Different from recent VQGAN-based approaches [39, 46], we exploit the discrete codebook prior by predicting code sequences via global modeling, and we secure prior effectiveness by fixing the encoder. Such designs allow our method to take full advantage of the codebook so that it does not depend on the feature fusion with LQ cues, significantly enhancing the robustness of face restoration. ",
304
+ "bbox": [
305
+ 174,
306
+ 650,
307
+ 825,
308
+ 911
309
+ ],
310
+ "page_idx": 2
311
+ },
312
+ {
313
+ "type": "image",
314
+ "img_path": "images/0d4e2a0f0c1216d1ca5d65c1b2a790b534ed76447c7dfad15b23882ac47eb820.jpg",
315
+ "image_caption": [
316
+ "Figure 2: Framework of CodeFormer. (a) We first learn a discrete codebook and a decoder to store high-quality visual parts of face images via self-reconstruction learning. (b) With fixed codebook and decoder, we then introduce a Transformer module for code sequence prediction, modeling the global face composition of lowquality inputs. Besides, a controllable feature transformation module is used to control the information flow from LQ encoder to decoder. Note that this connection is optional, which can be disabled to avoid adverse effects when inputs are severely degraded, and one can adjust a scalar weight $w$ to trade between quality and fidelity. "
317
+ ],
318
+ "image_footnote": [],
319
+ "bbox": [
320
+ 173,
321
+ 88,
322
+ 825,
323
+ 253
324
+ ],
325
+ "page_idx": 3
326
+ },
327
+ {
328
+ "type": "text",
329
+ "text": "3 Methodology ",
330
+ "text_level": 1,
331
+ "bbox": [
332
+ 174,
333
+ 356,
334
+ 313,
335
+ 373
336
+ ],
337
+ "page_idx": 3
338
+ },
339
+ {
340
+ "type": "text",
341
+ "text": "The main focus of this work is to exploit a discrete representation space that reduces the uncertainty of restoration mapping and complements high-quality details for the degraded inputs. Since local textures and details are lost and corrupted in low-quality inputs, we employ a Transformer module to model the global composition of natural faces, which remedies the local information loss, enabling high-quality restoration. The overall framework is illustrated in Fig. 2. ",
342
+ "bbox": [
343
+ 173,
344
+ 386,
345
+ 825,
346
+ 457
347
+ ],
348
+ "page_idx": 3
349
+ },
350
+ {
351
+ "type": "text",
352
+ "text": "We first incorporate the idea of vector quantization [11, 34] and pre-train a quantized autoencoder through self-reconstruction to obtain a discrete codebook and the corresponding decoder (Sec. 3.1). The prior from the codebook combination and decoder is then used for face restoration. Based on this codebook prior, we then employ a Transformer for accurate prediction of code combination from the low-quality inputs (Sec. 3.2). In addition, a controllable feature transformation module is introduced to exploit a flexible trade-off between restoration quality and fidelity (Sec. 3.3). The training of our method is divided into three stages accordingly. ",
353
+ "bbox": [
354
+ 173,
355
+ 462,
356
+ 825,
357
+ 560
358
+ ],
359
+ "page_idx": 3
360
+ },
361
+ {
362
+ "type": "text",
363
+ "text": "3.1 Codebook Learning (Stage I) ",
364
+ "text_level": 1,
365
+ "bbox": [
366
+ 176,
367
+ 575,
368
+ 413,
369
+ 590
370
+ ],
371
+ "page_idx": 3
372
+ },
373
+ {
374
+ "type": "text",
375
+ "text": "To reduce uncertainty of the LQ-HQ mapping and complement high-quality details for restoration, we first pre-train the quantized autoencoder to learn a context-rich codebook, which improves network expressiveness as well as robustness against degradation. ",
376
+ "bbox": [
377
+ 173,
378
+ 599,
379
+ 825,
380
+ 642
381
+ ],
382
+ "page_idx": 3
383
+ },
384
+ {
385
+ "type": "text",
386
+ "text": "As shown in Fig. 2(a), the HQ face image $I _ { h } \\in \\mathbb { R } ^ { H \\times W \\times 3 }$ is first embeded as a compressed feature $Z _ { h } \\in \\mathbb { R } ^ { m \\times n \\times d }$ by an encoder $E _ { H }$ . Following VQVAE [34] and VQGAN [11], we replace each “pixel” in $Z _ { h }$ H with the nearest item in the learnable codebook $\\mathcal { C } = \\{ c _ { k } \\in \\mathbb { R } ^ { d } \\} _ { k = 0 } ^ { \\tilde { N } }$ to obtain the quantized feature $Z _ { c } \\in \\mathbb { R } ^ { m \\times n \\times d }$ and the corresponding code token sequence $s \\in \\{ 0 , \\cdots , N - 1 \\} ^ { m \\cdot n }$ : ",
387
+ "bbox": [
388
+ 173,
389
+ 647,
390
+ 826,
391
+ 707
392
+ ],
393
+ "page_idx": 3
394
+ },
395
+ {
396
+ "type": "equation",
397
+ "img_path": "images/07d764c5dea6e69ca0fc7fd917ca58603240b47309c117ea71830352d6c23a39.jpg",
398
+ "text": "$$\nZ _ { c } ^ { ( i , j ) } = \\underset { c _ { k } \\in \\mathcal { C } } { \\operatorname { a r g m i n } } \\| Z _ { h } ^ { ( i , j ) } - c _ { k } \\| _ { 2 } ; \\quad s ^ { ( i , j ) } = \\underset { k } { \\operatorname { a r g m i n } } \\| Z _ { h } ^ { ( i , j ) } - c _ { k } \\| _ { 2 } .\n$$",
399
+ "text_format": "latex",
400
+ "bbox": [
401
+ 276,
402
+ 709,
403
+ 720,
404
+ 739
405
+ ],
406
+ "page_idx": 3
407
+ },
408
+ {
409
+ "type": "text",
410
+ "text": "The decoder $D _ { H }$ then reconstructs the high-quality face image $I _ { r e c }$ given $Z _ { c }$ . The $m \\cdot n$ code token sequence $s$ forms a new latent discrete representation that specifies the respective code index of the learned codebook, i.e., $Z _ { c } ^ { ( i , j ) } = c _ { k }$ when $s ^ { ( i , j ) } = k$ . ",
411
+ "bbox": [
412
+ 174,
413
+ 741,
414
+ 825,
415
+ 787
416
+ ],
417
+ "page_idx": 3
418
+ },
419
+ {
420
+ "type": "text",
421
+ "text": "Training Objectives. To train the quantized autoencoder with a codebook, we adopt three image-level reconstruction losses: L1 loss $\\mathcal { L } _ { 1 }$ , perceptual loss [19, 45] $\\mathcal { L } _ { p e r }$ , and adversarial loss [11] $\\mathcal { L } _ { a d v }$ : ",
422
+ "bbox": [
423
+ 171,
424
+ 792,
425
+ 825,
426
+ 821
427
+ ],
428
+ "page_idx": 3
429
+ },
430
+ {
431
+ "type": "text",
432
+ "text": "$\\mathcal { L } _ { 1 } = | | I _ { h } - I _ { r e c } | | _ { 1 } ; \\quad \\mathcal { L } _ { p e r } = | | \\Phi ( I _ { h } ) - \\Phi ( I _ { r e c } ) | | _ { 2 } ^ { 2 } ; \\quad \\mathcal { L } _ { a d v } = [ \\log D ( I _ { h } ) + \\log ( 1 - D ( I _ { r e c } ) ) ] ,$ (2) where $\\Phi$ denotes the feature extractor of VGG19 [31]. Since, image-level losses are underconstrained when updating the codebook items, we lso adopt the intermediate cod vel loss [11, 34] $\\mathcal { L } _ { c o d e } ^ { f e a t }$ to $\\mathcal { C }$ $Z _ { h }$ ",
433
+ "bbox": [
434
+ 174,
435
+ 825,
436
+ 826,
437
+ 891
438
+ ],
439
+ "page_idx": 3
440
+ },
441
+ {
442
+ "type": "equation",
443
+ "img_path": "images/aabfb70b431beb4b38a846e37259fb32781b803eecd3238b0a5510fe5e00a691.jpg",
444
+ "text": "$$\n\\mathcal { L } _ { c o d e } ^ { f e a t } = \\Vert \\mathbf { s g } ( Z _ { h } ) - Z _ { c } \\Vert _ { 2 } ^ { 2 } + \\beta \\Vert Z _ { h } - \\mathbf { s g } ( Z _ { c } ) \\Vert _ { 2 } ^ { 2 } ,\n$$",
445
+ "text_format": "latex",
446
+ "bbox": [
447
+ 341,
448
+ 893,
449
+ 655,
450
+ 912
451
+ ],
452
+ "page_idx": 3
453
+ },
454
+ {
455
+ "type": "text",
456
+ "text": "where $\\operatorname { s g } ( \\cdot )$ stands for the stop-gradient operator and $\\beta = 0 . 2 5$ is a weight trade-off for the update rates of the encoder and codebook. Since the quantization operation in Eq. (1) is non-differentiable, we adopt straight-through gradient estimator [11, 34] to copy the gradients from the decoder to the encoder. The complete objective of codebook prior learning $\\mathcal { L } _ { c o d e b o o k }$ is: ",
457
+ "bbox": [
458
+ 173,
459
+ 90,
460
+ 825,
461
+ 147
462
+ ],
463
+ "page_idx": 4
464
+ },
465
+ {
466
+ "type": "equation",
467
+ "img_path": "images/24510fcbddc542edac43a85bb320ebb0c21337901b23f25282b4af152fd4a17c.jpg",
468
+ "text": "$$\n\\mathcal { L } _ { c o d e b o o k } = \\mathcal { L } _ { 1 } + \\mathcal { L } _ { p e r } + \\mathcal { L } _ { c o d e } ^ { f e a t } + \\lambda _ { a d v } \\cdot \\mathcal { L } _ { a d v } ,\n$$",
469
+ "text_format": "latex",
470
+ "bbox": [
471
+ 339,
472
+ 151,
473
+ 656,
474
+ 172
475
+ ],
476
+ "page_idx": 4
477
+ },
478
+ {
479
+ "type": "text",
480
+ "text": "where $\\lambda _ { a d v }$ is set to 0.8 in our experiments. ",
481
+ "bbox": [
482
+ 174,
483
+ 176,
484
+ 459,
485
+ 191
486
+ ],
487
+ "page_idx": 4
488
+ },
489
+ {
490
+ "type": "text",
491
+ "text": "Codebook Settings. Our encoder $E _ { H }$ and decoder $D _ { H }$ consist of 12 residual blocks and 5 resize layers for downsampling and upsampling, respectively. Hence we obtain a large compression ratio of $r = H / n = W / \\bar { m } = 3 2$ , which leads to a great robustness against degradation and a tractable computational cost for our global modeling in Stage II. Although more codebook items could ease reconstruction, the redundant elements could cause ambiguity in subsequent code predictions. Hence, we set the item number $N$ of codebook to 1024, which is sufficient for accurate face reconstruction. Besides, the code dimension $d$ is set to 256. ",
492
+ "bbox": [
493
+ 173,
494
+ 195,
495
+ 826,
496
+ 295
497
+ ],
498
+ "page_idx": 4
499
+ },
500
+ {
501
+ "type": "text",
502
+ "text": "3.2 Codebook Lookup Transformer Learning (Stage II) ",
503
+ "text_level": 1,
504
+ "bbox": [
505
+ 173,
506
+ 309,
507
+ 573,
508
+ 325
509
+ ],
510
+ "page_idx": 4
511
+ },
512
+ {
513
+ "type": "text",
514
+ "text": "Due to corruptions of textures in LQ faces, the nearest-neighbour (NN) matching in Eq. (1) usually fails in finding accurate codes for face restoration. As depicted in Fig. 1(b), LQ features with diverse degradation could deviate from the correct code and be grouped into nearby clusters, resulting in undesirable restoration results, as shown in Fig. 1(f). To mitigate the problem, we employ a Transformer to model global interrelations for better code prediction. ",
515
+ "bbox": [
516
+ 173,
517
+ 334,
518
+ 825,
519
+ 405
520
+ ],
521
+ "page_idx": 4
522
+ },
523
+ {
524
+ "type": "text",
525
+ "text": "Built upon the learned autoencoder presented in Sec. 3.1, as shown in Fig. 2(b), we insert a Transformer [36] module containing nine self-attention blocks following the encoder. We fix the codebook $\\mathcal { C }$ and decoder $D _ { H }$ and finetune the encoder $E _ { H }$ for restoration. The finetuned encoder is denoted as $E _ { L }$ . To obtain the LQ features $Z _ { l } \\in \\mathbb { R } ^ { m \\times n \\times d }$ through $E _ { L }$ , we first unfold the features into $m \\cdot n$ vectors $Z _ { l } ^ { v } \\in \\mathbb { R } ^ { ( m \\cdot n ) \\times d }$ , and then feed them to the Transformer module. The $s$ -th self-attention block of Transformer computes as the following: ",
526
+ "bbox": [
527
+ 173,
528
+ 410,
529
+ 825,
530
+ 496
531
+ ],
532
+ "page_idx": 4
533
+ },
534
+ {
535
+ "type": "equation",
536
+ "img_path": "images/e5f8b403a18f9531da3950d7cfb1ced0e03353225325320fbee2408de7234a26.jpg",
537
+ "text": "$$\nX _ { s + 1 } = \\operatorname { S o f t m a x } ( Q _ { s } K _ { s } ) V _ { s } + X _ { s } ,\n$$",
538
+ "text_format": "latex",
539
+ "bbox": [
540
+ 382,
541
+ 501,
542
+ 614,
543
+ 518
544
+ ],
545
+ "page_idx": 4
546
+ },
547
+ {
548
+ "type": "text",
549
+ "text": "where $X _ { 0 } = Z _ { l } ^ { v }$ . The query $Q$ , key $K$ , and value $V$ are obtained from $X _ { s }$ through linear layers. We add a sinusoidal positional embedding $\\mathcal { P } \\in \\mathbb { R } ^ { ( m \\cdot n ) \\times d }$ [1, 7] on the queries $Q$ and the keys $K$ to increase the expressiveness of modeling sequential representation. Following the self-attention blocks, a Linear layer is adopted to project features to the dimension of $( m \\cdot { \\bar { n } } ) \\times N$ . Overall, taking the encoding feature $Z _ { l } ^ { v }$ as an input, the Transformer predicts the $m \\cdot n$ code sequence $\\hat { s } \\in \\{ 0 , \\cdot \\cdot \\cdot , | N | - 1 \\} ^ { m \\cdot n }$ in form of the probability of the $N$ code items. The predicted code sequence then retrieves the $m \\cdot n$ respective code items from the learned codebook, forming the quantized feature $\\hat { Z } _ { c } \\in \\mathbb { R } ^ { m \\times n \\times d }$ that produces a high-quality face image through the fixed decoder $D _ { H }$ . Thanks to our large compression ratio (i.e., 32), our Transformer is effective and efficient in modeling global correlations of LQ face images. ",
550
+ "bbox": [
551
+ 173,
552
+ 522,
553
+ 825,
554
+ 666
555
+ ],
556
+ "page_idx": 4
557
+ },
558
+ {
559
+ "type": "text",
560
+ "text": "Training Objectives. We train Transformer module $T$ as well as finetune the encoder $E _ { L }$ for restoration, while the codebook $\\mathcal { C }$ and decoder $D _ { H }$ are kept fixed. Instead of employing reconstruction loss and adversarial loss in the image-level, only code-level losses are required in this stage: 1) crossentropy loss $\\mathcal { L } _ { c o d e } ^ { t o k e n }$ for code token prediction supervision, and 2) L2 loss $\\mathcal { L } _ { c o d e } ^ { f e a t ^ { \\prime } }$ to force the LQ to approach the quantized feature from codebook, which eases the difficulty of token prediction learning: ",
561
+ "bbox": [
562
+ 173,
563
+ 671,
564
+ 826,
565
+ 760
566
+ ],
567
+ "page_idx": 4
568
+ },
569
+ {
570
+ "type": "equation",
571
+ "img_path": "images/7012696b2e07b6435db40ebec67a4815478416ea6f779550fc2de25d8181b128.jpg",
572
+ "text": "$$\n\\mathcal { L } _ { c o d e } ^ { t o k e n } = \\sum _ { i = 0 } ^ { m n - 1 } - s _ { i } \\log ( \\hat { s _ { i } } ) ; \\quad \\mathcal { L } _ { c o d e } ^ { f e a t ^ { \\prime } } = \\| Z _ { l } - \\mathrm { s g } ( Z _ { c } ) \\| _ { 2 } ^ { 2 } ,\n$$",
573
+ "text_format": "latex",
574
+ "bbox": [
575
+ 308,
576
+ 762,
577
+ 689,
578
+ 808
579
+ ],
580
+ "page_idx": 4
581
+ },
582
+ {
583
+ "type": "text",
584
+ "text": "where the ground truth of latent code $s$ is obtained from the pre-trained autoencoder in Stage I (Sec. 3.1), thus the quantized feature $Z _ { c }$ is then retrieved from codebook according to the $s$ . The final objective of Transformer learning is: ",
585
+ "bbox": [
586
+ 174,
587
+ 810,
588
+ 825,
589
+ 853
590
+ ],
591
+ "page_idx": 4
592
+ },
593
+ {
594
+ "type": "equation",
595
+ "img_path": "images/7b5afc28ccf7bc8bdbdccacbcd2423c6e10db03d07f3b5d2284fbbe960e8313c.jpg",
596
+ "text": "$$\n\\mathcal { L } _ { t f } = \\lambda _ { t o k e n } \\cdot \\mathcal { L } _ { c o d e } ^ { t o k e n } + \\mathcal { L } _ { c o d e } ^ { f e a t ^ { \\prime } } ,\n$$",
597
+ "text_format": "latex",
598
+ "bbox": [
599
+ 390,
600
+ 858,
601
+ 606,
602
+ 878
603
+ ],
604
+ "page_idx": 4
605
+ },
606
+ {
607
+ "type": "text",
608
+ "text": "where $\\lambda _ { t o k e n }$ is set to 0.5 in our method. Note that our network after this stage has already equipped with superior robustness and effectiveness in face restoration, especially for severely degraded faces. ",
609
+ "bbox": [
610
+ 171,
611
+ 883,
612
+ 828,
613
+ 911
614
+ ],
615
+ "page_idx": 4
616
+ },
617
+ {
618
+ "type": "text",
619
+ "text": "3.3 Controllable Feature Transformation (Stage III) ",
620
+ "text_level": 1,
621
+ "bbox": [
622
+ 173,
623
+ 90,
624
+ 547,
625
+ 106
626
+ ],
627
+ "page_idx": 5
628
+ },
629
+ {
630
+ "type": "text",
631
+ "text": "Despite our Stage $\\mathrm { I I }$ has obtained a great face restoration model, we also investigate a flexible tradeoff between quality and fidelity of face restoration. Thus, we propose the controllable feature transformation (CFT) module to control information flow from LQ encoder $E _ { L }$ to decoder $D _ { H }$ Specifically, as shown in Fig. 2, the LQ features $F _ { e }$ are used to slightly tune the decoder features $F _ { d }$ through spatial feature transformation [38] with the affine parameters of $\\alpha$ and $\\beta$ . An adjustable coefficient $w \\in [ 0 , 1 ]$ is then used to control the relative importance of the inputs: ",
632
+ "bbox": [
633
+ 173,
634
+ 116,
635
+ 825,
636
+ 200
637
+ ],
638
+ "page_idx": 5
639
+ },
640
+ {
641
+ "type": "equation",
642
+ "img_path": "images/19a792467832b6b6c83469d1acedcebb2f908786968546e01c3d68a6decbdd16.jpg",
643
+ "text": "$$\n\\begin{array} { r } { \\hat { F } _ { d } = F _ { d } + ( \\alpha \\odot F _ { d } + \\beta ) \\times w ; \\quad \\alpha , \\beta = \\mathcal { P } _ { \\theta } ( c ( F _ { d } , F _ { e } ) ) , } \\end{array}\n$$",
644
+ "text_format": "latex",
645
+ "bbox": [
646
+ 310,
647
+ 205,
648
+ 686,
649
+ 226
650
+ ],
651
+ "page_idx": 5
652
+ },
653
+ {
654
+ "type": "text",
655
+ "text": "where ${ \\mathcal { P } } _ { \\theta }$ denotes a stack of convolutions that predicts $\\alpha$ and $\\beta$ from the concatenated features of $c ( F _ { e } , F _ { d } )$ . We adopt the CFT modules at multiple scales $s \\in \\{ 3 2 , 6 4 , 1 2 8 , 2 5 6 \\}$ between encoder and decoder. Such a design allows our network to remain high fidelity for mild degradation and high quality for heavy degradation. Specifically, one could use a small $w$ to reduce the reliance on input LQ images with heavy degradation, thus producing high-quality outputs. The larger $w$ will introduce more information from LQ images to enhance the fidelity in case of mild degradation. ",
656
+ "bbox": [
657
+ 174,
658
+ 231,
659
+ 825,
660
+ 315
661
+ ],
662
+ "page_idx": 5
663
+ },
664
+ {
665
+ "type": "text",
666
+ "text": "Training Objectives. To train the controllable modules and finetune the encoder $E _ { L }$ in this stage, we keep the code-level losses of $\\mathcal { L } _ { t f }$ in Stage II, and also add image-level losses of $\\mathcal { L } _ { 1 }$ , $\\mathcal { L } _ { p e r }$ , and $\\mathcal { L } _ { a d v }$ , which are the same as that in Stage I except that $I _ { r e c }$ is replaced by restoration output $I _ { r e s }$ . The complete loss for this stage is the sum of above losses weighted with their original weight factors. We set the $w$ to 1 during training of this stage, which then allows network to achieve continuous transitions of results by adjusting $w$ in $[ 0 , 1 ]$ during inference. For inference, unless otherwise stated, we set the $w = 0 . 5$ by default to make a good balance between the quality and fidelity of outputs. ",
667
+ "bbox": [
668
+ 173,
669
+ 320,
670
+ 826,
671
+ 419
672
+ ],
673
+ "page_idx": 5
674
+ },
675
+ {
676
+ "type": "text",
677
+ "text": "4 Experiments ",
678
+ "text_level": 1,
679
+ "bbox": [
680
+ 174,
681
+ 438,
682
+ 312,
683
+ 454
684
+ ],
685
+ "page_idx": 5
686
+ },
687
+ {
688
+ "type": "text",
689
+ "text": "4.1 Datasets ",
690
+ "text_level": 1,
691
+ "bbox": [
692
+ 174,
693
+ 468,
694
+ 272,
695
+ 483
696
+ ],
697
+ "page_idx": 5
698
+ },
699
+ {
700
+ "type": "text",
701
+ "text": "Training Dataset. We train our models on the FFHQ dataset [21], which contains 70,000 high-quality (HQ) images, and all images are resized to $5 1 2 \\times 5 1 2$ for training. To form training pairs, we synthesize LQ images $I _ { l }$ from the HQ counterparts $I _ { h }$ with the following degradation model [24, 37, 43]: ",
702
+ "bbox": [
703
+ 174,
704
+ 493,
705
+ 823,
706
+ 536
707
+ ],
708
+ "page_idx": 5
709
+ },
710
+ {
711
+ "type": "equation",
712
+ "img_path": "images/2fe34ef842bce17d96c2cd0fd20fabd133e50a713e6c91a90fa3a024aba724cb.jpg",
713
+ "text": "$$\nI _ { l } = \\{ [ ( I _ { h } \\otimes k _ { \\sigma } ) _ { \\downarrow r } + n _ { \\delta } ] _ { \\mathrm { J P E G } _ { q } } \\} _ { \\uparrow r } ,\n$$",
714
+ "text_format": "latex",
715
+ "bbox": [
716
+ 382,
717
+ 541,
718
+ 612,
719
+ 560
720
+ ],
721
+ "page_idx": 5
722
+ },
723
+ {
724
+ "type": "text",
725
+ "text": "where the HQ image $I _ { h }$ is first convolved with a Gaussian kernel $k _ { \\sigma }$ , followed by a downsampling of scale $r$ . After that, additive Gaussian noise $n _ { \\delta }$ is added to the images, and then JPEG compression with quality factor $q$ is applied. Finally, the LQ image is resized back to $5 1 2 \\times 5 1 2$ . We randomly sample $\\sigma , r , \\delta$ , and $q$ from [1, 15], [1, 30], [0, 20], and [30, 90], respectively. ",
726
+ "bbox": [
727
+ 174,
728
+ 565,
729
+ 825,
730
+ 622
731
+ ],
732
+ "page_idx": 5
733
+ },
734
+ {
735
+ "type": "text",
736
+ "text": "Testing Datasets. We evaluate our method on a synthetic dataset CelebA-Test and three real-world datasets: LFW-Test, WebPhoto-Test, and our proposed WIDER-Test. CelebA-Test contains 3,000 images selected from the CelebA-HQ dataset [20], where LQ images are synthesized under the same degradation range as our training settings. The three real-world datasets respectively contain three different degrees of degradation, i.e., mild (LFW-Test), medium (WebPhoto-Test), and heavy (WIDER-Test). LFW-Test consists of the first image of each person in LFW dataset [17], containing 1,711 images. WebPhoto-Test [37] consists of 407 low-quality faces collected from the Internet. Our WIDER-Test comprises 970 severely degraded face images from the WIDER Face dataset [42], providing a more challenging dataset to evaluate the generalizability and robustness of blind face restoration methods. ",
737
+ "bbox": [
738
+ 173,
739
+ 627,
740
+ 826,
741
+ 766
742
+ ],
743
+ "page_idx": 5
744
+ },
745
+ {
746
+ "type": "text",
747
+ "text": "4.2 Experimental Settings and Metrics ",
748
+ "text_level": 1,
749
+ "bbox": [
750
+ 176,
751
+ 781,
752
+ 455,
753
+ 796
754
+ ],
755
+ "page_idx": 5
756
+ },
757
+ {
758
+ "type": "text",
759
+ "text": "Settings. We represent a face image of $5 1 2 \\times 5 1 2 \\times 3$ as a $1 6 \\times 1 6$ code sequence. For all stages of training, we use the Adam [23] optimizer with a batch size of 16. We set the learning rate to $\\mathrm { 8 } \\mathrm { \\times } \\mathrm { 1 0 ^ { - 5 } }$ for stages I and II, and adopt a smaller learning rate of $2 \\times 1 0 ^ { - 5 }$ for stage III. The three stages are trained with 1.5M, 200K, and 20K iterations, respectively. Our method is implemented with the PyTorch framework and trained using four NVIDIA Tesla V100 GPUs. ",
760
+ "bbox": [
761
+ 174,
762
+ 806,
763
+ 825,
764
+ 877
765
+ ],
766
+ "page_idx": 5
767
+ },
768
+ {
769
+ "type": "text",
770
+ "text": "Metrics. For the evaluation on CelebA-Test with ground truth, we adopt PSNR, SSIM, and LPIPS [45] as metrics. We also evaluate the identity preservation using the cosine similarity of features from ",
771
+ "bbox": [
772
+ 173,
773
+ 882,
774
+ 823,
775
+ 911
776
+ ],
777
+ "page_idx": 5
778
+ },
779
+ {
780
+ "type": "image",
781
+ "img_path": "images/7264dc8541b301c16c44949d364b383e15a5b278466f7677b3765b3045c564f0.jpg",
782
+ "image_caption": [
783
+ "Figure 3: Qualitative comparison on the CelebA-Test. Even though input faces are severely degraded, our CodeFormer produces high-quality faces with faithful details. (Zoom in for details) "
784
+ ],
785
+ "image_footnote": [],
786
+ "bbox": [
787
+ 176,
788
+ 85,
789
+ 823,
790
+ 223
791
+ ],
792
+ "page_idx": 6
793
+ },
794
+ {
795
+ "type": "image",
796
+ "img_path": "images/0281a1cf817113ca48d655185c25002b625e40f3697324d4556fea773bb22ab4.jpg",
797
+ "image_caption": [
798
+ "Figure 4: Qualitative comparison on real-world faces. Our CodeFormer is able to restore high-quality faces, showing robustness to the heavy degradation. (Zoom in for details) "
799
+ ],
800
+ "image_footnote": [],
801
+ "bbox": [
802
+ 176,
803
+ 261,
804
+ 823,
805
+ 460
806
+ ],
807
+ "page_idx": 6
808
+ },
809
+ {
810
+ "type": "text",
811
+ "text": "ArcFace network [8], denoted as IDS. For the evaluation on real-world datasets without ground truth, we employ the widely-used non-reference perceptual metrics: FID [15] and MUSIQ (KonIQ) [22]. ",
812
+ "bbox": [
813
+ 176,
814
+ 507,
815
+ 823,
816
+ 536
817
+ ],
818
+ "page_idx": 6
819
+ },
820
+ {
821
+ "type": "text",
822
+ "text": "4.3 Comparisons with State-of-the-Art Methods ",
823
+ "text_level": 1,
824
+ "bbox": [
825
+ 174,
826
+ 551,
827
+ 521,
828
+ 568
829
+ ],
830
+ "page_idx": 6
831
+ },
832
+ {
833
+ "type": "text",
834
+ "text": "We compare the proposed CodeFormer with state-of-the-art methods, including PULSE [27], DFDNet [24], PSFRGAN [5], GLEAN [3], GFP-GAN [37], and GPEN [43]. We conduct extensive comparisons on both synthetic and real-world datasets. ",
835
+ "bbox": [
836
+ 176,
837
+ 578,
838
+ 823,
839
+ 621
840
+ ],
841
+ "page_idx": 6
842
+ },
843
+ {
844
+ "type": "text",
845
+ "text": "Evaluation on Synthetic Dataset. We first show the quantitative comparison on the CelebA-Test in Table 1. In terms of the image quality metrics LPIPS, FID, and MUSIQ, our CodeFormer achieves the best scores than existing methods. Besides, it also faithfully preserves the identity, reflected by the highest IDS score and PSNR. Additionally, we present the qualitative comparison in Fig. 3. The compared methods fail to produce pleasant restoration results, e.g., DFDNet [24], PSFRGAN [5], GFP-GAN [37], and GPEN [43] introduce obvious artifacts and GLEAN [3] produces over-smoothed results that lack facial details. Moreover, all compared methods are unable to preserve the identity. Thanks to the expressive codebook prior and global modeling, CodeFormer not only produces high-quality faces but also preserves the identity well, even when inputs are highly degraded. ",
846
+ "bbox": [
847
+ 174,
848
+ 627,
849
+ 825,
850
+ 710
851
+ ],
852
+ "page_idx": 6
853
+ },
854
+ {
855
+ "type": "table",
856
+ "img_path": "images/138db364d7e305aa0edaf0be2210c341bc939652916ce8852ba5be33c8907286.jpg",
857
+ "table_caption": [
858
+ "Table 1: Quantitative comparison on the CelebATest. Red and blue indicate the best and the second best performance, respectively. The result of Code GT is the upper bound of CodeFormer. "
859
+ ],
860
+ "table_footnote": [],
861
+ "table_body": "<table><tr><td>Methods</td><td>LPIPS↓</td><td>FID↓</td><td>MUSIQ↑</td><td>IDS↑</td><td></td><td>PSNR↑ SSIM↑</td></tr><tr><td>Input</td><td>0.712</td><td>295.73</td><td>15.16</td><td>0.32</td><td>21.53</td><td>0.623</td></tr><tr><td>PULSE [27]</td><td>0.406</td><td>72.94</td><td>67.39</td><td>0.30</td><td>21.38</td><td>0.571</td></tr><tr><td>DFDNet [24]</td><td>0.466</td><td>85.15</td><td>57.00</td><td>0.42</td><td>21.24</td><td>0.562</td></tr><tr><td>PSFRGAN [5]</td><td>0.395</td><td>62.05</td><td>65.93</td><td>0.43</td><td>20.91</td><td>0.549</td></tr><tr><td>GLEAN [3]</td><td>0.371</td><td>59.87</td><td>61.59</td><td>0.51</td><td>21.59</td><td>0.598</td></tr><tr><td>GFP-GAN [37]</td><td>0.391</td><td>58.36</td><td>67.84</td><td>0.42</td><td>20.37</td><td>0.545</td></tr><tr><td>GPEN [43]</td><td>0.349</td><td>59.70</td><td>71.53</td><td>0.54</td><td>21.26</td><td>0.565</td></tr><tr><td>CodeFormer (ours)</td><td>0.299</td><td>60.62</td><td>73.79</td><td>0.60</td><td>22.18</td><td>0.610</td></tr><tr><td>Code GT</td><td>0.124</td><td>54.31</td><td>71.94*</td><td>0.89</td><td>25.43</td><td>0.749</td></tr><tr><td>GT</td><td>0</td><td>51.40</td><td>72.02*</td><td>1</td><td>8</td><td>1</td></tr></table>",
862
+ "bbox": [
863
+ 178,
864
+ 782,
865
+ 477,
866
+ 909
867
+ ],
868
+ "page_idx": 6
869
+ },
870
+ {
871
+ "type": "table",
872
+ "img_path": "images/c35c6ec719ebc603ffa7c68e8546ac16b43d5435d11fe57ced17de33df935f4d.jpg",
873
+ "table_caption": [
874
+ "Table 2: Quantitative comparison on the real-world LFW-Test, WebPhoto-Test, and WIDER-Test. Red and blue indicate the best and the second best performance, respectively. "
875
+ ],
876
+ "table_footnote": [],
877
+ "table_body": "<table><tr><td>Dataset Degradation Methods</td><td colspan=\"2\">LFW-Test mild FID↓ MUSIQ↑</td><td colspan=\"2\">WebPhoto-Test medium FID↓ MUSIQ↑</td><td colspan=\"2\">WIDER-Test heavy FID↓ MUSIQ↑</td></tr><tr><td>Input</td><td>137.56</td><td>25.05</td><td>170.11</td><td>19.24</td><td>202.06</td><td>15.57</td></tr><tr><td>PULSE [27]</td><td>64.86</td><td>66.98</td><td>86.45</td><td>66.57</td><td>73.59</td><td>65.36</td></tr><tr><td>DFDNet [24]</td><td>62.57</td><td>67.95</td><td>100.68</td><td>63.81</td><td>57.84</td><td>59.34</td></tr><tr><td>PSFRGAN [5]</td><td>51.89</td><td>69.21</td><td>88.45</td><td>67.09</td><td>51.16</td><td>67.27</td></tr><tr><td>GLEAN [3]</td><td>53.49</td><td>66.48</td><td>105.63</td><td>61.30</td><td>47.11</td><td>60.68</td></tr><tr><td>GFP-GAN [37]</td><td>49.96</td><td>68.95</td><td>87.35</td><td>68.04</td><td>40.59</td><td>68.26</td></tr><tr><td>GPEN [43]</td><td>57.58</td><td>73.59</td><td>81.77</td><td>73.41</td><td>46.99</td><td>72.36</td></tr><tr><td>CodeFormer (ours)</td><td>52.02</td><td>71.43</td><td>78.87</td><td>70.51</td><td>39.06</td><td>69.31</td></tr></table>",
878
+ "bbox": [
879
+ 495,
880
+ 782,
881
+ 825,
882
+ 909
883
+ ],
884
+ "page_idx": 6
885
+ },
886
+ {
887
+ "type": "table",
888
+ "img_path": "images/eeadcd9f0e29e5f6189d6f9900568a610859bbb2748da9bea3d89396af714c86.jpg",
889
+ "table_caption": [
890
+ "Table 3: Ablation studies of variant networks and code lookup methods on the CelebA-Test. Removing ‘Codebook’ means the network is a general encoder-decoder structure. $\\cdot _ { w } ,$ is an adjustable coefficient of CFT modules that controls the information flow from encoder. "
891
+ ],
892
+ "table_footnote": [],
893
+ "table_body": "<table><tr><td>Exp.</td><td colspan=\"3\">Networks Codebook Transformer Fix Decoder</td><td colspan=\"2\">Code Lookup NN Code Pred.</td><td colspan=\"2\">Metrics LPIPS↓ IDS↑</td></tr><tr><td>(a)</td><td></td><td></td><td>√</td><td></td><td></td><td>0.420</td><td>0.47</td></tr><tr><td>(b)</td><td>广</td><td></td><td>√</td><td></td><td></td><td>0.397</td><td>0.51</td></tr><tr><td>(c)</td><td></td><td></td><td></td><td>√</td><td>√</td><td>0.351</td><td>0.55</td></tr><tr><td>(e)</td><td>√</td><td>√</td><td></td><td></td><td>√</td><td>0.379</td><td>0.52</td></tr><tr><td>(f) (ours, w=1)</td><td>√</td><td>√</td><td></td><td></td><td>√</td><td>0.297</td><td>0.60</td></tr><tr><td>(g) (ours,w=0)</td><td>√</td><td></td><td></td><td>√</td><td>√</td><td>0.307</td><td>0.58</td></tr></table>",
894
+ "bbox": [
895
+ 176,
896
+ 89,
897
+ 578,
898
+ 181
899
+ ],
900
+ "page_idx": 7
901
+ },
902
+ {
903
+ "type": "image",
904
+ "img_path": "images/12ad6d83d3126058496c7e558248c344d7a1a2a9dadb32f684900ec3ce39ccf6.jpg",
905
+ "image_caption": [
906
+ "Figure 6: Curve comparison on code sequence prediction accuracy. "
907
+ ],
908
+ "image_footnote": [],
909
+ "bbox": [
910
+ 594,
911
+ 87,
912
+ 821,
913
+ 207
914
+ ],
915
+ "page_idx": 7
916
+ },
917
+ {
918
+ "type": "text",
919
+ "text": "",
920
+ "bbox": [
921
+ 174,
922
+ 263,
923
+ 825,
924
+ 305
925
+ ],
926
+ "page_idx": 7
927
+ },
928
+ {
929
+ "type": "text",
930
+ "text": "Evaluation on Real-world Datasets. As presented in Table 2, our CodeFormer achieves comparable perceptual quality of FID score with the compared methods on the real-world testing datasets with mild and medium degradation, and the best score on the testing dataset with heavy degradation. Although PULSE [27] also obtains good perceptual MUSIQ score, it cannot preserve the identity of input images, as the identity score of IDS and visual results respectively suggested in Table 1 and Fig. 4. From the visual comparisons in Fig. 4, it is observed that our method shows exceptional robustness to the real heavy degradation and produces most visually pleasing results. Notably, CodeFormer successfully preserves the identity and produces natural results with rich details. ",
931
+ "bbox": [
932
+ 173,
933
+ 310,
934
+ 825,
935
+ 422
936
+ ],
937
+ "page_idx": 7
938
+ },
939
+ {
940
+ "type": "text",
941
+ "text": "4.4 Ablation Studies ",
942
+ "text_level": 1,
943
+ "bbox": [
944
+ 176,
945
+ 452,
946
+ 328,
947
+ 467
948
+ ],
949
+ "page_idx": 7
950
+ },
951
+ {
952
+ "type": "text",
953
+ "text": "Effectiveness of Codebook Space. We first investigate the effectiveness of the codebook space. As shown in Exp. (a) of Table 3, removing the codebook (i.e., directly feeding the encoder features $Z _ { l }$ to the decoder) results in worse LPIPS and IDS scores. The results suggest that the discrete space of codebook is the key to ensure the robustness and effectiveness of our model. ",
954
+ "bbox": [
955
+ 174,
956
+ 483,
957
+ 825,
958
+ 539
959
+ ],
960
+ "page_idx": 7
961
+ },
962
+ {
963
+ "type": "text",
964
+ "text": "Superiority of Transformer-based Code Prediction. To verify the superiority of our Transformerbased code prediction for codebook lookup, we compare it with two different solutions, i.e., nearestneighbour (NN) matching, i.e., Exp. (b), and a CNN-based code prediction module, i.e., Exp. (c), that adopts a Linear layer for prediction following encoder $E _ { L }$ . As shown in Table 3, the comparison of Exps. (b) and (c) indicates that adopting code prediction for codebook lookup is more effective than NN feature matching. However, the local nature of convolution operation of CNNs restricts its modeling capability for long code sequence prediction. In comparison to the pure CNN-based method, i.e., Exp. (c), our Transformer-based solution produces better-fidelity results in terms of LPIPS and IDS scores, as well as higher accuracy of code prediction under all degradation degrees, as shown in Fig. 6. Besides, the superiority of CodeFormer is also demonstrated in visual comparisons shown in Fig. 5 and Fig. 9. ",
965
+ "bbox": [
966
+ 174,
967
+ 545,
968
+ 826,
969
+ 588
970
+ ],
971
+ "page_idx": 7
972
+ },
973
+ {
974
+ "type": "text",
975
+ "text": "",
976
+ "bbox": [
977
+ 174,
978
+ 588,
979
+ 517,
980
+ 780
981
+ ],
982
+ "page_idx": 7
983
+ },
984
+ {
985
+ "type": "image",
986
+ "img_path": "images/239939d5f94ca03d5d3be70744eabf3047d84bb6d01be732be68128fe2babba2.jpg",
987
+ "image_caption": [
988
+ "Figure 5: Qualitative comparisons of different codebook lookup methods. "
989
+ ],
990
+ "image_footnote": [],
991
+ "bbox": [
992
+ 534,
993
+ 594,
994
+ 820,
995
+ 752
996
+ ],
997
+ "page_idx": 7
998
+ },
999
+ {
1000
+ "type": "text",
1001
+ "text": "Importance of Fixed Decoder. Unlike the large dictionary $( \\sim 3 . 2 \\mathrm { G } )$ in DFDNet [24], which aims to store a massive quantity of facial details, we deliberately adopt a compact codebook $\\mathcal { C } \\in \\mathbb { R } ^ { N \\times d }$ with $N { = } 1 0 2 4$ and $d { = } 2 5 6$ that only keeps the essential codes for face restoration, which then activate the detailed cues stored in the pre-trained decoder. Thus, the codebook must be used alongside the decoder to fully unleash its potential. To vindicate our design, we conduct two studies: 1) fixing both codebook and decoder, i.e., Exp. (g), and 2) fixing codebook but fine-tuning decoder, i.e., Exp. (e). Table 3 shows fine-tuning decoder deteriorates the performance, validating our statement. This is because fine-tuning the decoder destroys the learned prior that is held by the pre-trained codebook and decoder, resulting in suboptimal performance. Therefore, we keep the decoder fixed in our method. ",
1002
+ "bbox": [
1003
+ 174,
1004
+ 786,
1005
+ 825,
1006
+ 911
1007
+ ],
1008
+ "page_idx": 7
1009
+ },
1010
+ {
1011
+ "type": "image",
1012
+ "img_path": "images/602139085815abb09b2367900deeab6eae7660199dba2c2802d27b8150e21942.jpg",
1013
+ "image_caption": [
1014
+ "Figure 7: CFT module is capable to generate continuous transitions between image quality and fidelity. "
1015
+ ],
1016
+ "image_footnote": [],
1017
+ "bbox": [
1018
+ 176,
1019
+ 88,
1020
+ 821,
1021
+ 181
1022
+ ],
1023
+ "page_idx": 8
1024
+ },
1025
+ {
1026
+ "type": "text",
1027
+ "text": "Flexibility of Controllable Feature Transformation Module. Considering the diverse degradation in real-world LQ face images, we provide a controllable feature transformation module (CFT) to allow a flexible trade-off between quality and fidelity. As shown in Fig. 7, a smaller $w$ tends to produce a high-quality result while a larger $w$ improves the fidelity. While such a flexibility is rarely explored in previous work, here we show that it is an appealing strategy to improves the adaptiveness of our method for different scenarios. As shown in Table 3, Exp. (f), i.e., setting the coefficient $w$ to 1 increases the reconstruction and identity scores but decreases the visual quality. In this work, we trade between the quality and fidelity, and set the coefficient $w$ to 0.5 by default. ",
1028
+ "bbox": [
1029
+ 173,
1030
+ 214,
1031
+ 825,
1032
+ 327
1033
+ ],
1034
+ "page_idx": 8
1035
+ },
1036
+ {
1037
+ "type": "text",
1038
+ "text": "4.5 Running time ",
1039
+ "text_level": 1,
1040
+ "bbox": [
1041
+ 174,
1042
+ 342,
1043
+ 308,
1044
+ 357
1045
+ ],
1046
+ "page_idx": 8
1047
+ },
1048
+ {
1049
+ "type": "text",
1050
+ "text": "We compare the running time of state-of-the-art methods [27, 24, 5, 2, 37, 43] and the proposed CodeFormer. All existing methods are evaluated on $5 1 2 ^ { 2 }$ face images using their publicly available code. As shown in Table 5, the proposed CodeFormer has a similar running time as PSFRGAN [5] and GPEN [43] that can infer one image within 0.1s. Meanwhile, our method achieves the best performance in terms of LPIPS on the Celeb-Test dataset. ",
1051
+ "bbox": [
1052
+ 174,
1053
+ 367,
1054
+ 825,
1055
+ 436
1056
+ ],
1057
+ "page_idx": 8
1058
+ },
1059
+ {
1060
+ "type": "table",
1061
+ "img_path": "images/cb29670ed01bf09ed31a12ca6ad039bcf4bf7e14779e82674209d803f233b928.jpg",
1062
+ "table_caption": [
1063
+ "Table 5: Running time of different networks. All methods are evaluated on $5 1 2 ^ { 2 }$ input images using an NVIDIA Tesla V100 GPU. ‘ ’ indicates the running time is less than 0.1s per test image. "
1064
+ ],
1065
+ "table_footnote": [],
1066
+ "table_body": "<table><tr><td></td><td>PULSE [27]</td><td>DFDNet [24]</td><td>PSFRGAN[5]</td><td>GLEAN [2]</td><td>GFP-GAN [37]</td><td>GPEN [43]</td><td>CodeFormer (Ours)</td></tr><tr><td>Time (sec)</td><td>48.955</td><td>0.179</td><td>0.065</td><td>0.132</td><td>0.126</td><td>0.055</td><td>0.070</td></tr><tr><td>LPIPS↓</td><td>0.406</td><td>0.466</td><td>0.395</td><td>0.371</td><td>0.391</td><td>0.349</td><td>0.299</td></tr></table>",
1067
+ "bbox": [
1068
+ 176,
1069
+ 488,
1070
+ 821,
1071
+ 532
1072
+ ],
1073
+ "page_idx": 8
1074
+ },
1075
+ {
1076
+ "type": "text",
1077
+ "text": "4.6 Extensions ",
1078
+ "text_level": 1,
1079
+ "bbox": [
1080
+ 174,
1081
+ 560,
1082
+ 289,
1083
+ 575
1084
+ ],
1085
+ "page_idx": 8
1086
+ },
1087
+ {
1088
+ "type": "text",
1089
+ "text": "Face Color Enhancement. We finetune our model on face color enhancement using the same color augmentations (random color jitter and grayscale conversion) as GFP-GAN (v1) [37]. We compare our method with GFP-GAN (v1) [37] on the real-world old photos (from CelebChild-Test dataset [37]) with color loss. The proposed CodeFormer generates high-quality face images with more natural color and faithful details. ",
1090
+ "bbox": [
1091
+ 173,
1092
+ 587,
1093
+ 825,
1094
+ 656
1095
+ ],
1096
+ "page_idx": 8
1097
+ },
1098
+ {
1099
+ "type": "image",
1100
+ "img_path": "images/8e1019f59cb5b029366f73982da328e7ef7b923f2585cfbf59a3e172bf836e35.jpg",
1101
+ "image_caption": [
1102
+ "Figure 8: Visual comparison of face color enhancement on the real-world old face photos. "
1103
+ ],
1104
+ "image_footnote": [],
1105
+ "bbox": [
1106
+ 174,
1107
+ 667,
1108
+ 821,
1109
+ 763
1110
+ ],
1111
+ "page_idx": 8
1112
+ },
1113
+ {
1114
+ "type": "text",
1115
+ "text": "Face Inpainting. The proposed Codeformer can be easily extended to face inpainting, and it shows great performance even in large mask ratios. To build training pairs, we use a publicly available script [43] to randomly draw irregular polyline masks for generating masked faces. We compare our method with two state-of-the-art face inpainting methods CTSDG [14] and GPEN [43], as well as Nearest-Neighbor matching for codebook lookup. As shown in Fig. 9, CTSDG and GPEN struggle in cases with large masks. Using Nearest-Neighbor matching within our framework roughly reconstructs the face structures, but it also fails in restoring complete visual parts such as the glasses and the eyes. In contrast, our CodeFormer generates high-quality natural faces without strokes and artifacts. ",
1116
+ "bbox": [
1117
+ 173,
1118
+ 800,
1119
+ 826,
1120
+ 911
1121
+ ],
1122
+ "page_idx": 8
1123
+ },
1124
+ {
1125
+ "type": "image",
1126
+ "img_path": "images/1bf345d14be320cad6e490700e84655b7289418c6560e9210cc87df2be0ce519.jpg",
1127
+ "image_caption": [
1128
+ "Figure 9: Visual comparison with state-of-the-art face inpainting methods on the challenging cases. "
1129
+ ],
1130
+ "image_footnote": [],
1131
+ "bbox": [
1132
+ 176,
1133
+ 88,
1134
+ 823,
1135
+ 267
1136
+ ],
1137
+ "page_idx": 9
1138
+ },
1139
+ {
1140
+ "type": "text",
1141
+ "text": "4.7 Limitation ",
1142
+ "text_level": 1,
1143
+ "bbox": [
1144
+ 174,
1145
+ 306,
1146
+ 287,
1147
+ 321
1148
+ ],
1149
+ "page_idx": 9
1150
+ },
1151
+ {
1152
+ "type": "text",
1153
+ "text": "Our method is built on a pre-trained autoencoder with a codebook. Thus, the capability and expressiveness of the autoencoder could affect the performance of our method. 1) Though the identity inconsistency issue is significantly relieved by the Transformer’s global modeling, inconsistency still exists in some rare visual parts such as accessories, where the current codebook space cannot seamlessly represent the image space. Using multiple scales in the codebook space to explore more fine-grained visual quantization may be a solution. 2) Although CodeFormer exhibits great robustness in most cases, when it comes to side faces, CodeFormer offers limited superiority to other methods and also cannot produce good results, as failure cases shown in Fig. 10. This is expected because there are only few side faces in the FFHQ training dataset, thus, the codebook is unable to learn sufficient codes for this case, leading to less effectiveness in both reconstruction and restoration. ",
1154
+ "bbox": [
1155
+ 173,
1156
+ 333,
1157
+ 825,
1158
+ 472
1159
+ ],
1160
+ "page_idx": 9
1161
+ },
1162
+ {
1163
+ "type": "image",
1164
+ "img_path": "images/c4cb9b43c69543ac02dcd3f008770131a727810a36ed2ca639a19802a7330ca6.jpg",
1165
+ "image_caption": [
1166
+ "Figure 10: Failure cases tend to occur on side faces, which could be caused by the limited number of side face images in the training dataset of FFHQ. "
1167
+ ],
1168
+ "image_footnote": [],
1169
+ "bbox": [
1170
+ 176,
1171
+ 486,
1172
+ 823,
1173
+ 582
1174
+ ],
1175
+ "page_idx": 9
1176
+ },
1177
+ {
1178
+ "type": "text",
1179
+ "text": "5 Conclusion ",
1180
+ "text_level": 1,
1181
+ "bbox": [
1182
+ 174,
1183
+ 635,
1184
+ 299,
1185
+ 651
1186
+ ],
1187
+ "page_idx": 9
1188
+ },
1189
+ {
1190
+ "type": "text",
1191
+ "text": "This paper aims to address the fundamental challenges in blind face restoration. With a learned small discrete but expressive codebook space, we turn face restoration to code token prediction, significantly reducing the uncertainty of restoration mapping and easing the learning of restoration network. To remedy the local loss, we explore global composition and dependency from degraded faces via an expressive Transformer module for better code prediction. Benefiting from these designs, our method shows great expressiveness and strong robustness against heavy degradation. To enhance the adaptiveness of our method for different degradation, we also propose a controllable feature transformation module that allows a flexible trade-off between fidelity and quality. Experimental results suggest the superiority and effectiveness of our method. ",
1192
+ "bbox": [
1193
+ 173,
1194
+ 665,
1195
+ 826,
1196
+ 791
1197
+ ],
1198
+ "page_idx": 9
1199
+ },
1200
+ {
1201
+ "type": "text",
1202
+ "text": "Acknowledgement ",
1203
+ "text_level": 1,
1204
+ "bbox": [
1205
+ 176,
1206
+ 809,
1207
+ 330,
1208
+ 827
1209
+ ],
1210
+ "page_idx": 9
1211
+ },
1212
+ {
1213
+ "type": "text",
1214
+ "text": "This study is supported under the RIE2020 Industry Alignment Fund – Industry Collaboration Projects (IAF-ICP) Funding Initiative, as well as cash and in-kind contribution from the industry partner(s). It is also partially supported by the NTU NAP grant. ",
1215
+ "bbox": [
1216
+ 173,
1217
+ 842,
1218
+ 825,
1219
+ 883
1220
+ ],
1221
+ "page_idx": 9
1222
+ },
1223
+ {
1224
+ "type": "text",
1225
+ "text": "References ",
1226
+ "text_level": 1,
1227
+ "bbox": [
1228
+ 174,
1229
+ 90,
1230
+ 267,
1231
+ 106
1232
+ ],
1233
+ "page_idx": 10
1234
+ },
1235
+ {
1236
+ "type": "text",
1237
+ "text": "Gabriel Synnaeve Zagoruyko. End-to-end object detection with transformers. In ECCV, 2020. [2] Kelvin CK Chan, Xintao Wang, Xiangyu Xu, Jinwei Gu, and Chen Change Loy. GLEAN: Generative latent bank for large-factor image super-resolution. In CVPR, 2021. [3] Kelvin CK Chan, Xiangyu Xu, Xintao Wang, Jinwei Gu, and Chen Change Loy. GLEAN: Generative latent bank for image super-resolution and beyond. IEEE Transactions on Pattern Analysis and Machine Intelligence, 2022. [4] Huiwen Chang, Han Zhang, Lu Jiang, Ce Liu, and William T Freeman. MaskGIT: Masked generative image transformer. In CVPR, 2022. [5] Chaofeng Chen, Xiaoming Li, Lingbo Yang, Xianhui Lin, Lei Zhang, and Kwan-Yee K Wong. Progressive semantic-aware style transformation for blind face restoration. In CVPR, 2021. [6] Yu Chen, Ying Tai, Xiaoming Liu, Chunhua Shen, and Jian Yang. FSRNet: End-to-end learning face super-resolution with facial priors. In CVPR, 2018. [7] Bowen Cheng, Ishan Misra, Alexander G. Schwing, Alexander Kirillov, and Rohit Girdhar. Maskedattention mask transformer for universal image segmentation. In CVPR, 2022. [8] Jiankang Deng, Jia Guo, Niannan Xue, and Stefanos Zafeiriou. ArcFace: Additive angular margin loss for deep face recognition. In CVPR, 2019. [9] Berk Dogan, Shuhang Gu, and Radu Timofte. Exemplar guided face image super-resolution without facial landmarks. In CVPRW, 2019. \n[10] Michael Elad and Michal Aharon. Image denoising via learned dictionaries and sparse representation. In CVPR, 2006. \n[11] Patrick Esser, Robin Rombach, and Bjorn Ommer. Taming transformers for high-resolution image synthesis. In CVPR, 2021. \n[12] Jinjin Gu, Yujun Shen, and Bolei Zhou. Image processing using multi-code gan prior. In CVPR, 2020. \n[13] Shuhang Gu, Wangmeng Zuo, Qi Xie, Deyu Meng, Xiangchu Feng, and Lei Zhang. Convolutional sparse coding for image super-resolution. In ICCV, 2015. \n[14] Xiefan Guo, Hongyu Yang, and Di Huang. Image inpainting via conditional texture and structure dual generation. In ICCV, 2021. \n[15] Martin Heusel, Hubert Ramsauer, Thomas Unterthiner, Bernhard Nessler, and Sepp Hochreiter. Gans trained by a two time-scale update rule converge to a local nash equilibrium. In NeurIPS, 2017. \n[16] Xiaobin Hu, Wenqi Ren, John LaMaster, Xiaochun Cao, Xiaoming Li, Zechao Li, Bjoern Menze, and Wei Liu. Face super-resolution guided by 3d facial priors. In ECCV, 2020. \n[17] Gary B Huang, Marwan Mattar, Tamara Berg, and Eric Learned-Miller. Labeled faces in the wild: A database forstudying face recognition in unconstrained environments. In Workshop on faces in’RealLife’Images: detection, alignment, and recognition, 2008. \n[18] Younghyun Jo and Seon Joo Kim. Practical single-image super-resolution using look-up table. In CVPR, 2021. \n[19] Justin Johnson, Alexandre Alahi, and Li Fei-Fei. Perceptual losses for real-time style transfer and super-resolution. In ECCV, 2016. \n[20] Tero Karras, Timo Aila, Samuli Laine, and Jaakko Lehtinen. Progressive growing of gans for improved quality, stability, and variation. In ICLR, 2018. \n[21] Tero Karras, Samuli Laine, and Timo Aila. A style-based generator architecture for generative adversarial networks. In CVPR, 2019. \n[22] Junjie Ke, Qifei Wang, Yilin Wang, Peyman Milanfar, and Feng Yang. MUSIQ: Multi-scale image quality transformer. In ICCV, 2021. \n[23] Diederik P Kingma and Jimmy Ba. Adam: A method for stochastic optimization. In ICLR, 2014. \n[24] Xiaoming Li, Chaofeng Chen, Shangchen Zhou, Xianhui Lin, Wangmeng Zuo, and Lei Zhang. Blind face restoration via deep multi-scale component dictionaries. In ECCV, 2020. \n[25] Xiaoming Li, Wenyu Li, Dongwei Ren, Hongzhi Zhang, Meng Wang, and Wangmeng Zuo. Enhanced blind face restoration with multi-exemplar images and adaptive spatial feature fusion. In CVPR, 2020. \n[26] Xiaoming Li, Ming Liu, Yuting Ye, Wangmeng Zuo, Liang Lin, and Ruigang Yang. Learning warped guidance for blind face restoration. In ECCV, 2018. \n[27] Sachit Menon, Alexandru Damian, Shijia Hu, Nikhil Ravi, and Cynthia Rudin. PULSE: Self-supervised photo upsampling via latent space exploration of generative models. In CVPR, 2020. \n[28] Wenqi Ren, Jiaolong Yang, Senyou Deng, David Wipf, Xiaochun Cao, and Xin Tong. Face video deblurring using 3d facial priors. In ICCV, 2019. \n[29] Elad Richardson, Yuval Alaluf, Or Patashnik, Yotam Nitzan, Yaniv Azar, Stav Shapiro, and Daniel Cohen-Or. Encoding in style: a StyleGAN encoder for image-to-image translation. In CVPR, 2021. \n[30] Ziyi Shen, Wei-Sheng Lai, Tingfa Xu, Jan Kautz, and Ming-Hsuan Yang. Deep semantic face deblurring. In CVPR, 2018. \n[31] Karen Simonyan and Andrew Zisserman. Very deep convolutional networks for large-scale image recognition. In ICLR, 2015. \n[32] Radu Timofte, Vincent De Smet, and Luc Van Gool. Anchored neighborhood regression for fast examplebased super-resolution. In ICCV, 2013. \n[33] Radu Timofte, Vincent De Smet, and Luc Van Gool. $\\mathbf { A } +$ : Adjusted anchored neighborhood regression for fast super-resolution. In ACCV, 2014. \n[34] Aaron Van Den Oord, Oriol Vinyals, et al. Neural discrete representation learning. NeurIPS, 2017. \n[35] Laurens Van Der Maaten. Accelerating t-sne using tree-based algorithms. The journal of machine learning research, 15(1):3221–3245, 2014. \n[36] Ashish Vaswani, Noam Shazeer, Niki Parmar, Jakob Uszkoreit, Llion Jones, Aidan N Gomez, Łukasz Kaiser, and Illia Polosukhin. Attention is all you need. In NeurIPS, 2017. \n[37] Xintao Wang, Yu Li, Honglun Zhang, and Ying Shan. Towards real-world blind face restoration with generative facial prior. In CVPR, 2021. \n[38] Xintao Wang, Ke Yu, Chao Dong, and Chen Change Loy. Recovering realistic texture in image superresolution by deep spatial feature transform. In CVPR, 2018. \n[39] Zhouxia Wang, Jiawei Zhang, Runjian Chen, Wenping Wang, and Ping Luo. RestoreFormer: High-quality blind face restoration from undegraded key-value pairs. In CVPR, 2022. \n[40] Jianchao Yang, John Wright, Thomas S Huang, and Yi Ma. Image super-resolution via sparse representation. IEEE transactions on image processing, 19(11):2861–2873, 2010. \n[41] Lingbo Yang, Shanshe Wang, Siwei Ma, Wen Gao, Chang Liu, Pan Wang, and Peiran Ren. HiFaceGAN: Face renovation via collaborative suppression and replenishment. In ACM MM, 2020. \n[42] Shuo Yang, Ping Luo, Chen Change Loy, and Xiaoou Tang. WIDER FACE: A face detection benchmark. In CVPR, 2016. \n[43] Tao Yang, Peiran Ren, Xuansong Xie, and Lei Zhang. GAN prior embedded network for blind face restoration in the wild. In CVPR, 2021. \n[44] Xin Yu, Basura Fernando, Bernard Ghanem, Fatih Porikli, and Richard Hartley. Face super-resolution guided by facial component heatmaps. In ECCV, 2018. \n[45] Richard Zhang, Phillip Isola, Alexei A Efros, Eli Shechtman, and Oliver Wang. The unreasonable effectiveness of deep features as a perceptual metric. In CVPR, 2018. \n[46] Yang Zhao, Yu-Chuan Su, Chun-Te Chu, Yandong Li, Marius Renn, Yukun Zhu, Changyou Chen, and Xuhui Jia. Rethinking deep face restoration. In CVPR, 2022. \n[47] Shangchen Zhou, Jiawei Zhang, Wangmeng Zuo, and Chen Change Loy. Cross-scale internal graph neural network for image super-resolution. In NeurIPS, 2020. \n[48] Feida Zhu, Junwei Zhu, Wenqing Chu, Xinyi Zhang, Xiaozhong Ji, Chengjie Wang, and Ying Tai. Blind face restoration via integrating face shape and generative priors. In CVPR, 2022. ",
1238
+ "bbox": [
1239
+ 171,
1240
+ 141,
1241
+ 828,
1242
+ 915
1243
+ ],
1244
+ "page_idx": 10
1245
+ },
1246
+ {
1247
+ "type": "text",
1248
+ "text": "",
1249
+ "bbox": [
1250
+ 171,
1251
+ 89,
1252
+ 826,
1253
+ 686
1254
+ ],
1255
+ "page_idx": 11
1256
+ },
1257
+ {
1258
+ "type": "text",
1259
+ "text": "Checklist ",
1260
+ "text_level": 1,
1261
+ "bbox": [
1262
+ 174,
1263
+ 89,
1264
+ 254,
1265
+ 106
1266
+ ],
1267
+ "page_idx": 12
1268
+ },
1269
+ {
1270
+ "type": "text",
1271
+ "text": "1. For all authors... ",
1272
+ "bbox": [
1273
+ 214,
1274
+ 116,
1275
+ 339,
1276
+ 131
1277
+ ],
1278
+ "page_idx": 12
1279
+ },
1280
+ {
1281
+ "type": "text",
1282
+ "text": "(a) Do the main claims made in the abstract and introduction accurately reflect the paper’s contributions and scope? [Yes] \n(b) Did you describe the limitations of your work? [Yes] See Sec. 4.7 \n(c) Did you discuss any potential negative societal impacts of your work? [N/A] \n(d) Have you read the ethics review guidelines and ensured that your paper conforms to them? [Yes] ",
1283
+ "bbox": [
1284
+ 238,
1285
+ 135,
1286
+ 825,
1287
+ 227
1288
+ ],
1289
+ "page_idx": 12
1290
+ },
1291
+ {
1292
+ "type": "text",
1293
+ "text": "2. If you are including theoretical results... ",
1294
+ "bbox": [
1295
+ 214,
1296
+ 231,
1297
+ 493,
1298
+ 244
1299
+ ],
1300
+ "page_idx": 12
1301
+ },
1302
+ {
1303
+ "type": "text",
1304
+ "text": "(a) Did you state the full set of assumptions of all theoretical results? [N/A] (b) Did you include complete proofs of all theoretical results? [N/A] ",
1305
+ "bbox": [
1306
+ 238,
1307
+ 248,
1308
+ 738,
1309
+ 280
1310
+ ],
1311
+ "page_idx": 12
1312
+ },
1313
+ {
1314
+ "type": "text",
1315
+ "text": "3. If you ran experiments... ",
1316
+ "bbox": [
1317
+ 212,
1318
+ 285,
1319
+ 393,
1320
+ 299
1321
+ ],
1322
+ "page_idx": 12
1323
+ },
1324
+ {
1325
+ "type": "text",
1326
+ "text": "(a) Did you include the code, data, and instructions needed to reproduce the main experimental results (either in the supplemental material or as a URL)? [Yes] The code is publicly available at: https://github.com/sczhou/CodeFormer. \n(b) Did you specify all the training details (e.g., data splits, hyperparameters, how they were chosen)? [Yes] See Sec. 4.2 \n(c) Did you report error bars (e.g., with respect to the random seed after running experiments multiple times)? [N/A] \n(d) Did you include the total amount of compute and the type of resources used (e.g., type of GPUs, internal cluster, or cloud provider)? [Yes] See Sec. 4.2 ",
1327
+ "bbox": [
1328
+ 238,
1329
+ 303,
1330
+ 825,
1331
+ 435
1332
+ ],
1333
+ "page_idx": 12
1334
+ },
1335
+ {
1336
+ "type": "text",
1337
+ "text": "4. If you are using existing assets (e.g., code, data, models) or curating/releasing new assets... ",
1338
+ "bbox": [
1339
+ 220,
1340
+ 439,
1341
+ 823,
1342
+ 454
1343
+ ],
1344
+ "page_idx": 12
1345
+ },
1346
+ {
1347
+ "type": "text",
1348
+ "text": "(a) If your work uses existing assets, did you cite the creators? [Yes] \n(b) Did you mention the license of the assets? [No] It is publicly available. \n(c) Did you include any new assets either in the supplemental material or as a URL? [Yes] The code and dataset can be found on our project page. \n(d) Did you discuss whether and how consent was obtained from people whose data you’re using/curating? [Yes] \n(e) Did you discuss whether the data you are using/curating contains personally identifiable information or offensive content? [N/A] ",
1349
+ "bbox": [
1350
+ 238,
1351
+ 458,
1352
+ 825,
1353
+ 579
1354
+ ],
1355
+ "page_idx": 12
1356
+ },
1357
+ {
1358
+ "type": "text",
1359
+ "text": "5. If you used crowdsourcing or conducted research with human subjects... ",
1360
+ "bbox": [
1361
+ 214,
1362
+ 583,
1363
+ 705,
1364
+ 598
1365
+ ],
1366
+ "page_idx": 12
1367
+ },
1368
+ {
1369
+ "type": "text",
1370
+ "text": "(a) Did you include the full text of instructions given to participants and screenshots, if applicable? [N/A] \n(b) Did you describe any potential participant risks, with links to Institutional Review Board (IRB) approvals, if applicable? [N/A] \n(c) Did you include the estimated hourly wage paid to participants and the total amount spent on participant compensation? [N/A] ",
1371
+ "bbox": [
1372
+ 238,
1373
+ 602,
1374
+ 825,
1375
+ 691
1376
+ ],
1377
+ "page_idx": 12
1378
+ }
1379
+ ]
parse/dev/XdDl3bFUNn5/XdDl3bFUNn5_model.json ADDED
The diff for this file is too large to render. See raw diff
 
parse/dev/puMfaHb1hY/puMfaHb1hY_content_list.json ADDED
@@ -0,0 +1,2002 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ [
2
+ {
3
+ "type": "text",
4
+ "text": "G-EVAL: NLG Evaluation using GPT-4 with Better Human Alignment ",
5
+ "text_level": 1,
6
+ "bbox": [
7
+ 134,
8
+ 89,
9
+ 867,
10
+ 110
11
+ ],
12
+ "page_idx": 0
13
+ },
14
+ {
15
+ "type": "text",
16
+ "text": "Yang Liu Dan Iter Yichong Xu Shuohang Wang Ruochen Xu Chenguang Zhu ",
17
+ "bbox": [
18
+ 284,
19
+ 130,
20
+ 719,
21
+ 165
22
+ ],
23
+ "page_idx": 0
24
+ },
25
+ {
26
+ "type": "text",
27
+ "text": "Microsoft Azure AI yaliu10@microsoft.com ",
28
+ "bbox": [
29
+ 403,
30
+ 181,
31
+ 600,
32
+ 214
33
+ ],
34
+ "page_idx": 0
35
+ },
36
+ {
37
+ "type": "text",
38
+ "text": "Abstract ",
39
+ "text_level": 1,
40
+ "bbox": [
41
+ 263,
42
+ 252,
43
+ 339,
44
+ 268
45
+ ],
46
+ "page_idx": 0
47
+ },
48
+ {
49
+ "type": "text",
50
+ "text": "The quality of texts generated by natural language generation (NLG) systems is hard to measure automatically. Conventional referencebased metrics, such as BLEU and ROUGE, have been shown to have relatively low correlation with human judgments, especially for tasks that require creativity and diversity. Recent studies suggest using large language models (LLMs) as reference-free metrics for NLG evaluation, which have the benefit of being applicable to new tasks that lack human references. However, these LLM-based evaluators still have lower human correspondence than medium-size neural evaluators. In this work, we present G-EVAL, a framework of using large language models with chain-of-thoughts (CoT) and a form-filling paradigm, to assess the quality of NLG outputs. We experiment with two generation tasks, text summarization and dialogue generation. We show that G-EVAL with GPT-4 as the backbone model achieves a Spearman correlation of 0.514 with human on summarization task, outperforming all previous methods by a large margin. We also propose analysis on the behavior of LLM-based evaluators, and highlight the potential concern of LLM-based evaluators having a bias towards the LLM-generated texts. ",
51
+ "bbox": [
52
+ 146,
53
+ 282,
54
+ 458,
55
+ 678
56
+ ],
57
+ "page_idx": 0
58
+ },
59
+ {
60
+ "type": "text",
61
+ "text": "Moreover, these metrics require associated reference output, which is costly to collect for new tasks. ",
62
+ "bbox": [
63
+ 512,
64
+ 253,
65
+ 884,
66
+ 284
67
+ ],
68
+ "page_idx": 0
69
+ },
70
+ {
71
+ "type": "text",
72
+ "text": "Recent studies propose directly using LLMs as reference-free NLG evaluators (Fu et al., 2023; Wang et al., 2023a). The idea is to use the LLMs to score the candidate output based on its generation probability without any reference target, under the assumption that the LLMs have learned to assign higher probabilities to high-quality and fluent texts. Meanwhile, it is becoming popular to use more powerful LLMs like GPT-4 to evaluate smaller or student models, like in Alpaca (Taori et al., 2023) and Vicuna (Zheng et al., 2023). However, the validity and reliability of using LLMs as NLG evaluators have not been systematically investigated. In addition, meta-evaluations show that these LLMbased evaluators still have lower human correspondence than medium-size neural evaluators (Zhong et al., 2022). Thus, there is a need for a more effective and reliable framework for using LLMs for NLG evaluation. ",
73
+ "bbox": [
74
+ 512,
75
+ 288,
76
+ 882,
77
+ 593
78
+ ],
79
+ "page_idx": 0
80
+ },
81
+ {
82
+ "type": "text",
83
+ "text": "1 Introduction ",
84
+ "text_level": 1,
85
+ "bbox": [
86
+ 117,
87
+ 693,
88
+ 257,
89
+ 708
90
+ ],
91
+ "page_idx": 0
92
+ },
93
+ {
94
+ "type": "text",
95
+ "text": "Evaluating the quality of natural language generation systems is a challenging problem even when large language models can generate high-quality and diverse texts that are often indistinguishable from human-written texts (Ouyang et al., 2022). Traditional automatic metrics, such as BLEU (Papineni et al., 2002), ROUGE (Lin, 2004), and METEOR (Banerjee and Lavie, 2005), are widely used for NLG evaluation, but they have been shown to have relatively low correlation with human judgments, especially for open-ended generation tasks. ",
96
+ "bbox": [
97
+ 117,
98
+ 720,
99
+ 487,
100
+ 895
101
+ ],
102
+ "page_idx": 0
103
+ },
104
+ {
105
+ "type": "text",
106
+ "text": "In this paper, we propose G-EVAL, a framework of using LLMs with chain-of-thoughts (CoT) (Wei et al., 2022) to evaluate the quality of generated texts in a form-filling paradigm. By only feeding the Task Introduction and the Evaluation Criteria as a prompt, we ask LLMs to generate a CoT of detailed Evaluation Steps. Then we use the prompt along with the generated CoT to evaluate the NLG outputs. The evaluator output is formatted as a form. Moreover, the probabilities of the output rating tokens can be used to refine the final metric. We conduct extensive experiments on three meta-evaluation benchmarks of two NLG tasks: text summarization and dialogue generation. The results show that G-EVAL can outperform existing NLG evaluators by a large margin in terms of correlation with human evaluations. Finally, we conduct analysis on the behavior of LLM-based evaluators, and highlight the potential issue of LLM-based evaluator having a bias towards the LLM-generated ",
107
+ "bbox": [
108
+ 512,
109
+ 599,
110
+ 882,
111
+ 919
112
+ ],
113
+ "page_idx": 0
114
+ },
115
+ {
116
+ "type": "text",
117
+ "text": "texts. ",
118
+ "bbox": [
119
+ 117,
120
+ 86,
121
+ 156,
122
+ 98
123
+ ],
124
+ "page_idx": 1
125
+ },
126
+ {
127
+ "type": "text",
128
+ "text": "To summarize, our main contributions and findings in this paper are: ",
129
+ "bbox": [
130
+ 115,
131
+ 102,
132
+ 487,
133
+ 131
134
+ ],
135
+ "page_idx": 1
136
+ },
137
+ {
138
+ "type": "text",
139
+ "text": "1. G-EVAL generally outperforms referencebased and reference-free baseline metrics in terms of correlation with human quality judgments, especially for open-ended and creative NLG tasks, such as dialogue response generation. ",
140
+ "bbox": [
141
+ 131,
142
+ 146,
143
+ 487,
144
+ 241
145
+ ],
146
+ "page_idx": 1
147
+ },
148
+ {
149
+ "type": "text",
150
+ "text": "2. We propose to use automatic chain-of-thought to improve the performance of LLM-based evaluators by providing more context and guidance. ",
151
+ "bbox": [
152
+ 131,
153
+ 254,
154
+ 487,
155
+ 317
156
+ ],
157
+ "page_idx": 1
158
+ },
159
+ {
160
+ "type": "text",
161
+ "text": "3. We propose to re-weight the discrete scores by their respective token probabilities to provide a more fine-grained continuous score for GEVAL. ",
162
+ "bbox": [
163
+ 131,
164
+ 329,
165
+ 487,
166
+ 392
167
+ ],
168
+ "page_idx": 1
169
+ },
170
+ {
171
+ "type": "text",
172
+ "text": "4. We conduct an analysis of the potential issue that LLM-based metrics have a preference of LLM-generated texts over humanwritten texts, which may lead to the selfreinforcement of LLMs if LLM-based metrics are used as the reward signal for improving themselves. ",
173
+ "bbox": [
174
+ 131,
175
+ 405,
176
+ 487,
177
+ 516
178
+ ],
179
+ "page_idx": 1
180
+ },
181
+ {
182
+ "type": "text",
183
+ "text": "2 Method ",
184
+ "text_level": 1,
185
+ "bbox": [
186
+ 117,
187
+ 530,
188
+ 215,
189
+ 545
190
+ ],
191
+ "page_idx": 1
192
+ },
193
+ {
194
+ "type": "text",
195
+ "text": "G-EVAL is a prompt-based evaluator with three main components: 1) a prompt that contains the definition of the evaluation task and the desired evaluation criteria, 2) a chain-of-thoughts (CoT) that is a set of intermediate instructions generated by the LLM describing the detailed evaluation steps, and 3) a scoring function that calls LLM and calculates the score based on the probabilities of the return tokens. ",
196
+ "bbox": [
197
+ 115,
198
+ 556,
199
+ 487,
200
+ 699
201
+ ],
202
+ "page_idx": 1
203
+ },
204
+ {
205
+ "type": "text",
206
+ "text": "Prompt for NLG Evaluation The prompt is a natural language instruction that defines the evaluation task and the desired evaluation criteria. For example, for text summarization, the prompt can be: ",
207
+ "bbox": [
208
+ 115,
209
+ 711,
210
+ 487,
211
+ 788
212
+ ],
213
+ "page_idx": 1
214
+ },
215
+ {
216
+ "type": "text",
217
+ "text": "You will be given one summary written for a news article. Your task is to rate the summary on one metric. ",
218
+ "bbox": [
219
+ 152,
220
+ 802,
221
+ 448,
222
+ 848
223
+ ],
224
+ "page_idx": 1
225
+ },
226
+ {
227
+ "type": "text",
228
+ "text": "Please make sure you read and understand these instructions carefully. Please keep this document open while reviewing, and refer to it as needed. ",
229
+ "bbox": [
230
+ 152,
231
+ 856,
232
+ 450,
233
+ 919
234
+ ],
235
+ "page_idx": 1
236
+ },
237
+ {
238
+ "type": "text",
239
+ "text": "The prompt should also contain customized evaluation criteria for different NLG tasks and, such as coherence, conciseness, or grammar. For example, for evaluating coherence in text summarization, we add the following content to the prompt: ",
240
+ "bbox": [
241
+ 512,
242
+ 85,
243
+ 884,
244
+ 164
245
+ ],
246
+ "page_idx": 1
247
+ },
248
+ {
249
+ "type": "text",
250
+ "text": "Evaluation Criteria: ",
251
+ "text_level": 1,
252
+ "bbox": [
253
+ 549,
254
+ 180,
255
+ 700,
256
+ 195
257
+ ],
258
+ "page_idx": 1
259
+ },
260
+ {
261
+ "type": "text",
262
+ "text": "Coherence (1-5) - the collective quality of all sentences. We align this dimension with the DUC quality question of structure and coherence whereby \"the summary should be well-structured and well-organized. The summary should not just be a heap of related information, but should build from sentence to sentence to a coherent body of information about a topic.\" ",
263
+ "bbox": [
264
+ 547,
265
+ 203,
266
+ 847,
267
+ 363
268
+ ],
269
+ "page_idx": 1
270
+ },
271
+ {
272
+ "type": "text",
273
+ "text": "Auto Chain-of-Thoughts for NLG Evaluation ",
274
+ "text_level": 1,
275
+ "bbox": [
276
+ 514,
277
+ 379,
278
+ 878,
279
+ 393
280
+ ],
281
+ "page_idx": 1
282
+ },
283
+ {
284
+ "type": "text",
285
+ "text": "The chain-of-thoughts (CoT) is a sequence of intermediate representations that are generated by the LLM during the text generation process. For evaluation tasks, some criteria need a more detailed evaluation instruction beyond the simple definition, and it is time-consuming to manually design such evaluation steps for each task. We find that LLM can generate such evaluation steps by itself. The CoT can provide more context and guidance for the LLM to evaluate the generated text, and can also help to explain the evaluation process and results. For example, for evaluating coherence in text summarization, we add a line of “Evaluation Steps:\" to the prompt and let LLM to generate the following CoT automatically: ",
286
+ "bbox": [
287
+ 510,
288
+ 382,
289
+ 882,
290
+ 634
291
+ ],
292
+ "page_idx": 1
293
+ },
294
+ {
295
+ "type": "text",
296
+ "text": "1. Read the news article carefully and identify the main topic and key points. ",
297
+ "bbox": [
298
+ 549,
299
+ 651,
300
+ 847,
301
+ 682
302
+ ],
303
+ "page_idx": 1
304
+ },
305
+ {
306
+ "type": "text",
307
+ "text": "2. Read the summary and compare it to the news article. Check if the summary covers the main topic and key points of the news article, and if it presents them in a clear and logical order. ",
308
+ "bbox": [
309
+ 549,
310
+ 690,
311
+ 847,
312
+ 769
313
+ ],
314
+ "page_idx": 1
315
+ },
316
+ {
317
+ "type": "text",
318
+ "text": "3. Assign a score for coherence on a scale of 1 to 5, where 1 is the lowest and 5 is the highest based on the Evaluation Criteria. ",
319
+ "bbox": [
320
+ 547,
321
+ 777,
322
+ 847,
323
+ 840
324
+ ],
325
+ "page_idx": 1
326
+ },
327
+ {
328
+ "type": "text",
329
+ "text": "Scoring Function The scoring function calls the LLM with the designed prompt, auto CoT, the input context and the target text that needs to be evaluated. Unlike GPTScore (Fu et al., 2023) which uses the conditional probability of generating the target text as an evaluation metric, G-EVAL directly performs the evaluation task with a form-filling paradigm. This provides a more flexible way to evaluate the text as the model can behave directly based on the evaluation criteria and steps. For example, for evaluating coherence in text summarization, we concatenate the prompt, the CoT, the news article, and the summary, and then call the LLM to output a score from 1 to 5 for each evaluation aspect, based on the defined criteria. ",
330
+ "bbox": [
331
+ 510,
332
+ 857,
333
+ 882,
334
+ 919
335
+ ],
336
+ "page_idx": 1
337
+ },
338
+ {
339
+ "type": "image",
340
+ "img_path": "images/1f5c6f4472af2ebba638b602393c7f721b474eedddf16198e530d0830bdc7a61.jpg",
341
+ "image_caption": [
342
+ "Figure 1: The overall framework of G-EVAL. We first input Task Introduction and Evaluation Criteria to the LLM, and ask it to generate a CoT of detailed Evaluation Steps. Then we use the prompt along with the generated CoT to evaluate the NLG outputs in a form-filling paradigm. Finally, we use the probability-weighted summation of the output scores as the final score. "
343
+ ],
344
+ "image_footnote": [],
345
+ "bbox": [
346
+ 115,
347
+ 84,
348
+ 880,
349
+ 407
350
+ ],
351
+ "page_idx": 2
352
+ },
353
+ {
354
+ "type": "text",
355
+ "text": "",
356
+ "bbox": [
357
+ 115,
358
+ 502,
359
+ 487,
360
+ 678
361
+ ],
362
+ "page_idx": 2
363
+ },
364
+ {
365
+ "type": "text",
366
+ "text": "However, we notice this direct scoring function has two issues: ",
367
+ "bbox": [
368
+ 115,
369
+ 681,
370
+ 485,
371
+ 709
372
+ ],
373
+ "page_idx": 2
374
+ },
375
+ {
376
+ "type": "text",
377
+ "text": "1. For some evaluation tasks, one digit usually dominates the distribution of the scores, such as 3 for a 1 - 5 scale. This may lead to the low variance of the scores and the low correlation with human judgments. ",
378
+ "bbox": [
379
+ 131,
380
+ 722,
381
+ 485,
382
+ 802
383
+ ],
384
+ "page_idx": 2
385
+ },
386
+ {
387
+ "type": "text",
388
+ "text": "2. LLMs usually only output integer scores, even when the prompt explicitly requests decimal values. This leads to many ties in evaluation scores which do not capture the subtle difference between generated texts. ",
389
+ "bbox": [
390
+ 132,
391
+ 813,
392
+ 487,
393
+ 892
394
+ ],
395
+ "page_idx": 2
396
+ },
397
+ {
398
+ "type": "text",
399
+ "text": "To address these issues, we propose using the probabilities of output tokens from LLMs to normalize the scores and take their weighted summation as the final results. Formally, given a set of scores (like from 1 to 5) predefined in the prompt ${ \\cal S } = \\{ s _ { 1 } , s _ { 2 } , . . . , s _ { n } \\}$ , the probability of each score $p ( s _ { i } )$ is calculated by the LLM, and the final score is: ",
400
+ "bbox": [
401
+ 136,
402
+ 904,
403
+ 485,
404
+ 920
405
+ ],
406
+ "page_idx": 2
407
+ },
408
+ {
409
+ "type": "text",
410
+ "text": "",
411
+ "bbox": [
412
+ 510,
413
+ 502,
414
+ 884,
415
+ 613
416
+ ],
417
+ "page_idx": 2
418
+ },
419
+ {
420
+ "type": "equation",
421
+ "img_path": "images/91aa6a654305565aee57e8c596c79010c976656bcff133029a47acf23537e6bb.jpg",
422
+ "text": "$$\ns c o r e = \\sum _ { i = 1 } ^ { n } p ( s _ { i } ) \\times s _ { i }\n$$",
423
+ "text_format": "latex",
424
+ "bbox": [
425
+ 608,
426
+ 626,
427
+ 783,
428
+ 667
429
+ ],
430
+ "page_idx": 2
431
+ },
432
+ {
433
+ "type": "text",
434
+ "text": "This method obtains more fine-grained, continuous scores that better reflect the quality and diversity of the generated texts. ",
435
+ "bbox": [
436
+ 510,
437
+ 673,
438
+ 884,
439
+ 719
440
+ ],
441
+ "page_idx": 2
442
+ },
443
+ {
444
+ "type": "text",
445
+ "text": "3 Experiments ",
446
+ "text_level": 1,
447
+ "bbox": [
448
+ 512,
449
+ 732,
450
+ 653,
451
+ 749
452
+ ],
453
+ "page_idx": 2
454
+ },
455
+ {
456
+ "type": "text",
457
+ "text": "Following Zhong et al. (2022), we meta-evaluate our evaluator on three benchmarks, SummEval, Topical-Chat and QAGS, of two NLG tasks, summarization and dialogue response generation. ",
458
+ "bbox": [
459
+ 510,
460
+ 759,
461
+ 884,
462
+ 822
463
+ ],
464
+ "page_idx": 2
465
+ },
466
+ {
467
+ "type": "text",
468
+ "text": "3.1 Implementation Details ",
469
+ "text_level": 1,
470
+ "bbox": [
471
+ 512,
472
+ 834,
473
+ 741,
474
+ 851
475
+ ],
476
+ "page_idx": 2
477
+ },
478
+ {
479
+ "type": "text",
480
+ "text": "We use OpenAI’s GPT family as our LLMs, including GPT-3.5 (text-davinci-003) and GPT-4. For GPT-3.5, we set decoding temperature to 0 to increase the model’s determinism. For GPT-4, as it does not support the output of token probabilities, we set $= 2 0 , t e m p e r a t u r e = 1 , t o p \\_ p = 1 ^ { \\prime }$ to sample 20 times to estimate the token probabilities. We use G-EVAL-4 to indicate G-EVAL with GPT-4 as the backbone model, and G-EVAL-3.5 to indicate G-EVAL with GPT-3.5 as the backbone model. Example prompts for each task are provided in the Appendix. ",
481
+ "bbox": [
482
+ 510,
483
+ 856,
484
+ 884,
485
+ 920
486
+ ],
487
+ "page_idx": 2
488
+ },
489
+ {
490
+ "type": "table",
491
+ "img_path": "images/a0a7ae64a63a98f682909ffd56b98e11f6edb5407e30cb06265fd81575d765ba.jpg",
492
+ "table_caption": [
493
+ "Table 1: Summary-level Spearman $( \\rho )$ and Kendall-Tau $( \\tau )$ correlations of different metrics on SummEval benchmark. G-EVAL without probabilities (italicized) should not be considered as a fair comparison to other metrics on $\\tau$ , as it leads to many ties in the scores. This results in a higher Kendall-Tau correlation, but it does not fairly reflect the true evaluation ability. More details are in Section 4. "
494
+ ],
495
+ "table_footnote": [],
496
+ "table_body": "<table><tr><td rowspan=\"2\">Metrics</td><td colspan=\"2\">Coherence</td><td colspan=\"2\">Consistency</td><td colspan=\"2\">Fluency</td><td colspan=\"2\">Relevance</td><td colspan=\"2\">AVG</td></tr><tr><td>p</td><td>T</td><td>p</td><td>T</td><td>p T</td><td>p</td><td>T</td><td></td><td>p</td><td>T</td></tr><tr><td>ROUGE-1</td><td>0.167</td><td>0.126</td><td>0.160</td><td>0.130</td><td>0.115</td><td>0.094</td><td>0.326</td><td>0.252</td><td>0.192</td><td>0.150</td></tr><tr><td>ROUGE-2</td><td>0.184</td><td>0.139</td><td>0.187</td><td>0.155</td><td>0.159</td><td>0.128</td><td>0.290</td><td>0.219</td><td>0.205</td><td>0.161</td></tr><tr><td>ROUGE-L</td><td>0.128</td><td>0.099</td><td>0.115</td><td>0.092</td><td>0.105</td><td>0.084</td><td>0.311</td><td>0.237</td><td>0.165</td><td>0.128</td></tr><tr><td>BERTScore</td><td>0.284</td><td>0.211</td><td>0.110</td><td>0.090</td><td>0.193</td><td>0.158</td><td>0.312</td><td>0.243</td><td>0.225</td><td>0.175</td></tr><tr><td>MOVERSscore</td><td>0.159</td><td>0.118</td><td>0.157</td><td>0.127</td><td>0.129</td><td>0.105</td><td>0.318</td><td>0.244</td><td>0.191</td><td>0.148</td></tr><tr><td>BARTScore</td><td>0.448</td><td>0.342</td><td>0.382</td><td>0.315</td><td>0.356</td><td>0.292</td><td>0.356</td><td>0.273</td><td>0.385</td><td>0.305</td></tr><tr><td>UniEval</td><td>0.575</td><td>0.442</td><td>0.446</td><td>0.371</td><td>0.449</td><td>0.371</td><td>0.426</td><td>0.325</td><td>0.474</td><td>0.377</td></tr><tr><td>GPTScore</td><td>0.434</td><td>1</td><td>0.449</td><td>1</td><td>0.403</td><td>1</td><td>0.381</td><td>1</td><td>0.417</td><td>1</td></tr><tr><td>G-EVAL-3.5</td><td>0.440</td><td>0.335</td><td>0.386</td><td>0.318</td><td>0.424</td><td>0.347</td><td>0.385</td><td>0.293</td><td>0.401</td><td>0.320</td></tr><tr><td>- Probs</td><td>0.359</td><td>0.313</td><td>0.361</td><td>0.344</td><td>0.339</td><td>0.323</td><td>0.327</td><td>0.288</td><td>0.346</td><td>0.317</td></tr><tr><td>G-EVAL-4</td><td>0.582</td><td>0.457</td><td>0.507</td><td>0.425</td><td>0.506</td><td>0.455</td><td>0.547</td><td>0.433</td><td>0.514</td><td>0.418</td></tr><tr><td>- Probs</td><td>0.560</td><td>0.472</td><td>0.501</td><td>0.459</td><td>0.505</td><td>0.473</td><td>0.511</td><td>0.444</td><td>0.502</td><td>0.446</td></tr><tr><td>-CoT</td><td>0.564</td><td>0.454</td><td>0.493</td><td>0.413</td><td>0.483</td><td>0.431</td><td>0.538</td><td>0.427</td><td>0.500</td><td>0.407</td></tr><tr><td> - Description</td><td>0.513</td><td>0.424</td><td>0.421</td><td>0.344</td><td>0.447</td><td>0.373</td><td>0.479</td><td>0.388</td><td>0.479</td><td>0.377</td></tr></table>",
497
+ "bbox": [
498
+ 117,
499
+ 82,
500
+ 875,
501
+ 344
502
+ ],
503
+ "page_idx": 3
504
+ },
505
+ {
506
+ "type": "text",
507
+ "text": "",
508
+ "bbox": [
509
+ 115,
510
+ 438,
511
+ 487,
512
+ 567
513
+ ],
514
+ "page_idx": 3
515
+ },
516
+ {
517
+ "type": "text",
518
+ "text": "3.2 Benchmarks ",
519
+ "text_level": 1,
520
+ "bbox": [
521
+ 117,
522
+ 577,
523
+ 258,
524
+ 592
525
+ ],
526
+ "page_idx": 3
527
+ },
528
+ {
529
+ "type": "text",
530
+ "text": "We adopt three meta-evaluation benchmarks to measure the correlation between G-EVAL and human judgments. ",
531
+ "bbox": [
532
+ 115,
533
+ 599,
534
+ 485,
535
+ 645
536
+ ],
537
+ "page_idx": 3
538
+ },
539
+ {
540
+ "type": "text",
541
+ "text": "SummEval (Fabbri et al., 2021) is a benchmark that compares different evaluation methods for summarization. It gives human ratings for four aspects of each summary: fluency, coherence, consistency and relevance. It is built on the CNN/DailyMail dataset (Hermann et al., 2015) ",
542
+ "bbox": [
543
+ 115,
544
+ 663,
545
+ 487,
546
+ 758
547
+ ],
548
+ "page_idx": 3
549
+ },
550
+ {
551
+ "type": "text",
552
+ "text": "Topical-Chat (Mehri and Eskenazi, 2020) is a testbed for meta-evaluating different evaluators on dialogue response generation systems that use knowledge. We follow (Zhong et al., 2022) to use its human ratings on four aspects: naturalness, coherence, engagingness and groundedness. ",
553
+ "bbox": [
554
+ 115,
555
+ 776,
556
+ 485,
557
+ 870
558
+ ],
559
+ "page_idx": 3
560
+ },
561
+ {
562
+ "type": "text",
563
+ "text": "QAGS (Wang et al., 2020) is a benchmark for evaluating hallucinations in the summarization task. It aims to measure the consistency dimension of summaries by asking and answering questions. It is collected from two different news summarization datasets CNN/DailyMail and XSum. ",
564
+ "bbox": [
565
+ 115,
566
+ 888,
567
+ 485,
568
+ 919
569
+ ],
570
+ "page_idx": 3
571
+ },
572
+ {
573
+ "type": "text",
574
+ "text": "",
575
+ "bbox": [
576
+ 512,
577
+ 438,
578
+ 882,
579
+ 517
580
+ ],
581
+ "page_idx": 3
582
+ },
583
+ {
584
+ "type": "text",
585
+ "text": "3.3 Baselines ",
586
+ "text_level": 1,
587
+ "bbox": [
588
+ 512,
589
+ 529,
590
+ 628,
591
+ 543
592
+ ],
593
+ "page_idx": 3
594
+ },
595
+ {
596
+ "type": "text",
597
+ "text": "We evaluate G-EVAL against various evaluators that achieved state-of-the-art performance. ",
598
+ "bbox": [
599
+ 512,
600
+ 550,
601
+ 880,
602
+ 581
603
+ ],
604
+ "page_idx": 3
605
+ },
606
+ {
607
+ "type": "text",
608
+ "text": "BERTScore (Zhang et al., 2019) measures the similarity between two texts based on the contextualized embedding from BERT (Devlin et al., 2019). ",
609
+ "bbox": [
610
+ 512,
611
+ 582,
612
+ 882,
613
+ 630
614
+ ],
615
+ "page_idx": 3
616
+ },
617
+ {
618
+ "type": "text",
619
+ "text": "MoverScore (Zhao et al., 2019) improves BERTScore by adding soft alignments and new aggregation methods to obtain a more robust similarity measure. ",
620
+ "bbox": [
621
+ 512,
622
+ 631,
623
+ 882,
624
+ 693
625
+ ],
626
+ "page_idx": 3
627
+ },
628
+ {
629
+ "type": "text",
630
+ "text": "BARTScore (Yuan et al., 2021) is a unified evaluator which evaluate with the average likelihood of the pretrained encoder-decoder model, BART (Lewis et al., 2020). It can predict different scores depending on the formats of source and target. ",
631
+ "bbox": [
632
+ 510,
633
+ 695,
634
+ 882,
635
+ 774
636
+ ],
637
+ "page_idx": 3
638
+ },
639
+ {
640
+ "type": "text",
641
+ "text": "FactCC and QAGS (Krysci ´ nski et al. ´ , 2020; Wang et al., 2020) are two evaluators that measure the factual consistency of generated summaries. FactCC is a BERT-based classifier that predicts whether a summary is consistent with the source document. QAGS is a question-answering based evaluator that generates questions from the summary and checks if the answers can be found in the source document. ",
642
+ "bbox": [
643
+ 512,
644
+ 776,
645
+ 882,
646
+ 919
647
+ ],
648
+ "page_idx": 3
649
+ },
650
+ {
651
+ "type": "table",
652
+ "img_path": "images/b318b7eb015aa2ae79d4ac27b05aab924995046a3f3340bdce824694782ee7cb.jpg",
653
+ "table_caption": [],
654
+ "table_footnote": [
655
+ "Table 2: Turn-level Spearman $( \\rho )$ and Kendall-Tau $( \\tau )$ correlations of different metrics on Topical-Chat benchmark. "
656
+ ],
657
+ "table_body": "<table><tr><td rowspan=\"2\">Metrics</td><td colspan=\"2\">Naturalness</td><td colspan=\"2\">Coherence</td><td colspan=\"2\">Engagingness</td><td colspan=\"2\">Groundedness</td><td colspan=\"2\">AVG</td></tr><tr><td>r</td><td>p</td><td>r</td><td>p</td><td>r</td><td>p</td><td>r</td><td>p</td><td>r</td><td>p</td></tr><tr><td>ROUGE-L</td><td>0.176</td><td>0.146</td><td>0.193</td><td>0.203</td><td>0.295</td><td>0.300</td><td>0.310</td><td>0.327</td><td>0.243</td><td>0.244</td></tr><tr><td>BLEU-4</td><td>0.180</td><td>0.175</td><td>0.131</td><td>0.235</td><td>0.232</td><td>0.316</td><td>0.213</td><td>0.310</td><td>0.189</td><td>0.259</td></tr><tr><td>METEOR</td><td>0.212</td><td>0.191</td><td>0.250</td><td>0.302</td><td>0.367</td><td>0.439</td><td>0.333</td><td>0.391</td><td>0.290</td><td>0.331</td></tr><tr><td>BERTScore</td><td>0.226</td><td>0.209</td><td>0.214</td><td>0.233</td><td>0.317</td><td>0.335</td><td>0.291</td><td>0.317</td><td>0.262</td><td>0.273</td></tr><tr><td>USR</td><td>0.337</td><td>0.325</td><td>0.416</td><td>0.377</td><td>0.456</td><td>0.465</td><td>0.222</td><td>0.447</td><td>0.358</td><td>0.403</td></tr><tr><td>UniEval</td><td>0.455</td><td>0.330</td><td>0.602</td><td>0.455</td><td>0.573</td><td>0.430</td><td>0.577</td><td>0.453</td><td>0.552</td><td>0.417</td></tr><tr><td>G-EVAL-3.5</td><td>0.532</td><td>0.539</td><td>0.519</td><td>0.544</td><td>0.660</td><td>0.691</td><td>0.586</td><td>0.567</td><td>0.574</td><td>0.585</td></tr><tr><td>G-EVAL-4</td><td>0.549</td><td>0.565</td><td>0.594</td><td>0.605</td><td>0.627</td><td>0.631</td><td>0.531</td><td>0.551</td><td>0.575</td><td>0.588</td></tr></table>",
658
+ "bbox": [
659
+ 115,
660
+ 83,
661
+ 867,
662
+ 249
663
+ ],
664
+ "page_idx": 4
665
+ },
666
+ {
667
+ "type": "text",
668
+ "text": "USR (Mehri and Eskenazi, 2020) is evaluator that assesses dialogue response generation from different perspectives. It has several versions that assign different scores to each target response. ",
669
+ "bbox": [
670
+ 115,
671
+ 299,
672
+ 485,
673
+ 363
674
+ ],
675
+ "page_idx": 4
676
+ },
677
+ {
678
+ "type": "text",
679
+ "text": "UniEval (Zhong et al., 2022) is a unified evaluator that can evaluate different aspects of text generation as QA tasks. It uses a pretrained T5 model (Raffel et al., 2020) to encode the evaluation task, source and target texts as questions and answers, and then computes the QA score as the evaluation score. It can also handle different evaluation tasks by changing the question format. ",
680
+ "bbox": [
681
+ 115,
682
+ 365,
683
+ 487,
684
+ 493
685
+ ],
686
+ "page_idx": 4
687
+ },
688
+ {
689
+ "type": "text",
690
+ "text": "GPTScore (Fu et al., 2023) is a new framework that evaluates texts with generative pre-training models like GPT-3. It assumes that a generative pre-training model will assign a higher probability of high-quality generated text following a given instruction and context. Unlike G-EVAL, GPTScore formulates the evaluation task as a conditional generation problem instead of a form-filling problem. We report the score of GPTScore with GPT3-textdavinci-003 as the LLM, which is also usually referred as GPT-3.5. ",
691
+ "bbox": [
692
+ 115,
693
+ 495,
694
+ 487,
695
+ 670
696
+ ],
697
+ "page_idx": 4
698
+ },
699
+ {
700
+ "type": "text",
701
+ "text": "3.4 Results for Summarization ",
702
+ "text_level": 1,
703
+ "bbox": [
704
+ 119,
705
+ 688,
706
+ 369,
707
+ 702
708
+ ],
709
+ "page_idx": 4
710
+ },
711
+ {
712
+ "type": "text",
713
+ "text": "We adopt the same approach as Zhong et al. (2022) to evaluate different summarization metrics using summary-level Spearman and Kendall-Tau correlation. The first part of Table 1 shows the results of metrics that compare the semantic similarity between the model output and the reference text. These metrics perform poorly on most dimensions. The second part shows the results of metrics that use neural networks to learn from human ratings of summary quality. These metrics have much higher correlations than the similarity-based metrics, suggesting that they are more reliable for summarization evaluation. ",
714
+ "bbox": [
715
+ 115,
716
+ 711,
717
+ 487,
718
+ 919
719
+ ],
720
+ "page_idx": 4
721
+ },
722
+ {
723
+ "type": "text",
724
+ "text": "In the last part of Table 1 which corresponds to GPT-based evaluators, GPTScore also uses GPTs for evaluating summarization texts, but relies on GPT’s conditional probabilities of the given target. G-EVAL substantially surpasses all previous state-of-the-art evaluators on the SummEval benchmark. G-EVAL-4 achieved much higher human correspondence compared with G-EVAL-3.5 on both Spearman and Kendall-Tau correlation, which indicates that the larger model size of GPT-4 is beneficial for summarization evaluation. G-EVAL also outperforms GPTScore on several dimension, demonstrating the effectiveness of the simple formfilling paradigm. ",
725
+ "bbox": [
726
+ 512,
727
+ 299,
728
+ 882,
729
+ 524
730
+ ],
731
+ "page_idx": 4
732
+ },
733
+ {
734
+ "type": "text",
735
+ "text": "3.5 Results for Dialogue Generation ",
736
+ "text_level": 1,
737
+ "bbox": [
738
+ 515,
739
+ 538,
740
+ 806,
741
+ 554
742
+ ],
743
+ "page_idx": 4
744
+ },
745
+ {
746
+ "type": "text",
747
+ "text": "We use the Topical-chat benchmark from Mehri and Eskenazi (2020) to measure how well different evaluators agree with human ratings on the quality of dialogue responses. We calculate the Pearson and Spearman correlation for each turn of the dialogue. Table 2 shows that similarity-based metrics have good agreement with humans on how engaging and grounded the responses are, but not on the other aspects. With respect to the learningbased evaluators, before G-EVAL, UniEval predicts scores that are most consistent with human judgments across all aspects. ",
748
+ "bbox": [
749
+ 512,
750
+ 561,
751
+ 882,
752
+ 752
753
+ ],
754
+ "page_idx": 4
755
+ },
756
+ {
757
+ "type": "text",
758
+ "text": "As shown in the last part, G-EVAL also substantially surpasses all previous state-of-the-art evaluator on the Topical-Chat benchmark. Notably, the G-EVAL-3.5 can achieve similar results with G-EVAL-4. This indicates that this benchmark is relatively easy for the G-EVAL model. ",
759
+ "bbox": [
760
+ 512,
761
+ 756,
762
+ 882,
763
+ 851
764
+ ],
765
+ "page_idx": 4
766
+ },
767
+ {
768
+ "type": "text",
769
+ "text": "3.6 Results on Hallucinations ",
770
+ "text_level": 1,
771
+ "bbox": [
772
+ 514,
773
+ 865,
774
+ 756,
775
+ 881
776
+ ],
777
+ "page_idx": 4
778
+ },
779
+ {
780
+ "type": "text",
781
+ "text": "Advanced NLG models often produce text that does not match the context input (Cao et al., 2018), and recent studies find even powerful LLMs also suffer from the problem of hallucination. This motivates recent research to design evaluators for measuring the consistency aspect in summarization (Krys-´ cinski et al. ´ , 2020; Wang et al., 2020; Cao et al., 2020; Durmus et al., 2020). We test the QAGS meta-evaluation benchmark, which includes two different summarization datasets: CNN/DailyMail and XSum (Narayan et al., 2018) Table 3 shows that BARTScore performs well on the more extractive subset (QAGS-CNN), but has low correlation on the more abstractive subset (QAGS-Xsum). UniEval has good correlation on both subsets of the data. ",
782
+ "bbox": [
783
+ 512,
784
+ 889,
785
+ 880,
786
+ 919
787
+ ],
788
+ "page_idx": 4
789
+ },
790
+ {
791
+ "type": "table",
792
+ "img_path": "images/d5fc402bb127d275e3c5f636374b0eaf2fa1a2e42855c8b5af7873787dba1b8d.jpg",
793
+ "table_caption": [],
794
+ "table_footnote": [
795
+ "Table 3: Pearson $( r )$ , Spearman $( \\rho )$ and Kendall-Tau $( \\tau )$ correlations of different metrics on QAGS benchmark. "
796
+ ],
797
+ "table_body": "<table><tr><td rowspan=\"2\">Metrics</td><td colspan=\"3\">QAGS-CNN</td><td colspan=\"3\">QAGS-XSUM</td><td colspan=\"3\">Average</td></tr><tr><td>r</td><td>p</td><td>T</td><td>r</td><td>p</td><td>T</td><td>r</td><td>p</td><td>T</td></tr><tr><td>ROUGE-2</td><td>0.459</td><td>0.418</td><td>0.333</td><td>0.097</td><td>0.083</td><td>0.068</td><td>0.278</td><td>0.250</td><td>0.200</td></tr><tr><td>ROUGE-L</td><td>0.357</td><td>0.324</td><td>0.254</td><td>0.024</td><td>-0.011</td><td>-0.009</td><td>0.190</td><td>0.156</td><td>0.122</td></tr><tr><td>BERTScore</td><td>0.576</td><td>0.505</td><td>0.399</td><td>0.024</td><td>0.008</td><td>0.006</td><td>0.300</td><td>0.256</td><td>0.202</td></tr><tr><td>MoverScore</td><td>0.414</td><td>0.347</td><td>0.271</td><td>0.054</td><td>0.044</td><td>0.036</td><td>0.234</td><td>0.195</td><td>0.153</td></tr><tr><td>FactCC</td><td>0.416</td><td>0.484</td><td>0.376</td><td>0.297</td><td>0.259</td><td>0.212</td><td>0.356</td><td>0.371</td><td>0.294</td></tr><tr><td>QAGS</td><td>0.545</td><td>-</td><td>1</td><td>0.175</td><td>1</td><td>1</td><td>0.375</td><td>1</td><td>1</td></tr><tr><td>BARTScore</td><td>0.735</td><td>0.680</td><td>0.557</td><td>0.184</td><td>0.159</td><td>0.130</td><td>0.459</td><td>0.420</td><td>0.343</td></tr><tr><td>CTC</td><td>0.619</td><td>0.564</td><td>0.450</td><td>0.309</td><td>0.295</td><td>0.242</td><td>0.464</td><td>0.430</td><td>0.346</td></tr><tr><td>UniEval</td><td>0.682</td><td>0.662</td><td>0.532</td><td>0.461</td><td>0.488</td><td>0.399</td><td>0.571</td><td>0.575</td><td>0.465</td></tr><tr><td>G-EVAL-3.5</td><td>0.477</td><td>0.516</td><td>0.410</td><td>0.211</td><td>0.406</td><td>0.343</td><td>0.344</td><td>0.461</td><td>0.377</td></tr><tr><td>G-EVAL-4</td><td>0.631</td><td>0.685</td><td>0.591</td><td>0.558</td><td>0.537</td><td>0.472</td><td>0.599</td><td>0.611</td><td>0.525</td></tr></table>",
798
+ "bbox": [
799
+ 154,
800
+ 83,
801
+ 845,
802
+ 297
803
+ ],
804
+ "page_idx": 5
805
+ },
806
+ {
807
+ "type": "text",
808
+ "text": "",
809
+ "bbox": [
810
+ 115,
811
+ 348,
812
+ 487,
813
+ 571
814
+ ],
815
+ "page_idx": 5
816
+ },
817
+ {
818
+ "type": "text",
819
+ "text": "On average, G-EVAL-4 outperforms all state-ofthe-art evaluators on QAGS, with a large margin on QAGS-Xsum. G-EVAL-3.5, on the other hand, failed to perform well on this benchmark, which indicates that the consistency aspect is sensitive to the LLM’s capacity. This result is consistent with Table 1. ",
820
+ "bbox": [
821
+ 115,
822
+ 574,
823
+ 487,
824
+ 686
825
+ ],
826
+ "page_idx": 5
827
+ },
828
+ {
829
+ "type": "text",
830
+ "text": "4 Analysis ",
831
+ "text_level": 1,
832
+ "bbox": [
833
+ 117,
834
+ 700,
835
+ 221,
836
+ 717
837
+ ],
838
+ "page_idx": 5
839
+ },
840
+ {
841
+ "type": "text",
842
+ "text": "Will G-EVAL prefer LLM-based outputs? One concern about using LLM as an evaluator is that it may prefer the outputs generated by the LLM itself, rather than the high-quality human-written texts. To investigate this issue, we conduct an experiment on the summarization task, where we compare the evaluation scores of the LLM-generated and the human-written summaries. We use the dataset collected in Zhang et al. (2023), where they first ask freelance writers to write high-quality summaries for news articles, and then ask annotators to compare human-written summaries and LLMgenerated summaries (using GPT-3.5, text-davinci003). ",
843
+ "bbox": [
844
+ 115,
845
+ 727,
846
+ 487,
847
+ 919
848
+ ],
849
+ "page_idx": 5
850
+ },
851
+ {
852
+ "type": "image",
853
+ "img_path": "images/14310d11da9813f4681270efcb4b023f8cef3919f186f06d0862cd52441b8bdd.jpg",
854
+ "image_caption": [
855
+ "Figure 2: Averaged G-EVAL-4’s scores for humanwritten summaries and GPT-3.5 summaries, divided by human judges’ preference. "
856
+ ],
857
+ "image_footnote": [],
858
+ "bbox": [
859
+ 521,
860
+ 346,
861
+ 875,
862
+ 492
863
+ ],
864
+ "page_idx": 5
865
+ },
866
+ {
867
+ "type": "text",
868
+ "text": "",
869
+ "bbox": [
870
+ 512,
871
+ 574,
872
+ 882,
873
+ 605
874
+ ],
875
+ "page_idx": 5
876
+ },
877
+ {
878
+ "type": "text",
879
+ "text": "The dataset can be divided in three categories: 1) human-written summaries that are rated higher than GPT-3.5 summaries by human judges, 2) human-written summaries that are rated lower than GPT-3.5 summaries by human judges, and 3) human-written summaries and GPT-3.5 summaries are rated equally good by human judges. We use GEVAL-4 to evaluate the summaries in each category, and compare the averaged scores. 2 ",
880
+ "bbox": [
881
+ 512,
882
+ 607,
883
+ 882,
884
+ 750
885
+ ],
886
+ "page_idx": 5
887
+ },
888
+ {
889
+ "type": "text",
890
+ "text": "The results are shown in Figure 2. We can see that, G-EVAL-4 assigns higher scores to humanwritten summaries when human judges also prefer human-written summaries, and assigns lower scores when human judges prefer GPT-3.5 summaries. However, G-EVAL-4 always gives higher scores to GPT-3.5 summaries than human-written summaries, even when human judges prefer humanwritten summaries. We propose two potential reasons for this phenomenon: ",
891
+ "bbox": [
892
+ 512,
893
+ 751,
894
+ 882,
895
+ 863
896
+ ],
897
+ "page_idx": 5
898
+ },
899
+ {
900
+ "type": "text",
901
+ "text": "",
902
+ "bbox": [
903
+ 115,
904
+ 85,
905
+ 487,
906
+ 131
907
+ ],
908
+ "page_idx": 6
909
+ },
910
+ {
911
+ "type": "text",
912
+ "text": "1. NLG outputs from high-quality systems are in natural difficult to evaluate. The authors of the original paper found that inter-annotator agreement on judging human-written and LLM-generated summaries is very low, with Krippendorff’s alpha at 0.07. 2. G-EVAL may have a bias towards the LLMgenerated summaries because the model could share the same concept of evaluation criteria during generation and evaluation. ",
913
+ "bbox": [
914
+ 131,
915
+ 142,
916
+ 487,
917
+ 312
918
+ ],
919
+ "page_idx": 6
920
+ },
921
+ {
922
+ "type": "text",
923
+ "text": "Our work should be considered as a preliminary study on this issue, and more research is needed to fully understand the behavior of LLM-based evaluators to reduce its inherent bias towards LLMgenerated text. We highlight this concern in the context that LLM-based evaluators may lead to self-reinforcement of LLMs if the evaluation score is used as a reward signal for further tuning. And this could result in the over-fitting of the LLMs to their own evaluation criteria, rather than the true evaluation criteria of the NLG tasks. ",
924
+ "bbox": [
925
+ 115,
926
+ 324,
927
+ 485,
928
+ 499
929
+ ],
930
+ "page_idx": 6
931
+ },
932
+ {
933
+ "type": "text",
934
+ "text": "The Effect of Chain-of-Thoughts We compare the performance of G-EVAL with and without chain-of-thoughts (CoT) on the SummEval benchmark. Table 1 shows that G-EVAL-4 with CoT has higher correlation than G-EVAL-4 without CoT on all dimensions, especially for fluency. This suggests that CoT can provide more context and guidance for the LLM to evaluate the generated text, and can also help to explain the evaluation process and results. And it is shown that CoT is more useful on consistency and fluency dimensions. We also provide results of G-EVAL with a simple prompting baseline on SummEval (only asking GPT-4 to score a summary from 1-5 on each dimension, without detailed task introduction, evaluation criteria and CoT). ",
935
+ "bbox": [
936
+ 115,
937
+ 510,
938
+ 487,
939
+ 765
940
+ ],
941
+ "page_idx": 6
942
+ },
943
+ {
944
+ "type": "text",
945
+ "text": "The Effect of Probability Normalization We compare the performance of G-EVAL with and without probability normalization on the SummEval benchmark. Table 1 shows that, on KendallTau correlation, G-EVAL-4 with probabilities is inferior to G-EVAL-4 without probabilities on SummEval. We believe this is related to the calculation of Kendall-Tau correlation, which is based on the number of concordant and discordant pairs. Direct scoring without probabilities can lead to many ties, which are not counted as either concordant or discordant. This may result in a higher Kendall-Tau correlation, but it does not reflect the model’s true capacity of evaluating the generated texts. On the other hand, probability normalization can obtain more fine-grained, continuous scores that better capture the subtle difference between generated texts. This is reflected by the higher Spearman correlation of G-EVAL-4 with probabilities, which is based on the rank order of the scores. ",
946
+ "bbox": [
947
+ 115,
948
+ 775,
949
+ 487,
950
+ 919
951
+ ],
952
+ "page_idx": 6
953
+ },
954
+ {
955
+ "type": "text",
956
+ "text": "",
957
+ "bbox": [
958
+ 512,
959
+ 85,
960
+ 882,
961
+ 260
962
+ ],
963
+ "page_idx": 6
964
+ },
965
+ {
966
+ "type": "text",
967
+ "text": "The Effect of Different LLMs We compare the performance of G-EVAL with different LLMs on the SummEval and QAGS benchmarks. Table 1 and Table 3 show that G-EVAL-4 has higher correlation than G-EVAL-3.5 on most dimensions and datasets, except for engagingness and groundedness on the Topical-Chat benchmark. This demonstrates that a better LLM can improve the performance of G-EVAL, especially for more challenging and complex evaluation tasks, such as consistency and relevance. ",
968
+ "bbox": [
969
+ 512,
970
+ 273,
971
+ 882,
972
+ 449
973
+ ],
974
+ "page_idx": 6
975
+ },
976
+ {
977
+ "type": "text",
978
+ "text": "5 Related Work ",
979
+ "text_level": 1,
980
+ "bbox": [
981
+ 512,
982
+ 463,
983
+ 663,
984
+ 479
985
+ ],
986
+ "page_idx": 6
987
+ },
988
+ {
989
+ "type": "text",
990
+ "text": "Ngram-based Metrics Ngram-based metrics refer to the scores for evaluating the NLG models by measuring the lexical overlap between a generated text and a reference text. BLEU (Papineni et al., 2002) is the most widely used metric for machine translation evaluation, which calculates the geometric mean of modified n-gram precision and a brevity penalty. ROUGE (Lin, 2004) is a recall-oriented metric for summarization evaluation, which measures the n-gram overlap between a generated summary and a set of reference summaries. It has been shown that more than $60 \\%$ of recent papers on NLG only rely on ROUGE or BLEU to evaluate their systems (Kasai et al., 2022). However, these metrics fail to measure content quality (Reiter and Belz, 2009) or capture syntactic errors (Stent et al., 2005), and therefore do not reflect the reliability of NLG systems accurately. ",
991
+ "bbox": [
992
+ 510,
993
+ 489,
994
+ 882,
995
+ 780
996
+ ],
997
+ "page_idx": 6
998
+ },
999
+ {
1000
+ "type": "text",
1001
+ "text": "Embedding-based Metrics Embedding-based metrics refer to the scores for evaluating the NLG models by measuring the semantic similarity between a generated text and a reference text based on the word or sentence embeddings. WMD (Kusner et al., 2015) is a metric that measures the distance between two texts based on the word embeddings. BERTScore (Zhang et al., 2019) measures the similarity between two texts based on the contextualized embedding from BERT (Devlin et al., 2019). MoverScore (Zhao et al., 2019) improves BERTScore by adding soft alignments and new aggregation methods to obtain a more robust similarity measure. (Clark et al., 2019) propose a metric that evaluates multi-sentence texts by computing the similarity between the generated text and the reference text based on the sentence embeddings. ",
1002
+ "bbox": [
1003
+ 512,
1004
+ 791,
1005
+ 884,
1006
+ 919
1007
+ ],
1008
+ "page_idx": 6
1009
+ },
1010
+ {
1011
+ "type": "text",
1012
+ "text": "",
1013
+ "bbox": [
1014
+ 117,
1015
+ 85,
1016
+ 485,
1017
+ 228
1018
+ ],
1019
+ "page_idx": 7
1020
+ },
1021
+ {
1022
+ "type": "text",
1023
+ "text": "Task-specific Evaluators Task-specific metrics refer to the scores for evaluating the NLG models by measuring the quality of the generated texts based on the specific task requirements. For example, summarization tasks need to assess the consistency of the generated summaries (Krys-´ cinski et al. ´ , 2020; Wang et al., 2020; Cao et al., 2020; Durmus et al., 2020), and dialogue response generation tasks need to assess the coherence of the generated responses (Dziri et al., 2019; Ye et al., 2021; Ghazarian et al., 2019). However, these metrics are not generalizable to other NLG tasks, and they are not able to measure the overall quality of the generated texts. ",
1024
+ "bbox": [
1025
+ 115,
1026
+ 239,
1027
+ 487,
1028
+ 462
1029
+ ],
1030
+ "page_idx": 7
1031
+ },
1032
+ {
1033
+ "type": "text",
1034
+ "text": "Unified Evaluators Recently, some evaluators have been developed to assess text quality from multiple dimensions by varying the input and output contents (Yuan et al., 2021) or the model variants (Mehri and Eskenazi, 2020) they use. UniEval (Zhong et al., 2022) is a unified evaluator that can evaluate different aspects of text generation as QA tasks. By changing the question format, it can handle different evaluation tasks. ",
1035
+ "bbox": [
1036
+ 115,
1037
+ 473,
1038
+ 487,
1039
+ 615
1040
+ ],
1041
+ "page_idx": 7
1042
+ },
1043
+ {
1044
+ "type": "text",
1045
+ "text": "LLM-based Evaluators Fu et al. (2023) propose GPTScore, a new framework that evaluated texts with generative pre-training models like GPT-3. It assumes that a generative pre-training model will assign a higher probability of high-quality generated text following a given instruction and context. Wang et al. (2023a) conduct a preliminary survey of using ChatGPT as a NLG evaluator. Kocmi and Federmann (2023); Lu et al. (2023) proposed to use GPT models for evaluating machine translation tasks. Very recently, Wang et al. (2023b) investigated the problem of unfairness when using large models in evaluating dialogue responses. ",
1046
+ "bbox": [
1047
+ 115,
1048
+ 626,
1049
+ 487,
1050
+ 834
1051
+ ],
1052
+ "page_idx": 7
1053
+ },
1054
+ {
1055
+ "type": "text",
1056
+ "text": "extensive experiments on two NLG tasks, text summarization and dialogue generation, and show that G-EVAL can outperform state-of-the-art evaluators and achieve higher human correspondence. We also propose preliminary analysis on the behavior of LLM-based evaluators, and highlight the potential issue of LLM-based evaluator having a bias towards the LLM-generated texts. We hope our work can inspire more research on using LLMs for NLG evaluation, and also raise awareness of the potential risks and challenges of using LLMs as evaluators. ",
1057
+ "bbox": [
1058
+ 512,
1059
+ 85,
1060
+ 882,
1061
+ 275
1062
+ ],
1063
+ "page_idx": 7
1064
+ },
1065
+ {
1066
+ "type": "text",
1067
+ "text": "Limitations ",
1068
+ "text_level": 1,
1069
+ "bbox": [
1070
+ 512,
1071
+ 290,
1072
+ 613,
1073
+ 305
1074
+ ],
1075
+ "page_idx": 7
1076
+ },
1077
+ {
1078
+ "type": "text",
1079
+ "text": "G-EVAL is a framework that uses LLMs to evaluate the quality of generated texts. However, it also has some limitations that need to be addressed in future work. ",
1080
+ "bbox": [
1081
+ 512,
1082
+ 316,
1083
+ 880,
1084
+ 378
1085
+ ],
1086
+ "page_idx": 7
1087
+ },
1088
+ {
1089
+ "type": "text",
1090
+ "text": "1. As we already discussed in the paper, G-EVAL may have a bias towards the LLM-generated texts. This may lead to the self-reinforcement of LLMs if the evaluation score is used as a reward signal for further tuning. And this could result in the over-fitting of the LLMs to their own evaluation criteria, rather than the true evaluation criteria of the NLG tasks. ",
1091
+ "bbox": [
1092
+ 527,
1093
+ 393,
1094
+ 882,
1095
+ 519
1096
+ ],
1097
+ "page_idx": 7
1098
+ },
1099
+ {
1100
+ "type": "text",
1101
+ "text": "2. G-EVAL is limited by the availability and accessibility of LLMs. Currently, most LLMs are not publicly available, and require special access or payment to use. This may limit the applicability and reproducibility of G-EVAL. Moreover, the LLMs are constantly updated, which may lead to inconsistent evaluation results across different versions of the LLMs. ",
1102
+ "bbox": [
1103
+ 527,
1104
+ 532,
1105
+ 884,
1106
+ 661
1107
+ ],
1108
+ "page_idx": 7
1109
+ },
1110
+ {
1111
+ "type": "text",
1112
+ "text": "3. We meta-evaluate G-EVAL on two NLG tasks, text summarization and dialogue generation. However, there are some emerging NLG tasks in the LLM era where users prompt with freeform natural language instructions. In this case, the evaluation criteria may need to be more flexible and adaptive to the user’s intention and preference. Therefore, more research is needed to explore how to use G-EVAL for evaluating these new types of NLG tasks. ",
1113
+ "bbox": [
1114
+ 526,
1115
+ 674,
1116
+ 884,
1117
+ 833
1118
+ ],
1119
+ "page_idx": 7
1120
+ },
1121
+ {
1122
+ "type": "text",
1123
+ "text": "6 Conclusion ",
1124
+ "text_level": 1,
1125
+ "bbox": [
1126
+ 117,
1127
+ 846,
1128
+ 243,
1129
+ 863
1130
+ ],
1131
+ "page_idx": 7
1132
+ },
1133
+ {
1134
+ "type": "text",
1135
+ "text": "In this paper, we propose G-EVAL, a framework of using LLM with chain-of-thoughts (CoT) to evaluate the quality of generated texts. We conduct ",
1136
+ "bbox": [
1137
+ 115,
1138
+ 872,
1139
+ 487,
1140
+ 919
1141
+ ],
1142
+ "page_idx": 7
1143
+ },
1144
+ {
1145
+ "type": "text",
1146
+ "text": "Ethics Statement ",
1147
+ "text_level": 1,
1148
+ "bbox": [
1149
+ 512,
1150
+ 846,
1151
+ 660,
1152
+ 862
1153
+ ],
1154
+ "page_idx": 7
1155
+ },
1156
+ {
1157
+ "type": "text",
1158
+ "text": "The G-EVAL framework we proposed is designed to offer a more effective and reliable method for assessing natural language generation systems. Its purpose is to aid researchers, developers, and other interested parties in evaluating the quality of text produced by NLG systems. Possible risks could exist if G-EVAL is unable to precisely evaluate the quality of produced texts or shows a preference for LLM-created texts. This could lead to developers overestimating the performance of their systems or unintentionally reinforcing biases in their models. Furthermore, users depending on the generated material may receive low-quality or biased information. ",
1159
+ "bbox": [
1160
+ 512,
1161
+ 872,
1162
+ 882,
1163
+ 920
1164
+ ],
1165
+ "page_idx": 7
1166
+ },
1167
+ {
1168
+ "type": "text",
1169
+ "text": "",
1170
+ "bbox": [
1171
+ 117,
1172
+ 85,
1173
+ 485,
1174
+ 260
1175
+ ],
1176
+ "page_idx": 8
1177
+ },
1178
+ {
1179
+ "type": "text",
1180
+ "text": "References ",
1181
+ "text_level": 1,
1182
+ "bbox": [
1183
+ 117,
1184
+ 290,
1185
+ 211,
1186
+ 305
1187
+ ],
1188
+ "page_idx": 8
1189
+ },
1190
+ {
1191
+ "type": "text",
1192
+ "text": "Satanjeev Banerjee and Alon Lavie. 2005. Meteor: An automatic metric for mt evaluation with improved correlation with human judgments. In Proceedings of the acl workshop on intrinsic and extrinsic evaluation measures for machine translation and/or summarization, pages 65–72. ",
1193
+ "bbox": [
1194
+ 117,
1195
+ 312,
1196
+ 487,
1197
+ 391
1198
+ ],
1199
+ "page_idx": 8
1200
+ },
1201
+ {
1202
+ "type": "text",
1203
+ "text": "Meng Cao, Yue Dong, Jiapeng Wu, and Jackie Chi Kit Cheung. 2020. Factual error correction for abstractive summarization models. In Proceedings of the 2020 Conference on Empirical Methods in Natural Language Processing (EMNLP), pages 6251–6258. ",
1204
+ "bbox": [
1205
+ 115,
1206
+ 403,
1207
+ 487,
1208
+ 468
1209
+ ],
1210
+ "page_idx": 8
1211
+ },
1212
+ {
1213
+ "type": "text",
1214
+ "text": "Ziqiang Cao, Furu Wei, Wenjie Li, and Sujian Li. 2018. Faithful to the original: Fact aware neural abstractive summarization. In thirty-second AAAI conference on artificial intelligence. ",
1215
+ "bbox": [
1216
+ 115,
1217
+ 480,
1218
+ 487,
1219
+ 532
1220
+ ],
1221
+ "page_idx": 8
1222
+ },
1223
+ {
1224
+ "type": "text",
1225
+ "text": "Elizabeth Clark, Asli Celikyilmaz, and Noah A Smith. 2019. Sentence mover’s similarity: Automatic evaluation for multi-sentence texts. In Proceedings of the 57th Annual Meeting of the Association for Computational Linguistics, pages 2748–2760. ",
1226
+ "bbox": [
1227
+ 117,
1228
+ 544,
1229
+ 487,
1230
+ 609
1231
+ ],
1232
+ "page_idx": 8
1233
+ },
1234
+ {
1235
+ "type": "text",
1236
+ "text": "Jacob Devlin, Ming-Wei Chang, Kenton Lee, and Kristina Toutanova. 2019. Bert: Pre-training of deep bidirectional transformers for language understanding. In Proceedings of the 2019 Conference of the North American Chapter of the Association for Computational Linguistics: Human Language Technologies, Volume 1 (Long and Short Papers), pages 4171– 4186. ",
1237
+ "bbox": [
1238
+ 117,
1239
+ 621,
1240
+ 487,
1241
+ 725
1242
+ ],
1243
+ "page_idx": 8
1244
+ },
1245
+ {
1246
+ "type": "text",
1247
+ "text": "Esin Durmus, He He, and Mona Diab. 2020. Feqa: A question answering evaluation framework for faithfulness assessment in abstractive summarization. In Proceedings of the 58th Annual Meeting of the Association for Computational Linguistics, pages 5055– 5070. ",
1248
+ "bbox": [
1249
+ 117,
1250
+ 737,
1251
+ 487,
1252
+ 815
1253
+ ],
1254
+ "page_idx": 8
1255
+ },
1256
+ {
1257
+ "type": "text",
1258
+ "text": "Nouha Dziri, Ehsan Kamalloo, Kory Mathewson, and Osmar R Zaiane. 2019. Evaluating coherence in dialogue systems using entailment. In Proceedings of the 2019 Conference of the North American Chapter of the Association for Computational Linguistics: Human Language Technologies, Volume 1 (Long and Short Papers), pages 3806–3812. ",
1259
+ "bbox": [
1260
+ 117,
1261
+ 827,
1262
+ 487,
1263
+ 919
1264
+ ],
1265
+ "page_idx": 8
1266
+ },
1267
+ {
1268
+ "type": "text",
1269
+ "text": "Alexander R Fabbri, Wojciech Krysci ´ nski, Bryan Mc- ´ Cann, Caiming Xiong, Richard Socher, and Dragomir Radev. 2021. Summeval: Re-evaluating summarization evaluation. Transactions of the Association for Computational Linguistics, 9:391–409. ",
1270
+ "bbox": [
1271
+ 512,
1272
+ 85,
1273
+ 882,
1274
+ 151
1275
+ ],
1276
+ "page_idx": 8
1277
+ },
1278
+ {
1279
+ "type": "text",
1280
+ "text": "Jinlan Fu, See-Kiong Ng, Zhengbao Jiang, and Pengfei Liu. 2023. Gptscore: Evaluate as you desire. arXiv preprint arXiv:2302.04166. ",
1281
+ "bbox": [
1282
+ 510,
1283
+ 164,
1284
+ 880,
1285
+ 203
1286
+ ],
1287
+ "page_idx": 8
1288
+ },
1289
+ {
1290
+ "type": "text",
1291
+ "text": "Sarik Ghazarian, Johnny Wei, Aram Galstyan, and Nanyun Peng. 2019. Better automatic evaluation of open-domain dialogue systems with contextualized embeddings. In Proceedings of the Workshop on Methods for Optimizing and Evaluating Neural Language Generation, pages 82–89, Minneapolis, Minnesota. Association for Computational Linguistics. ",
1292
+ "bbox": [
1293
+ 510,
1294
+ 216,
1295
+ 882,
1296
+ 319
1297
+ ],
1298
+ "page_idx": 8
1299
+ },
1300
+ {
1301
+ "type": "text",
1302
+ "text": "Karl Moritz Hermann, Tomas Kocisky, Edward Grefenstette, Lasse Espeholt, Will Kay, Mustafa Suleyman, and Phil Blunsom. 2015. Teaching machines to read and comprehend. Advances in neural information processing systems, 28. ",
1303
+ "bbox": [
1304
+ 512,
1305
+ 334,
1306
+ 882,
1307
+ 398
1308
+ ],
1309
+ "page_idx": 8
1310
+ },
1311
+ {
1312
+ "type": "text",
1313
+ "text": "Jungo Kasai, Keisuke Sakaguchi, Ronan Le Bras, Lavinia Dunagan, Jacob Morrison, Alexander Fabbri, Yejin Choi, and Noah A. Smith. 2022. Bidimensional leaderboards: Generate and evaluate language hand in hand. In Proceedings of the 2022 Conference of the North American Chapter of the Association for Computational Linguistics: Human Language Technologies, pages 3540–3557, Seattle, United States. Association for Computational Linguistics. ",
1314
+ "bbox": [
1315
+ 510,
1316
+ 411,
1317
+ 882,
1318
+ 529
1319
+ ],
1320
+ "page_idx": 8
1321
+ },
1322
+ {
1323
+ "type": "text",
1324
+ "text": "Tom Kocmi and Christian Federmann. 2023. Large language models are state-of-the-art evaluators of translation quality. arXiv preprint arXiv:2302.14520. ",
1325
+ "bbox": [
1326
+ 512,
1327
+ 542,
1328
+ 882,
1329
+ 580
1330
+ ],
1331
+ "page_idx": 8
1332
+ },
1333
+ {
1334
+ "type": "text",
1335
+ "text": "Wojciech Krysci ´ nski, Bryan McCann, Caiming Xiong, ´ and Richard Socher. 2020. Evaluating the factual consistency of abstractive text summarization. In Proceedings of the 2020 Conference on Empirical Methods in Natural Language Processing (EMNLP), pages 9332–9346. ",
1336
+ "bbox": [
1337
+ 512,
1338
+ 593,
1339
+ 882,
1340
+ 671
1341
+ ],
1342
+ "page_idx": 8
1343
+ },
1344
+ {
1345
+ "type": "text",
1346
+ "text": "Matt Kusner, Yu Sun, Nicholas Kolkin, and Kilian Weinberger. 2015. From word embeddings to document distances. In International conference on machine learning, pages 957–966. PMLR. ",
1347
+ "bbox": [
1348
+ 510,
1349
+ 684,
1350
+ 882,
1351
+ 737
1352
+ ],
1353
+ "page_idx": 8
1354
+ },
1355
+ {
1356
+ "type": "text",
1357
+ "text": "Mike Lewis, Yinhan Liu, Naman Goyal, Marjan Ghazvininejad, Abdelrahman Mohamed, Omer Levy, Veselin Stoyanov, and Luke Zettlemoyer. 2020. BART: denoising sequence-to-sequence pre-training for natural language generation, translation, and comprehension. In Proceedings of the 58th Annual Meeting of the Association for Computational Linguistics, ACL 2020, Online, July 5-10, 2020, pages 7871–7880. Association for Computational Linguistics. ",
1358
+ "bbox": [
1359
+ 510,
1360
+ 749,
1361
+ 882,
1362
+ 866
1363
+ ],
1364
+ "page_idx": 8
1365
+ },
1366
+ {
1367
+ "type": "text",
1368
+ "text": "Chin-Yew Lin. 2004. Rouge: A package for automatic evaluation of summaries. In Text summarization branches out, pages 74–81. ",
1369
+ "bbox": [
1370
+ 510,
1371
+ 879,
1372
+ 880,
1373
+ 919
1374
+ ],
1375
+ "page_idx": 8
1376
+ },
1377
+ {
1378
+ "type": "text",
1379
+ "text": "Qingyu Lu, Baopu Qiu, Liang Ding, Liping Xie, and Dacheng Tao. 2023. Error analysis prompting enables human-like translation evaluation in large language models: A case study on chatgpt. arXiv preprint arXiv:2303.13809. ",
1380
+ "bbox": [
1381
+ 117,
1382
+ 86,
1383
+ 487,
1384
+ 151
1385
+ ],
1386
+ "page_idx": 9
1387
+ },
1388
+ {
1389
+ "type": "text",
1390
+ "text": "Shikib Mehri and Maxine Eskenazi. 2020. USR: An unsupervised and reference free evaluation metric for dialog generation. In Proceedings of the 58th Annual Meeting of the Association for Computational Linguistics, pages 681–707, Online. Association for Computational Linguistics. ",
1391
+ "bbox": [
1392
+ 117,
1393
+ 160,
1394
+ 485,
1395
+ 239
1396
+ ],
1397
+ "page_idx": 9
1398
+ },
1399
+ {
1400
+ "type": "text",
1401
+ "text": "Shashi Narayan, Shay B Cohen, and Mirella Lapata. 2018. Don’t give me the details, just the summary! topic-aware convolutional neural networks for extreme summarization. In Proceedings of the 2018 Conference on Empirical Methods in Natural Language Processing, pages 1797–1807. ",
1402
+ "bbox": [
1403
+ 117,
1404
+ 247,
1405
+ 487,
1406
+ 325
1407
+ ],
1408
+ "page_idx": 9
1409
+ },
1410
+ {
1411
+ "type": "text",
1412
+ "text": "Long Ouyang, Jeffrey Wu, Xu Jiang, Diogo Almeida, Carroll Wainwright, Pamela Mishkin, Chong Zhang, Sandhini Agarwal, Katarina Slama, Alex Ray, et al. 2022. Training language models to follow instructions with human feedback. Advances in Neural Information Processing Systems, 35:27730–27744. ",
1413
+ "bbox": [
1414
+ 117,
1415
+ 335,
1416
+ 487,
1417
+ 412
1418
+ ],
1419
+ "page_idx": 9
1420
+ },
1421
+ {
1422
+ "type": "text",
1423
+ "text": "Kishore Papineni, Salim Roukos, Todd Ward, and WeiJing Zhu. 2002. Bleu: a method for automatic evaluation of machine translation. In Proceedings of the 40th annual meeting of the Association for Computational Linguistics, pages 311–318. ",
1424
+ "bbox": [
1425
+ 117,
1426
+ 422,
1427
+ 487,
1428
+ 487
1429
+ ],
1430
+ "page_idx": 9
1431
+ },
1432
+ {
1433
+ "type": "text",
1434
+ "text": "Colin Raffel, Noam Shazeer, Adam Roberts, Katherine Lee, Sharan Narang, Michael Matena, Yanqi Zhou, Wei Li, and Peter J Liu. 2020. Exploring the limits of transfer learning with a unified text-to-text transformer. Journal of Machine Learning Research, 21:1– 67. ",
1435
+ "bbox": [
1436
+ 117,
1437
+ 495,
1438
+ 487,
1439
+ 573
1440
+ ],
1441
+ "page_idx": 9
1442
+ },
1443
+ {
1444
+ "type": "text",
1445
+ "text": "Ehud Reiter and Anja Belz. 2009. An investigation into the validity of some metrics for automatically evaluating natural language generation systems. Computational Linguistics, 35(4):529–558. ",
1446
+ "bbox": [
1447
+ 115,
1448
+ 583,
1449
+ 487,
1450
+ 634
1451
+ ],
1452
+ "page_idx": 9
1453
+ },
1454
+ {
1455
+ "type": "text",
1456
+ "text": "Amanda Stent, Matthew Marge, and Mohit Singhai. 2005. Evaluating evaluation methods for generation in the presence of variation. In Proceedings of the 6th international conference on Computational Linguistics and Intelligent Text Processing, pages 341–351. ",
1457
+ "bbox": [
1458
+ 117,
1459
+ 644,
1460
+ 487,
1461
+ 709
1462
+ ],
1463
+ "page_idx": 9
1464
+ },
1465
+ {
1466
+ "type": "text",
1467
+ "text": "Rohan Taori, Ishaan Gulrajani, Tianyi Zhang, Yann Dubois, Xuechen Li, Carlos Guestrin, Percy Liang, and Tatsunori B. Hashimoto. 2023. Stanford alpaca: An instruction-following llama model. https:// github.com/tatsu-lab/stanford_alpaca. ",
1468
+ "bbox": [
1469
+ 117,
1470
+ 718,
1471
+ 487,
1472
+ 783
1473
+ ],
1474
+ "page_idx": 9
1475
+ },
1476
+ {
1477
+ "type": "text",
1478
+ "text": "Alex Wang, Kyunghyun Cho, and Mike Lewis. 2020. Asking and answering questions to evaluate the factual consistency of summaries. In Proceedings of the 58th Annual Meeting of the Association for Computational Linguistics, pages 5008–5020. ",
1479
+ "bbox": [
1480
+ 117,
1481
+ 793,
1482
+ 487,
1483
+ 857
1484
+ ],
1485
+ "page_idx": 9
1486
+ },
1487
+ {
1488
+ "type": "text",
1489
+ "text": "Jiaan Wang, Yunlong Liang, Fandong Meng, Haoxiang Shi, Zhixu Li, Jinan Xu, Jianfeng Qu, and Jie Zhou. 2023a. Is chatgpt a good nlg evaluator? a preliminary study. arXiv preprint arXiv:2303.04048. ",
1490
+ "bbox": [
1491
+ 115,
1492
+ 866,
1493
+ 487,
1494
+ 919
1495
+ ],
1496
+ "page_idx": 9
1497
+ },
1498
+ {
1499
+ "type": "text",
1500
+ "text": "Peiyi Wang, Lei Li, Liang Chen, Dawei Zhu, Binghuai Lin, Yunbo Cao, Qi Liu, Tianyu Liu, and Zhifang Sui. 2023b. Large language models are not fair evaluators. arXiv preprint arXiv:2305.17926. ",
1501
+ "bbox": [
1502
+ 510,
1503
+ 86,
1504
+ 882,
1505
+ 139
1506
+ ],
1507
+ "page_idx": 9
1508
+ },
1509
+ {
1510
+ "type": "text",
1511
+ "text": "Jason Wei, Xuezhi Wang, Dale Schuurmans, Maarten Bosma, Ed Chi, Quoc Le, and Denny Zhou. 2022. Chain of thought prompting elicits reasoning in large language models. Advances in neural information processing systems, 28. ",
1512
+ "bbox": [
1513
+ 510,
1514
+ 151,
1515
+ 882,
1516
+ 215
1517
+ ],
1518
+ "page_idx": 9
1519
+ },
1520
+ {
1521
+ "type": "text",
1522
+ "text": "Zheng Ye, Liucun Lu, Lishan Huang, Liang Lin, and Xiaodan Liang. 2021. Towards quantifiable dialogue coherence evaluation. In Proceedings of the 59th Annual Meeting of the Association for Computational Linguistics and the 11th International Joint Conference on Natural Language Processing (Volume 1: Long Papers), pages 2718–2729. ",
1523
+ "bbox": [
1524
+ 510,
1525
+ 227,
1526
+ 882,
1527
+ 318
1528
+ ],
1529
+ "page_idx": 9
1530
+ },
1531
+ {
1532
+ "type": "text",
1533
+ "text": "Weizhe Yuan, Graham Neubig, and Pengfei Liu. 2021. Bartscore: Evaluating generated text as text generation. Advances in Neural Information Processing Systems, 34. ",
1534
+ "bbox": [
1535
+ 510,
1536
+ 330,
1537
+ 882,
1538
+ 382
1539
+ ],
1540
+ "page_idx": 9
1541
+ },
1542
+ {
1543
+ "type": "text",
1544
+ "text": "Tianyi Zhang, Varsha Kishore, Felix Wu, Kilian Q Weinberger, and Yoav Artzi. 2019. Bertscore: Evaluating text generation with bert. arXiv preprint arXiv:1904.09675. ",
1545
+ "bbox": [
1546
+ 512,
1547
+ 394,
1548
+ 882,
1549
+ 445
1550
+ ],
1551
+ "page_idx": 9
1552
+ },
1553
+ {
1554
+ "type": "text",
1555
+ "text": "Tianyi Zhang, Faisal Ladhak, Esin Durmus, Percy Liang, Kathleen McKeown, and Tatsunori B. Hashimoto. 2023. Benchmarking large language models for news summarization. ",
1556
+ "bbox": [
1557
+ 512,
1558
+ 458,
1559
+ 882,
1560
+ 510
1561
+ ],
1562
+ "page_idx": 9
1563
+ },
1564
+ {
1565
+ "type": "text",
1566
+ "text": "Wei Zhao, Maxime Peyrard, Fei Liu, Yang Gao, Christian M Meyer, and Steffen Eger. 2019. Moverscore: Text generation evaluating with contextualized embeddings and earth mover distance. In Proceedings of the 2019 Conference on Empirical Methods in Natural Language Processing and the 9th International Joint Conference on Natural Language Processing (EMNLP-IJCNLP), pages 563–578. ",
1567
+ "bbox": [
1568
+ 512,
1569
+ 521,
1570
+ 882,
1571
+ 626
1572
+ ],
1573
+ "page_idx": 9
1574
+ },
1575
+ {
1576
+ "type": "text",
1577
+ "text": "Lianmin Zheng, Wei-Lin Chiang, Ying Sheng, Siyuan Zhuang, Zhanghao Wu, Yonghao Zhuang, Zi Lin, Zhuohan Li, Dacheng Li, Eric. P Xing, Hao Zhang, Joseph E. Gonzalez, and Ion Stoica. 2023. Judging llm-as-a-judge with mt-bench and chatbot arena. ",
1578
+ "bbox": [
1579
+ 510,
1580
+ 638,
1581
+ 882,
1582
+ 703
1583
+ ],
1584
+ "page_idx": 9
1585
+ },
1586
+ {
1587
+ "type": "text",
1588
+ "text": "Ming Zhong, Yang Liu, Da Yin, Yuning Mao, Yizhu Jiao, Pengfei Liu, Chenguang Zhu, Heng Ji, and Jiawei Han. 2022. Towards a unified multidimensional evaluator for text generation. In Proceedings of the 2022 Conference on Empirical Methods in Natural Language Processing, pages 2023– 2038, Abu Dhabi, United Arab Emirates. ",
1589
+ "bbox": [
1590
+ 510,
1591
+ 715,
1592
+ 882,
1593
+ 806
1594
+ ],
1595
+ "page_idx": 9
1596
+ },
1597
+ {
1598
+ "type": "text",
1599
+ "text": "A Example Prompts ",
1600
+ "text_level": 1,
1601
+ "bbox": [
1602
+ 514,
1603
+ 834,
1604
+ 702,
1605
+ 850
1606
+ ],
1607
+ "page_idx": 9
1608
+ },
1609
+ {
1610
+ "type": "text",
1611
+ "text": "Evaluate Coherence in the Summarization Task ",
1612
+ "text_level": 1,
1613
+ "bbox": [
1614
+ 512,
1615
+ 860,
1616
+ 880,
1617
+ 875
1618
+ ],
1619
+ "page_idx": 9
1620
+ },
1621
+ {
1622
+ "type": "text",
1623
+ "text": "You will be given one summary written for a news article. ",
1624
+ "bbox": [
1625
+ 547,
1626
+ 889,
1627
+ 845,
1628
+ 919
1629
+ ],
1630
+ "page_idx": 9
1631
+ },
1632
+ {
1633
+ "type": "text",
1634
+ "text": "Your task is to rate the summary on one metric. ",
1635
+ "bbox": [
1636
+ 152,
1637
+ 85,
1638
+ 448,
1639
+ 115
1640
+ ],
1641
+ "page_idx": 10
1642
+ },
1643
+ {
1644
+ "type": "text",
1645
+ "text": "Please make sure you read and understand these instructions carefully. Please keep this document open while reviewing, and refer to it as needed. ",
1646
+ "bbox": [
1647
+ 152,
1648
+ 122,
1649
+ 450,
1650
+ 184
1651
+ ],
1652
+ "page_idx": 10
1653
+ },
1654
+ {
1655
+ "type": "text",
1656
+ "text": "Evaluation Criteria: ",
1657
+ "text_level": 1,
1658
+ "bbox": [
1659
+ 154,
1660
+ 203,
1661
+ 304,
1662
+ 217
1663
+ ],
1664
+ "page_idx": 10
1665
+ },
1666
+ {
1667
+ "type": "text",
1668
+ "text": "Coherence (1-5) - the collective quality of all sentences. We align this dimension with the DUC quality question of structure and coherence whereby \"the summary should be well-structured and well-organized. The summary should not just be a heap of related information, but should build from sentence to sentence to a coherent body of information about a topic.\" ",
1669
+ "bbox": [
1670
+ 152,
1671
+ 223,
1672
+ 450,
1673
+ 382
1674
+ ],
1675
+ "page_idx": 10
1676
+ },
1677
+ {
1678
+ "type": "text",
1679
+ "text": "Evaluation Steps: ",
1680
+ "text_level": 1,
1681
+ "bbox": [
1682
+ 152,
1683
+ 400,
1684
+ 284,
1685
+ 416
1686
+ ],
1687
+ "page_idx": 10
1688
+ },
1689
+ {
1690
+ "type": "text",
1691
+ "text": "1. Read the news article carefully and identify the main topic and key points. ",
1692
+ "bbox": [
1693
+ 152,
1694
+ 420,
1695
+ 450,
1696
+ 453
1697
+ ],
1698
+ "page_idx": 10
1699
+ },
1700
+ {
1701
+ "type": "text",
1702
+ "text": "2. Read the summary and compare it to the news article. Check if the summary covers the main topic and key points of the news article, and if it presents them in a clear and logical order. ",
1703
+ "bbox": [
1704
+ 152,
1705
+ 458,
1706
+ 450,
1707
+ 537
1708
+ ],
1709
+ "page_idx": 10
1710
+ },
1711
+ {
1712
+ "type": "text",
1713
+ "text": "3. Assign a score for coherence on a scale of 1 to 5, where 1 is the lowest and 5 is the highest based on the Evaluation Criteria. ",
1714
+ "bbox": [
1715
+ 152,
1716
+ 544,
1717
+ 450,
1718
+ 606
1719
+ ],
1720
+ "page_idx": 10
1721
+ },
1722
+ {
1723
+ "type": "text",
1724
+ "text": "Example: Source Text: {{Document}} Summary: {{Summary}} ",
1725
+ "bbox": [
1726
+ 151,
1727
+ 624,
1728
+ 258,
1729
+ 722
1730
+ ],
1731
+ "page_idx": 10
1732
+ },
1733
+ {
1734
+ "type": "text",
1735
+ "text": "Evaluation Form (scores ONLY): - Coherence: ",
1736
+ "bbox": [
1737
+ 151,
1738
+ 739,
1739
+ 396,
1740
+ 775
1741
+ ],
1742
+ "page_idx": 10
1743
+ },
1744
+ {
1745
+ "type": "text",
1746
+ "text": "Evaluate Engagingness in the Dialogue Generation Task ",
1747
+ "text_level": 1,
1748
+ "bbox": [
1749
+ 115,
1750
+ 784,
1751
+ 487,
1752
+ 814
1753
+ ],
1754
+ "page_idx": 10
1755
+ },
1756
+ {
1757
+ "type": "text",
1758
+ "text": "You will be given a conversation between two individuals. You will then be given one potential response for the next turn in the conversation. The response concerns an interesting fact, which will be provided as well. ",
1759
+ "bbox": [
1760
+ 152,
1761
+ 824,
1762
+ 450,
1763
+ 919
1764
+ ],
1765
+ "page_idx": 10
1766
+ },
1767
+ {
1768
+ "type": "text",
1769
+ "text": "Your task is to rate the responses on one metric. ",
1770
+ "bbox": [
1771
+ 549,
1772
+ 85,
1773
+ 843,
1774
+ 115
1775
+ ],
1776
+ "page_idx": 10
1777
+ },
1778
+ {
1779
+ "type": "text",
1780
+ "text": "Please make sure you read and understand these instructions carefully. Please keep this document open while reviewing, and refer to it as needed. ",
1781
+ "bbox": [
1782
+ 549,
1783
+ 122,
1784
+ 847,
1785
+ 185
1786
+ ],
1787
+ "page_idx": 10
1788
+ },
1789
+ {
1790
+ "type": "text",
1791
+ "text": "Evaluation Crieteria: ",
1792
+ "text_level": 1,
1793
+ "bbox": [
1794
+ 549,
1795
+ 203,
1796
+ 707,
1797
+ 217
1798
+ ],
1799
+ "page_idx": 10
1800
+ },
1801
+ {
1802
+ "type": "text",
1803
+ "text": "Engagingness (1-3) Is the response dull/interesting? ",
1804
+ "bbox": [
1805
+ 547,
1806
+ 224,
1807
+ 845,
1808
+ 255
1809
+ ],
1810
+ "page_idx": 10
1811
+ },
1812
+ {
1813
+ "type": "text",
1814
+ "text": "- A score of 1 (dull) means that the response is generic and dull. ",
1815
+ "bbox": [
1816
+ 546,
1817
+ 261,
1818
+ 847,
1819
+ 292
1820
+ ],
1821
+ "page_idx": 10
1822
+ },
1823
+ {
1824
+ "type": "text",
1825
+ "text": "- A score of 2 (somewhat interesting) means the response is somewhat interesting and could engage you in the conversation (e.g., an opinion, thought) ",
1826
+ "bbox": [
1827
+ 547,
1828
+ 298,
1829
+ 847,
1830
+ 361
1831
+ ],
1832
+ "page_idx": 10
1833
+ },
1834
+ {
1835
+ "type": "text",
1836
+ "text": "- A score of 3 (interesting) means the response is very interesting or presents an interesting fact ",
1837
+ "bbox": [
1838
+ 547,
1839
+ 368,
1840
+ 847,
1841
+ 414
1842
+ ],
1843
+ "page_idx": 10
1844
+ },
1845
+ {
1846
+ "type": "text",
1847
+ "text": "Evaluation Steps: ",
1848
+ "text_level": 1,
1849
+ "bbox": [
1850
+ 549,
1851
+ 432,
1852
+ 678,
1853
+ 447
1854
+ ],
1855
+ "page_idx": 10
1856
+ },
1857
+ {
1858
+ "type": "text",
1859
+ "text": "1. Read the conversation, the corresponding fact and the response carefully. ",
1860
+ "bbox": [
1861
+ 547,
1862
+ 454,
1863
+ 847,
1864
+ 485
1865
+ ],
1866
+ "page_idx": 10
1867
+ },
1868
+ {
1869
+ "type": "text",
1870
+ "text": "2. Rate the response on a scale of 1-3 for engagingness, according to the criteria above. ",
1871
+ "bbox": [
1872
+ 547,
1873
+ 491,
1874
+ 845,
1875
+ 537
1876
+ ],
1877
+ "page_idx": 10
1878
+ },
1879
+ {
1880
+ "type": "text",
1881
+ "text": "3. Provide a brief explanation for your rating, referring to specific aspects of the response and the conversation. ",
1882
+ "bbox": [
1883
+ 547,
1884
+ 544,
1885
+ 847,
1886
+ 590
1887
+ ],
1888
+ "page_idx": 10
1889
+ },
1890
+ {
1891
+ "type": "text",
1892
+ "text": "Example: ",
1893
+ "text_level": 1,
1894
+ "bbox": [
1895
+ 549,
1896
+ 609,
1897
+ 620,
1898
+ 624
1899
+ ],
1900
+ "page_idx": 10
1901
+ },
1902
+ {
1903
+ "type": "text",
1904
+ "text": "Conversation History: \n{{Document}} \nCorresponding Fact: \n{{Fact}} \nResponse: \n{{Response}} ",
1905
+ "bbox": [
1906
+ 546,
1907
+ 629,
1908
+ 712,
1909
+ 751
1910
+ ],
1911
+ "page_idx": 10
1912
+ },
1913
+ {
1914
+ "type": "text",
1915
+ "text": "Evaluation Form (scores ONLY): - Engagingness: ",
1916
+ "bbox": [
1917
+ 546,
1918
+ 768,
1919
+ 793,
1920
+ 804
1921
+ ],
1922
+ "page_idx": 10
1923
+ },
1924
+ {
1925
+ "type": "text",
1926
+ "text": "Evaluate Hallucinations ",
1927
+ "text_level": 1,
1928
+ "bbox": [
1929
+ 514,
1930
+ 814,
1931
+ 702,
1932
+ 829
1933
+ ],
1934
+ "page_idx": 10
1935
+ },
1936
+ {
1937
+ "type": "text",
1938
+ "text": "Human Evaluation of Text Summarization Systems: ",
1939
+ "bbox": [
1940
+ 547,
1941
+ 840,
1942
+ 847,
1943
+ 870
1944
+ ],
1945
+ "page_idx": 10
1946
+ },
1947
+ {
1948
+ "type": "text",
1949
+ "text": "Factual Consistency: Does the summary untruthful or misleading facts that are not supported by the source text? ",
1950
+ "bbox": [
1951
+ 547,
1952
+ 888,
1953
+ 845,
1954
+ 919
1955
+ ],
1956
+ "page_idx": 10
1957
+ },
1958
+ {
1959
+ "type": "text",
1960
+ "text": "",
1961
+ "bbox": [
1962
+ 154,
1963
+ 85,
1964
+ 448,
1965
+ 99
1966
+ ],
1967
+ "page_idx": 11
1968
+ },
1969
+ {
1970
+ "type": "text",
1971
+ "text": "Source Text: {{Document}} Summary: {{Summary}} ",
1972
+ "bbox": [
1973
+ 151,
1974
+ 117,
1975
+ 258,
1976
+ 197
1977
+ ],
1978
+ "page_idx": 11
1979
+ },
1980
+ {
1981
+ "type": "text",
1982
+ "text": "Does the summary contain factual inconsistency? ",
1983
+ "bbox": [
1984
+ 152,
1985
+ 214,
1986
+ 452,
1987
+ 244
1988
+ ],
1989
+ "page_idx": 11
1990
+ },
1991
+ {
1992
+ "type": "text",
1993
+ "text": "Answer: ",
1994
+ "bbox": [
1995
+ 152,
1996
+ 252,
1997
+ 215,
1998
+ 265
1999
+ ],
2000
+ "page_idx": 11
2001
+ }
2002
+ ]
parse/dev/qhu9uX4QlP8/qhu9uX4QlP8_content_list.json ADDED
The diff for this file is too large to render. See raw diff
 
parse/dev/qhu9uX4QlP8/qhu9uX4QlP8_model.json ADDED
The diff for this file is too large to render. See raw diff
 
parse/dev/yJE7iQSAep/yJE7iQSAep_middle.json ADDED
The diff for this file is too large to render. See raw diff