ZHANGYUXUAN-zR commited on
Commit
18f66a9
·
verified ·
1 Parent(s): 1ef610f

Add files using upload-large-folder tool

Browse files
This view is limited to 50 files because it contains too many changes.   See raw diff
Files changed (50) hide show
  1. .gitattributes +111 -0
  2. parse/train/1XwPDFrJObw/1XwPDFrJObw_layout.pdf +3 -0
  3. parse/train/1XwPDFrJObw/1XwPDFrJObw_origin.pdf +3 -0
  4. parse/train/1XwPDFrJObw/1XwPDFrJObw_span.pdf +3 -0
  5. parse/train/5KWmB6JePx/5KWmB6JePx.md +357 -0
  6. parse/train/5KWmB6JePx/5KWmB6JePx_content_list.json +1720 -0
  7. parse/train/5KWmB6JePx/5KWmB6JePx_middle.json +0 -0
  8. parse/train/5KWmB6JePx/5KWmB6JePx_model.json +0 -0
  9. parse/train/6OoCDvFV4m/6OoCDvFV4m_layout.pdf +3 -0
  10. parse/train/6OoCDvFV4m/6OoCDvFV4m_origin.pdf +3 -0
  11. parse/train/6OoCDvFV4m/6OoCDvFV4m_span.pdf +3 -0
  12. parse/train/B1ckMDqlg/B1ckMDqlg_layout.pdf +3 -0
  13. parse/train/B1ckMDqlg/B1ckMDqlg_origin.pdf +3 -0
  14. parse/train/B1ckMDqlg/B1ckMDqlg_span.pdf +3 -0
  15. parse/train/B1g8VkHFPH/B1g8VkHFPH.md +343 -0
  16. parse/train/B1g8VkHFPH/B1g8VkHFPH_content_list.json +1812 -0
  17. parse/train/B1g8VkHFPH/B1g8VkHFPH_middle.json +0 -0
  18. parse/train/B1g8VkHFPH/B1g8VkHFPH_model.json +0 -0
  19. parse/train/BJgQfkSYDS/BJgQfkSYDS_layout.pdf +3 -0
  20. parse/train/BJgQfkSYDS/BJgQfkSYDS_origin.pdf +3 -0
  21. parse/train/BJgQfkSYDS/BJgQfkSYDS_span.pdf +3 -0
  22. parse/train/BJlVeyHFwH/BJlVeyHFwH_layout.pdf +3 -0
  23. parse/train/BJlVeyHFwH/BJlVeyHFwH_origin.pdf +3 -0
  24. parse/train/BJlVeyHFwH/BJlVeyHFwH_span.pdf +3 -0
  25. parse/train/BJlZ5ySKPH/BJlZ5ySKPH_layout.pdf +3 -0
  26. parse/train/BJlZ5ySKPH/BJlZ5ySKPH_origin.pdf +3 -0
  27. parse/train/BJlZ5ySKPH/BJlZ5ySKPH_span.pdf +3 -0
  28. parse/train/Bkxbrn0cYX/Bkxbrn0cYX_layout.pdf +3 -0
  29. parse/train/Bkxbrn0cYX/Bkxbrn0cYX_origin.pdf +3 -0
  30. parse/train/Bkxbrn0cYX/Bkxbrn0cYX_span.pdf +3 -0
  31. parse/train/Byey7n05FQ/Byey7n05FQ_layout.pdf +3 -0
  32. parse/train/Byey7n05FQ/Byey7n05FQ_origin.pdf +3 -0
  33. parse/train/Byey7n05FQ/Byey7n05FQ_span.pdf +3 -0
  34. parse/train/D2TE6VTJG9/D2TE6VTJG9_span.pdf +3 -0
  35. parse/train/DNl5s5BXeBn/DNl5s5BXeBn_layout.pdf +3 -0
  36. parse/train/DNl5s5BXeBn/DNl5s5BXeBn_origin.pdf +3 -0
  37. parse/train/DNl5s5BXeBn/DNl5s5BXeBn_span.pdf +3 -0
  38. parse/train/Ec85b0tUwbA/Ec85b0tUwbA_layout.pdf +3 -0
  39. parse/train/Ec85b0tUwbA/Ec85b0tUwbA_origin.pdf +3 -0
  40. parse/train/Ec85b0tUwbA/Ec85b0tUwbA_span.pdf +3 -0
  41. parse/train/FjnCWyzXu8m/FjnCWyzXu8m_layout.pdf +3 -0
  42. parse/train/FjnCWyzXu8m/FjnCWyzXu8m_origin.pdf +3 -0
  43. parse/train/FjnCWyzXu8m/FjnCWyzXu8m_span.pdf +3 -0
  44. parse/train/H1q-TM-AW/H1q-TM-AW_layout.pdf +3 -0
  45. parse/train/H1q-TM-AW/H1q-TM-AW_origin.pdf +3 -0
  46. parse/train/H1q-TM-AW/H1q-TM-AW_span.pdf +3 -0
  47. parse/train/HJMC_iA5tm/HJMC_iA5tm_layout.pdf +3 -0
  48. parse/train/HJMC_iA5tm/HJMC_iA5tm_origin.pdf +3 -0
  49. parse/train/HJMC_iA5tm/HJMC_iA5tm_span.pdf +3 -0
  50. parse/train/Hk95PK9le/Hk95PK9le.md +162 -0
.gitattributes CHANGED
@@ -15197,3 +15197,114 @@ parse/train/6vaActvpcp3/6vaActvpcp3_layout.pdf filter=lfs diff=lfs merge=lfs -te
15197
  parse/train/6vaActvpcp3/6vaActvpcp3_origin.pdf filter=lfs diff=lfs merge=lfs -text
15198
  parse/train/D2TE6VTJG9/D2TE6VTJG9_layout.pdf filter=lfs diff=lfs merge=lfs -text
15199
  parse/train/D2TE6VTJG9/D2TE6VTJG9_origin.pdf filter=lfs diff=lfs merge=lfs -text
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
15197
  parse/train/6vaActvpcp3/6vaActvpcp3_origin.pdf filter=lfs diff=lfs merge=lfs -text
15198
  parse/train/D2TE6VTJG9/D2TE6VTJG9_layout.pdf filter=lfs diff=lfs merge=lfs -text
15199
  parse/train/D2TE6VTJG9/D2TE6VTJG9_origin.pdf filter=lfs diff=lfs merge=lfs -text
15200
+ parse/train/D2TE6VTJG9/D2TE6VTJG9_span.pdf filter=lfs diff=lfs merge=lfs -text
15201
+ parse/train/H1q-TM-AW/H1q-TM-AW_span.pdf filter=lfs diff=lfs merge=lfs -text
15202
+ parse/train/H1q-TM-AW/H1q-TM-AW_layout.pdf filter=lfs diff=lfs merge=lfs -text
15203
+ parse/train/H1q-TM-AW/H1q-TM-AW_origin.pdf filter=lfs diff=lfs merge=lfs -text
15204
+ parse/train/bMCfFepJXM/bMCfFepJXM_span.pdf filter=lfs diff=lfs merge=lfs -text
15205
+ parse/train/bMCfFepJXM/bMCfFepJXM_origin.pdf filter=lfs diff=lfs merge=lfs -text
15206
+ parse/train/bMCfFepJXM/bMCfFepJXM_layout.pdf filter=lfs diff=lfs merge=lfs -text
15207
+ parse/train/BJlVeyHFwH/BJlVeyHFwH_span.pdf filter=lfs diff=lfs merge=lfs -text
15208
+ parse/train/BJlVeyHFwH/BJlVeyHFwH_layout.pdf filter=lfs diff=lfs merge=lfs -text
15209
+ parse/train/BJlVeyHFwH/BJlVeyHFwH_origin.pdf filter=lfs diff=lfs merge=lfs -text
15210
+ parse/train/Bkxbrn0cYX/Bkxbrn0cYX_span.pdf filter=lfs diff=lfs merge=lfs -text
15211
+ parse/train/Bkxbrn0cYX/Bkxbrn0cYX_layout.pdf filter=lfs diff=lfs merge=lfs -text
15212
+ parse/train/Bkxbrn0cYX/Bkxbrn0cYX_origin.pdf filter=lfs diff=lfs merge=lfs -text
15213
+ parse/train/nMefdZyJ7ie/nMefdZyJ7ie_layout.pdf filter=lfs diff=lfs merge=lfs -text
15214
+ parse/train/nMefdZyJ7ie/nMefdZyJ7ie_origin.pdf filter=lfs diff=lfs merge=lfs -text
15215
+ parse/train/nMefdZyJ7ie/nMefdZyJ7ie_span.pdf filter=lfs diff=lfs merge=lfs -text
15216
+ parse/train/Ec85b0tUwbA/Ec85b0tUwbA_layout.pdf filter=lfs diff=lfs merge=lfs -text
15217
+ parse/train/Ec85b0tUwbA/Ec85b0tUwbA_origin.pdf filter=lfs diff=lfs merge=lfs -text
15218
+ parse/train/Ec85b0tUwbA/Ec85b0tUwbA_span.pdf filter=lfs diff=lfs merge=lfs -text
15219
+ parse/train/BJgQfkSYDS/BJgQfkSYDS_span.pdf filter=lfs diff=lfs merge=lfs -text
15220
+ parse/train/BJgQfkSYDS/BJgQfkSYDS_origin.pdf filter=lfs diff=lfs merge=lfs -text
15221
+ parse/train/BJgQfkSYDS/BJgQfkSYDS_layout.pdf filter=lfs diff=lfs merge=lfs -text
15222
+ parse/train/HJMC_iA5tm/HJMC_iA5tm_layout.pdf filter=lfs diff=lfs merge=lfs -text
15223
+ parse/train/HJMC_iA5tm/HJMC_iA5tm_span.pdf filter=lfs diff=lfs merge=lfs -text
15224
+ parse/train/HJMC_iA5tm/HJMC_iA5tm_origin.pdf filter=lfs diff=lfs merge=lfs -text
15225
+ parse/train/gIHd-5X324/gIHd-5X324_origin.pdf filter=lfs diff=lfs merge=lfs -text
15226
+ parse/train/gIHd-5X324/gIHd-5X324_span.pdf filter=lfs diff=lfs merge=lfs -text
15227
+ parse/train/gIHd-5X324/gIHd-5X324_layout.pdf filter=lfs diff=lfs merge=lfs -text
15228
+ parse/train/O358nrve1W/O358nrve1W_layout.pdf filter=lfs diff=lfs merge=lfs -text
15229
+ parse/train/O358nrve1W/O358nrve1W_origin.pdf filter=lfs diff=lfs merge=lfs -text
15230
+ parse/train/O358nrve1W/O358nrve1W_span.pdf filter=lfs diff=lfs merge=lfs -text
15231
+ parse/train/r14EOsCqKX/r14EOsCqKX_origin.pdf filter=lfs diff=lfs merge=lfs -text
15232
+ parse/train/r14EOsCqKX/r14EOsCqKX_layout.pdf filter=lfs diff=lfs merge=lfs -text
15233
+ parse/train/r14EOsCqKX/r14EOsCqKX_span.pdf filter=lfs diff=lfs merge=lfs -text
15234
+ parse/train/rkeqn1rtDH/rkeqn1rtDH_layout.pdf filter=lfs diff=lfs merge=lfs -text
15235
+ parse/train/rkeqn1rtDH/rkeqn1rtDH_origin.pdf filter=lfs diff=lfs merge=lfs -text
15236
+ parse/train/rkeqn1rtDH/rkeqn1rtDH_span.pdf filter=lfs diff=lfs merge=lfs -text
15237
+ parse/train/e5vrkfc5aau/e5vrkfc5aau_layout.pdf filter=lfs diff=lfs merge=lfs -text
15238
+ parse/train/e5vrkfc5aau/e5vrkfc5aau_origin.pdf filter=lfs diff=lfs merge=lfs -text
15239
+ parse/train/e5vrkfc5aau/e5vrkfc5aau_span.pdf filter=lfs diff=lfs merge=lfs -text
15240
+ parse/train/Byey7n05FQ/Byey7n05FQ_origin.pdf filter=lfs diff=lfs merge=lfs -text
15241
+ parse/train/Byey7n05FQ/Byey7n05FQ_layout.pdf filter=lfs diff=lfs merge=lfs -text
15242
+ parse/train/Byey7n05FQ/Byey7n05FQ_span.pdf filter=lfs diff=lfs merge=lfs -text
15243
+ parse/train/BJlZ5ySKPH/BJlZ5ySKPH_layout.pdf filter=lfs diff=lfs merge=lfs -text
15244
+ parse/train/BJlZ5ySKPH/BJlZ5ySKPH_origin.pdf filter=lfs diff=lfs merge=lfs -text
15245
+ parse/train/BJlZ5ySKPH/BJlZ5ySKPH_span.pdf filter=lfs diff=lfs merge=lfs -text
15246
+ parse/train/r1lPleBFvH/r1lPleBFvH_origin.pdf filter=lfs diff=lfs merge=lfs -text
15247
+ parse/train/r1lPleBFvH/r1lPleBFvH_span.pdf filter=lfs diff=lfs merge=lfs -text
15248
+ parse/train/r1lPleBFvH/r1lPleBFvH_layout.pdf filter=lfs diff=lfs merge=lfs -text
15249
+ parse/train/ryenvpEKDr/ryenvpEKDr_origin.pdf filter=lfs diff=lfs merge=lfs -text
15250
+ parse/train/ryenvpEKDr/ryenvpEKDr_span.pdf filter=lfs diff=lfs merge=lfs -text
15251
+ parse/train/ryenvpEKDr/ryenvpEKDr_layout.pdf filter=lfs diff=lfs merge=lfs -text
15252
+ parse/train/HkeSdCEtDS/HkeSdCEtDS_layout.pdf filter=lfs diff=lfs merge=lfs -text
15253
+ parse/train/HkeSdCEtDS/HkeSdCEtDS_origin.pdf filter=lfs diff=lfs merge=lfs -text
15254
+ parse/train/HkeSdCEtDS/HkeSdCEtDS_span.pdf filter=lfs diff=lfs merge=lfs -text
15255
+ parse/train/B1ckMDqlg/B1ckMDqlg_span.pdf filter=lfs diff=lfs merge=lfs -text
15256
+ parse/train/B1ckMDqlg/B1ckMDqlg_origin.pdf filter=lfs diff=lfs merge=lfs -text
15257
+ parse/train/B1ckMDqlg/B1ckMDqlg_layout.pdf filter=lfs diff=lfs merge=lfs -text
15258
+ parse/train/Kloou2uk_Rz/Kloou2uk_Rz_origin.pdf filter=lfs diff=lfs merge=lfs -text
15259
+ parse/train/Kloou2uk_Rz/Kloou2uk_Rz_span.pdf filter=lfs diff=lfs merge=lfs -text
15260
+ parse/train/Kloou2uk_Rz/Kloou2uk_Rz_layout.pdf filter=lfs diff=lfs merge=lfs -text
15261
+ parse/train/HklBjCEKvH/HklBjCEKvH_origin.pdf filter=lfs diff=lfs merge=lfs -text
15262
+ parse/train/HklBjCEKvH/HklBjCEKvH_layout.pdf filter=lfs diff=lfs merge=lfs -text
15263
+ parse/train/HklBjCEKvH/HklBjCEKvH_span.pdf filter=lfs diff=lfs merge=lfs -text
15264
+ parse/train/chPj_I5KMHG/chPj_I5KMHG_span.pdf filter=lfs diff=lfs merge=lfs -text
15265
+ parse/train/chPj_I5KMHG/chPj_I5KMHG_origin.pdf filter=lfs diff=lfs merge=lfs -text
15266
+ parse/train/chPj_I5KMHG/chPj_I5KMHG_layout.pdf filter=lfs diff=lfs merge=lfs -text
15267
+ parse/train/Q2iaAc-4I1v/Q2iaAc-4I1v_layout.pdf filter=lfs diff=lfs merge=lfs -text
15268
+ parse/train/Q2iaAc-4I1v/Q2iaAc-4I1v_origin.pdf filter=lfs diff=lfs merge=lfs -text
15269
+ parse/train/Q2iaAc-4I1v/Q2iaAc-4I1v_span.pdf filter=lfs diff=lfs merge=lfs -text
15270
+ parse/train/Skvd-myR-/Skvd-myR-_layout.pdf filter=lfs diff=lfs merge=lfs -text
15271
+ parse/train/Skvd-myR-/Skvd-myR-_span.pdf filter=lfs diff=lfs merge=lfs -text
15272
+ parse/train/Skvd-myR-/Skvd-myR-_origin.pdf filter=lfs diff=lfs merge=lfs -text
15273
+ parse/train/SyxrxR4KPS/SyxrxR4KPS_span.pdf filter=lfs diff=lfs merge=lfs -text
15274
+ parse/train/SyxrxR4KPS/SyxrxR4KPS_origin.pdf filter=lfs diff=lfs merge=lfs -text
15275
+ parse/train/SyxrxR4KPS/SyxrxR4KPS_layout.pdf filter=lfs diff=lfs merge=lfs -text
15276
+ parse/train/6OoCDvFV4m/6OoCDvFV4m_span.pdf filter=lfs diff=lfs merge=lfs -text
15277
+ parse/train/6OoCDvFV4m/6OoCDvFV4m_origin.pdf filter=lfs diff=lfs merge=lfs -text
15278
+ parse/train/6OoCDvFV4m/6OoCDvFV4m_layout.pdf filter=lfs diff=lfs merge=lfs -text
15279
+ parse/train/OdklztJBBYH/OdklztJBBYH_layout.pdf filter=lfs diff=lfs merge=lfs -text
15280
+ parse/train/OdklztJBBYH/OdklztJBBYH_origin.pdf filter=lfs diff=lfs merge=lfs -text
15281
+ parse/train/OdklztJBBYH/OdklztJBBYH_span.pdf filter=lfs diff=lfs merge=lfs -text
15282
+ parse/train/oXSw7laxwUpln/oXSw7laxwUpln_span.pdf filter=lfs diff=lfs merge=lfs -text
15283
+ parse/train/oXSw7laxwUpln/oXSw7laxwUpln_layout.pdf filter=lfs diff=lfs merge=lfs -text
15284
+ parse/train/oXSw7laxwUpln/oXSw7laxwUpln_origin.pdf filter=lfs diff=lfs merge=lfs -text
15285
+ parse/train/FjnCWyzXu8m/FjnCWyzXu8m_origin.pdf filter=lfs diff=lfs merge=lfs -text
15286
+ parse/train/FjnCWyzXu8m/FjnCWyzXu8m_span.pdf filter=lfs diff=lfs merge=lfs -text
15287
+ parse/train/FjnCWyzXu8m/FjnCWyzXu8m_layout.pdf filter=lfs diff=lfs merge=lfs -text
15288
+ parse/train/HyxoX6EKvB/HyxoX6EKvB_span.pdf filter=lfs diff=lfs merge=lfs -text
15289
+ parse/train/HyxoX6EKvB/HyxoX6EKvB_origin.pdf filter=lfs diff=lfs merge=lfs -text
15290
+ parse/train/HyxoX6EKvB/HyxoX6EKvB_layout.pdf filter=lfs diff=lfs merge=lfs -text
15291
+ parse/train/1XwPDFrJObw/1XwPDFrJObw_span.pdf filter=lfs diff=lfs merge=lfs -text
15292
+ parse/train/1XwPDFrJObw/1XwPDFrJObw_layout.pdf filter=lfs diff=lfs merge=lfs -text
15293
+ parse/train/1XwPDFrJObw/1XwPDFrJObw_origin.pdf filter=lfs diff=lfs merge=lfs -text
15294
+ parse/train/r1ZdKJ-0W/r1ZdKJ-0W_layout.pdf filter=lfs diff=lfs merge=lfs -text
15295
+ parse/train/r1ZdKJ-0W/r1ZdKJ-0W_origin.pdf filter=lfs diff=lfs merge=lfs -text
15296
+ parse/train/r1ZdKJ-0W/r1ZdKJ-0W_span.pdf filter=lfs diff=lfs merge=lfs -text
15297
+ parse/train/DNl5s5BXeBn/DNl5s5BXeBn_span.pdf filter=lfs diff=lfs merge=lfs -text
15298
+ parse/train/DNl5s5BXeBn/DNl5s5BXeBn_origin.pdf filter=lfs diff=lfs merge=lfs -text
15299
+ parse/train/DNl5s5BXeBn/DNl5s5BXeBn_layout.pdf filter=lfs diff=lfs merge=lfs -text
15300
+ parse/train/Syg-YfWCW/Syg-YfWCW_origin.pdf filter=lfs diff=lfs merge=lfs -text
15301
+ parse/train/Syg-YfWCW/Syg-YfWCW_layout.pdf filter=lfs diff=lfs merge=lfs -text
15302
+ parse/train/Syg-YfWCW/Syg-YfWCW_span.pdf filter=lfs diff=lfs merge=lfs -text
15303
+ parse/train/rkxmPgrKwB/rkxmPgrKwB_origin.pdf filter=lfs diff=lfs merge=lfs -text
15304
+ parse/train/rkxmPgrKwB/rkxmPgrKwB_span.pdf filter=lfs diff=lfs merge=lfs -text
15305
+ parse/train/rkxmPgrKwB/rkxmPgrKwB_layout.pdf filter=lfs diff=lfs merge=lfs -text
15306
+ parse/train/dmCL033_YwO/dmCL033_YwO_span.pdf filter=lfs diff=lfs merge=lfs -text
15307
+ parse/train/dmCL033_YwO/dmCL033_YwO_layout.pdf filter=lfs diff=lfs merge=lfs -text
15308
+ parse/train/dmCL033_YwO/dmCL033_YwO_origin.pdf filter=lfs diff=lfs merge=lfs -text
15309
+ parse/train/SJxzFySKwH/SJxzFySKwH_span.pdf filter=lfs diff=lfs merge=lfs -text
15310
+ parse/train/SJxzFySKwH/SJxzFySKwH_origin.pdf filter=lfs diff=lfs merge=lfs -text
parse/train/1XwPDFrJObw/1XwPDFrJObw_layout.pdf ADDED
@@ -0,0 +1,3 @@
 
 
 
 
1
+ version https://git-lfs.github.com/spec/v1
2
+ oid sha256:098d8f1ecb89aba5098d04499949d62d3d63ed0ce801a1c29ae9afd7c0ce3441
3
+ size 826163
parse/train/1XwPDFrJObw/1XwPDFrJObw_origin.pdf ADDED
@@ -0,0 +1,3 @@
 
 
 
 
1
+ version https://git-lfs.github.com/spec/v1
2
+ oid sha256:47b8e6fd081dceaf324170e51fb12ebbc867b9ca0d63327dc664eba61c76eae5
3
+ size 522902
parse/train/1XwPDFrJObw/1XwPDFrJObw_span.pdf ADDED
@@ -0,0 +1,3 @@
 
 
 
 
1
+ version https://git-lfs.github.com/spec/v1
2
+ oid sha256:4f0c073bd43c1bdfbbed4a6e7f4d7c2d800b81f00cfc5b21797162418825d4be
3
+ size 840471
parse/train/5KWmB6JePx/5KWmB6JePx.md ADDED
@@ -0,0 +1,357 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ # End-to-End Training of Multi-Document Reader and Retriever for Open-Domain Question Answering
2
+
3
+ Devendra Singh Sachan1,2, Siva Reddy1,2, William Hamilton1,2, Chris Dyer3, Dani Yogatama3
4
+
5
+ 1Mila - Quebec AI Institute 2School of Computer Science, McGill University 3DeepMind sachande@mila.quebec, {siva, wlh}@cs.mcgill.ca {cdyer, dyogatama}@deepmind.com
6
+
7
+ # Abstract
8
+
9
+ We present an end-to-end differentiable training method for retrieval-augmented open-domain question answering systems that combine information from multiple retrieved documents when generating answers. We model retrieval decisions as latent variables over sets of relevant documents. Since marginalizing over sets of retrieved documents is computationally hard, we approximate this using an expectation-maximization algorithm. We iteratively estimate the value of our latent variable (the set of relevant documents for a given question) and then use this estimate to update the retriever and reader parameters. We hypothesize that such end-to-end training allows training signals to flow to the reader and then to the retriever better than stage-wise training. This results in a retriever that is able to select more relevant documents for a question and a reader that is trained on more accurate documents to generate an answer. Experiments on three benchmark datasets demonstrate that our proposed method outperforms all existing approaches of comparable size by 2-3 absolute exact match points, achieving new state-of-theart results. Our results also demonstrate the feasibility of learning to retrieve to improve answer generation without explicit supervision of retrieval decisions.
10
+
11
+ # 1 Introduction
12
+
13
+ Open-domain question answering (OpenQA) is a question answering task where the goal is to train a language model to produce an answer for a given question. In contrast to many question answering tasks, an OpenQA model is only provided with the question as its input without accompanying documents that contain the answer. One of the most promising approaches to OpenQA is based on augmenting the language model with an external knowledge source such as Wikipedia (often referred to as the evidence documents). In this approach, the model consists of two core components (Chen et al., 2017): (i) an information retrieval system to identify useful pieces of text from the knowledge source (the retriever); and (ii) a system to produce the answer given the retrieved documents and the question (the reader).
14
+
15
+ We can view such a model as a latent variable model, where the latent variables represent retrieved documents that are used to produce answers given questions (Lee et al., 2019). End-to-end (joint) training of this model is challenging since we need to learn both to generate an answer given retrieved documents and what to retrieve. Previous work considers two potential solutions (see Table 1 for a high-level summary). First, they adopt a stage-wise training, where the retriever is trained while freezing the reader and vice versa (Karpukhin et al., 2020, Izacard and Grave, 2021b,a). Another alternative is to constraint the reader to condition on each retrieved document individually1 (Guu et al., 2020)—sometimes with extra supervision for the latent variables in the form of the relevant document for a question (Lewis et al., 2020b).
16
+
17
+ Table 1: Bird’s-eye view of the recent OpenQA approaches. Multi-Doc reader indicates whether the reader architecture uses multiple documents or a single document. Retriever adaptation shows whether the retriever gets feedback from the reader to update its parameters. Disjoint denotes that first the retriever is trained and then the reader is trained. End-to-end denotes that the reader and retriever are trained jointly in one cycle. Multi-step indicates that the reader and retriever are trained iteratively in multiple cycles. Unsupervised retriever indicates whether the retriever is initialized using unsupervised approaches or using supervised data.
18
+
19
+ <table><tr><td></td><td colspan="5">Reader and Retriever Training</td></tr><tr><td>Model</td><td>Multi-Doc Reader</td><td>Retriever Adaptation</td><td>Disjoint End-to-End Multi-Step Unsupervised</td><td></td><td>Retriever</td></tr><tr><td>REALM (Guu et al., 2020)</td><td></td><td>√</td><td></td><td></td><td>√</td></tr><tr><td>DPR (Karpukhin et al., 2020)</td><td></td><td></td><td>√</td><td></td><td></td></tr><tr><td>RAG (Lewis et al., 2020b)</td><td></td><td>√</td><td></td><td></td><td></td></tr><tr><td>FiD (Izacard and Grave, 2021b)</td><td></td><td></td><td>√</td><td></td><td></td></tr><tr><td>FiD-KD (Izacard and Grave, 2021a)</td><td>√</td><td>√</td><td></td><td>√</td><td></td></tr><tr><td>EMDR² (Our Approach)</td><td>√</td><td>√</td><td>√</td><td></td><td>√</td></tr></table>
20
+
21
+ In this paper, we consider a retrieval-augmented question answering model that combines information from multiple documents when generating answers. Expectation-maximization (Dempster et al., 1977) offers a principled template for learning this class of latent variable models. We present EMDR2: End-to-end training of Multi-Document Reader and Retriever (§2). EMDR2 iteratively uses feedback from the model itself as “pseudo labels” of the latent variables for optimizing the retriever and reader parameters. We use two estimates of the latent variables: (i) prior scores for updating the reader parameters and (ii) approximate posterior scores given all observed variables for the retriever parameters.
22
+
23
+ We evaluate our proposed method by experimenting on three commonly used OpenQA datasets: Natural Questions, TriviaQA, and WebQuestions (§3). EMDR2 achieves new state-of-the-art results for models of comparable size on all datasets, outperforming recent approaches by 2-3 absolute exact match points. We also show that EMDR2 is robust to retriever initialization. It achieves high accuracy with unsupervised initialization, suggesting that supervised training of the retriever may not be an essential component of the training process as suggested in prior work (Karpukhin et al., 2020).
24
+
25
+ In summary, our contributions are as follows: (i) we present an end-to-end training method $( \mathrm { E M D R } ^ { 2 } $ ) for retrieval-augmented question-answering systems; (ii) we demonstrate that $\mathrm { E M D R ^ { 2 } }$ outperforms other existing approaches of comparable size without any kind of supervision on the latent variables; (iii) we provide ablation studies for a better understanding of the contributions of different components of our proposed method; and (iv) we release our code and checkpoints to facilitate future work and for reproducibility.2
26
+
27
+ EMDR2 is a framework that can be used to train retrieval-augmented text generation models for any task. We believe that our estimation technique in EMDR2 is also useful for learning similar latent variable models in other domains.
28
+
29
+ # 2 Model
30
+
31
+ Our proposed model EMDR2 consists of two components: (i) a neural retriever and (ii) a neural reader, which we train jointly in an end-to-end setting. Figure 1 shows an illustration of our model and training procedure. We discuss each component and our training objective in detail below.
32
+
33
+ # 2.1 Neural Retriever: Dual Encoder
34
+
35
+ Let the collection of evidence documents be denoted by $\mathcal { D } = \{ d _ { 1 } , \hdots , d _ { M } \}$ . Given a question $\pmb q$ the goal of the retriever module is to select a subset of documents $\mathcal { Z } \subset \mathcal { D }$ to answer the question. We model the retriever as a dual-encoder network (Bromley et al., 1994), where one encoder $f _ { q }$ encodes the question and another $f _ { d }$ encodes the evidence document (to a vector). The retrieval score is defined as the dot product between the two resulting vectors:
36
+
37
+ $$
38
+ \begin{array} { r } { \mathrm { s c o r e } ( \pmb { q } , \pmb { d } _ { i } ; \Phi ) = { f } _ { \ b { q } } ( \pmb { q } ; \Phi _ { q } ) ^ { \top } { f } _ { d } ( \pmb { d } _ { i } ; \Phi _ { d } ) , } \end{array}
39
+ $$
40
+
41
+ where $\Phi = [ \Phi _ { q } , \Phi _ { d } ]$ denotes the retriever parameters. We select top- $K$ documents for the question $\pmb q$ from $\mathcal { D }$ based on the retrieval scores. We denote the set of retrieved documents by $\mathcal { Z } = \{ z _ { 1 } , \ldots , z _ { K } \}$
42
+
43
+ We use transformer encoders (Vaswani et al., 2017) as our $f _ { q }$ and $f _ { d }$ . Our transformer architecture is similar to BERT with 12 layers and 768 hidden size (Devlin et al., 2019). We use the final representation of the first token (i.e., the standard [CLS] token from BERT’s tokenization) as our question (and similarly document) embedding. Initializing $f _ { q }$ and $f _ { d }$ with BERT weights has been shown to lead to a poor retrieval accuracy (Lee et al., 2019, Sachan et al., 2021). Therefore, we initialize the retriever with an unsupervised training procedure. We discuss our initialization technique in detail in $\ S$ .
44
+
45
+ # 2.2 Neural Reader: Fusion-in-Decoder
46
+
47
+ The reader takes as input a question $\pmb q$ and a set of retrieved documents (to be read) $\mathcal { Z }$ to generate an answer. Our reader is based on the Fusion-in-Decoder (FiD; Izacard and Grave, 2021b) model, which is built on top of T5 (Raffel et al., 2020). T5 is a pretrained sequence-to-sequence transformer that consists of an encoder $g _ { e }$ and a decoder $g _ { d }$ .
48
+
49
+ In FiD, each retrieved document $z _ { k }$ is first appended with its title $( t _ { z _ { k } } )$ and the question:
50
+
51
+ $$
52
+ \pmb { x } _ { k } = [ \mathbb { C } \mathrm { L S } ] \pmb { q } [ \mathrm { S E P } ] \pmb { t } _ { z _ { k } } [ \mathrm { S E P } ] \pmb { z } _ { k } [ \mathrm { S E P } ] ,
53
+ $$
54
+
55
+ where [CLS] is used to indicate the start of a document and [SEP] is used as a separator for the different parts of the document as well as the final token.
56
+
57
+ Each $\scriptstyle { \mathbf { { \mathit { x } } } } _ { k }$ is then independently given as an input to the T5 encoder $g _ { e }$ . The output representations corresponding to all of the retrieved documents are concatenated as:
58
+
59
+ $$
60
+ { \bf X } _ { \mathcal { Z } } = [ g _ { e } ( { \pmb x } _ { 1 } ) ; \dots ; g _ { e } ( { \pmb x } _ { K } ) ] \in \mathbb { R } ^ { ( N \times K ) \times H } ,
61
+ $$
62
+
63
+ where $N$ is the number of tokens in each ${ \pmb x } _ { k } { } ^ { 3 }$ and $H$ is the hidden size of the T5 encoder $g _ { e }$ . In this work, we use the T5-base configuration with $N = 5 1 2$ and $H = 7 6 8$ .
64
+
65
+ $\mathbf { X } _ { \mathcal { Z } }$ is then given as an input to the T5 decoder $g _ { d }$ . When generating an answer token, the decoder attends to both previously generated tokens (i.e., causal attention) as well as the tokens encoded in $\mathbf { X } _ { \mathcal { Z } }$ (i.e., cross attention). Since $\mathbf { X } _ { \mathcal { Z } }$ contains information from multiple documents, the decoder has the ability to aggregate useful signals contained in multiple documents and jointly reason over them. We define the probability of the answer as:
66
+
67
+ $$
68
+ p ( \pmb { a } \mid \pmb { q } , \mathcal { Z } ; \Theta ) = \prod _ { t = 1 } ^ { T } p \left( a _ { t } \mid \pmb { a } _ { < t } , \pmb { q } , \mathcal { Z } ; \Theta \right) ,
69
+ $$
70
+
71
+ where $\Theta$ denotes the reader parameters (i.e., T5 encoder and decoder) and $T$ is the number of answer tokens. We keep generating answer tokens until the decoder outputs a special EOS token or a pre-specified maximum answer length is reached.
72
+
73
+ # 2.3 End-to-End Training of Reader and Retriever
74
+
75
+ In contrast to previous work on generative question answering, we train both the reader and the retriever jointly in an end-to-end differentiable fashion.
76
+
77
+ Denote our latent variable which represents a set of retrieved documents by $Z$ and let $\mathcal { Z }$ be a possible value of $Z$ . The marginal likelihood of an answer (marginalizing over all the possible values of $Z$ )
78
+
79
+ ![](images/9e2662a32c5c5501904bf0ea417bf805daa3f201c7eef57857b0fdb3b1cf1efa.jpg)
80
+ Figure 1: An illustration of the different components of $\mathrm { E M D R } ^ { 2 }$ . Colored blocks indicate components which contain trainable parameters.
81
+
82
+ is: $\begin{array} { r } { p ( \pmb { a } \mid q ; \Theta , \Phi ) = \sum _ { Z = \mathcal { Z } } p ( \pmb { a } \mid q , \mathcal { Z } ; \Theta ) p ( \mathcal { Z } \mid q ; \Phi ) } \end{array}$ . The goal of our training procedure is to find $\Phi$ and $\Theta$ Z that would maximize the above objective. Exactly optimizing Eq. 3 is intractable as it is combinatorial in nature.4 For one particular value $\mathcal { Z }$ , the log-likelihood is simpler to compute: $\log p ( { \pmb a } \mid { \pmb q } , { \mathcal Z } ; { \Theta } ) p ( { \mathcal Z } \mid { \pmb q } ; { \Phi } ) = \log p ( { \pmb a } \mid { \pmb q } , { \mathcal Z } ; { \Theta } ) + \log p ( { \mathcal Z } \mid { \pmb q } ; { \Phi } )$
83
+
84
+ Expectation-maximization (EM) algorithm (Dempster et al., 1977) offers a solution to learning this latent variable model. In classical EM, we iteratively compute the posterior of $Z$ given all observed variables and use it to update $\Theta$ and $\Phi$ .
85
+
86
+ We propose using two estimates of $Z { - } \mathcal { Z } _ { \mathrm { r e a d e r } }$ and $\mathcal { Z } _ { \mathrm { r e t r i e v e r } }$ —for updating the two components of the model (reader parameters $\Theta$ and retriever parameters $\Phi$ ):
87
+
88
+ $$
89
+ \log \underbrace { p ( a \mid q , \mathcal { Z } _ { \mathrm { r e a d e r } } ; \Theta ) } _ { \mathrm { r e a d e r } } + \log \underbrace { p ( \mathcal { Z } _ { \mathrm { r e t r i e v e r } } \mid q ; \Phi ) } _ { \mathrm { r e t r i e v e r } } .
90
+ $$
91
+
92
+ In the first term, we set the value of the latent variable $Z = \mathcal { Z } _ { \mathrm { r e a d e r } }$ based on the prior scores. In the second term, we seek to maximize an approximate posterior of $Z = \mathcal { Z } _ { \mathrm { r e t r i e v e r } }$ . We discuss them in more detail below.
93
+
94
+ Reader parameters $\Theta$ . For updating $\Theta$ (the first term of Eq. 3), we use the top- $K$ documents with the highest individual scores (as computed by Eq. 1 based on the current value of $\Phi$ ) to construct Zreader. This is equivalent to relying on the prior $p ( Z \mid q ; \Phi )$ to estimate ${ \mathcal { Z } } _ { \mathrm { r e a d e r } }$ (without using information from the answer $\textbf { \em a }$ ). We choose to use the prior to train reader parameters since the prior scores are also used at evaluation time to obtain the top- $K$ documents. As a result, there is no mismatch between training and test computations when computing $p ( \pmb { a } \mid \pmb { q } , \mathcal { Z } ; \Theta )$ (i.e., $\mathcal { Z }$ that is used at test time is obtained in exactly the same way as $\mathcal { Z } _ { \mathrm { r e a d e r } } = \mathcal { Z } _ { \mathrm { t o p } - K } ,$ .
95
+
96
+ Retriever parameters $\Phi$ . For updating $\Phi$ (the second term of Eq. 3), we propose to use the posterior estimate. In other words, we use additional information from $\textbf { \em a }$ when evaluating $Z _ { \mathrm { r e t r i e v e r } }$ to train $\Phi$ . Using the posterior allows our retriever to learn from richer training signals as opposed to relying only on the prior.
97
+
98
+ We need to be able to compute $p ( \mathcal { Z } _ { \mathrm { r e t r i e v e r } } \mid q , a ; \Theta , \Phi )$ to maximize the retriever parameters. However, computing this quantity is difficult since it is a probability of a set.5 Consider a set of $K$ documents (e.g., ${ \mathcal { Z } } _ { \mathrm { t o p } - K } ,$ ), where $z _ { k }$ denotes a document in the set. We approximate the maximization of the probability of the set by assuming that its probability is maximized if the sum of the probability of each document in the set is maximized.6 With this approximation, we arrive at a simpler quantity: $\begin{array} { r } { \sum _ { k = 1 } ^ { K } p ( z _ { k } \mid q , \pmb { a } ; \Theta , \Phi ) } \end{array}$ . Note that using Bayes rule, we can rewrite:7
99
+
100
+ $$
101
+ p ( z _ { k } \mid q , a ; \Theta , \Phi ) \propto p ( a \mid q , z _ { k } ; \Theta ) p ( z _ { k } \mid q ; \Phi ) .
102
+ $$
103
+
104
+ The reader now only conditions on one document when computing the probability of an answer $p ( \pmb { a } \mid \pmb { q } , \pmb { z } _ { k } ; \Theta )$ . This simpler reader uses the same parameters as the more sophisticated one $\Theta$ , but it only uses one document $z _ { k }$ instead of a set of documents.
105
+
106
+ To compute Eq. 4, we first obtain $K$ documents with the highest scores as computed by Eq. 1 based on the current value of $\Phi$ . We compute the probability of document $z _ { k } \in \mathcal { Z } _ { \mathrm { t o p } - K }$ as:
107
+
108
+ $$
109
+ p ( z _ { k } \mid q , \mathcal { Z } _ { \mathrm { t o p } - K } ; \Phi ) \approx \frac { \exp ( \operatorname { s c o r e } ( q , z _ { k } ) / \tau ; \Phi ) } { \sum _ { j = 1 } ^ { K } \exp ( \operatorname { s c o r e } ( q , z _ { j } ) / \tau ; \Phi ) } ,
110
+ $$
111
+
112
+ where $\tau$ is a temperature hyperparameter and the approximation assumes that documents beyond the top- $K$ contributes very small scores so we do not need to sum over all evidence documents $M$ in the denominator (which is in the order of tens of millions in our experiments). We then compute $p ( \pmb { a } \mid \pmb { q } , \pmb { z } _ { k } ; \Theta )$ similarly to Eq. 2.
113
+
114
+ Overall training objective of $\mathbf { E M D R } ^ { 2 }$ . Combining the above derivations, our end-to-end training objective that we seek to maximize for a particular example becomes:
115
+
116
+ $$
117
+ \mathcal { L } = \underbrace { \log p ( a \mid q , \mathcal { Z } _ { \mathrm { t o p } \cdot K } ; \Theta ) } _ { \mathrm { r e a d e r } } + \log \sum _ { k = 1 } ^ { K } \mathbb { S } \mathbb { G } \left( p ( a \mid q , z _ { k } ; \Theta ) \right) p ( z _ { k } \mid q , \mathcal { Z } _ { \mathrm { t o p } \cdot K } ; \Phi ) ,
118
+ $$
119
+
120
+ where $\mathbb { S } \mathbb { G }$ is the stop-gradient operator so that the reader parameters $\Theta$ are not updated to also perform well given a single document $z _ { k }$ . The stop-gradient operator in the second term of $\mathrm { E M D R ^ { 2 } }$ has several benefits. First, the FiD reader is trained from the first term of the $\mathrm { E M D R ^ { 2 } }$ objective in which its likelihood is conditioned on all the retrieved documents, similar to how the reader is used at test time. Second, it also makes training faster since the backward pass which is computationally more expensive than the forward pass is not needed, which in turn reduces the usage of GPU RAM as intermediate activations need not be saved.
121
+
122
+ Given a training example, we update $\Theta$ and $\Phi$ by taking gradients of Eq. 6 with respect to $\Theta$ and $\Phi$ in an end-to-end fashion. Intuitively, we train the reader to generate the correct answer given $K$ highest scoring documents ${ \mathcal { Z } } _ { \mathrm { t o p } - K }$ . For the retriever, we train it to select $K$ documents which collectively has a high score of generating an answer (since the sum over $K$ is inside the log in the second term) while taking into account feedback from the reader. Algorithm 1 summarizes our training algorithm.
123
+
124
+ Algorithm 1: End-to-end training of multi-document reader and retriever.
125
+
126
+ Input: Model parameters $\Theta$ and $\Phi$ , evidence documents $\mathcal { D }$
127
+
128
+ while not converged do
129
+
130
+ • Compute ${ \mathcal { Z } } _ { \mathrm { t o p } - K }$ using the current retriever parameters $\Phi$ . // E-step • Compute $p ( \dot { \pmb { a } } \mid \pmb { q } , \pmb { z } _ { k } )$ for each $z _ { k }$ using the current reader parameters $\Theta$ . // E-step • Update model parameters $\Theta$ and $\Phi$ to maximize the log-likelihood in Eq. 6. // M-step
131
+
132
+ end
133
+
134
+ # 3 Experiments
135
+
136
+ # 3.1 Datasets
137
+
138
+ We experiment with three commonly used open-domain question answering datasets:
139
+
140
+ 6 The intuition is that each element of the set contributes independently, which greatly simplifies the computation to find the maximum of the set.
141
+
142
+ • Natural Questions (NQ; Kwiatkowski et al., 2019). NQ contains questions asked by users of the Google search engine. Similar to Lee et al. (2019), we use the short answer subset.
143
+
144
+ • TriviaQA (Joshi et al., 2017). TriviaQA is a collection of trivia question-answer pairs that were collected from multiple sources on the web.
145
+
146
+ • WebQuestions (WebQ; Berant et al., 2013). WebQ questions were collected using Google Suggest API and the answers were annotated using Mechanical Turk. We use the version from Chen et al. (2017) where Freebase IDs in the answers are replaced by entity names.
147
+
148
+ Evidence documents $\mathcal { D }$ . We use the preprocessed English Wikipedia dump from December 2018 released by Karpukhin et al. (2020) as our evidence documents. Each Wikipedia article is split into non-overlapping 100 words long segments. Each segment corresponds to a document in our case. There are a total of 21,015,324 documents in total.
149
+
150
+ We provide descriptive statistics and other preprocessing details in Appendix A.
151
+
152
+ # 3.2 Implementation Details
153
+
154
+ Hardware and library. We run all of our experiments on a machine with 96 CPUs, 1.3TB physical memory, and 16 A100 GPUs. We use PyTorch (Paszke et al., 2019) to implement our proposed model and relevant baselines.
155
+
156
+ Model configurations. For both the retriever and reader, we use the base configuration that consists of 12 layers, 768 dimensional hidden size, and 12 attention heads. In all experiments, we retrieve 50 documents, unless stated otherwise. We only use the base configuration in our experiments due to GPU memory constraints. However, we believe that our results would generalize to larger configurations as well.
157
+
158
+ Retrieval. To support fast retrieval, we pre-compute evidence document embeddings and store them in a distributed fashion over all the GPUs. We refer to these document embeddings as the document index. For each question, we retrieve documents in an online (on-the-fly) manner by performing exact maximum inner product search (MIPS), implemented using asynchronous distributed matrix multiplication over the document index. These documents are converted to subwords using BERT’s tokenization and are given as input to the T5 reader. If a tokenized document is shorter than 512 tokens, it is padded using the tokens from the neighboring documents until the maximum token limit is reached. Such padding additionally helps to provide an extended context for answer generation.
159
+
160
+ Initialization and training details. We initialize the parameters of the model with unsupervised pre-training before performing supervised training using the question-answer training examples. Unsupervised pre-training is essential as it helps to warm-start the retriever so that it outputs relevant documents for a given question.
161
+
162
+ We first pre-train the retriever parameters with unsupervised Inverse Cloze Task training (Lee et al., 2019) for 100,000 steps. We then extract sentences containing named entities from the evidence documents. Next, we replace $15 \%$ of the named entity tokens with masked tokens, which are often referred to as masked salient spans (MSS; Guu et al., 2020). The masked sentence can be considered as the question and its salient spans (i.e, named entities) can be considered as the answer to train the model with Eq. 6. We train the model on these question-answer (masked sentence-named entities) pairs for 82,000 steps with a batch size of 64 using Adam (Kingma and Ba, 2015). We refer to this initialization method as unsupervised pre-training with masked salient spans. We provide further description in Appendix C.
163
+
164
+ After MSS training, we finetune the model on the dataset-specific question-answer training examples with EMDR2. We perform training for 10 epochs on NQ and TriviaQA with a batch size of 64, and for 20 epochs on WebQ with a batch size of 16. During training, we save a checkpoint every 500 steps and select the best checkpoint based on its performance on the development set.
165
+
166
+ During end-to-end training, since the parameters of the document encoder $( f _ { d } )$ are also updated at every step, the pre-computed document embeddings become stale as training progresses. We use the most recent document encoder checkpoint to compute fresh document embeddings asynchronously with which the document index is updated after every 500 training steps to prevent staleness.
167
+
168
+ Table 2: Exact match scores on three evaluation datasets. Top- $K$ denotes the number of retrieved documents that are used by the reader to produce an answer. To provide a fair comparison with our reimplementations, we show results from other papers with the base configuration, except for RAG-Sequence that uses BART-large (Lewis et al., 2020a). $\dagger$ indicates that their results on WebQ use NQ training data to pretrain the model.
169
+
170
+ <table><tr><td rowspan="2">Model</td><td rowspan="2">top-K</td><td colspan="2">NQ</td><td colspan="2">TriviaQA</td><td colspan="2">WebQ</td><td rowspan="2">#of params</td></tr><tr><td>dev</td><td>test</td><td>dev</td><td>test</td><td>dev</td><td>test</td></tr><tr><td colspan="9">Closed-Book QA Models</td></tr><tr><td>T5-base (Roberts et al., 2020)</td><td>0</td><td></td><td>25.7</td><td></td><td>24.2</td><td>=</td><td>28.2</td><td>220M</td></tr><tr><td>T5-large (Roberts et al.,2020)</td><td>0</td><td>-</td><td>27.3</td><td>=</td><td>28.5</td><td></td><td>29.5</td><td>770M</td></tr><tr><td>T5-XXL (Roberts et al., 2020)</td><td>0</td><td></td><td>32.8</td><td></td><td>42.9</td><td></td><td>35.6</td><td>11B</td></tr><tr><td>GPT-3 (Brown et al., 2020)</td><td>0</td><td>-</td><td>29.9</td><td>=</td><td>1</td><td>=</td><td>41.5</td><td>175B</td></tr><tr><td colspan="9">Open-Book QA Models</td></tr><tr><td>BM25 + BERT (Lee et al., 2019)</td><td>5</td><td>24.8</td><td>26.5</td><td>47.2</td><td>47.1</td><td>27.1</td><td>21.3</td><td>220M</td></tr><tr><td>ORQA (Lee et al., 2019)</td><td>5</td><td>31.3</td><td>33.3</td><td>45.1</td><td>45.0</td><td>36.8</td><td>30.1</td><td>330M</td></tr><tr><td>REALM (Guu et al., 2020)</td><td>5</td><td>38.2</td><td>40.4</td><td>1</td><td>1</td><td>1</td><td>40.7</td><td>330M</td></tr><tr><td>DPR (Karpukhin et al., 2020)</td><td>25</td><td>1</td><td>41.5</td><td>-</td><td>56.8</td><td>-</td><td>34.6</td><td>330M</td></tr><tr><td>RECONsIDER (Iyer et al.,2021)t</td><td>30</td><td>-</td><td>43.1</td><td>1</td><td>59.3</td><td>-</td><td>44.4</td><td>440M</td></tr><tr><td>RAG-Sequence (Lewis et al., 2020b)t</td><td>50</td><td>44.0</td><td>44.5</td><td>55.8</td><td>56.8</td><td>44.9</td><td>45.2</td><td>626M</td></tr><tr><td>Individual Top-K (Sachan et al., 2021)</td><td>-</td><td>1</td><td>45.9</td><td>1</td><td>56.3</td><td>1</td><td>1</td><td>440M</td></tr><tr><td>Joint Top-K (Sachan et al., 2021)</td><td>50</td><td>-</td><td>49.2</td><td>1</td><td>64.8</td><td>-</td><td>-</td><td>440M</td></tr><tr><td>FiD (Izacard and Grave, 2021b)</td><td>100</td><td>1</td><td>48.2</td><td>1</td><td>65.0</td><td>=</td><td>=</td><td>440M</td></tr><tr><td>FiD-KD (Izacard and Grave, 2021a)</td><td>100</td><td>48.0</td><td>49.6</td><td>68.6</td><td>68.8</td><td>=</td><td>=</td><td>440M</td></tr><tr><td colspan="9">Our Implementation (Base Configuration)</td></tr><tr><td>FiD /T5-base</td><td>0</td><td>26.0</td><td>25.1</td><td>26.7</td><td>27.8</td><td>31.0</td><td>32.4</td><td>220M</td></tr><tr><td>FiD (DPR retriever, T5 reader)</td><td>1</td><td>37.3</td><td>38.4</td><td>50.8</td><td>50.4</td><td>40.2</td><td>38.3</td><td>440M</td></tr><tr><td>FiD (DPR retriever, T5 reader)</td><td>50</td><td>47.3</td><td>48.3</td><td>65.5</td><td>66.3</td><td>46.0</td><td>45.2</td><td>440M</td></tr><tr><td>FiD (MSS+DPR retriever, T5 reader)</td><td>50</td><td>48.8</td><td>50.4</td><td>68.0</td><td>68.8</td><td>43.5</td><td>46.8</td><td>440M</td></tr><tr><td>FiD (MSS retriever, MSS reader)</td><td>50</td><td>38.5</td><td>40.1</td><td>60.0</td><td>59.8</td><td>39.1</td><td>40.2</td><td>440M</td></tr><tr><td>EMDR² (MSS retriever,MSS reader)</td><td>50</td><td>50.4</td><td>52.5</td><td>71.1</td><td>71.4</td><td>49.9</td><td>48.7</td><td>440M</td></tr></table>
171
+
172
+ Inference. We use greedy decoding for answer generation at inference time.
173
+
174
+ # 3.3 Baselines
175
+
176
+ We compare our model to other approaches for OpenQA that can be categorized under the following two classes:
177
+
178
+ • Closed-book QA models. Large-scale language models capture a lot of world knowledge in their parameters derived from the corpus they have been trained on (Petroni et al., 2019). We compare with the work of Roberts et al. (2020) who show that larger T5 models—when finetuned with question-answer pairs—can perform remarkably well. We also compare with the few-shot results of GPT-3 (Brown et al., 2020).8
179
+
180
+ • Open-book QA models. Similar to this work, these models consist of retriever and reader components and adopt the retrieve then predict approach for answering questions given a collection of evidence documents. These models mainly differ in how the retriever is initialized (ORQA; Lee et al., 2019, DPR; Karpukhin et al., 2020), whether the reader processes a single document (ORQA, DPR, RAG; Lewis et al., 2020b) or multiple documents (FiD; Izacard and Grave, 2021b), or whether the reader and retriever are trained jointly or in a multistage process (REALM; Guu et al., 2020, FiD-KD; Izacard and Grave, 2021a).
181
+
182
+ # 3.4 Results
183
+
184
+ We follow standard conventions and report exact match (EM) scores using the reference answers included in each dataset. Table 2 shows our main results. We divide the table into three main sections: closed-book QA models, open-book QA models, and our implementation. The first two sections contain results from other papers, which we include for comparisons. The last section includes results from our proposed model, as well as our reimplementation of relevant baselines to control for our experimental setup.
185
+
186
+ Our reimplementation of T5-base provides strong baselines when the number of retrieved documents is set to 0 (no retrieval) and 1. From Table 2, we see that the setting of top-1 vastly improves performance over the setting with no retrieved documents, signifying the importance of retrieval for OpenQA tasks. When further increasing the top- $k$ documents to 50, the performance of the FiD models substantially improves over the top-1 retrieval, verifying the observation from (Izacard and Grave, 2021b) about the importance of modeling the retrieved documents as a set.
187
+
188
+ Comparing EMDR2 with our reimplementation of FiD illustrates the benefit of our end-to-end training approach. The underlying model is similar in both cases, but the training method is different. FiD adopts a two-stage approach to first train the retriever and then the reader. We have three variants of FiD: (i) the reader and retriever are initialized with MSS training, (ii) the retriever is initialized with DPR training, which is the setting used in the original paper (Izacard and Grave, 2021b), and (iii) the retriever is initialized with $\mathrm { M S S + D P R }$ training from (Sachan et al., 2021), as it further improves DPR recall. EMDR2 outperforms all the variants by large margins on all the datasets.
189
+
190
+ The current best approach for training multi-document reader and retriever is FiD-KD (Izacard and Grave, 2021a). FiD-KD is a complex training procedure that requires multiple training stages and performs knowledge distillation with inter-attention scores. We take the results from the original paper when comparing our model with FiD-KD. EMDR2 outperforms the reported numbers of FiD-KD by more than 2.5 points on NQ and TriviaQA to obtain new state-of-the-art results on these benchmarks.
191
+
192
+ In addition to better performance, $\mathrm { E M D R } ^ { 2 }$ also has three other advantages compared to FiD-KD: (i) EMDR2 is more efficient since it only uses 50 evidence documents, whereas FiD-KD leverages 100 documents; (ii) FiD-KD is based on a distillation approach which requires multiple cycles of retriever and reader training, while EMDR2 only requires one cycle of end-to-end training; and (iii) FiD-KD relies on supervised initialization of the retriever to achieve its best performance. EMDR2 is more robust to the retriever initialization, as demonstrated by state-of-the-art results even with unsupervised initialization of the retriever.
193
+
194
+ For the WebQ dataset, the training set size is much smaller compared to the other datasets (Table 5). Previous approaches such as RAG rely on supervised transfer (i.e., they finetune a model pre-trained on NQ) to obtain good results. In contrast, EMDR2 improves over the results from this RAG model by 3.5 points without the supervised transfer step. This result demonstrates the applicability of our approach to the low-resource setting where we only have a limited number of training examples.
195
+
196
+ We also perform qualitative analysis of the model outputs, which is included in Appendix E.
197
+
198
+ # 3.5 Ablations
199
+
200
+ Number of retrieved documents. We investigate the performance of $\mathrm { E M D R } ^ { 2 }$ and FiD as we vary the number of retrieved documents $K$ in Figure 2. We observe that when the number of retrieved documents is increased, both $\mathrm { E M D R } ^ { 2 }$ and FiD improve in performance. When $K$ is small, the gap between EMDR2 and FiD is larger. This indicates the efficacy of $\mathrm { E M D R } ^ { 2 }$ in a more constrained setting where we can only retrieve a small number of documents (e.g., due to memory limitations).
201
+
202
+ Retriever initialization. We explore the effect of different parameter initialization strategies when training with $\mathrm { E M D R } ^ { 2 }$ : (i) unsupervised MSS pre-training, (ii) supervised retriever training (DPR), and (iii) MSS pre-training followed by supervised retriever training $( \mathbf { M S S } + \mathbf { D P R }$ ; Sachan et al. (2021)). Table 3 shows our results. We can see that on NQ, MSS pre-training being unsupervised leads to a lower initial retriever recall than DPR. After EMDR2 training, the recall improves by $20 \%$ (highlighted in yellow cells). Training with DPR initialization leads to the same final recall as obtained by MSS pre-training, suggesting that DPR initialization of the retriever may not be an essential component to obtain good performance in OpenQA tasks. Similar trends are also observed on TriviaQA and WebQ. Similarly, $\mathrm { M S S + D P R }$ initialization has a better initial recall but leads to a marginal or no improvements in answer extraction performance over MSS pre-training. Finally, we also observe that MSS pre-training also provides an improvement of 2 points in answer extraction on WebQ when compared to the T5 reader (shown in orange cells), highlighting its importance in the low-resource OpenQA tasks.
203
+
204
+ ![](images/7dcd063be0e6d81cac03b624c5218469124ad2c2ee286002d863efadc3e0c9ae.jpg)
205
+
206
+ Figure 2: Performance on NQ, TriviaQA, and WebQ as we vary the number of retrieved documents.
207
+
208
+ <table><tr><td></td><td></td><td colspan="2">NQ (dev)</td><td colspan="4">TriviaQA (dev)</td><td colspan="3">WebQ (dev)</td></tr><tr><td>Retriever</td><td>Reader</td><td colspan="2">R@50</td><td>EM</td><td colspan="2">R@50</td><td>EM</td><td colspan="2">R@50</td><td>EM</td></tr><tr><td>Initialization</td><td>Initialization</td><td>B.T.A.T.</td><td></td><td></td><td>B.T.</td><td>A.T.</td><td></td><td>B.T.</td><td>A.T.</td><td></td></tr><tr><td>MSS pre-training</td><td>MSS pre-training</td><td>66.4</td><td>86.3</td><td>50.4</td><td>74.8</td><td>86.2</td><td>71.1</td><td>59.8</td><td>88.6</td><td>49.9</td></tr><tr><td>MSS pre-training</td><td>T5</td><td>66.4</td><td>86.3</td><td>50.3</td><td>74.8</td><td>86.3</td><td>70.9</td><td>59.8</td><td>88.6</td><td>47.7</td></tr><tr><td>DPR training</td><td>T5</td><td>82.3</td><td>86.3</td><td>50.0</td><td>83.2</td><td>86.2</td><td>70.5</td><td>84.2</td><td>88.6</td><td>49.0</td></tr><tr><td>MSS +DPR</td><td>MSS pre-training</td><td>84.5</td><td>86.3</td><td>50.5</td><td>85.3</td><td>86.3</td><td>71.2</td><td>85.0</td><td>88.6</td><td>49.9</td></tr></table>
209
+
210
+ Table 3: $\mathrm { R @ 5 0 }$ denotes the retrieval recall from the top-50 retrieved documents. B.T. and A.T. indicates $\mathrm { R @ 5 0 }$ score Before Training and After Training the model, respectively.
211
+
212
+ # 3.6 Alternative End-to-End Training Objectives
213
+
214
+ We compare $\mathrm { E M D R } ^ { 2 }$ objective (Eq. 6) to two alternative formulations for end-to-end training.
215
+
216
+ In the first alternative formulation, when training the retriever parameters $\Phi$ , we simply factorize $p ( \mathcal { Z } \mid \mathbf { \bar { q } } ; \Phi ) =$ $\textstyle \prod _ { k = 1 } ^ { K } p ( z _ { k } \mid q ; \Phi )$ to arrive at the following objective:
217
+
218
+ $$
219
+ \mathcal { L } _ { \mathrm { a l t - 1 } } = \log p ( \boldsymbol { a } \mid \boldsymbol { q } , \mathcal { Z } ; \boldsymbol { \Theta } ) + \sum _ { k = 1 } ^ { K } \log p ( \boldsymbol { z } _ { k } \mid \boldsymbol { q } , \mathcal { Z } ; \boldsymbol { \Phi } ) .
220
+ $$
221
+
222
+ The second term in this objective is maximised by a uniform retrieval, in other words, by removing any discrimination between documents in the retriever. We include it to show the impact of an adversarial objective.
223
+
224
+ <table><tr><td>Method t top-k</td><td>NQ</td><td>TriviaQA</td><td>WebQ</td></tr><tr><td>FiD EMDR²</td><td>50 47.3 50 50.4</td><td>65.5 71.1</td><td>46.0 49.9</td></tr><tr><td>Lalt-1</td><td>50 14.1</td><td>11.9</td><td>28.0</td></tr><tr><td>Lalt-2</td><td>50 49.9</td><td>69.6</td><td>28.8</td></tr></table>
225
+
226
+ Table 4: EM scores on the development set for alternative training objectives.
227
+
228
+ In the second formulation, for each retrieved document, we approximate its posterior under the assumption that we have a uniform prior over the set of retrieved documents: $\tilde { p } ( z _ { k } \mid q , \pmb { a } , \mathcal { Z } _ { \mathrm { t o p } - K } ; \Theta ) \propto$ $p ( { \pmb a } \mid { \pmb q } , z _ { k } ; \Theta ) \times \frac { 1 } { K }$ . We use this to train reader and retriever parameters as follows:
229
+
230
+ $$
231
+ \mathcal { L } _ { \mathrm { a l t - 2 } } = \log p ( \boldsymbol { a } \mid \boldsymbol { q } , \mathcal { Z } ; \boldsymbol { \Theta } ) + \mathbb { K L } \big ( \mathbb { S } \mathbb { G } \left( \tilde { p } ( \boldsymbol { z } _ { k } \mid \boldsymbol { q } , \boldsymbol { a } , \mathcal { Z } _ { \mathrm { t o p } \cdot K } ; \boldsymbol { \Theta } ) \right) \mid \mid p ( \boldsymbol { z } _ { k } \mid \boldsymbol { q } , \mathcal { Z } ; \boldsymbol { \Phi } ) \big ) .
232
+ $$
233
+
234
+ Intuitively, we try to match the probability of retrieving a document $z _ { k }$ with the “contribution” of that document to the generated answer $\textbf { \em a }$ , regardless of whether the retriever is relatively more or less likely to retreieve the document a priori.
235
+
236
+ Table 4 shows our results on the development set of NQ. We observe that training with the adversarial ${ \mathcal { L } } _ { \mathrm { a l t - 1 } }$ objective diverges, leading to poor performance, as expected. This shows that harming the retriever during training can significantly harm performance of the QA system. In contrast, although it disregards the estimated prior, the ${ \mathcal { L } } _ { \mathrm { a l t - 2 } }$ objective still improves over the FiD baseline for NQ and
237
+
238
+ TriviaQA. However, it still lags behind EMDR2. On WebQ, the ${ \mathcal { L } } _ { \mathrm { a l t - 2 } }$ objective diverges and leads to a poor performance. We leave further analysis on the convergence of ${ \mathcal { L } } _ { \mathrm { a l t - 2 } }$ objective as a part of future work.
239
+
240
+ # 4 Related Work
241
+
242
+ Our work is based on end-to-end training of neural readers and retrievers, which we discuss in $\ S 1 , \ S 2$ and $\ S 3$ . Here we instead focus on discussing previous work related to standalone neural retrievers, neural readers, and their application in other natural language processing tasks.
243
+
244
+ Neural retrievers. There are two broad classes of neural retrievers based on the number of embeddings computed for a document: dual encoders (Yih et al., 2011, Lee et al., 2019) and multivector encoders (Khattab and Zaharia, 2020, Luan et al., 2021). Dual encoders store one embedding for each evidence document. Multivector encoders require multiple embeddings, which can be computationally expensive for large-scale retrieval. Due to the large size of the evidence document collection in OpenQA, our work uses the more efficient dual-encoder. Sachan et al. (2021) show that the performance of supervised dual encoders in OpenQA can be improved when pre-training with the Inverse Cloze Task for the high-resource setting or masked salient spans for the low-resource setting.
245
+
246
+ Neural readers. Neural readers output an answer given retrieved documents as its input. There are also two broad classes of neural readers: extractive and generative. Extractive readers (Clark and Gardner, 2018, de Masson d’Autume et al., 2019, Wang et al., 2019, Guu et al., 2020, Karpukhin et al., 2020) extract a span from a retrieved document to produce an answer. Generative readers (Izacard and Grave, 2021b), on the other hand, generates an answer conditioned on the retrieved documents.
247
+
248
+ Other application areas. In addition to question answering, retrieval-augmented methods have been successfully applied to other natural language processing tasks. In left-to-right language modeling, retrieving similar words from an external memory has been shown to improve perplexity (Khandelwal et al., 2020, Yogatama et al., 2021). In machine translation, retrieving domain-specific target language tokens has improved performance in domain adaptation (Khandelwal et al., 2021). Finally, in dialog modeling, retrieving knowledge-informed text has helped improve factual correctness in the generated conversations (Fan et al., 2021).
249
+
250
+ We provide a detailed comparison of EMDR2 with some of the previous work in Appendix C and D.
251
+
252
+ # 5 Discussion
253
+
254
+ Summary of contributions. We presented EMDR2, an end-to-end training method for retrievalaugmented question answering systems. We showed how to arrive at our training objective using the expectation-maximization algorithm. We demonstrated that EMDR2 achieves state-of-the-art performance on three benchmark OpenQA datasets.
255
+
256
+ Technical limitations. EMDR2 shares a few limitations with other retrieval-augmented question answering models. In particular, as evidence documents are stored in an uncompressed format, maintaining them and searching for relevant documents can be expensive (both in terms of compute and memory consumption). In our experiments, we only focused on open-domain question answering. It would be interesting to see how EMDR2 performs for other text generation models as well. We also note that training is relatively resource-heavy (requiring 16 GPUs), potentially having environmental concerns.
257
+
258
+ Potential negative societal impacts. While EMDR2 has the potential to improve language models in the low-resource setting (as demonstrated by our results on WebQ in $\ S 3 . 4 )$ , it could exhibit typical biases that are associated with large language models. For example, our model does not have an explicit mechanism to generate answers that are calibrated for fairness across all spectra. As a retrieval-augmented method, it also could be more prone to generating fake answers if an attacker manages to have access and modify information in the collection of evidence documents.
259
+
260
+ # Acknowledgements
261
+
262
+ The authors would like to thank the DeepMind Language team, Mila’s students, and anonymous reviewers for providing us valuable feedback and useful suggestions about this work that helped us improve the paper.
263
+
264
+ # Funding Statement
265
+
266
+ DSS was supported by the Canada CIFAR AI Chair held by Prof. William Hamilton.
267
+
268
+ # References
269
+
270
+ Berant, J., Chou, A., Frostig, R., and Liang, P. (2013). Semantic parsing on Freebase from questionanswer pairs. In Proceedings of the 2013 Conference on Empirical Methods in Natural Language Processing.
271
+ Bromley, J., Guyon, I., LeCun, Y., Säckinger, E., and Shah, R. (1994). Signature verification using a "siamese" time delay neural network. In Advances in Neural Information Processing Systems.
272
+ Brown, T., Mann, B., Ryder, N., Subbiah, M., Kaplan, J. D., Dhariwal, P., Neelakantan, A., Shyam, P., Sastry, G., Askell, A., Agarwal, S., Herbert-Voss, A., Krueger, G., Henighan, T., Child, R., Ramesh, A., Ziegler, D., Wu, J., Winter, C., Hesse, C., Chen, M., Sigler, E., Litwin, M., Gray, S., Chess, B., Clark, J., Berner, C., McCandlish, S., Radford, A., Sutskever, I., and Amodei, D. (2020). Language models are few-shot learners. In Advances in Neural Information Processing Systems.
273
+ Chen, D., Fisch, A., Weston, J., and Bordes, A. (2017). Reading Wikipedia to answer open-domain questions. In Proceedings of the 55th Annual Meeting of the Association for Computational Linguistics (Volume 1: Long Papers).
274
+ Clark, C. and Gardner, M. (2018). Simple and effective multi-paragraph reading comprehension. In Proceedings of the 56th Annual Meeting of the Association for Computational Linguistics (Volume 1: Long Papers).
275
+ de Masson d’Autume, C., Ruder, S., Kong, L., and Yogatama, D. (2019). Episodic memory in lifelong language learning. In Advances in Neural Information Processing Systems.
276
+ Dempster, A., Laird, N., and Rubin, D. (1977). Maximum likelihood from incomplete data via the em algorithm. Journal of the Royal Statistical Society, Series B, 1(39), 1–38.
277
+ Devlin, J., Chang, M.-W., Lee, K., and Toutanova, K. (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).
278
+ Fan, A., Gardent, C., Braud, C., and Bordes, A. (2021). Augmenting Transformers with KNN-Based Composite Memory for Dialog. Transactions of the Association for Computational Linguistics, 9.
279
+ Guu, K., Lee, K., Tung, Z., Pasupat, P., and Chang, M. (2020). Retrieval augmented language model pre-training. In Proceedings of the 37th International Conference on Machine Learning.
280
+ Iyer, S., Min, S., Mehdad, Y., and Yih, W. (2021). Reconsider: Re-ranking using span-focused cross-attention for open domain question answering. In Proceedings of the 2021 Conference of the North American Chapter of the Association for Computational Linguistics: Human Language Technologies, Volume 1 (Long and Short Papers).
281
+ Izacard, G. and Grave, E. (2021a). Distilling knowledge from reader to retriever for question answering. In International Conference on Learning Representations.
282
+ Izacard, G. and Grave, E. (2021b). Leveraging passage retrieval with generative models for open domain question answering. In Proceedings of the 16th Conference of the European Chapter of the Association for Computational Linguistics: Main Volume.
283
+
284
+ Joshi, M., Choi, E., Weld, D., and Zettlemoyer, L. (2017). TriviaQA: A large scale distantly supervised challenge dataset for reading comprehension. In Proceedings of the 55th Annual Meeting of the Association for Computational Linguistics (Volume 1: Long Papers).
285
+
286
+ Karpukhin, V., Oguz, B., Min, S., Wu, L., Edunov, S., Chen, D., and Yih, W.-t. (2020). Dense ˘ passage retrieval for open-domain question answering. In Proceedings of the 2020 Conference on Empirical Methods in Natural Language Processing (EMNLP).
287
+
288
+ Khandelwal, U., Levy, O., Jurafsky, D., Zettlemoyer, L., and Lewis, M. (2020). Generalization through memorization: Nearest neighbor language models. In International Conference on Learning Representations.
289
+
290
+ Khandelwal, U., Fan, A., Jurafsky, D., Zettlemoyer, L., and Lewis, M. (2021). Nearest neighbor machine translation. In International Conference on Learning Representations.
291
+
292
+ Khattab, O. and Zaharia, M. (2020). Colbert: Efficient and effective passage search via contextualized late interaction over bert. In Proceedings of the 43rd International ACM SIGIR Conference on Research and Development in Information Retrieval.
293
+
294
+ Kingma, D. P. and Ba, J. (2015). Adam: A method for stochastic optimization. In The 2015 International Conference for Learning Representations.
295
+
296
+ Kwiatkowski, T., Palomaki, J., Redfield, O., Collins, M., Parikh, A., Alberti, C., Epstein, D., Polosukhin, I., Kelcey, M., Devlin, J., Lee, K., Toutanova, K. N., Jones, L., Chang, M.-W., Dai, A., Uszkoreit, J., Le, Q., and Petrov, S. (2019). Natural questions: a benchmark for question answering research. Transactions of the Association of Computational Linguistics.
297
+
298
+ Lee, K., Chang, M.-W., and Toutanova, K. (2019). Latent retrieval for weakly supervised open domain question answering. In Proceedings of the 57th Annual Meeting of the Association for Computational Linguistics.
299
+
300
+ Lewis, M., Liu, Y., Goyal, N., Ghazvininejad, M., Mohamed, A., Levy, O., Stoyanov, V., and Zettlemoyer, L. (2020a). 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.
301
+
302
+ Lewis, P., Perez, E., Piktus, A., Petroni, F., Karpukhin, V., Goyal, N., Küttler, H., Lewis, M., Yih, W.-t., Rocktäschel, T., Riedel, S., and Kiela, D. (2020b). Retrieval-augmented generation for knowledge-intensive nlp tasks. In Advances in Neural Information Processing Systems.
303
+
304
+ Luan, Y., Eisenstein, J., Toutanova, K., and Collins, M. (2021). Sparse, Dense, and Attentional Representations for Text Retrieval. Transactions of the Association for Computational Linguistics, 9.
305
+
306
+ Min, S., Chen, D., Hajishirzi, H., and Zettlemoyer, L. (2019). A discrete hard EM approach for weakly supervised question answering. 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), Hong Kong, China. Association for Computational Linguistics.
307
+
308
+ Paszke, A., Gross, S., Massa, F., Lerer, A., Bradbury, J., Chanan, G., Killeen, T., Lin, Z., Gimelshein, N., Antiga, L., Desmaison, A., Kopf, A., Yang, E., DeVito, Z., Raison, M., Tejani, A., Chilamkurthy, S., Steiner, B., Fang, L., Bai, J., and Chintala, S. (2019). Pytorch: An imperative style, highperformance deep learning library. In H. Wallach, H. Larochelle, A. Beygelzimer, F. d'Alché-Buc, E. Fox, and R. Garnett, editors, Advances in Neural Information Processing Systems.
309
+
310
+ Petroni, F., Rocktäschel, T., Riedel, S., Lewis, P., Bakhtin, A., Wu, Y., and Miller, A. (2019). Language models as knowledge bases? 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).
311
+
312
+ Qi, P., Zhang, Y., Zhang, Y., Bolton, J., and Manning, C. D. (2020). Stanza: A Python natural language processing toolkit for many human languages. In Proceedings of the 58th Annual Meeting of the Association for Computational Linguistics: System Demonstrations.
313
+
314
+ Raffel, C., Shazeer, N., Roberts, A., Lee, K., Narang, S., Matena, M., Zhou, Y., Li, W., and Liu, P. J. (2020). Exploring the limits of transfer learning with a unified text-to-text transformer. Journal of Machine Learning Research, 21(140), 1–67.
315
+ Roberts, A., Raffel, C., and Shazeer, N. (2020). How much knowledge can you pack into the parameters of a language model? In Proceedings of the 2020 Conference on Empirical Methods in Natural Language Processing (EMNLP).
316
+ Robertson, S. and Zaragoza, H. (2009). The probabilistic relevance framework: Bm25 and beyond. Foundations and Trends in Information Retrieval.
317
+ Sachan, D. S., Patwary, M., Shoeybi, M., Kant, N., Ping, W., Hamilton, W. L., and Catanzaro, B. (2021). End-to-end training of neural retrievers for open-domain question answering. In Joint Conference of the 59th Annual Meeting of the Association for Computational Linguistics and the 11th International Joint Conference on Natural Language Processing (ACL-IJCNLP).
318
+ Shoeybi, M., Patwary, M., Puri, R., LeGresley, P., Casper, J., and Catanzaro, B. (2019). Megatron-lm: Training multi-billion parameter language models using gpu model parallelism. arXiv preprint arXiv:1909.08053.
319
+ Vaswani, A., Shazeer, N., Parmar, N., Uszkoreit, J., Jones, L., Gomez, A. N., Kaiser, Ł., and Polosukhin, I. (2017). Attention is all you need. In Advances in Neural Information Processing Systems.
320
+ Wang, S., Yu, M., Guo, X., Wang, Z., Klinger, T., Zhang, W., Chang, S., Tesauro, G., Zhou, B., and Jiang, J. (2018). R3: Reinforced ranker-reader for open-domain question answering. In AAAI.
321
+ Wang, Z., Ng, P., Ma, X., Nallapati, R., and Xiang, B. (2019). Multi-passage BERT: A globally normalized BERT model for open-domain question answering. 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).
322
+ Yih, W.-t., Toutanova, K., Platt, J. C., and Meek, C. (2011). Learning discriminative projections for text similarity measures. In Proceedings of the Fifteenth Conference on Computational Natural Language Learning.
323
+ Yogatama, D., de Masson d’Autume, C., and Kong, L. (2021). Adaptive Semiparametric Language Models. Transactions of the Association for Computational Linguistics, 9, 362–373.
324
+
325
+ # Checklist
326
+
327
+ 1. For all authors...
328
+
329
+ (a) Do the main claims made in the abstract and introduction accurately reflect the paper’s contributions and scope? [Yes] Please see the model (§2) and result (§3) sections that solidify the claims made in the abstract and introduction sections.
330
+ (b) Did you describe the limitations of your work? [Yes] Please see limitations in $\ S$ .
331
+ (c) Did you discuss any potential negative societal impacts of your work? [Yes] Please see negative societal impact in $\ S 5$ .
332
+ (d) Have you read the ethics review guidelines and ensured that your paper conforms to them? [Yes]
333
+
334
+ 2. If you are including theoretical results...
335
+
336
+ (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]
337
+
338
+ 3. If you ran experiments...
339
+
340
+ (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 include the code, data, and instructions in the supplemental material and $\ S$ .
341
+ (b) Did you specify all the training details (e.g., data splits, hyperparameters, how they were chosen)? [Yes] We specify these details in the appendix included in the supplementary material.
342
+ (c) Did you report error bars (e.g., with respect to the random seed after running experiments multiple times)? [No] Our experiments are compute expensive and it is not feasible to perform multiple runs of the same experiment with different seeds. All our training runs use the same seed value (1234). As an alternative to running multiple seeds, we perform a number of ablation studies (§3.5).
343
+ (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] Please see $\ S 3 . 2$ under hardware and library.
344
+
345
+ 4. If you are using existing assets (e.g., code, data, models) or curating/releasing new assets...
346
+
347
+ (a) If your work uses existing assets, did you cite the creators? [Yes] Please see $\ S 3 . 1$ for the details.
348
+ (b) Did you mention the license of the assets? [Yes] Our work is based on open-source data and framework. When applicable, we describe the license information in the appendix.
349
+ (c) Did you include any new assets either in the supplemental material or as a URL? [Yes] We include our code in the supplementary material.
350
+ (d) Did you discuss whether and how consent was obtained from people whose data you’re using/curating? [N/A]
351
+ (e) Did you discuss whether the data you are using/curating contains personally identifiable information or offensive content? [N/A]
352
+
353
+ 5. If you used crowdsourcing or conducted research with human subjects...
354
+
355
+ (a) Did you include the full text of instructions given to participants and screenshots, if applicable? [N/A]
356
+ (b) Did you describe any potential participant risks, with links to Institutional Review Board (IRB) approvals, if applicable? [N/A]
357
+ (c) Did you include the estimated hourly wage paid to participants and the total amount spent on participant compensation? [N/A]
parse/train/5KWmB6JePx/5KWmB6JePx_content_list.json ADDED
@@ -0,0 +1,1720 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ [
2
+ {
3
+ "type": "text",
4
+ "text": "End-to-End Training of Multi-Document Reader and Retriever for Open-Domain Question Answering ",
5
+ "text_level": 1,
6
+ "bbox": [
7
+ 179,
8
+ 122,
9
+ 820,
10
+ 172
11
+ ],
12
+ "page_idx": 0
13
+ },
14
+ {
15
+ "type": "text",
16
+ "text": "Devendra Singh Sachan1,2, Siva Reddy1,2, William Hamilton1,2, Chris Dyer3, Dani Yogatama3 ",
17
+ "bbox": [
18
+ 183,
19
+ 224,
20
+ 839,
21
+ 241
22
+ ],
23
+ "page_idx": 0
24
+ },
25
+ {
26
+ "type": "text",
27
+ "text": "1Mila - Quebec AI Institute 2School of Computer Science, McGill University 3DeepMind sachande@mila.quebec, {siva, wlh}@cs.mcgill.ca {cdyer, dyogatama}@deepmind.com ",
28
+ "bbox": [
29
+ 289,
30
+ 242,
31
+ 738,
32
+ 311
33
+ ],
34
+ "page_idx": 0
35
+ },
36
+ {
37
+ "type": "text",
38
+ "text": "Abstract ",
39
+ "text_level": 1,
40
+ "bbox": [
41
+ 462,
42
+ 347,
43
+ 535,
44
+ 363
45
+ ],
46
+ "page_idx": 0
47
+ },
48
+ {
49
+ "type": "text",
50
+ "text": "We present an end-to-end differentiable training method for retrieval-augmented open-domain question answering systems that combine information from multiple retrieved documents when generating answers. We model retrieval decisions as latent variables over sets of relevant documents. Since marginalizing over sets of retrieved documents is computationally hard, we approximate this using an expectation-maximization algorithm. We iteratively estimate the value of our latent variable (the set of relevant documents for a given question) and then use this estimate to update the retriever and reader parameters. We hypothesize that such end-to-end training allows training signals to flow to the reader and then to the retriever better than stage-wise training. This results in a retriever that is able to select more relevant documents for a question and a reader that is trained on more accurate documents to generate an answer. Experiments on three benchmark datasets demonstrate that our proposed method outperforms all existing approaches of comparable size by 2-3 absolute exact match points, achieving new state-of-theart results. Our results also demonstrate the feasibility of learning to retrieve to improve answer generation without explicit supervision of retrieval decisions. ",
51
+ "bbox": [
52
+ 233,
53
+ 383,
54
+ 764,
55
+ 604
56
+ ],
57
+ "page_idx": 0
58
+ },
59
+ {
60
+ "type": "text",
61
+ "text": "1 Introduction ",
62
+ "text_level": 1,
63
+ "bbox": [
64
+ 174,
65
+ 642,
66
+ 312,
67
+ 660
68
+ ],
69
+ "page_idx": 0
70
+ },
71
+ {
72
+ "type": "text",
73
+ "text": "Open-domain question answering (OpenQA) is a question answering task where the goal is to train a language model to produce an answer for a given question. In contrast to many question answering tasks, an OpenQA model is only provided with the question as its input without accompanying documents that contain the answer. One of the most promising approaches to OpenQA is based on augmenting the language model with an external knowledge source such as Wikipedia (often referred to as the evidence documents). In this approach, the model consists of two core components (Chen et al., 2017): (i) an information retrieval system to identify useful pieces of text from the knowledge source (the retriever); and (ii) a system to produce the answer given the retrieved documents and the question (the reader). ",
74
+ "bbox": [
75
+ 174,
76
+ 679,
77
+ 825,
78
+ 804
79
+ ],
80
+ "page_idx": 0
81
+ },
82
+ {
83
+ "type": "text",
84
+ "text": "We can view such a model as a latent variable model, where the latent variables represent retrieved documents that are used to produce answers given questions (Lee et al., 2019). End-to-end (joint) training of this model is challenging since we need to learn both to generate an answer given retrieved documents and what to retrieve. Previous work considers two potential solutions (see Table 1 for a high-level summary). First, they adopt a stage-wise training, where the retriever is trained while freezing the reader and vice versa (Karpukhin et al., 2020, Izacard and Grave, 2021b,a). Another alternative is to constraint the reader to condition on each retrieved document individually1 (Guu et al., 2020)—sometimes with extra supervision for the latent variables in the form of the relevant document for a question (Lewis et al., 2020b). ",
85
+ "bbox": [
86
+ 174,
87
+ 810,
88
+ 825,
89
+ 893
90
+ ],
91
+ "page_idx": 0
92
+ },
93
+ {
94
+ "type": "table",
95
+ "img_path": "images/fd54ec1897f4b52460b348efbaab532d8d6c016e55a2efd6c0fcdd762312ed62.jpg",
96
+ "table_caption": [
97
+ "Table 1: Bird’s-eye view of the recent OpenQA approaches. Multi-Doc reader indicates whether the reader architecture uses multiple documents or a single document. Retriever adaptation shows whether the retriever gets feedback from the reader to update its parameters. Disjoint denotes that first the retriever is trained and then the reader is trained. End-to-end denotes that the reader and retriever are trained jointly in one cycle. Multi-step indicates that the reader and retriever are trained iteratively in multiple cycles. Unsupervised retriever indicates whether the retriever is initialized using unsupervised approaches or using supervised data. "
98
+ ],
99
+ "table_footnote": [],
100
+ "table_body": "<table><tr><td></td><td colspan=\"5\">Reader and Retriever Training</td></tr><tr><td>Model</td><td>Multi-Doc Reader</td><td>Retriever Adaptation</td><td>Disjoint End-to-End Multi-Step Unsupervised</td><td></td><td>Retriever</td></tr><tr><td>REALM (Guu et al., 2020)</td><td></td><td>√</td><td></td><td></td><td>√</td></tr><tr><td>DPR (Karpukhin et al., 2020)</td><td></td><td></td><td>√</td><td></td><td></td></tr><tr><td>RAG (Lewis et al., 2020b)</td><td></td><td>√</td><td></td><td></td><td></td></tr><tr><td>FiD (Izacard and Grave, 2021b)</td><td></td><td></td><td>√</td><td></td><td></td></tr><tr><td>FiD-KD (Izacard and Grave, 2021a)</td><td>√</td><td>√</td><td></td><td>√</td><td></td></tr><tr><td>EMDR² (Our Approach)</td><td>√</td><td>√</td><td>√</td><td></td><td>√</td></tr></table>",
101
+ "bbox": [
102
+ 173,
103
+ 88,
104
+ 830,
105
+ 232
106
+ ],
107
+ "page_idx": 1
108
+ },
109
+ {
110
+ "type": "text",
111
+ "text": "",
112
+ "bbox": [
113
+ 176,
114
+ 367,
115
+ 823,
116
+ 409
117
+ ],
118
+ "page_idx": 1
119
+ },
120
+ {
121
+ "type": "text",
122
+ "text": "In this paper, we consider a retrieval-augmented question answering model that combines information from multiple documents when generating answers. Expectation-maximization (Dempster et al., 1977) offers a principled template for learning this class of latent variable models. We present EMDR2: End-to-end training of Multi-Document Reader and Retriever (§2). EMDR2 iteratively uses feedback from the model itself as “pseudo labels” of the latent variables for optimizing the retriever and reader parameters. We use two estimates of the latent variables: (i) prior scores for updating the reader parameters and (ii) approximate posterior scores given all observed variables for the retriever parameters. ",
123
+ "bbox": [
124
+ 173,
125
+ 415,
126
+ 825,
127
+ 526
128
+ ],
129
+ "page_idx": 1
130
+ },
131
+ {
132
+ "type": "text",
133
+ "text": "We evaluate our proposed method by experimenting on three commonly used OpenQA datasets: Natural Questions, TriviaQA, and WebQuestions (§3). EMDR2 achieves new state-of-the-art results for models of comparable size on all datasets, outperforming recent approaches by 2-3 absolute exact match points. We also show that EMDR2 is robust to retriever initialization. It achieves high accuracy with unsupervised initialization, suggesting that supervised training of the retriever may not be an essential component of the training process as suggested in prior work (Karpukhin et al., 2020). ",
134
+ "bbox": [
135
+ 174,
136
+ 532,
137
+ 825,
138
+ 616
139
+ ],
140
+ "page_idx": 1
141
+ },
142
+ {
143
+ "type": "text",
144
+ "text": "In summary, our contributions are as follows: (i) we present an end-to-end training method $( \\mathrm { E M D R } ^ { 2 } $ ) for retrieval-augmented question-answering systems; (ii) we demonstrate that $\\mathrm { E M D R ^ { 2 } }$ outperforms other existing approaches of comparable size without any kind of supervision on the latent variables; (iii) we provide ablation studies for a better understanding of the contributions of different components of our proposed method; and (iv) we release our code and checkpoints to facilitate future work and for reproducibility.2 ",
145
+ "bbox": [
146
+ 174,
147
+ 622,
148
+ 825,
149
+ 705
150
+ ],
151
+ "page_idx": 1
152
+ },
153
+ {
154
+ "type": "text",
155
+ "text": "EMDR2 is a framework that can be used to train retrieval-augmented text generation models for any task. We believe that our estimation technique in EMDR2 is also useful for learning similar latent variable models in other domains. ",
156
+ "bbox": [
157
+ 176,
158
+ 712,
159
+ 825,
160
+ 753
161
+ ],
162
+ "page_idx": 1
163
+ },
164
+ {
165
+ "type": "text",
166
+ "text": "2 Model ",
167
+ "text_level": 1,
168
+ "bbox": [
169
+ 174,
170
+ 777,
171
+ 258,
172
+ 794
173
+ ],
174
+ "page_idx": 1
175
+ },
176
+ {
177
+ "type": "text",
178
+ "text": "Our proposed model EMDR2 consists of two components: (i) a neural retriever and (ii) a neural reader, which we train jointly in an end-to-end setting. Figure 1 shows an illustration of our model and training procedure. We discuss each component and our training objective in detail below. ",
179
+ "bbox": [
180
+ 174,
181
+ 810,
182
+ 825,
183
+ 853
184
+ ],
185
+ "page_idx": 1
186
+ },
187
+ {
188
+ "type": "text",
189
+ "text": "2.1 Neural Retriever: Dual Encoder ",
190
+ "text_level": 1,
191
+ "bbox": [
192
+ 174,
193
+ 90,
194
+ 437,
195
+ 106
196
+ ],
197
+ "page_idx": 2
198
+ },
199
+ {
200
+ "type": "text",
201
+ "text": "Let the collection of evidence documents be denoted by $\\mathcal { D } = \\{ d _ { 1 } , \\hdots , d _ { M } \\}$ . Given a question $\\pmb q$ the goal of the retriever module is to select a subset of documents $\\mathcal { Z } \\subset \\mathcal { D }$ to answer the question. We model the retriever as a dual-encoder network (Bromley et al., 1994), where one encoder $f _ { q }$ encodes the question and another $f _ { d }$ encodes the evidence document (to a vector). The retrieval score is defined as the dot product between the two resulting vectors: ",
202
+ "bbox": [
203
+ 173,
204
+ 116,
205
+ 825,
206
+ 185
207
+ ],
208
+ "page_idx": 2
209
+ },
210
+ {
211
+ "type": "equation",
212
+ "img_path": "images/22ca51fd7c07416f3e57fae244282ccaf995c6225076fb292ccff4a6885906e3.jpg",
213
+ "text": "$$\n\\begin{array} { r } { \\mathrm { s c o r e } ( \\pmb { q } , \\pmb { d } _ { i } ; \\Phi ) = { f } _ { \\ b { q } } ( \\pmb { q } ; \\Phi _ { q } ) ^ { \\top } { f } _ { d } ( \\pmb { d } _ { i } ; \\Phi _ { d } ) , } \\end{array}\n$$",
214
+ "text_format": "latex",
215
+ "bbox": [
216
+ 362,
217
+ 190,
218
+ 633,
219
+ 210
220
+ ],
221
+ "page_idx": 2
222
+ },
223
+ {
224
+ "type": "text",
225
+ "text": "where $\\Phi = [ \\Phi _ { q } , \\Phi _ { d } ]$ denotes the retriever parameters. We select top- $K$ documents for the question $\\pmb q$ from $\\mathcal { D }$ based on the retrieval scores. We denote the set of retrieved documents by $\\mathcal { Z } = \\{ z _ { 1 } , \\ldots , z _ { K } \\}$ ",
226
+ "bbox": [
227
+ 169,
228
+ 214,
229
+ 825,
230
+ 243
231
+ ],
232
+ "page_idx": 2
233
+ },
234
+ {
235
+ "type": "text",
236
+ "text": "We use transformer encoders (Vaswani et al., 2017) as our $f _ { q }$ and $f _ { d }$ . Our transformer architecture is similar to BERT with 12 layers and 768 hidden size (Devlin et al., 2019). We use the final representation of the first token (i.e., the standard [CLS] token from BERT’s tokenization) as our question (and similarly document) embedding. Initializing $f _ { q }$ and $f _ { d }$ with BERT weights has been shown to lead to a poor retrieval accuracy (Lee et al., 2019, Sachan et al., 2021). Therefore, we initialize the retriever with an unsupervised training procedure. We discuss our initialization technique in detail in $\\ S$ . ",
237
+ "bbox": [
238
+ 173,
239
+ 248,
240
+ 825,
241
+ 347
242
+ ],
243
+ "page_idx": 2
244
+ },
245
+ {
246
+ "type": "text",
247
+ "text": "2.2 Neural Reader: Fusion-in-Decoder ",
248
+ "text_level": 1,
249
+ "bbox": [
250
+ 174,
251
+ 362,
252
+ 455,
253
+ 377
254
+ ],
255
+ "page_idx": 2
256
+ },
257
+ {
258
+ "type": "text",
259
+ "text": "The reader takes as input a question $\\pmb q$ and a set of retrieved documents (to be read) $\\mathcal { Z }$ to generate an answer. Our reader is based on the Fusion-in-Decoder (FiD; Izacard and Grave, 2021b) model, which is built on top of T5 (Raffel et al., 2020). T5 is a pretrained sequence-to-sequence transformer that consists of an encoder $g _ { e }$ and a decoder $g _ { d }$ . ",
260
+ "bbox": [
261
+ 173,
262
+ 387,
263
+ 825,
264
+ 444
265
+ ],
266
+ "page_idx": 2
267
+ },
268
+ {
269
+ "type": "text",
270
+ "text": "In FiD, each retrieved document $z _ { k }$ is first appended with its title $( t _ { z _ { k } } )$ and the question: ",
271
+ "bbox": [
272
+ 169,
273
+ 449,
274
+ 754,
275
+ 464
276
+ ],
277
+ "page_idx": 2
278
+ },
279
+ {
280
+ "type": "equation",
281
+ "img_path": "images/6916fb9654c771f7fe89261ca80f5a436b81054a555ecbb253fe2468a9994002.jpg",
282
+ "text": "$$\n\\pmb { x } _ { k } = [ \\mathbb { C } \\mathrm { L S } ] \\pmb { q } [ \\mathrm { S E P } ] \\pmb { t } _ { z _ { k } } [ \\mathrm { S E P } ] \\pmb { z } _ { k } [ \\mathrm { S E P } ] ,\n$$",
283
+ "text_format": "latex",
284
+ "bbox": [
285
+ 351,
286
+ 470,
287
+ 643,
288
+ 486
289
+ ],
290
+ "page_idx": 2
291
+ },
292
+ {
293
+ "type": "text",
294
+ "text": "where [CLS] is used to indicate the start of a document and [SEP] is used as a separator for the different parts of the document as well as the final token. ",
295
+ "bbox": [
296
+ 171,
297
+ 491,
298
+ 823,
299
+ 520
300
+ ],
301
+ "page_idx": 2
302
+ },
303
+ {
304
+ "type": "text",
305
+ "text": "Each $\\scriptstyle { \\mathbf { { \\mathit { x } } } } _ { k }$ is then independently given as an input to the T5 encoder $g _ { e }$ . The output representations corresponding to all of the retrieved documents are concatenated as: ",
306
+ "bbox": [
307
+ 169,
308
+ 526,
309
+ 823,
310
+ 554
311
+ ],
312
+ "page_idx": 2
313
+ },
314
+ {
315
+ "type": "equation",
316
+ "img_path": "images/daada4b35dea8701a42afcf7a8697f89a6b23d3a8e171fa1640f110ce6ebb9a6.jpg",
317
+ "text": "$$\n{ \\bf X } _ { \\mathcal { Z } } = [ g _ { e } ( { \\pmb x } _ { 1 } ) ; \\dots ; g _ { e } ( { \\pmb x } _ { K } ) ] \\in \\mathbb { R } ^ { ( N \\times K ) \\times H } ,\n$$",
318
+ "text_format": "latex",
319
+ "bbox": [
320
+ 351,
321
+ 559,
322
+ 645,
323
+ 579
324
+ ],
325
+ "page_idx": 2
326
+ },
327
+ {
328
+ "type": "text",
329
+ "text": "where $N$ is the number of tokens in each ${ \\pmb x } _ { k } { } ^ { 3 }$ and $H$ is the hidden size of the T5 encoder $g _ { e }$ . In this work, we use the T5-base configuration with $N = 5 1 2$ and $H = 7 6 8$ . ",
330
+ "bbox": [
331
+ 173,
332
+ 584,
333
+ 823,
334
+ 613
335
+ ],
336
+ "page_idx": 2
337
+ },
338
+ {
339
+ "type": "text",
340
+ "text": "$\\mathbf { X } _ { \\mathcal { Z } }$ is then given as an input to the T5 decoder $g _ { d }$ . When generating an answer token, the decoder attends to both previously generated tokens (i.e., causal attention) as well as the tokens encoded in $\\mathbf { X } _ { \\mathcal { Z } }$ (i.e., cross attention). Since $\\mathbf { X } _ { \\mathcal { Z } }$ contains information from multiple documents, the decoder has the ability to aggregate useful signals contained in multiple documents and jointly reason over them. We define the probability of the answer as: ",
341
+ "bbox": [
342
+ 173,
343
+ 619,
344
+ 825,
345
+ 689
346
+ ],
347
+ "page_idx": 2
348
+ },
349
+ {
350
+ "type": "equation",
351
+ "img_path": "images/b93150deefb243060486a5fbcc7597b547c37c71202cb839ac38ce709d4ef947.jpg",
352
+ "text": "$$\np ( \\pmb { a } \\mid \\pmb { q } , \\mathcal { Z } ; \\Theta ) = \\prod _ { t = 1 } ^ { T } p \\left( a _ { t } \\mid \\pmb { a } _ { < t } , \\pmb { q } , \\mathcal { Z } ; \\Theta \\right) ,\n$$",
353
+ "text_format": "latex",
354
+ "bbox": [
355
+ 354,
356
+ 694,
357
+ 642,
358
+ 738
359
+ ],
360
+ "page_idx": 2
361
+ },
362
+ {
363
+ "type": "text",
364
+ "text": "where $\\Theta$ denotes the reader parameters (i.e., T5 encoder and decoder) and $T$ is the number of answer tokens. We keep generating answer tokens until the decoder outputs a special EOS token or a pre-specified maximum answer length is reached. ",
365
+ "bbox": [
366
+ 173,
367
+ 741,
368
+ 825,
369
+ 785
370
+ ],
371
+ "page_idx": 2
372
+ },
373
+ {
374
+ "type": "text",
375
+ "text": "2.3 End-to-End Training of Reader and Retriever ",
376
+ "text_level": 1,
377
+ "bbox": [
378
+ 174,
379
+ 799,
380
+ 532,
381
+ 815
382
+ ],
383
+ "page_idx": 2
384
+ },
385
+ {
386
+ "type": "text",
387
+ "text": "In contrast to previous work on generative question answering, we train both the reader and the retriever jointly in an end-to-end differentiable fashion. ",
388
+ "bbox": [
389
+ 174,
390
+ 825,
391
+ 823,
392
+ 854
393
+ ],
394
+ "page_idx": 2
395
+ },
396
+ {
397
+ "type": "text",
398
+ "text": "Denote our latent variable which represents a set of retrieved documents by $Z$ and let $\\mathcal { Z }$ be a possible value of $Z$ . The marginal likelihood of an answer (marginalizing over all the possible values of $Z$ ) ",
399
+ "bbox": [
400
+ 176,
401
+ 859,
402
+ 825,
403
+ 888
404
+ ],
405
+ "page_idx": 2
406
+ },
407
+ {
408
+ "type": "image",
409
+ "img_path": "images/9e2662a32c5c5501904bf0ea417bf805daa3f201c7eef57857b0fdb3b1cf1efa.jpg",
410
+ "image_caption": [
411
+ "Figure 1: An illustration of the different components of $\\mathrm { E M D R } ^ { 2 }$ . Colored blocks indicate components which contain trainable parameters. "
412
+ ],
413
+ "image_footnote": [],
414
+ "bbox": [
415
+ 210,
416
+ 87,
417
+ 781,
418
+ 297
419
+ ],
420
+ "page_idx": 3
421
+ },
422
+ {
423
+ "type": "text",
424
+ "text": "is: $\\begin{array} { r } { p ( \\pmb { a } \\mid q ; \\Theta , \\Phi ) = \\sum _ { Z = \\mathcal { Z } } p ( \\pmb { a } \\mid q , \\mathcal { Z } ; \\Theta ) p ( \\mathcal { Z } \\mid q ; \\Phi ) } \\end{array}$ . The goal of our training procedure is to find $\\Phi$ and $\\Theta$ Z that would maximize the above objective. Exactly optimizing Eq. 3 is intractable as it is combinatorial in nature.4 For one particular value $\\mathcal { Z }$ , the log-likelihood is simpler to compute: $\\log p ( { \\pmb a } \\mid { \\pmb q } , { \\mathcal Z } ; { \\Theta } ) p ( { \\mathcal Z } \\mid { \\pmb q } ; { \\Phi } ) = \\log p ( { \\pmb a } \\mid { \\pmb q } , { \\mathcal Z } ; { \\Theta } ) + \\log p ( { \\mathcal Z } \\mid { \\pmb q } ; { \\Phi } )$ ",
425
+ "bbox": [
426
+ 173,
427
+ 364,
428
+ 825,
429
+ 422
430
+ ],
431
+ "page_idx": 3
432
+ },
433
+ {
434
+ "type": "text",
435
+ "text": "Expectation-maximization (EM) algorithm (Dempster et al., 1977) offers a solution to learning this latent variable model. In classical EM, we iteratively compute the posterior of $Z$ given all observed variables and use it to update $\\Theta$ and $\\Phi$ . ",
436
+ "bbox": [
437
+ 176,
438
+ 428,
439
+ 821,
440
+ 469
441
+ ],
442
+ "page_idx": 3
443
+ },
444
+ {
445
+ "type": "text",
446
+ "text": "We propose using two estimates of $Z { - } \\mathcal { Z } _ { \\mathrm { r e a d e r } }$ and $\\mathcal { Z } _ { \\mathrm { r e t r i e v e r } }$ —for updating the two components of the model (reader parameters $\\Theta$ and retriever parameters $\\Phi$ ): ",
447
+ "bbox": [
448
+ 173,
449
+ 476,
450
+ 823,
451
+ 505
452
+ ],
453
+ "page_idx": 3
454
+ },
455
+ {
456
+ "type": "equation",
457
+ "img_path": "images/adc5d83605acb74d7aa426f3d949b5600a40cc5cbebe667faa9cc9afb2fd560e.jpg",
458
+ "text": "$$\n\\log \\underbrace { p ( a \\mid q , \\mathcal { Z } _ { \\mathrm { r e a d e r } } ; \\Theta ) } _ { \\mathrm { r e a d e r } } + \\log \\underbrace { p ( \\mathcal { Z } _ { \\mathrm { r e t r i e v e r } } \\mid q ; \\Phi ) } _ { \\mathrm { r e t r i e v e r } } .\n$$",
459
+ "text_format": "latex",
460
+ "bbox": [
461
+ 341,
462
+ 512,
463
+ 655,
464
+ 547
465
+ ],
466
+ "page_idx": 3
467
+ },
468
+ {
469
+ "type": "text",
470
+ "text": "In the first term, we set the value of the latent variable $Z = \\mathcal { Z } _ { \\mathrm { r e a d e r } }$ based on the prior scores. In the second term, we seek to maximize an approximate posterior of $Z = \\mathcal { Z } _ { \\mathrm { r e t r i e v e r } }$ . We discuss them in more detail below. ",
471
+ "bbox": [
472
+ 174,
473
+ 554,
474
+ 825,
475
+ 597
476
+ ],
477
+ "page_idx": 3
478
+ },
479
+ {
480
+ "type": "text",
481
+ "text": "Reader parameters $\\Theta$ . For updating $\\Theta$ (the first term of Eq. 3), we use the top- $K$ documents with the highest individual scores (as computed by Eq. 1 based on the current value of $\\Phi$ ) to construct Zreader. This is equivalent to relying on the prior $p ( Z \\mid q ; \\Phi )$ to estimate ${ \\mathcal { Z } } _ { \\mathrm { r e a d e r } }$ (without using information from the answer $\\textbf { \\em a }$ ). We choose to use the prior to train reader parameters since the prior scores are also used at evaluation time to obtain the top- $K$ documents. As a result, there is no mismatch between training and test computations when computing $p ( \\pmb { a } \\mid \\pmb { q } , \\mathcal { Z } ; \\Theta )$ (i.e., $\\mathcal { Z }$ that is used at test time is obtained in exactly the same way as $\\mathcal { Z } _ { \\mathrm { r e a d e r } } = \\mathcal { Z } _ { \\mathrm { t o p } - K } ,$ . ",
482
+ "bbox": [
483
+ 173,
484
+ 613,
485
+ 825,
486
+ 712
487
+ ],
488
+ "page_idx": 3
489
+ },
490
+ {
491
+ "type": "text",
492
+ "text": "Retriever parameters $\\Phi$ . For updating $\\Phi$ (the second term of Eq. 3), we propose to use the posterior estimate. In other words, we use additional information from $\\textbf { \\em a }$ when evaluating $Z _ { \\mathrm { r e t r i e v e r } }$ to train $\\Phi$ . Using the posterior allows our retriever to learn from richer training signals as opposed to relying only on the prior. ",
493
+ "bbox": [
494
+ 174,
495
+ 727,
496
+ 825,
497
+ 784
498
+ ],
499
+ "page_idx": 3
500
+ },
501
+ {
502
+ "type": "text",
503
+ "text": "We need to be able to compute $p ( \\mathcal { Z } _ { \\mathrm { r e t r i e v e r } } \\mid q , a ; \\Theta , \\Phi )$ to maximize the retriever parameters. However, computing this quantity is difficult since it is a probability of a set.5 Consider a set of $K$ documents (e.g., ${ \\mathcal { Z } } _ { \\mathrm { t o p } - K } ,$ ), where $z _ { k }$ denotes a document in the set. We approximate the maximization of the probability of the set by assuming that its probability is maximized if the sum of the probability of each document in the set is maximized.6 With this approximation, we arrive at a simpler quantity: $\\begin{array} { r } { \\sum _ { k = 1 } ^ { K } p ( z _ { k } \\mid q , \\pmb { a } ; \\Theta , \\Phi ) } \\end{array}$ . Note that using Bayes rule, we can rewrite:7 ",
504
+ "bbox": [
505
+ 174,
506
+ 790,
507
+ 825,
508
+ 844
509
+ ],
510
+ "page_idx": 3
511
+ },
512
+ {
513
+ "type": "text",
514
+ "text": "",
515
+ "bbox": [
516
+ 171,
517
+ 90,
518
+ 823,
519
+ 122
520
+ ],
521
+ "page_idx": 4
522
+ },
523
+ {
524
+ "type": "equation",
525
+ "img_path": "images/fdda536b6663193f43ff710d71e2024465fbe0a45a1b40d289887f3ebc125c7b.jpg",
526
+ "text": "$$\np ( z _ { k } \\mid q , a ; \\Theta , \\Phi ) \\propto p ( a \\mid q , z _ { k } ; \\Theta ) p ( z _ { k } \\mid q ; \\Phi ) .\n$$",
527
+ "text_format": "latex",
528
+ "bbox": [
529
+ 334,
530
+ 126,
531
+ 663,
532
+ 143
533
+ ],
534
+ "page_idx": 4
535
+ },
536
+ {
537
+ "type": "text",
538
+ "text": "The reader now only conditions on one document when computing the probability of an answer $p ( \\pmb { a } \\mid \\pmb { q } , \\pmb { z } _ { k } ; \\Theta )$ . This simpler reader uses the same parameters as the more sophisticated one $\\Theta$ , but it only uses one document $z _ { k }$ instead of a set of documents. ",
539
+ "bbox": [
540
+ 173,
541
+ 148,
542
+ 826,
543
+ 189
544
+ ],
545
+ "page_idx": 4
546
+ },
547
+ {
548
+ "type": "text",
549
+ "text": "To compute Eq. 4, we first obtain $K$ documents with the highest scores as computed by Eq. 1 based on the current value of $\\Phi$ . We compute the probability of document $z _ { k } \\in \\mathcal { Z } _ { \\mathrm { t o p } - K }$ as: ",
550
+ "bbox": [
551
+ 173,
552
+ 195,
553
+ 823,
554
+ 224
555
+ ],
556
+ "page_idx": 4
557
+ },
558
+ {
559
+ "type": "equation",
560
+ "img_path": "images/8d04808cbe7ce31e92391af31799b327aea010e379173b9e1e77ded3cf4d3d59.jpg",
561
+ "text": "$$\np ( z _ { k } \\mid q , \\mathcal { Z } _ { \\mathrm { t o p } - K } ; \\Phi ) \\approx \\frac { \\exp ( \\operatorname { s c o r e } ( q , z _ { k } ) / \\tau ; \\Phi ) } { \\sum _ { j = 1 } ^ { K } \\exp ( \\operatorname { s c o r e } ( q , z _ { j } ) / \\tau ; \\Phi ) } ,\n$$",
562
+ "text_format": "latex",
563
+ "bbox": [
564
+ 316,
565
+ 229,
566
+ 679,
567
+ 268
568
+ ],
569
+ "page_idx": 4
570
+ },
571
+ {
572
+ "type": "text",
573
+ "text": "where $\\tau$ is a temperature hyperparameter and the approximation assumes that documents beyond the top- $K$ contributes very small scores so we do not need to sum over all evidence documents $M$ in the denominator (which is in the order of tens of millions in our experiments). We then compute $p ( \\pmb { a } \\mid \\pmb { q } , \\pmb { z } _ { k } ; \\Theta )$ similarly to Eq. 2. ",
574
+ "bbox": [
575
+ 173,
576
+ 271,
577
+ 825,
578
+ 328
579
+ ],
580
+ "page_idx": 4
581
+ },
582
+ {
583
+ "type": "text",
584
+ "text": "Overall training objective of $\\mathbf { E M D R } ^ { 2 }$ . Combining the above derivations, our end-to-end training objective that we seek to maximize for a particular example becomes: ",
585
+ "bbox": [
586
+ 171,
587
+ 340,
588
+ 823,
589
+ 371
590
+ ],
591
+ "page_idx": 4
592
+ },
593
+ {
594
+ "type": "equation",
595
+ "img_path": "images/5d7f328b461f379d35a13dece670d79316fa1b6659783e077c97f32245386e18.jpg",
596
+ "text": "$$\n\\mathcal { L } = \\underbrace { \\log p ( a \\mid q , \\mathcal { Z } _ { \\mathrm { t o p } \\cdot K } ; \\Theta ) } _ { \\mathrm { r e a d e r } } + \\log \\sum _ { k = 1 } ^ { K } \\mathbb { S } \\mathbb { G } \\left( p ( a \\mid q , z _ { k } ; \\Theta ) \\right) p ( z _ { k } \\mid q , \\mathcal { Z } _ { \\mathrm { t o p } \\cdot K } ; \\Phi ) ,\n$$",
597
+ "text_format": "latex",
598
+ "bbox": [
599
+ 235,
600
+ 373,
601
+ 761,
602
+ 420
603
+ ],
604
+ "page_idx": 4
605
+ },
606
+ {
607
+ "type": "text",
608
+ "text": "where $\\mathbb { S } \\mathbb { G }$ is the stop-gradient operator so that the reader parameters $\\Theta$ are not updated to also perform well given a single document $z _ { k }$ . The stop-gradient operator in the second term of $\\mathrm { E M D R ^ { 2 } }$ has several benefits. First, the FiD reader is trained from the first term of the $\\mathrm { E M D R ^ { 2 } }$ objective in which its likelihood is conditioned on all the retrieved documents, similar to how the reader is used at test time. Second, it also makes training faster since the backward pass which is computationally more expensive than the forward pass is not needed, which in turn reduces the usage of GPU RAM as intermediate activations need not be saved. ",
609
+ "bbox": [
610
+ 173,
611
+ 438,
612
+ 825,
613
+ 536
614
+ ],
615
+ "page_idx": 4
616
+ },
617
+ {
618
+ "type": "text",
619
+ "text": "Given a training example, we update $\\Theta$ and $\\Phi$ by taking gradients of Eq. 6 with respect to $\\Theta$ and $\\Phi$ in an end-to-end fashion. Intuitively, we train the reader to generate the correct answer given $K$ highest scoring documents ${ \\mathcal { Z } } _ { \\mathrm { t o p } - K }$ . For the retriever, we train it to select $K$ documents which collectively has a high score of generating an answer (since the sum over $K$ is inside the log in the second term) while taking into account feedback from the reader. Algorithm 1 summarizes our training algorithm. ",
620
+ "bbox": [
621
+ 173,
622
+ 541,
623
+ 826,
624
+ 612
625
+ ],
626
+ "page_idx": 4
627
+ },
628
+ {
629
+ "type": "text",
630
+ "text": "Algorithm 1: End-to-end training of multi-document reader and retriever. ",
631
+ "bbox": [
632
+ 174,
633
+ 630,
634
+ 656,
635
+ 645
636
+ ],
637
+ "page_idx": 4
638
+ },
639
+ {
640
+ "type": "text",
641
+ "text": "Input: Model parameters $\\Theta$ and $\\Phi$ , evidence documents $\\mathcal { D }$ ",
642
+ "bbox": [
643
+ 173,
644
+ 647,
645
+ 562,
646
+ 661
647
+ ],
648
+ "page_idx": 4
649
+ },
650
+ {
651
+ "type": "text",
652
+ "text": "while not converged do ",
653
+ "bbox": [
654
+ 174,
655
+ 662,
656
+ 330,
657
+ 675
658
+ ],
659
+ "page_idx": 4
660
+ },
661
+ {
662
+ "type": "text",
663
+ "text": "• Compute ${ \\mathcal { Z } } _ { \\mathrm { t o p } - K }$ using the current retriever parameters $\\Phi$ . // E-step • Compute $p ( \\dot { \\pmb { a } } \\mid \\pmb { q } , \\pmb { z } _ { k } )$ for each $z _ { k }$ using the current reader parameters $\\Theta$ . // E-step • Update model parameters $\\Theta$ and $\\Phi$ to maximize the log-likelihood in Eq. 6. // M-step ",
664
+ "bbox": [
665
+ 196,
666
+ 676,
667
+ 802,
668
+ 718
669
+ ],
670
+ "page_idx": 4
671
+ },
672
+ {
673
+ "type": "text",
674
+ "text": "end ",
675
+ "bbox": [
676
+ 173,
677
+ 719,
678
+ 202,
679
+ 731
680
+ ],
681
+ "page_idx": 4
682
+ },
683
+ {
684
+ "type": "text",
685
+ "text": "3 Experiments ",
686
+ "text_level": 1,
687
+ "bbox": [
688
+ 174,
689
+ 766,
690
+ 312,
691
+ 784
692
+ ],
693
+ "page_idx": 4
694
+ },
695
+ {
696
+ "type": "text",
697
+ "text": "3.1 Datasets ",
698
+ "text_level": 1,
699
+ "bbox": [
700
+ 174,
701
+ 797,
702
+ 272,
703
+ 811
704
+ ],
705
+ "page_idx": 4
706
+ },
707
+ {
708
+ "type": "text",
709
+ "text": "We experiment with three commonly used open-domain question answering datasets: ",
710
+ "bbox": [
711
+ 176,
712
+ 823,
713
+ 730,
714
+ 838
715
+ ],
716
+ "page_idx": 4
717
+ },
718
+ {
719
+ "type": "text",
720
+ "text": "6 The intuition is that each element of the set contributes independently, which greatly simplifies the computation to find the maximum of the set. ",
721
+ "bbox": [
722
+ 173,
723
+ 847,
724
+ 823,
725
+ 872
726
+ ],
727
+ "page_idx": 4
728
+ },
729
+ {
730
+ "type": "text",
731
+ "text": "• Natural Questions (NQ; Kwiatkowski et al., 2019). NQ contains questions asked by users of the Google search engine. Similar to Lee et al. (2019), we use the short answer subset. ",
732
+ "bbox": [
733
+ 218,
734
+ 92,
735
+ 825,
736
+ 119
737
+ ],
738
+ "page_idx": 5
739
+ },
740
+ {
741
+ "type": "text",
742
+ "text": "• TriviaQA (Joshi et al., 2017). TriviaQA is a collection of trivia question-answer pairs that were collected from multiple sources on the web. ",
743
+ "bbox": [
744
+ 218,
745
+ 125,
746
+ 823,
747
+ 151
748
+ ],
749
+ "page_idx": 5
750
+ },
751
+ {
752
+ "type": "text",
753
+ "text": "• WebQuestions (WebQ; Berant et al., 2013). WebQ questions were collected using Google Suggest API and the answers were annotated using Mechanical Turk. We use the version from Chen et al. (2017) where Freebase IDs in the answers are replaced by entity names. ",
754
+ "bbox": [
755
+ 222,
756
+ 156,
757
+ 823,
758
+ 199
759
+ ],
760
+ "page_idx": 5
761
+ },
762
+ {
763
+ "type": "text",
764
+ "text": "Evidence documents $\\mathcal { D }$ . We use the preprocessed English Wikipedia dump from December 2018 released by Karpukhin et al. (2020) as our evidence documents. Each Wikipedia article is split into non-overlapping 100 words long segments. Each segment corresponds to a document in our case. There are a total of 21,015,324 documents in total. ",
765
+ "bbox": [
766
+ 176,
767
+ 214,
768
+ 826,
769
+ 270
770
+ ],
771
+ "page_idx": 5
772
+ },
773
+ {
774
+ "type": "text",
775
+ "text": "We provide descriptive statistics and other preprocessing details in Appendix A. ",
776
+ "bbox": [
777
+ 174,
778
+ 276,
779
+ 694,
780
+ 291
781
+ ],
782
+ "page_idx": 5
783
+ },
784
+ {
785
+ "type": "text",
786
+ "text": "3.2 Implementation Details ",
787
+ "text_level": 1,
788
+ "bbox": [
789
+ 174,
790
+ 308,
791
+ 377,
792
+ 321
793
+ ],
794
+ "page_idx": 5
795
+ },
796
+ {
797
+ "type": "text",
798
+ "text": "Hardware and library. We run all of our experiments on a machine with 96 CPUs, 1.3TB physical memory, and 16 A100 GPUs. We use PyTorch (Paszke et al., 2019) to implement our proposed model and relevant baselines. ",
799
+ "bbox": [
800
+ 174,
801
+ 333,
802
+ 825,
803
+ 375
804
+ ],
805
+ "page_idx": 5
806
+ },
807
+ {
808
+ "type": "text",
809
+ "text": "Model configurations. For both the retriever and reader, we use the base configuration that consists of 12 layers, 768 dimensional hidden size, and 12 attention heads. In all experiments, we retrieve 50 documents, unless stated otherwise. We only use the base configuration in our experiments due to GPU memory constraints. However, we believe that our results would generalize to larger configurations as well. ",
810
+ "bbox": [
811
+ 174,
812
+ 390,
813
+ 825,
814
+ 459
815
+ ],
816
+ "page_idx": 5
817
+ },
818
+ {
819
+ "type": "text",
820
+ "text": "Retrieval. To support fast retrieval, we pre-compute evidence document embeddings and store them in a distributed fashion over all the GPUs. We refer to these document embeddings as the document index. For each question, we retrieve documents in an online (on-the-fly) manner by performing exact maximum inner product search (MIPS), implemented using asynchronous distributed matrix multiplication over the document index. These documents are converted to subwords using BERT’s tokenization and are given as input to the T5 reader. If a tokenized document is shorter than 512 tokens, it is padded using the tokens from the neighboring documents until the maximum token limit is reached. Such padding additionally helps to provide an extended context for answer generation. ",
821
+ "bbox": [
822
+ 174,
823
+ 474,
824
+ 825,
825
+ 585
826
+ ],
827
+ "page_idx": 5
828
+ },
829
+ {
830
+ "type": "text",
831
+ "text": "Initialization and training details. We initialize the parameters of the model with unsupervised pre-training before performing supervised training using the question-answer training examples. Unsupervised pre-training is essential as it helps to warm-start the retriever so that it outputs relevant documents for a given question. ",
832
+ "bbox": [
833
+ 174,
834
+ 601,
835
+ 825,
836
+ 656
837
+ ],
838
+ "page_idx": 5
839
+ },
840
+ {
841
+ "type": "text",
842
+ "text": "We first pre-train the retriever parameters with unsupervised Inverse Cloze Task training (Lee et al., 2019) for 100,000 steps. We then extract sentences containing named entities from the evidence documents. Next, we replace $15 \\%$ of the named entity tokens with masked tokens, which are often referred to as masked salient spans (MSS; Guu et al., 2020). The masked sentence can be considered as the question and its salient spans (i.e, named entities) can be considered as the answer to train the model with Eq. 6. We train the model on these question-answer (masked sentence-named entities) pairs for 82,000 steps with a batch size of 64 using Adam (Kingma and Ba, 2015). We refer to this initialization method as unsupervised pre-training with masked salient spans. We provide further description in Appendix C. ",
843
+ "bbox": [
844
+ 174,
845
+ 662,
846
+ 825,
847
+ 787
848
+ ],
849
+ "page_idx": 5
850
+ },
851
+ {
852
+ "type": "text",
853
+ "text": "After MSS training, we finetune the model on the dataset-specific question-answer training examples with EMDR2. We perform training for 10 epochs on NQ and TriviaQA with a batch size of 64, and for 20 epochs on WebQ with a batch size of 16. During training, we save a checkpoint every 500 steps and select the best checkpoint based on its performance on the development set. ",
854
+ "bbox": [
855
+ 174,
856
+ 794,
857
+ 825,
858
+ 849
859
+ ],
860
+ "page_idx": 5
861
+ },
862
+ {
863
+ "type": "text",
864
+ "text": "During end-to-end training, since the parameters of the document encoder $( f _ { d } )$ are also updated at every step, the pre-computed document embeddings become stale as training progresses. We use the most recent document encoder checkpoint to compute fresh document embeddings asynchronously with which the document index is updated after every 500 training steps to prevent staleness. ",
865
+ "bbox": [
866
+ 176,
867
+ 856,
868
+ 823,
869
+ 911
870
+ ],
871
+ "page_idx": 5
872
+ },
873
+ {
874
+ "type": "table",
875
+ "img_path": "images/1370a3f595fa7581589afd2b33298e062eb93c57fa2fbcd2cc04ae08a0004edc.jpg",
876
+ "table_caption": [
877
+ "Table 2: Exact match scores on three evaluation datasets. Top- $K$ denotes the number of retrieved documents that are used by the reader to produce an answer. To provide a fair comparison with our reimplementations, we show results from other papers with the base configuration, except for RAG-Sequence that uses BART-large (Lewis et al., 2020a). $\\dagger$ indicates that their results on WebQ use NQ training data to pretrain the model. "
878
+ ],
879
+ "table_footnote": [],
880
+ "table_body": "<table><tr><td rowspan=\"2\">Model</td><td rowspan=\"2\">top-K</td><td colspan=\"2\">NQ</td><td colspan=\"2\">TriviaQA</td><td colspan=\"2\">WebQ</td><td rowspan=\"2\">#of params</td></tr><tr><td>dev</td><td>test</td><td>dev</td><td>test</td><td>dev</td><td>test</td></tr><tr><td colspan=\"9\">Closed-Book QA Models</td></tr><tr><td>T5-base (Roberts et al., 2020)</td><td>0</td><td></td><td>25.7</td><td></td><td>24.2</td><td>=</td><td>28.2</td><td>220M</td></tr><tr><td>T5-large (Roberts et al.,2020)</td><td>0</td><td>-</td><td>27.3</td><td>=</td><td>28.5</td><td></td><td>29.5</td><td>770M</td></tr><tr><td>T5-XXL (Roberts et al., 2020)</td><td>0</td><td></td><td>32.8</td><td></td><td>42.9</td><td></td><td>35.6</td><td>11B</td></tr><tr><td>GPT-3 (Brown et al., 2020)</td><td>0</td><td>-</td><td>29.9</td><td>=</td><td>1</td><td>=</td><td>41.5</td><td>175B</td></tr><tr><td colspan=\"9\">Open-Book QA Models</td></tr><tr><td>BM25 + BERT (Lee et al., 2019)</td><td>5</td><td>24.8</td><td>26.5</td><td>47.2</td><td>47.1</td><td>27.1</td><td>21.3</td><td>220M</td></tr><tr><td>ORQA (Lee et al., 2019)</td><td>5</td><td>31.3</td><td>33.3</td><td>45.1</td><td>45.0</td><td>36.8</td><td>30.1</td><td>330M</td></tr><tr><td>REALM (Guu et al., 2020)</td><td>5</td><td>38.2</td><td>40.4</td><td>1</td><td>1</td><td>1</td><td>40.7</td><td>330M</td></tr><tr><td>DPR (Karpukhin et al., 2020)</td><td>25</td><td>1</td><td>41.5</td><td>-</td><td>56.8</td><td>-</td><td>34.6</td><td>330M</td></tr><tr><td>RECONsIDER (Iyer et al.,2021)t</td><td>30</td><td>-</td><td>43.1</td><td>1</td><td>59.3</td><td>-</td><td>44.4</td><td>440M</td></tr><tr><td>RAG-Sequence (Lewis et al., 2020b)t</td><td>50</td><td>44.0</td><td>44.5</td><td>55.8</td><td>56.8</td><td>44.9</td><td>45.2</td><td>626M</td></tr><tr><td>Individual Top-K (Sachan et al., 2021)</td><td>-</td><td>1</td><td>45.9</td><td>1</td><td>56.3</td><td>1</td><td>1</td><td>440M</td></tr><tr><td>Joint Top-K (Sachan et al., 2021)</td><td>50</td><td>-</td><td>49.2</td><td>1</td><td>64.8</td><td>-</td><td>-</td><td>440M</td></tr><tr><td>FiD (Izacard and Grave, 2021b)</td><td>100</td><td>1</td><td>48.2</td><td>1</td><td>65.0</td><td>=</td><td>=</td><td>440M</td></tr><tr><td>FiD-KD (Izacard and Grave, 2021a)</td><td>100</td><td>48.0</td><td>49.6</td><td>68.6</td><td>68.8</td><td>=</td><td>=</td><td>440M</td></tr><tr><td colspan=\"9\">Our Implementation (Base Configuration)</td></tr><tr><td>FiD /T5-base</td><td>0</td><td>26.0</td><td>25.1</td><td>26.7</td><td>27.8</td><td>31.0</td><td>32.4</td><td>220M</td></tr><tr><td>FiD (DPR retriever, T5 reader)</td><td>1</td><td>37.3</td><td>38.4</td><td>50.8</td><td>50.4</td><td>40.2</td><td>38.3</td><td>440M</td></tr><tr><td>FiD (DPR retriever, T5 reader)</td><td>50</td><td>47.3</td><td>48.3</td><td>65.5</td><td>66.3</td><td>46.0</td><td>45.2</td><td>440M</td></tr><tr><td>FiD (MSS+DPR retriever, T5 reader)</td><td>50</td><td>48.8</td><td>50.4</td><td>68.0</td><td>68.8</td><td>43.5</td><td>46.8</td><td>440M</td></tr><tr><td>FiD (MSS retriever, MSS reader)</td><td>50</td><td>38.5</td><td>40.1</td><td>60.0</td><td>59.8</td><td>39.1</td><td>40.2</td><td>440M</td></tr><tr><td>EMDR² (MSS retriever,MSS reader)</td><td>50</td><td>50.4</td><td>52.5</td><td>71.1</td><td>71.4</td><td>49.9</td><td>48.7</td><td>440M</td></tr></table>",
881
+ "bbox": [
882
+ 174,
883
+ 90,
884
+ 825,
885
+ 459
886
+ ],
887
+ "page_idx": 6
888
+ },
889
+ {
890
+ "type": "text",
891
+ "text": "Inference. We use greedy decoding for answer generation at inference time. ",
892
+ "bbox": [
893
+ 174,
894
+ 582,
895
+ 684,
896
+ 597
897
+ ],
898
+ "page_idx": 6
899
+ },
900
+ {
901
+ "type": "text",
902
+ "text": "3.3 Baselines ",
903
+ "text_level": 1,
904
+ "bbox": [
905
+ 174,
906
+ 633,
907
+ 277,
908
+ 647
909
+ ],
910
+ "page_idx": 6
911
+ },
912
+ {
913
+ "type": "text",
914
+ "text": "We compare our model to other approaches for OpenQA that can be categorized under the following two classes: ",
915
+ "bbox": [
916
+ 176,
917
+ 667,
918
+ 823,
919
+ 695
920
+ ],
921
+ "page_idx": 6
922
+ },
923
+ {
924
+ "type": "text",
925
+ "text": "• Closed-book QA models. Large-scale language models capture a lot of world knowledge in their parameters derived from the corpus they have been trained on (Petroni et al., 2019). We compare with the work of Roberts et al. (2020) who show that larger T5 models—when finetuned with question-answer pairs—can perform remarkably well. We also compare with the few-shot results of GPT-3 (Brown et al., 2020).8 ",
926
+ "bbox": [
927
+ 218,
928
+ 722,
929
+ 825,
930
+ 791
931
+ ],
932
+ "page_idx": 6
933
+ },
934
+ {
935
+ "type": "text",
936
+ "text": "• Open-book QA models. Similar to this work, these models consist of retriever and reader components and adopt the retrieve then predict approach for answering questions given a collection of evidence documents. These models mainly differ in how the retriever is initialized (ORQA; Lee et al., 2019, DPR; Karpukhin et al., 2020), whether the reader processes a single document (ORQA, DPR, RAG; Lewis et al., 2020b) or multiple documents (FiD; Izacard and Grave, 2021b), or whether the reader and retriever are trained jointly or in a multistage process (REALM; Guu et al., 2020, FiD-KD; Izacard and Grave, 2021a). ",
937
+ "bbox": [
938
+ 218,
939
+ 814,
940
+ 825,
941
+ 911
942
+ ],
943
+ "page_idx": 6
944
+ },
945
+ {
946
+ "type": "text",
947
+ "text": "3.4 Results ",
948
+ "text_level": 1,
949
+ "bbox": [
950
+ 174,
951
+ 92,
952
+ 263,
953
+ 106
954
+ ],
955
+ "page_idx": 7
956
+ },
957
+ {
958
+ "type": "text",
959
+ "text": "We follow standard conventions and report exact match (EM) scores using the reference answers included in each dataset. Table 2 shows our main results. We divide the table into three main sections: closed-book QA models, open-book QA models, and our implementation. The first two sections contain results from other papers, which we include for comparisons. The last section includes results from our proposed model, as well as our reimplementation of relevant baselines to control for our experimental setup. ",
960
+ "bbox": [
961
+ 174,
962
+ 117,
963
+ 825,
964
+ 200
965
+ ],
966
+ "page_idx": 7
967
+ },
968
+ {
969
+ "type": "text",
970
+ "text": "Our reimplementation of T5-base provides strong baselines when the number of retrieved documents is set to 0 (no retrieval) and 1. From Table 2, we see that the setting of top-1 vastly improves performance over the setting with no retrieved documents, signifying the importance of retrieval for OpenQA tasks. When further increasing the top- $k$ documents to 50, the performance of the FiD models substantially improves over the top-1 retrieval, verifying the observation from (Izacard and Grave, 2021b) about the importance of modeling the retrieved documents as a set. ",
971
+ "bbox": [
972
+ 174,
973
+ 207,
974
+ 825,
975
+ 290
976
+ ],
977
+ "page_idx": 7
978
+ },
979
+ {
980
+ "type": "text",
981
+ "text": "Comparing EMDR2 with our reimplementation of FiD illustrates the benefit of our end-to-end training approach. The underlying model is similar in both cases, but the training method is different. FiD adopts a two-stage approach to first train the retriever and then the reader. We have three variants of FiD: (i) the reader and retriever are initialized with MSS training, (ii) the retriever is initialized with DPR training, which is the setting used in the original paper (Izacard and Grave, 2021b), and (iii) the retriever is initialized with $\\mathrm { M S S + D P R }$ training from (Sachan et al., 2021), as it further improves DPR recall. EMDR2 outperforms all the variants by large margins on all the datasets. ",
982
+ "bbox": [
983
+ 174,
984
+ 296,
985
+ 825,
986
+ 393
987
+ ],
988
+ "page_idx": 7
989
+ },
990
+ {
991
+ "type": "text",
992
+ "text": "The current best approach for training multi-document reader and retriever is FiD-KD (Izacard and Grave, 2021a). FiD-KD is a complex training procedure that requires multiple training stages and performs knowledge distillation with inter-attention scores. We take the results from the original paper when comparing our model with FiD-KD. EMDR2 outperforms the reported numbers of FiD-KD by more than 2.5 points on NQ and TriviaQA to obtain new state-of-the-art results on these benchmarks. ",
993
+ "bbox": [
994
+ 174,
995
+ 400,
996
+ 825,
997
+ 468
998
+ ],
999
+ "page_idx": 7
1000
+ },
1001
+ {
1002
+ "type": "text",
1003
+ "text": "In addition to better performance, $\\mathrm { E M D R } ^ { 2 }$ also has three other advantages compared to FiD-KD: (i) EMDR2 is more efficient since it only uses 50 evidence documents, whereas FiD-KD leverages 100 documents; (ii) FiD-KD is based on a distillation approach which requires multiple cycles of retriever and reader training, while EMDR2 only requires one cycle of end-to-end training; and (iii) FiD-KD relies on supervised initialization of the retriever to achieve its best performance. EMDR2 is more robust to the retriever initialization, as demonstrated by state-of-the-art results even with unsupervised initialization of the retriever. ",
1004
+ "bbox": [
1005
+ 174,
1006
+ 474,
1007
+ 825,
1008
+ 571
1009
+ ],
1010
+ "page_idx": 7
1011
+ },
1012
+ {
1013
+ "type": "text",
1014
+ "text": "For the WebQ dataset, the training set size is much smaller compared to the other datasets (Table 5). Previous approaches such as RAG rely on supervised transfer (i.e., they finetune a model pre-trained on NQ) to obtain good results. In contrast, EMDR2 improves over the results from this RAG model by 3.5 points without the supervised transfer step. This result demonstrates the applicability of our approach to the low-resource setting where we only have a limited number of training examples. ",
1015
+ "bbox": [
1016
+ 174,
1017
+ 579,
1018
+ 825,
1019
+ 648
1020
+ ],
1021
+ "page_idx": 7
1022
+ },
1023
+ {
1024
+ "type": "text",
1025
+ "text": "We also perform qualitative analysis of the model outputs, which is included in Appendix E. ",
1026
+ "bbox": [
1027
+ 174,
1028
+ 655,
1029
+ 774,
1030
+ 669
1031
+ ],
1032
+ "page_idx": 7
1033
+ },
1034
+ {
1035
+ "type": "text",
1036
+ "text": "3.5 Ablations ",
1037
+ "text_level": 1,
1038
+ "bbox": [
1039
+ 174,
1040
+ 686,
1041
+ 279,
1042
+ 700
1043
+ ],
1044
+ "page_idx": 7
1045
+ },
1046
+ {
1047
+ "type": "text",
1048
+ "text": "Number of retrieved documents. We investigate the performance of $\\mathrm { E M D R } ^ { 2 }$ and FiD as we vary the number of retrieved documents $K$ in Figure 2. We observe that when the number of retrieved documents is increased, both $\\mathrm { E M D R } ^ { 2 }$ and FiD improve in performance. When $K$ is small, the gap between EMDR2 and FiD is larger. This indicates the efficacy of $\\mathrm { E M D R } ^ { 2 }$ in a more constrained setting where we can only retrieve a small number of documents (e.g., due to memory limitations). ",
1049
+ "bbox": [
1050
+ 174,
1051
+ 713,
1052
+ 823,
1053
+ 782
1054
+ ],
1055
+ "page_idx": 7
1056
+ },
1057
+ {
1058
+ "type": "text",
1059
+ "text": "Retriever initialization. We explore the effect of different parameter initialization strategies when training with $\\mathrm { E M D R } ^ { 2 }$ : (i) unsupervised MSS pre-training, (ii) supervised retriever training (DPR), and (iii) MSS pre-training followed by supervised retriever training $( \\mathbf { M S S } + \\mathbf { D P R }$ ; Sachan et al. (2021)). Table 3 shows our results. We can see that on NQ, MSS pre-training being unsupervised leads to a lower initial retriever recall than DPR. After EMDR2 training, the recall improves by $20 \\%$ (highlighted in yellow cells). Training with DPR initialization leads to the same final recall as obtained by MSS pre-training, suggesting that DPR initialization of the retriever may not be an essential component to obtain good performance in OpenQA tasks. Similar trends are also observed on TriviaQA and WebQ. Similarly, $\\mathrm { M S S + D P R }$ initialization has a better initial recall but leads to a marginal or no improvements in answer extraction performance over MSS pre-training. Finally, we also observe that MSS pre-training also provides an improvement of 2 points in answer extraction on WebQ when compared to the T5 reader (shown in orange cells), highlighting its importance in the low-resource OpenQA tasks. ",
1060
+ "bbox": [
1061
+ 174,
1062
+ 787,
1063
+ 825,
1064
+ 871
1065
+ ],
1066
+ "page_idx": 7
1067
+ },
1068
+ {
1069
+ "type": "image",
1070
+ "img_path": "images/7dcd063be0e6d81cac03b624c5218469124ad2c2ee286002d863efadc3e0c9ae.jpg",
1071
+ "image_caption": [],
1072
+ "image_footnote": [],
1073
+ "bbox": [
1074
+ 184,
1075
+ 94,
1076
+ 812,
1077
+ 193
1078
+ ],
1079
+ "page_idx": 8
1080
+ },
1081
+ {
1082
+ "type": "table",
1083
+ "img_path": "images/d6b6b7bc88c3c194f683dd3a5675d6b247072de68a5415894c1958f26ee1ce98.jpg",
1084
+ "table_caption": [
1085
+ "Figure 2: Performance on NQ, TriviaQA, and WebQ as we vary the number of retrieved documents. "
1086
+ ],
1087
+ "table_footnote": [
1088
+ "Table 3: $\\mathrm { R @ 5 0 }$ denotes the retrieval recall from the top-50 retrieved documents. B.T. and A.T. indicates $\\mathrm { R @ 5 0 }$ score Before Training and After Training the model, respectively. "
1089
+ ],
1090
+ "table_body": "<table><tr><td></td><td></td><td colspan=\"2\">NQ (dev)</td><td colspan=\"4\">TriviaQA (dev)</td><td colspan=\"3\">WebQ (dev)</td></tr><tr><td>Retriever</td><td>Reader</td><td colspan=\"2\">R@50</td><td>EM</td><td colspan=\"2\">R@50</td><td>EM</td><td colspan=\"2\">R@50</td><td>EM</td></tr><tr><td>Initialization</td><td>Initialization</td><td>B.T.A.T.</td><td></td><td></td><td>B.T.</td><td>A.T.</td><td></td><td>B.T.</td><td>A.T.</td><td></td></tr><tr><td>MSS pre-training</td><td>MSS pre-training</td><td>66.4</td><td>86.3</td><td>50.4</td><td>74.8</td><td>86.2</td><td>71.1</td><td>59.8</td><td>88.6</td><td>49.9</td></tr><tr><td>MSS pre-training</td><td>T5</td><td>66.4</td><td>86.3</td><td>50.3</td><td>74.8</td><td>86.3</td><td>70.9</td><td>59.8</td><td>88.6</td><td>47.7</td></tr><tr><td>DPR training</td><td>T5</td><td>82.3</td><td>86.3</td><td>50.0</td><td>83.2</td><td>86.2</td><td>70.5</td><td>84.2</td><td>88.6</td><td>49.0</td></tr><tr><td>MSS +DPR</td><td>MSS pre-training</td><td>84.5</td><td>86.3</td><td>50.5</td><td>85.3</td><td>86.3</td><td>71.2</td><td>85.0</td><td>88.6</td><td>49.9</td></tr></table>",
1091
+ "bbox": [
1092
+ 173,
1093
+ 234,
1094
+ 826,
1095
+ 347
1096
+ ],
1097
+ "page_idx": 8
1098
+ },
1099
+ {
1100
+ "type": "text",
1101
+ "text": "",
1102
+ "bbox": [
1103
+ 173,
1104
+ 407,
1105
+ 825,
1106
+ 506
1107
+ ],
1108
+ "page_idx": 8
1109
+ },
1110
+ {
1111
+ "type": "text",
1112
+ "text": "3.6 Alternative End-to-End Training Objectives ",
1113
+ "text_level": 1,
1114
+ "bbox": [
1115
+ 174,
1116
+ 521,
1117
+ 519,
1118
+ 536
1119
+ ],
1120
+ "page_idx": 8
1121
+ },
1122
+ {
1123
+ "type": "text",
1124
+ "text": "We compare $\\mathrm { E M D R } ^ { 2 }$ objective (Eq. 6) to two alternative formulations for end-to-end training. ",
1125
+ "bbox": [
1126
+ 171,
1127
+ 546,
1128
+ 782,
1129
+ 561
1130
+ ],
1131
+ "page_idx": 8
1132
+ },
1133
+ {
1134
+ "type": "text",
1135
+ "text": "In the first alternative formulation, when training the retriever parameters $\\Phi$ , we simply factorize $p ( \\mathcal { Z } \\mid \\mathbf { \\bar { q } } ; \\Phi ) =$ $\\textstyle \\prod _ { k = 1 } ^ { K } p ( z _ { k } \\mid q ; \\Phi )$ to arrive at the following objective: ",
1136
+ "bbox": [
1137
+ 173,
1138
+ 568,
1139
+ 550,
1140
+ 614
1141
+ ],
1142
+ "page_idx": 8
1143
+ },
1144
+ {
1145
+ "type": "equation",
1146
+ "img_path": "images/7d9e8b05f0b14517cde3884bade9ceaeea5084f28aacb388f2f396334ae600ca.jpg",
1147
+ "text": "$$\n\\mathcal { L } _ { \\mathrm { a l t - 1 } } = \\log p ( \\boldsymbol { a } \\mid \\boldsymbol { q } , \\mathcal { Z } ; \\boldsymbol { \\Theta } ) + \\sum _ { k = 1 } ^ { K } \\log p ( \\boldsymbol { z } _ { k } \\mid \\boldsymbol { q } , \\mathcal { Z } ; \\boldsymbol { \\Phi } ) .\n$$",
1148
+ "text_format": "latex",
1149
+ "bbox": [
1150
+ 184,
1151
+ 619,
1152
+ 537,
1153
+ 664
1154
+ ],
1155
+ "page_idx": 8
1156
+ },
1157
+ {
1158
+ "type": "text",
1159
+ "text": "The second term in this objective is maximised by a uniform retrieval, in other words, by removing any discrimination between documents in the retriever. We include it to show the impact of an adversarial objective. ",
1160
+ "bbox": [
1161
+ 173,
1162
+ 670,
1163
+ 550,
1164
+ 726
1165
+ ],
1166
+ "page_idx": 8
1167
+ },
1168
+ {
1169
+ "type": "table",
1170
+ "img_path": "images/18f2441b9cc74b3dcbb1b78455e31edae3e0bf7d0f0879de75c102f2a65ccdb2.jpg",
1171
+ "table_caption": [],
1172
+ "table_footnote": [
1173
+ "Table 4: EM scores on the development set for alternative training objectives. "
1174
+ ],
1175
+ "table_body": "<table><tr><td>Method t top-k</td><td>NQ</td><td>TriviaQA</td><td>WebQ</td></tr><tr><td>FiD EMDR²</td><td>50 47.3 50 50.4</td><td>65.5 71.1</td><td>46.0 49.9</td></tr><tr><td>Lalt-1</td><td>50 14.1</td><td>11.9</td><td>28.0</td></tr><tr><td>Lalt-2</td><td>50 49.9</td><td>69.6</td><td>28.8</td></tr></table>",
1176
+ "bbox": [
1177
+ 565,
1178
+ 584,
1179
+ 820,
1180
+ 671
1181
+ ],
1182
+ "page_idx": 8
1183
+ },
1184
+ {
1185
+ "type": "text",
1186
+ "text": "In the second formulation, for each retrieved document, we approximate its posterior under the assumption that we have a uniform prior over the set of retrieved documents: $\\tilde { p } ( z _ { k } \\mid q , \\pmb { a } , \\mathcal { Z } _ { \\mathrm { t o p } - K } ; \\Theta ) \\propto$ $p ( { \\pmb a } \\mid { \\pmb q } , z _ { k } ; \\Theta ) \\times \\frac { 1 } { K }$ . We use this to train reader and retriever parameters as follows: ",
1187
+ "bbox": [
1188
+ 173,
1189
+ 731,
1190
+ 826,
1191
+ 776
1192
+ ],
1193
+ "page_idx": 8
1194
+ },
1195
+ {
1196
+ "type": "equation",
1197
+ "img_path": "images/9bf85e192de130b2929ab980ee5078a106a19f1d9426a72097edd12cb2ad763f.jpg",
1198
+ "text": "$$\n\\mathcal { L } _ { \\mathrm { a l t - 2 } } = \\log p ( \\boldsymbol { a } \\mid \\boldsymbol { q } , \\mathcal { Z } ; \\boldsymbol { \\Theta } ) + \\mathbb { K L } \\big ( \\mathbb { S } \\mathbb { G } \\left( \\tilde { p } ( \\boldsymbol { z } _ { k } \\mid \\boldsymbol { q } , \\boldsymbol { a } , \\mathcal { Z } _ { \\mathrm { t o p } \\cdot K } ; \\boldsymbol { \\Theta } ) \\right) \\mid \\mid p ( \\boldsymbol { z } _ { k } \\mid \\boldsymbol { q } , \\mathcal { Z } ; \\boldsymbol { \\Phi } ) \\big ) .\n$$",
1199
+ "text_format": "latex",
1200
+ "bbox": [
1201
+ 225,
1202
+ 784,
1203
+ 771,
1204
+ 801
1205
+ ],
1206
+ "page_idx": 8
1207
+ },
1208
+ {
1209
+ "type": "text",
1210
+ "text": "Intuitively, we try to match the probability of retrieving a document $z _ { k }$ with the “contribution” of that document to the generated answer $\\textbf { \\em a }$ , regardless of whether the retriever is relatively more or less likely to retreieve the document a priori. ",
1211
+ "bbox": [
1212
+ 174,
1213
+ 806,
1214
+ 825,
1215
+ 849
1216
+ ],
1217
+ "page_idx": 8
1218
+ },
1219
+ {
1220
+ "type": "text",
1221
+ "text": "Table 4 shows our results on the development set of NQ. We observe that training with the adversarial ${ \\mathcal { L } } _ { \\mathrm { a l t - 1 } }$ objective diverges, leading to poor performance, as expected. This shows that harming the retriever during training can significantly harm performance of the QA system. In contrast, although it disregards the estimated prior, the ${ \\mathcal { L } } _ { \\mathrm { a l t - 2 } }$ objective still improves over the FiD baseline for NQ and ",
1222
+ "bbox": [
1223
+ 174,
1224
+ 854,
1225
+ 825,
1226
+ 911
1227
+ ],
1228
+ "page_idx": 8
1229
+ },
1230
+ {
1231
+ "type": "text",
1232
+ "text": "TriviaQA. However, it still lags behind EMDR2. On WebQ, the ${ \\mathcal { L } } _ { \\mathrm { a l t - 2 } }$ objective diverges and leads to a poor performance. We leave further analysis on the convergence of ${ \\mathcal { L } } _ { \\mathrm { a l t - 2 } }$ objective as a part of future work. ",
1233
+ "bbox": [
1234
+ 176,
1235
+ 90,
1236
+ 823,
1237
+ 132
1238
+ ],
1239
+ "page_idx": 9
1240
+ },
1241
+ {
1242
+ "type": "text",
1243
+ "text": "4 Related Work ",
1244
+ "text_level": 1,
1245
+ "bbox": [
1246
+ 174,
1247
+ 151,
1248
+ 321,
1249
+ 170
1250
+ ],
1251
+ "page_idx": 9
1252
+ },
1253
+ {
1254
+ "type": "text",
1255
+ "text": "Our work is based on end-to-end training of neural readers and retrievers, which we discuss in $\\ S 1 , \\ S 2$ and $\\ S 3$ . Here we instead focus on discussing previous work related to standalone neural retrievers, neural readers, and their application in other natural language processing tasks. ",
1256
+ "bbox": [
1257
+ 174,
1258
+ 184,
1259
+ 825,
1260
+ 226
1261
+ ],
1262
+ "page_idx": 9
1263
+ },
1264
+ {
1265
+ "type": "text",
1266
+ "text": "Neural retrievers. There are two broad classes of neural retrievers based on the number of embeddings computed for a document: dual encoders (Yih et al., 2011, Lee et al., 2019) and multivector encoders (Khattab and Zaharia, 2020, Luan et al., 2021). Dual encoders store one embedding for each evidence document. Multivector encoders require multiple embeddings, which can be computationally expensive for large-scale retrieval. Due to the large size of the evidence document collection in OpenQA, our work uses the more efficient dual-encoder. Sachan et al. (2021) show that the performance of supervised dual encoders in OpenQA can be improved when pre-training with the Inverse Cloze Task for the high-resource setting or masked salient spans for the low-resource setting. ",
1267
+ "bbox": [
1268
+ 174,
1269
+ 232,
1270
+ 825,
1271
+ 343
1272
+ ],
1273
+ "page_idx": 9
1274
+ },
1275
+ {
1276
+ "type": "text",
1277
+ "text": "Neural readers. Neural readers output an answer given retrieved documents as its input. There are also two broad classes of neural readers: extractive and generative. Extractive readers (Clark and Gardner, 2018, de Masson d’Autume et al., 2019, Wang et al., 2019, Guu et al., 2020, Karpukhin et al., 2020) extract a span from a retrieved document to produce an answer. Generative readers (Izacard and Grave, 2021b), on the other hand, generates an answer conditioned on the retrieved documents. ",
1278
+ "bbox": [
1279
+ 174,
1280
+ 349,
1281
+ 825,
1282
+ 433
1283
+ ],
1284
+ "page_idx": 9
1285
+ },
1286
+ {
1287
+ "type": "text",
1288
+ "text": "Other application areas. In addition to question answering, retrieval-augmented methods have been successfully applied to other natural language processing tasks. In left-to-right language modeling, retrieving similar words from an external memory has been shown to improve perplexity (Khandelwal et al., 2020, Yogatama et al., 2021). In machine translation, retrieving domain-specific target language tokens has improved performance in domain adaptation (Khandelwal et al., 2021). Finally, in dialog modeling, retrieving knowledge-informed text has helped improve factual correctness in the generated conversations (Fan et al., 2021). ",
1289
+ "bbox": [
1290
+ 174,
1291
+ 439,
1292
+ 825,
1293
+ 536
1294
+ ],
1295
+ "page_idx": 9
1296
+ },
1297
+ {
1298
+ "type": "text",
1299
+ "text": "We provide a detailed comparison of EMDR2 with some of the previous work in Appendix C and D. ",
1300
+ "bbox": [
1301
+ 173,
1302
+ 541,
1303
+ 818,
1304
+ 558
1305
+ ],
1306
+ "page_idx": 9
1307
+ },
1308
+ {
1309
+ "type": "text",
1310
+ "text": "5 Discussion ",
1311
+ "text_level": 1,
1312
+ "bbox": [
1313
+ 174,
1314
+ 575,
1315
+ 292,
1316
+ 592
1317
+ ],
1318
+ "page_idx": 9
1319
+ },
1320
+ {
1321
+ "type": "text",
1322
+ "text": "Summary of contributions. We presented EMDR2, an end-to-end training method for retrievalaugmented question answering systems. We showed how to arrive at our training objective using the expectation-maximization algorithm. We demonstrated that EMDR2 achieves state-of-the-art performance on three benchmark OpenQA datasets. ",
1323
+ "bbox": [
1324
+ 174,
1325
+ 607,
1326
+ 825,
1327
+ 662
1328
+ ],
1329
+ "page_idx": 9
1330
+ },
1331
+ {
1332
+ "type": "text",
1333
+ "text": "Technical limitations. EMDR2 shares a few limitations with other retrieval-augmented question answering models. In particular, as evidence documents are stored in an uncompressed format, maintaining them and searching for relevant documents can be expensive (both in terms of compute and memory consumption). In our experiments, we only focused on open-domain question answering. It would be interesting to see how EMDR2 performs for other text generation models as well. We also note that training is relatively resource-heavy (requiring 16 GPUs), potentially having environmental concerns. ",
1334
+ "bbox": [
1335
+ 174,
1336
+ 678,
1337
+ 825,
1338
+ 773
1339
+ ],
1340
+ "page_idx": 9
1341
+ },
1342
+ {
1343
+ "type": "text",
1344
+ "text": "Potential negative societal impacts. While EMDR2 has the potential to improve language models in the low-resource setting (as demonstrated by our results on WebQ in $\\ S 3 . 4 )$ , it could exhibit typical biases that are associated with large language models. For example, our model does not have an explicit mechanism to generate answers that are calibrated for fairness across all spectra. As a retrieval-augmented method, it also could be more prone to generating fake answers if an attacker manages to have access and modify information in the collection of evidence documents. ",
1345
+ "bbox": [
1346
+ 174,
1347
+ 789,
1348
+ 825,
1349
+ 872
1350
+ ],
1351
+ "page_idx": 9
1352
+ },
1353
+ {
1354
+ "type": "text",
1355
+ "text": "Acknowledgements ",
1356
+ "text_level": 1,
1357
+ "bbox": [
1358
+ 176,
1359
+ 89,
1360
+ 338,
1361
+ 106
1362
+ ],
1363
+ "page_idx": 10
1364
+ },
1365
+ {
1366
+ "type": "text",
1367
+ "text": "The authors would like to thank the DeepMind Language team, Mila’s students, and anonymous reviewers for providing us valuable feedback and useful suggestions about this work that helped us improve the paper. ",
1368
+ "bbox": [
1369
+ 174,
1370
+ 121,
1371
+ 825,
1372
+ 162
1373
+ ],
1374
+ "page_idx": 10
1375
+ },
1376
+ {
1377
+ "type": "text",
1378
+ "text": "Funding Statement ",
1379
+ "text_level": 1,
1380
+ "bbox": [
1381
+ 174,
1382
+ 183,
1383
+ 336,
1384
+ 199
1385
+ ],
1386
+ "page_idx": 10
1387
+ },
1388
+ {
1389
+ "type": "text",
1390
+ "text": "DSS was supported by the Canada CIFAR AI Chair held by Prof. William Hamilton. ",
1391
+ "bbox": [
1392
+ 176,
1393
+ 213,
1394
+ 725,
1395
+ 228
1396
+ ],
1397
+ "page_idx": 10
1398
+ },
1399
+ {
1400
+ "type": "text",
1401
+ "text": "References ",
1402
+ "text_level": 1,
1403
+ "bbox": [
1404
+ 174,
1405
+ 248,
1406
+ 266,
1407
+ 265
1408
+ ],
1409
+ "page_idx": 10
1410
+ },
1411
+ {
1412
+ "type": "text",
1413
+ "text": "Berant, J., Chou, A., Frostig, R., and Liang, P. (2013). Semantic parsing on Freebase from questionanswer pairs. In Proceedings of the 2013 Conference on Empirical Methods in Natural Language Processing. \nBromley, J., Guyon, I., LeCun, Y., Säckinger, E., and Shah, R. (1994). Signature verification using a \"siamese\" time delay neural network. In Advances in Neural Information Processing Systems. \nBrown, T., Mann, B., Ryder, N., Subbiah, M., Kaplan, J. D., Dhariwal, P., Neelakantan, A., Shyam, P., Sastry, G., Askell, A., Agarwal, S., Herbert-Voss, A., Krueger, G., Henighan, T., Child, R., Ramesh, A., Ziegler, D., Wu, J., Winter, C., Hesse, C., Chen, M., Sigler, E., Litwin, M., Gray, S., Chess, B., Clark, J., Berner, C., McCandlish, S., Radford, A., Sutskever, I., and Amodei, D. (2020). Language models are few-shot learners. In Advances in Neural Information Processing Systems. \nChen, D., Fisch, A., Weston, J., and Bordes, A. (2017). Reading Wikipedia to answer open-domain questions. In Proceedings of the 55th Annual Meeting of the Association for Computational Linguistics (Volume 1: Long Papers). \nClark, C. and Gardner, M. (2018). Simple and effective multi-paragraph reading comprehension. In Proceedings of the 56th Annual Meeting of the Association for Computational Linguistics (Volume 1: Long Papers). \nde Masson d’Autume, C., Ruder, S., Kong, L., and Yogatama, D. (2019). Episodic memory in lifelong language learning. In Advances in Neural Information Processing Systems. \nDempster, A., Laird, N., and Rubin, D. (1977). Maximum likelihood from incomplete data via the em algorithm. Journal of the Royal Statistical Society, Series B, 1(39), 1–38. \nDevlin, J., Chang, M.-W., Lee, K., and Toutanova, K. (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). \nFan, A., Gardent, C., Braud, C., and Bordes, A. (2021). Augmenting Transformers with KNN-Based Composite Memory for Dialog. Transactions of the Association for Computational Linguistics, 9. \nGuu, K., Lee, K., Tung, Z., Pasupat, P., and Chang, M. (2020). Retrieval augmented language model pre-training. In Proceedings of the 37th International Conference on Machine Learning. \nIyer, S., Min, S., Mehdad, Y., and Yih, W. (2021). Reconsider: Re-ranking using span-focused cross-attention for open domain question answering. In Proceedings of the 2021 Conference of the North American Chapter of the Association for Computational Linguistics: Human Language Technologies, Volume 1 (Long and Short Papers). \nIzacard, G. and Grave, E. (2021a). Distilling knowledge from reader to retriever for question answering. In International Conference on Learning Representations. \nIzacard, G. and Grave, E. (2021b). Leveraging passage retrieval with generative models for open domain question answering. In Proceedings of the 16th Conference of the European Chapter of the Association for Computational Linguistics: Main Volume. ",
1414
+ "bbox": [
1415
+ 171,
1416
+ 265,
1417
+ 828,
1418
+ 911
1419
+ ],
1420
+ "page_idx": 10
1421
+ },
1422
+ {
1423
+ "type": "text",
1424
+ "text": "Joshi, M., Choi, E., Weld, D., and Zettlemoyer, L. (2017). TriviaQA: A large scale distantly supervised challenge dataset for reading comprehension. In Proceedings of the 55th Annual Meeting of the Association for Computational Linguistics (Volume 1: Long Papers). ",
1425
+ "bbox": [
1426
+ 173,
1427
+ 90,
1428
+ 821,
1429
+ 133
1430
+ ],
1431
+ "page_idx": 11
1432
+ },
1433
+ {
1434
+ "type": "text",
1435
+ "text": "Karpukhin, V., Oguz, B., Min, S., Wu, L., Edunov, S., Chen, D., and Yih, W.-t. (2020). Dense ˘ passage retrieval for open-domain question answering. In Proceedings of the 2020 Conference on Empirical Methods in Natural Language Processing (EMNLP). ",
1436
+ "bbox": [
1437
+ 176,
1438
+ 141,
1439
+ 820,
1440
+ 184
1441
+ ],
1442
+ "page_idx": 11
1443
+ },
1444
+ {
1445
+ "type": "text",
1446
+ "text": "Khandelwal, U., Levy, O., Jurafsky, D., Zettlemoyer, L., and Lewis, M. (2020). Generalization through memorization: Nearest neighbor language models. In International Conference on Learning Representations. ",
1447
+ "bbox": [
1448
+ 176,
1449
+ 191,
1450
+ 823,
1451
+ 234
1452
+ ],
1453
+ "page_idx": 11
1454
+ },
1455
+ {
1456
+ "type": "text",
1457
+ "text": "Khandelwal, U., Fan, A., Jurafsky, D., Zettlemoyer, L., and Lewis, M. (2021). Nearest neighbor machine translation. In International Conference on Learning Representations. ",
1458
+ "bbox": [
1459
+ 171,
1460
+ 242,
1461
+ 825,
1462
+ 272
1463
+ ],
1464
+ "page_idx": 11
1465
+ },
1466
+ {
1467
+ "type": "text",
1468
+ "text": "Khattab, O. and Zaharia, M. (2020). Colbert: Efficient and effective passage search via contextualized late interaction over bert. In Proceedings of the 43rd International ACM SIGIR Conference on Research and Development in Information Retrieval. ",
1469
+ "bbox": [
1470
+ 176,
1471
+ 279,
1472
+ 823,
1473
+ 323
1474
+ ],
1475
+ "page_idx": 11
1476
+ },
1477
+ {
1478
+ "type": "text",
1479
+ "text": "Kingma, D. P. and Ba, J. (2015). Adam: A method for stochastic optimization. In The 2015 International Conference for Learning Representations. ",
1480
+ "bbox": [
1481
+ 171,
1482
+ 330,
1483
+ 823,
1484
+ 359
1485
+ ],
1486
+ "page_idx": 11
1487
+ },
1488
+ {
1489
+ "type": "text",
1490
+ "text": "Kwiatkowski, T., Palomaki, J., Redfield, O., Collins, M., Parikh, A., Alberti, C., Epstein, D., Polosukhin, I., Kelcey, M., Devlin, J., Lee, K., Toutanova, K. N., Jones, L., Chang, M.-W., Dai, A., Uszkoreit, J., Le, Q., and Petrov, S. (2019). Natural questions: a benchmark for question answering research. Transactions of the Association of Computational Linguistics. ",
1491
+ "bbox": [
1492
+ 174,
1493
+ 367,
1494
+ 826,
1495
+ 424
1496
+ ],
1497
+ "page_idx": 11
1498
+ },
1499
+ {
1500
+ "type": "text",
1501
+ "text": "Lee, K., Chang, M.-W., and Toutanova, K. (2019). Latent retrieval for weakly supervised open domain question answering. In Proceedings of the 57th Annual Meeting of the Association for Computational Linguistics. ",
1502
+ "bbox": [
1503
+ 174,
1504
+ 431,
1505
+ 825,
1506
+ 474
1507
+ ],
1508
+ "page_idx": 11
1509
+ },
1510
+ {
1511
+ "type": "text",
1512
+ "text": "Lewis, M., Liu, Y., Goyal, N., Ghazvininejad, M., Mohamed, A., Levy, O., Stoyanov, V., and Zettlemoyer, L. (2020a). 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. ",
1513
+ "bbox": [
1514
+ 174,
1515
+ 482,
1516
+ 825,
1517
+ 539
1518
+ ],
1519
+ "page_idx": 11
1520
+ },
1521
+ {
1522
+ "type": "text",
1523
+ "text": "Lewis, P., Perez, E., Piktus, A., Petroni, F., Karpukhin, V., Goyal, N., Küttler, H., Lewis, M., Yih, W.-t., Rocktäschel, T., Riedel, S., and Kiela, D. (2020b). Retrieval-augmented generation for knowledge-intensive nlp tasks. In Advances in Neural Information Processing Systems. ",
1524
+ "bbox": [
1525
+ 174,
1526
+ 546,
1527
+ 825,
1528
+ 589
1529
+ ],
1530
+ "page_idx": 11
1531
+ },
1532
+ {
1533
+ "type": "text",
1534
+ "text": "Luan, Y., Eisenstein, J., Toutanova, K., and Collins, M. (2021). Sparse, Dense, and Attentional Representations for Text Retrieval. Transactions of the Association for Computational Linguistics, 9. ",
1535
+ "bbox": [
1536
+ 173,
1537
+ 597,
1538
+ 826,
1539
+ 638
1540
+ ],
1541
+ "page_idx": 11
1542
+ },
1543
+ {
1544
+ "type": "text",
1545
+ "text": "Min, S., Chen, D., Hajishirzi, H., and Zettlemoyer, L. (2019). A discrete hard EM approach for weakly supervised question answering. 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), Hong Kong, China. Association for Computational Linguistics. ",
1546
+ "bbox": [
1547
+ 173,
1548
+ 647,
1549
+ 825,
1550
+ 718
1551
+ ],
1552
+ "page_idx": 11
1553
+ },
1554
+ {
1555
+ "type": "text",
1556
+ "text": "Paszke, A., Gross, S., Massa, F., Lerer, A., Bradbury, J., Chanan, G., Killeen, T., Lin, Z., Gimelshein, N., Antiga, L., Desmaison, A., Kopf, A., Yang, E., DeVito, Z., Raison, M., Tejani, A., Chilamkurthy, S., Steiner, B., Fang, L., Bai, J., and Chintala, S. (2019). Pytorch: An imperative style, highperformance deep learning library. In H. Wallach, H. Larochelle, A. Beygelzimer, F. d'Alché-Buc, E. Fox, and R. Garnett, editors, Advances in Neural Information Processing Systems. ",
1557
+ "bbox": [
1558
+ 173,
1559
+ 726,
1560
+ 826,
1561
+ 796
1562
+ ],
1563
+ "page_idx": 11
1564
+ },
1565
+ {
1566
+ "type": "text",
1567
+ "text": "Petroni, F., Rocktäschel, T., Riedel, S., Lewis, P., Bakhtin, A., Wu, Y., and Miller, A. (2019). Language models as knowledge bases? 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). ",
1568
+ "bbox": [
1569
+ 174,
1570
+ 804,
1571
+ 825,
1572
+ 861
1573
+ ],
1574
+ "page_idx": 11
1575
+ },
1576
+ {
1577
+ "type": "text",
1578
+ "text": "Qi, P., Zhang, Y., Zhang, Y., Bolton, J., and Manning, C. D. (2020). Stanza: A Python natural language processing toolkit for many human languages. In Proceedings of the 58th Annual Meeting of the Association for Computational Linguistics: System Demonstrations. ",
1579
+ "bbox": [
1580
+ 174,
1581
+ 869,
1582
+ 826,
1583
+ 911
1584
+ ],
1585
+ "page_idx": 11
1586
+ },
1587
+ {
1588
+ "type": "text",
1589
+ "text": "Raffel, C., Shazeer, N., Roberts, A., Lee, K., Narang, S., Matena, M., Zhou, Y., Li, W., and Liu, P. J. (2020). Exploring the limits of transfer learning with a unified text-to-text transformer. Journal of Machine Learning Research, 21(140), 1–67. \nRoberts, A., Raffel, C., and Shazeer, N. (2020). How much knowledge can you pack into the parameters of a language model? In Proceedings of the 2020 Conference on Empirical Methods in Natural Language Processing (EMNLP). \nRobertson, S. and Zaragoza, H. (2009). The probabilistic relevance framework: Bm25 and beyond. Foundations and Trends in Information Retrieval. \nSachan, D. S., Patwary, M., Shoeybi, M., Kant, N., Ping, W., Hamilton, W. L., and Catanzaro, B. (2021). End-to-end training of neural retrievers for open-domain question answering. In Joint Conference of the 59th Annual Meeting of the Association for Computational Linguistics and the 11th International Joint Conference on Natural Language Processing (ACL-IJCNLP). \nShoeybi, M., Patwary, M., Puri, R., LeGresley, P., Casper, J., and Catanzaro, B. (2019). Megatron-lm: Training multi-billion parameter language models using gpu model parallelism. arXiv preprint arXiv:1909.08053. \nVaswani, A., Shazeer, N., Parmar, N., Uszkoreit, J., Jones, L., Gomez, A. N., Kaiser, Ł., and Polosukhin, I. (2017). Attention is all you need. In Advances in Neural Information Processing Systems. \nWang, S., Yu, M., Guo, X., Wang, Z., Klinger, T., Zhang, W., Chang, S., Tesauro, G., Zhou, B., and Jiang, J. (2018). R3: Reinforced ranker-reader for open-domain question answering. In AAAI. \nWang, Z., Ng, P., Ma, X., Nallapati, R., and Xiang, B. (2019). Multi-passage BERT: A globally normalized BERT model for open-domain question answering. 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). \nYih, W.-t., Toutanova, K., Platt, J. C., and Meek, C. (2011). Learning discriminative projections for text similarity measures. In Proceedings of the Fifteenth Conference on Computational Natural Language Learning. \nYogatama, D., de Masson d’Autume, C., and Kong, L. (2021). Adaptive Semiparametric Language Models. Transactions of the Association for Computational Linguistics, 9, 362–373. ",
1590
+ "bbox": [
1591
+ 171,
1592
+ 85,
1593
+ 828,
1594
+ 588
1595
+ ],
1596
+ "page_idx": 12
1597
+ },
1598
+ {
1599
+ "type": "text",
1600
+ "text": "Checklist ",
1601
+ "text_level": 1,
1602
+ "bbox": [
1603
+ 174,
1604
+ 89,
1605
+ 254,
1606
+ 106
1607
+ ],
1608
+ "page_idx": 13
1609
+ },
1610
+ {
1611
+ "type": "text",
1612
+ "text": "1. For all authors... ",
1613
+ "bbox": [
1614
+ 214,
1615
+ 116,
1616
+ 339,
1617
+ 130
1618
+ ],
1619
+ "page_idx": 13
1620
+ },
1621
+ {
1622
+ "type": "text",
1623
+ "text": "(a) Do the main claims made in the abstract and introduction accurately reflect the paper’s contributions and scope? [Yes] Please see the model (§2) and result (§3) sections that solidify the claims made in the abstract and introduction sections. \n(b) Did you describe the limitations of your work? [Yes] Please see limitations in $\\ S$ . \n(c) Did you discuss any potential negative societal impacts of your work? [Yes] Please see negative societal impact in $\\ S 5$ . \n(d) Have you read the ethics review guidelines and ensured that your paper conforms to them? [Yes] ",
1624
+ "bbox": [
1625
+ 238,
1626
+ 135,
1627
+ 825,
1628
+ 253
1629
+ ],
1630
+ "page_idx": 13
1631
+ },
1632
+ {
1633
+ "type": "text",
1634
+ "text": "2. If you are including theoretical results... ",
1635
+ "bbox": [
1636
+ 214,
1637
+ 257,
1638
+ 493,
1639
+ 272
1640
+ ],
1641
+ "page_idx": 13
1642
+ },
1643
+ {
1644
+ "type": "text",
1645
+ "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] ",
1646
+ "bbox": [
1647
+ 236,
1648
+ 276,
1649
+ 736,
1650
+ 308
1651
+ ],
1652
+ "page_idx": 13
1653
+ },
1654
+ {
1655
+ "type": "text",
1656
+ "text": "3. If you ran experiments... ",
1657
+ "bbox": [
1658
+ 212,
1659
+ 311,
1660
+ 393,
1661
+ 325
1662
+ ],
1663
+ "page_idx": 13
1664
+ },
1665
+ {
1666
+ "type": "text",
1667
+ "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 include the code, data, and instructions in the supplemental material and $\\ S$ . \n(b) Did you specify all the training details (e.g., data splits, hyperparameters, how they were chosen)? [Yes] We specify these details in the appendix included in the supplementary material. \n(c) Did you report error bars (e.g., with respect to the random seed after running experiments multiple times)? [No] Our experiments are compute expensive and it is not feasible to perform multiple runs of the same experiment with different seeds. All our training runs use the same seed value (1234). As an alternative to running multiple seeds, we perform a number of ablation studies (§3.5). \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] Please see $\\ S 3 . 2$ under hardware and library. ",
1668
+ "bbox": [
1669
+ 238,
1670
+ 332,
1671
+ 825,
1672
+ 531
1673
+ ],
1674
+ "page_idx": 13
1675
+ },
1676
+ {
1677
+ "type": "text",
1678
+ "text": "4. If you are using existing assets (e.g., code, data, models) or curating/releasing new assets... ",
1679
+ "bbox": [
1680
+ 209,
1681
+ 536,
1682
+ 823,
1683
+ 551
1684
+ ],
1685
+ "page_idx": 13
1686
+ },
1687
+ {
1688
+ "type": "text",
1689
+ "text": "(a) If your work uses existing assets, did you cite the creators? [Yes] Please see $\\ S 3 . 1$ for the details. \n(b) Did you mention the license of the assets? [Yes] Our work is based on open-source data and framework. When applicable, we describe the license information in the appendix. \n(c) Did you include any new assets either in the supplemental material or as a URL? [Yes] We include our code in the supplementary material. \n(d) Did you discuss whether and how consent was obtained from people whose data you’re using/curating? [N/A] \n(e) Did you discuss whether the data you are using/curating contains personally identifiable information or offensive content? [N/A] ",
1690
+ "bbox": [
1691
+ 238,
1692
+ 555,
1693
+ 825,
1694
+ 703
1695
+ ],
1696
+ "page_idx": 13
1697
+ },
1698
+ {
1699
+ "type": "text",
1700
+ "text": "5. If you used crowdsourcing or conducted research with human subjects... ",
1701
+ "bbox": [
1702
+ 214,
1703
+ 707,
1704
+ 705,
1705
+ 722
1706
+ ],
1707
+ "page_idx": 13
1708
+ },
1709
+ {
1710
+ "type": "text",
1711
+ "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] ",
1712
+ "bbox": [
1713
+ 238,
1714
+ 727,
1715
+ 825,
1716
+ 815
1717
+ ],
1718
+ "page_idx": 13
1719
+ }
1720
+ ]
parse/train/5KWmB6JePx/5KWmB6JePx_middle.json ADDED
The diff for this file is too large to render. See raw diff
 
parse/train/5KWmB6JePx/5KWmB6JePx_model.json ADDED
The diff for this file is too large to render. See raw diff
 
parse/train/6OoCDvFV4m/6OoCDvFV4m_layout.pdf ADDED
@@ -0,0 +1,3 @@
 
 
 
 
1
+ version https://git-lfs.github.com/spec/v1
2
+ oid sha256:341333aeafa6e0e1431c4bffffd27dcd1b189d3bfb573aef33b0dff74c4c38d4
3
+ size 1155074
parse/train/6OoCDvFV4m/6OoCDvFV4m_origin.pdf ADDED
@@ -0,0 +1,3 @@
 
 
 
 
1
+ version https://git-lfs.github.com/spec/v1
2
+ oid sha256:e97747e06b57e91fb0dcb16913021898ff540af55dd74296ef89744d97c706f2
3
+ size 988598
parse/train/6OoCDvFV4m/6OoCDvFV4m_span.pdf ADDED
@@ -0,0 +1,3 @@
 
 
 
 
1
+ version https://git-lfs.github.com/spec/v1
2
+ oid sha256:634ce52bed0ecf699a8ca736d237533eda2b8872772080add0a94061e2216dd2
3
+ size 1161330
parse/train/B1ckMDqlg/B1ckMDqlg_layout.pdf ADDED
@@ -0,0 +1,3 @@
 
 
 
 
1
+ version https://git-lfs.github.com/spec/v1
2
+ oid sha256:b13bd7d0a1099ca87ea240ebd02ac7489ea39c1cfbe7c90ea37c571a9af2a10d
3
+ size 654331
parse/train/B1ckMDqlg/B1ckMDqlg_origin.pdf ADDED
@@ -0,0 +1,3 @@
 
 
 
 
1
+ version https://git-lfs.github.com/spec/v1
2
+ oid sha256:af9983cb28a4596ad1ee5f6aefad696308d454325f0dea6824774034f147093a
3
+ size 435901
parse/train/B1ckMDqlg/B1ckMDqlg_span.pdf ADDED
@@ -0,0 +1,3 @@
 
 
 
 
1
+ version https://git-lfs.github.com/spec/v1
2
+ oid sha256:5d8381735fafb59c12709aa14fcb8bcb8ee9e7705259bdfaa5626c0b89f22153
3
+ size 654207
parse/train/B1g8VkHFPH/B1g8VkHFPH.md ADDED
@@ -0,0 +1,343 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ # RETHINKING THE HYPERPARAMETERS FOR FINE-TUNING
2
+
3
+ Hao $\mathbf { L i } ^ { 1 }$ , Pratik Chaudhari2∗, Hao Yang1, Michael Lam1, Avinash Ravichandran1, Rahul Bhotika1, Stefano Soatto1,3
4
+
5
+ 1Amazon Web Services, 2University of Pennsylvania, 3University of California, Los Angeles {haolimax, haoyng, michlam, ravinash, bhotikar, soattos} $@$ amazon.com, pratikac@seas.upenn.edu
6
+
7
+ # ABSTRACT
8
+
9
+ Fine-tuning from pre-trained ImageNet models has become the de-facto standard for various computer vision tasks. Current practices for fine-tuning typically involve selecting an ad-hoc choice of hyperparameters and keeping them fixed to values normally used for training from scratch. This paper re-examines several common practices of setting hyperparameters for fine-tuning. Our findings are based on extensive empirical evaluation for fine-tuning on various transfer learning benchmarks. (1) While prior works have thoroughly investigated learning rate and batch size, momentum for fine-tuning is a relatively unexplored parameter. We find that the value of momentum also affects fine-tuning performance and connect it with previous theoretical findings. (2) Optimal hyperparameters for fine-tuning, in particular, the effective learning rate, are not only dataset dependent but also sensitive to the similarity between the source domain and target domain. This is in contrast to hyperparameters for training from scratch. (3) Reference-based regularization that keeps models close to the initial model does not necessarily apply for “dissimilar” datasets. Our findings challenge common practices of finetuning and encourages deep learning practitioners to rethink the hyperparameters for fine-tuning.
10
+
11
+ # 1 INTRODUCTION
12
+
13
+ Many real-world applications often have a limited number of training instances, which makes directly training deep neural networks hard and prone to overfitting. Transfer learning with the knowledge of models learned on a similar task can help to avoid overfitting. Fine-tuning is a simple and effective approach of transfer learning and has become popular for solving new tasks in which pre-trained models are fine-tuned with the target dataset. Specifically, fine-tuning on pre-trained ImageNet classification models (Simonyan & Zisserman, 2015; He et al., 2016b) has achieved impressive results for tasks such as object detection (Ren et al., 2015) and segmentation (He et al., 2017; Chen et al., 2017) and is becoming the de-facto standard of solving computer vision problems. It is believed that the weights learned on the source dataset with a large number of instances provide better initialization for the target task than random initialization. Even when there is enough training data, fine-tuning is still preferred as it often reduces training time significantly (He et al., 2019).
14
+
15
+ The common practice of fine-tuning is to adopt the default hyperparameters for training large models while using smaller initial learning rate and shorter learning rate schedule. It is believed that adhering to the original hyperparameters for fine-tuning with small learning rate prevents destroying the originally learned knowledge or features. For instance, many studies conduct fine-tuning of ResNets (He et al., 2016b) with these default hyperparameters: learning rate 0.01, momentum 0.9 and weight decay 0.0001. However, the default setting is not necessarily optimal for fine-tuning on other tasks. While few studies have performed extensive hyperparameter search for learning rate and weight decay (Mahajan et al., 2018; Kornblith et al., 2019), the momentum coefficient is rarely changed. Though the effectiveness of the hyperparameters has been studied extensively for training a model from scratch, how to set the hyperparameters for fine-tuning is not yet fully understood.
16
+
17
+ In addition to using ad-hoc hyperparameters, commonly held beliefs for fine-tuning also include:
18
+
19
+ • Fine-tuning pre-trained networks outperforms training from scratch; recent work (He et al., 2019) has already revisited this.
20
+ • Fine-tuning from similar domains and tasks works better (Ge & Yu, 2017; Cui et al., 2018; Achille et al., 2019; Ngiam et al., 2018).
21
+ • Explicit regularization with initial models matters for transfer learning performance (Li et al., 2018; 2019).
22
+
23
+ Are these practices or beliefs always valid? From an optimization perspective, the difference between fine-tuning and training from scratch is all about the initialization. However, the loss landscape of the pre-trained model and the fine-tuned solution could be much different, so as their optimization strategies and hyperparameters. Would the hyperparameters for training from scratch still be useful for fine-tuning? In addition, most of the hyperparameters (e.g., batch size, momentum, weight decay) are frozen; will the conclusion differ when some of them are changed?
24
+
25
+ With these questions in mind, we re-examined the common practices for fine-tuning. We conducted extensive hyperparameter search for fine-tuning on various transfer learning benchmarks with different source models. The goal of our work is not to obtain state-of-the-art performance on each fine-tuning task, but to understand the effectiveness of each hyperparameter for fine-tuning, avoiding unnecessary computation. We explain why certain hyperparameters work so well on certain datasets while fail on others, which can guide hyperparameter search for fine-tuning.
26
+
27
+ Our main findings are as follows:
28
+
29
+ • Optimal hyperparameters for fine-tuning are not only dataset dependent, but are also dependent on the similarity between the source and target domains, which is different from training from scratch. Therefore, the common practice of using optimization schedules derived from ImageNet training cannot guarantee good performance. It explains why some tasks are not achieving satisfactory results after fine-tuning because of inappropriate hyperparameter selection. Specifically, as opposed to the common practice of rarely tuning the momentum value beyond 0.9, we find that zero momentum sometimes work better for fine-tuning on tasks that are similar with the source domain, while nonzero momentum works better for target domains that are different from the source domain.
30
+ Hyperparameters are coupled together and it is the effective learning rate—which encapsulates the learning rate and momentum—that matters for fine-tuning performance. While effective learning rate has been studied for training from scratch, to the best of our knowledge, no previous work investigates effective learning rate for fine-tuning and is less used in practice. Our observation of momentum can be explained as small momentum actually decreases the effective learning rate, which is more suitable for fine-tuning on similar tasks. We show that the optimal effective learning rate depends on the similarity between the source and target domains. We find regularization methods that were designed to keep models close to the initial model does not necessarily work for “dissimilar” datasets, especially for nets with Batch Normalization. Simple weight decay can result in as good performance as the referencebased regularization methods for fine-tuning with better search space.
31
+
32
+ # 2 RELATED WORK
33
+
34
+ In transfer learning for image classification, the last layer of a pre-trained network is usually replaced with a randomly initialized fully connected layer with the same size as the number of classes in the target task (Simonyan & Zisserman, 2015). It has been shown that fine-tuning the whole network usually results in better performance than using the network as a static feature extractor (Yosinski et al., 2014; Donahue et al., 2014; Huh et al., 2016; Mormont et al., 2018; Kornblith et al., 2019). Ge & Yu (2017) select images that have similar local features from source domain to jointly fine-tune pre-trained networks. Cui et al. (2018) estimate domain similarity with ImageNet and demonstrate that transfer learning benefits from pre-training on a similar source domain. Besides image classification, many object detection frameworks also rely on fine-tuning to improve over training from scratch (Girshick et al., 2014; Ren et al., 2015).
35
+
36
+ Many researchers re-examined whether fine-tuning is a necessity for obtaining good performance. Ngiam et al. (2018) find that when domains are mismatched, the effectiveness of transfer learning is negative, even when domains are intuitively similar. Kornblith et al. (2019) examine the fine-tuning performance of various ImageNet models and find a strong correlation between ImageNet top-1 accuracy and the transfer accuracy. They also find that pre-training on ImageNet provides minimal benefits for some fine-grained object classification dataset. He et al. (2019) questioned whether ImageNet pre-training is necessary for training object detectors. They find the solution of training from scratch is no worse than the fine-tuning counterpart as long as the target dataset is large enough. Raghu et al. (2019) find that transfer learning has negligible performance boost on medical imaging applications, but speed up the convergence significantly.
37
+
38
+ There are many literatures on hyperparameter selection for training neural networks from scratch, mostly on batch size, learning rate and weight decay (Goyal et al., 2017; Smith et al., 2018; Smith & Topin, 2019). There are few works on the selection of momentum (Sutskever et al., 2013). Zhang & Mitliagkas (2017) proposed an automatic tuner for momentum and learning rate in SGD. There are also studies on the correlations of the hyperparameters, such as linear scaling rule between batch size and learning (Goyal et al., 2017; Smith et al., 2018; Smith, 2017). However, most of these advances on hyperparameter tuning are designed for training from scratch and have not examined on fine-tuning tasks for computer vision problems. Most work on fine-tuning simply choose fixed hyperparameters (Cui et al., 2018) or use dataset-dependent learning rates (Li et al., 2018) in their experiments. Due to the huge computational cost for hyperparameter search, only a few works (Kornblith et al., 2019; Mahajan et al., 2018) performed large-scale grid search of learning rate and weight decay for obtaining the best performance.
39
+
40
+ # 3 TUNING HYPERPARAMETERS FOR FINE-TUNING
41
+
42
+ In this section, we first introduce the notations and experimental settings, and then present our observations on momentum, effective learning rate and regularization. The fine-tuning process is not different from learning from scratch except for the weights initialization. The goal of the process is still to minimize the objective function L = 1N PNi=1 \` $\begin{array} { r } { L = \frac { 1 } { N } \sum _ { i = 1 } ^ { N } \ell ( f ( x _ { i } , \theta ) , y _ { i } ) + \frac { \lambda } { 2 } \| \theta \| _ { 2 } ^ { 2 } } \end{array}$ , where $\ell$ is the loss function, $N$ is the number of samples, $x _ { i }$ is the input data, $y _ { i }$ is its label, $f$ is the neural network, $\theta$ is the model parameters and $\lambda$ is the regularization hyperparameter or weight decay. Momentum is widely used for accelerating and smoothing the convergence of SGD by accumulating a velocity vector in the direction of persistent loss reduction (Polyak, 1964; Sutskever et al., 2013; Goh, 2017). The commonly used Nesterov’s Accelerated Gradient (Nesterov, 1983) is given by:
43
+
44
+ $$
45
+ \begin{array} { l } { { \displaystyle v _ { t + 1 } = m v _ { t } - \eta _ { t } \frac { 1 } { n } \sum _ { i = 1 } ^ { n } \nabla \ell \big ( f \big ( x _ { i } , \theta _ { t } + m v _ { t } \big ) , y _ { i } \big ) } } \\ { { \theta _ { t + 1 } = \theta _ { t } + v _ { t + 1 } - \eta \lambda \theta _ { t } } } \end{array}
46
+ $$
47
+
48
+ where $\theta _ { t }$ indicates the model parameters at iteration $t$ . The hyperparameters include the learning rate $\eta _ { t }$ , batch size $n$ , momentum coefficient $m \in [ 0 , 1 )$ , and the weight decay $\lambda$ .
49
+
50
+ # 3.1 EXPERIMENTAL SETTINGS
51
+
52
+ We evaluate fine-tuning on seven widely used image classification datasets, which covers tasks for fine-grained object recognition, scene recognition and general object recognition. Detailed statistics of each dataset can be seen in Table 1. We use ImageNet (Russakovsky et al., 2015), Places-365 (Zhou et al., 2018) and iNaturalist (Van Horn et al., 2018) as source domains for pre-trained models. We resize the input images such that the aspect ratio is preserved and the shorter side is 256 pixels. The images are normalized with mean and std values calculated over ImageNet. For data augmentation, we adopt the common practices used for training ImageNet models (Szegedy et al., 2015): random mirror, random scaled cropping with scale and aspect variations, and color jittering. The augmented images are resized to $2 2 4 \times 2 2 4$ . Note that state-of-the-art results could achieve even better performance by using higher resolution images (Cui et al., 2018) or better data augmentation (Cubuk et al., 2018).
53
+
54
+ We mainly use ResNet-101-V2 (He et al., 2016a) as our base network, which is pre-trained on ImageNet (Russakovsky et al., 2015). Similar observations are also made on DenseNets (Huang et al., 2017) and MobileNet (Howard et al., 2017). The hyperparameters to be tuned (and ranges)
55
+
56
+ Table 1: Datasets statistics. For the Caltech-256 dataset, we randomly sampled 60 images for each class following the procedure used in (Li et al., 2018). For the Aircraft and Flower dataset, we combined the original training set and validation set and evaluated on the test set. For iNat 2017, we combined the original training set and $90 \%$ of the validation set following (Cui et al., 2018).
57
+
58
+ <table><tr><td>Datasets</td><td>Task Category</td><td>Classes</td><td>Training</td><td>Test</td></tr><tr><td>Oxford Flowers (Nilsback &amp; Zisserman, 2008)</td><td>fine-grained object recog.</td><td>102</td><td>2,040</td><td>6,149</td></tr><tr><td>CUB-Birds 200-2011 (Wah et al., 2011)</td><td>fine-grained object recog.</td><td>200</td><td>5,994</td><td>5,794</td></tr><tr><td>FGVC Aircrafts (Maji et al., 2013)</td><td>fine-grained object recog.</td><td>100</td><td>6,667</td><td>3,333</td></tr><tr><td>Stanford Cars (Krause etal., 2013)</td><td>fine-grained object recog.</td><td>196</td><td>8,144</td><td>8,041</td></tr><tr><td>Stanford Dogs (Khosla et al., 2011)</td><td>fine-grained object recog.</td><td>120</td><td>12.000</td><td>8,580</td></tr><tr><td>MIT Indoor-67 (Sharif Razavian et al., 2014)</td><td>scene classification</td><td>67</td><td>5,360</td><td>1,340</td></tr><tr><td>Caltech-256-60 (Griffin et al., 2007)</td><td>general object recog.</td><td>256</td><td>15,360</td><td>15,189</td></tr><tr><td>iNaturalist 2017 (Van Horn et al., 2018)</td><td>fine-grained object recog.</td><td>5,089</td><td>665,571</td><td>9,599</td></tr><tr><td>Place365 (Zhou et al., 2018)</td><td>scene classification</td><td>365</td><td>1,803,460</td><td>36,500</td></tr></table>
59
+
60
+ are: learning rate (0.1, 0.05, 0.01, 0.005, 0.001, 0.0001), momentum (0.9, 0.99, 0.95, 0.9, 0.8, 0.0) and weight decay (0.0, 0.0001, 0.0005, 0.001). We set the default hyperparameters to be batch size $2 5 6 ^ { 1 }$ , learning rate 0.01, momentum 0.9 and weight decay 0.0001. To avoid insufficient training and observe the complete convergence behavior, we use 300 epochs for fine-tuning and 600 epochs for scratch-training, which is long enough for the training curves to converge. The learning rate is decayed by a factor of 0.1 at epoch 150 and 250. We report the Top-1 validation (test) error at the end of training. The total computation time for the experiments is more than 10K GPU hours.
61
+
62
+ # 3.2 EFFECT OF MOMENTUM AND DOMAIN SIMILARITY
63
+
64
+ Momentum 0.9 is the most widely used value for training from scratch (Krizhevsky et al., 2012; Simonyan & Zisserman, 2015; He et al., 2016b) and is also widely adopted for fine-tuning (Kornblith et al., 2019). To the best of our knowledge, it is rarely changed, regardless of the network architectures or target tasks. To check the influence of momentum on fine-tuning, we first search for the best momentum value for fine-tuning on the Birds dataset with different weight decay and learning rate. Figure 1(a) shows the performance of fine-tuning with and without weight decays. Surprisingly, momentum zero actually outperforms the nonzero momentum. The optimal learning rate also increases when the momentum is disabled as shown in Figure 1(b).
65
+
66
+ ![](images/0c290ddf7caa7aebc7d4a1743b9b33e47aa7d70c53ddde6baf696ba1ecd2aad5.jpg)
67
+ Figure 1: (a) Searching for the optimal momentum on Birds dataset with fixed learning rate 0.01 and different weight decays. Detailed learning curves and results of other hyperparameters can be found in Appendix A. (b) Comparison of momentum 0.9 and 0.0 with different learning rates on the Birds dataset, $\lambda$ is fixed at 0.0001.
68
+
69
+ To verify this observation, we further compare momentum 0.9 and 0.0 on other datasets. Table 2 shows the performance of 8 hyperparameter settings on 7 datasets. We observe a clear pattern that disabling momentum works better for Dogs, Caltech and Indoor, while momentum 0.9 works better for Cars, Aircrafts and Flowers.
70
+
71
+ Table 2: Top-1 validation errors on seven datasets by fine-tuning ImageNet pre-trained ResNet-101 with different hyperparmeters. Each row represents a network fine-tuned by a set of hyperparameters (left four columns). The datasets are ranked by the relative improvement by disabling momentum. The lowest error rates with the same momentum are marked as bold. Note that the performance difference for Birds is not very significant.
72
+
73
+ <table><tr><td>m</td><td>n</td><td>入</td><td>Dogs</td><td>Caltech</td><td>Indoor</td><td>Birds</td><td>Cars</td><td>Aircrafts</td><td>Flowers</td></tr><tr><td>0.9</td><td>0.01</td><td>0.0001</td><td>17.20</td><td>14.85</td><td>23.76</td><td>18.10</td><td>9.10</td><td>17.55</td><td>3.12</td></tr><tr><td>0.9</td><td>0.01</td><td>0</td><td>17.41</td><td>14.51</td><td>24.59</td><td>18.42</td><td>9.60</td><td>17.40</td><td>3.33</td></tr><tr><td>0.9</td><td>0.005</td><td>0.0001</td><td>14.14</td><td>13.42</td><td>24.59</td><td>17.24</td><td>9.08</td><td>18.21</td><td>3.50</td></tr><tr><td>0.9</td><td>0.005</td><td>0</td><td>14.80</td><td>13.67</td><td>22.79</td><td>17.54</td><td>9.31</td><td>17.82</td><td>3.53</td></tr><tr><td>0</td><td>0.01</td><td>0.0001</td><td>11.00</td><td>12.11</td><td>21.14</td><td>17.41</td><td>11.07</td><td>20.58</td><td>5.48</td></tr><tr><td>0</td><td>0.01</td><td>0</td><td>10.87</td><td>12.16</td><td>21.29</td><td>17.21</td><td>10.65</td><td>20.46</td><td>5.25</td></tr><tr><td>0</td><td>0.005</td><td>0.0001</td><td>10.21</td><td>11.86</td><td>21.96</td><td>18.24</td><td>13.22</td><td>24.39</td><td>7.03</td></tr><tr><td>0</td><td>0.005</td><td>0</td><td>10.12</td><td>11.61</td><td>20.76</td><td>18.40</td><td>13.11</td><td>23.91</td><td>6.78</td></tr></table>
74
+
75
+ Table 3: Verification of the effect of momentum on other source domains rather than ImageNet. The hyperparameters are $n = 2 5 6$ , $\eta = 0 . 0 1$ , and $\lambda = 0 . 0 0 0 1$ . Momentum 0 works better for transferring from iNat-2017 to Birds and transferring from Places-365 to Indoor comparing to momentum 0.9 counterparts.
76
+
77
+ <table><tr><td>Source domain</td><td>m</td><td>Indoor</td><td>Birds</td><td>Dogs</td><td>Caltech</td><td>Cars</td><td>Aircrafts</td></tr><tr><td rowspan="2">iNat-2017</td><td>0.9</td><td>30.73</td><td>14.69</td><td>24.74</td><td>20.12</td><td>11.16</td><td>19.86</td></tr><tr><td>0</td><td>34.11</td><td>12.29</td><td>23.87</td><td>21.47</td><td>16.89</td><td>27.21</td></tr><tr><td rowspan="2">Places-365</td><td>0.9</td><td>22.19</td><td>27.72</td><td>30.84</td><td>22.53</td><td>11.06</td><td>21.27</td></tr><tr><td>0</td><td>20.16</td><td>32.17</td><td>32.47</td><td>22.60</td><td>14.67</td><td>25.29</td></tr></table>
78
+
79
+ Interestingly, datasets such as Dogs, Caltech, Indoor and Birds are known to have high overlap with ImageNet dataset2, while Cars and Aircrafts are identified to be difficult to benefit from fine-tuning from pre-trained ImageNet models (Kornblith et al., 2019). According to Cui et al. (2018), in which the Earth Mover’s Distance (EMD) is used to calculate the similarity between ImageNet and other domains, the similarity to Dogs and Birds are 0.619 and 0.563, while the similarity to Cars, Aircrafts and Flowers are 0.560, 0.556 and $0 . 5 2 5$ . The relative order of similarities to ImageNet is
80
+
81
+ Dogs, Birds, Cars, Aircrafts and Flowers
82
+
83
+ which aligns well with the transition of optimal momentum value from 0.0 to 0.9. Following the similarity calculation, we can also verified Caltech and Indoor are more close to ImageNet than Cars/Aircrafts/Flowers (Table 3.3).
84
+
85
+ To verify the connection between momentum and domain similarity, we further fine-tune from different source domains such as Places-365 and iNaturalist, which are known to be better source domains than ImageNet for fine-tuning on Indoor and Birds dataset (Cui et al., 2018). We may expect that fine-tuning from iNaturalist works better for Birds with $m = 0$ and similarly, Places for Indoor. Indeed, as shown in Table 3, disabling momentum improves the performance when the source and target domain are similar, such as Places for Indoor and iNaturalist for Birds.
86
+
87
+ Small momentum works better for fine-tuning on domains that are close to the source domain One explanation for the above observations is that because the Dogs dataset is very close to ImageNet, the pre-trained ImageNet model is expected to be close to the fine-tuned solution on the Dogs dataset. In this case, momentum may not help much as the gradient direction around the minimum could be much random and accumulating the momentum direction could be meaningless. Whereas, for faraway target domains (e.g., Cars and Aircrafts) where the pre-trained ImageNet model could be much different with the fine-tuned solution, the fine-tuning process is more similar with training from scratch, where large momentum stabilizes the decent directions towards the minimum. An illustration of the difference can be found in Figure 2.
88
+
89
+ ![](images/8710eb91220c9eed34f7e6c7a190bb7a5badb9469fe7ade7fb1849f922d09bec.jpg)
90
+ Figure 2: An illustration of the effect of momentum on different fine-tuning scenarios from the loss-landscape perspective. The red point is the pre-trained model and the blue point is the fine-tuned solution. The dashed lines are loss contours. Assuming the step size is fixed, large momentum accelerates the convergence when the initialization is far from the minimum ((a) and (b)). On the contrary, large momentum may impede the convergence as shown in (c) and (d) when the initialization is close to the minimum.
91
+
92
+ Connections to early observations on decreasing momentum Early work (Sutskever et al., 2013) actually pointed out that reducing momentum during the final stage of training allows finer convergence while aggressive momentum would prevent this. They recommended reducing momentum from 0.99 to 0.9 in the last 1000 parameter updates but not disabling it completely. Recent work (Liu et al., 2018; Smith, 2018) showed that a large momentum helps escape from saddle points but can hurt the final convergence within the neighborhood of the optima, implying that momentum should be reduced at the end of training. Liu et al. (2018) find that a larger momentum introduces higher variance of noise and encourages more exploration at the beginning of optimization, and encourages more aggressive exploitation at the end of training. They suggest that at the final stage of the step size annealing, momentum SGD should use a much smaller step size than that of vanilla SGD. When applied to fine-tuning, we can interpret that if the pre-trained model lies in the neighborhood of the optimal solution on the target dataset, the momentum should be small. Our work identifies the empirical evidence of disabling momentum helps final convergence, and fine-tuning on close domains is a good exemplar.
93
+
94
+ # 3.3 COUPLED HYPERPARAMETERS AND THE VIEW OF EFFECTIVE LEARNING RATE
95
+
96
+ Now that we had discovered the effect of momentum by fixing other hyperparameters and only allowed momentum to change. But note that the two difficult scenarios shown in Figure 2 (b) and (c) might also be mitigated by increasing or decreasing learning rate. That is, hyperparameters are coupled and varying one hyperparameter can change the optimal values of the other hyperparameters that lead to the best performance. In addition, optimal values of certain hyperparameters depend on the values of other hyperparameters in systematic ways. For example, learning rate is entangled with batch size, momentum and weight decay. There is a notion of effective learning rate (ELR) (Hertz et al., 1991; Smith et al., 2018; Smith & Le, 2018) for SGD with momentum: $\eta ^ { \prime } = \eta / ( 1 - m )$ , which was shown to be more closely related with training dynamics and final performance rather than $\eta$ . The effective learning rate with $m = 0 . 9$ is $1 0 \times$ higher than the one with $m = 0 . 0$ if other hyperparameters are fixed, which is probably why we see an increase in optimal learning rate when momentum is disabled in Figure 1(b) and Appendix A.
97
+
98
+ ![](images/4ce32bf9da77a8f4482b67fb5d03fa2a987b1a28a539865b05840b1064f3263c.jpg)
99
+ Figure 3: The effect of momentum w/ and w/o fixing ELR $\eta ^ { \prime }$ . When $\eta ^ { \prime }$ is the same, momentum 0 and 0.9 are almost equivalent. If $\eta ^ { \prime }$ is allowed to change, there is almost no difference between optimal performance obtained by different $m$ .
100
+
101
+ It is the effective learning rate that matters for fine-tuning performance Because hyperparameters are coupled, looking at the performance with only one hyperparameter varied may give a misleading understanding of the effect of hyperparameters. Therefore, to examine the effect of momentum, we should report the best result obtainable with and without momentum, as long as other hyperparameters explored are sufficiently explored. We re-examine previous experiments that demonstrated the importance of momentum tuning when the ELR $\eta ^ { \prime } \bar { = } \eta / ( 1 - \bar { m } )$ is held fixed instead of simply fixing learning rate $\eta$ . Figure 3 shows that when $\eta ^ { \prime }$ is constant, the best performance obtained by $m = 0 . 9$ and $m = 0$ are almost equivalent when other hyperparameters are allowed to change. However, different ELR does result in different performance, which indicates its importance for the best performance. It explains why the common practice of changing only learning rate generally works, though changing momentum may results in the same result, they both change the ELR. In fact, as long as the initial learning rate is small enough, we can always search for the optimal momentum as it is an amplifier, making the ELR larger by a factor of $1 / ( 1 - m )$ . Therefore, momentum does determine the search ranges of learning rate.
102
+
103
+ Optimal ELR depends on the similarity between source domain and target domain Now that we have shown ELR is critical for fine-tuning performance, we are interested in the factors that determine the optimal ELR for a given task. Previous work (Smith & Le, 2018) found that there is an optimum ELR which maximizes the test accuracy. However, the observations are only based on scratch training on small datasets (e.g., CIFAR-10); the relationship between ELR and domain similarity, especially for fine-tuning, is still unexplored. To examine this, we search the best ELR on each fine-tuning task and reports in Fig. 4 the best validation error obtained by each ELR while allowing other hyperparameters to change. It shows the optimal ELR depends on both source domain and target domain. As shown in Fig. 4 (a-c), the optimal ELR for Dogs/Caltech/Indoor are much smaller than these for Aircrafts/Flowers/Cars when fine-tuned from ImageNet pre-trained model. Similar observations can be made on DenseNets and MobileNet. Though the optimal ELR value is different, the relative order of domain similarity is consistent and architecture agnostic. We can also see a smaller ELR works better when source domain and target domain are similar, such as Dogs for ImageNet and Birds for iNat2017 (Fig. 4 (a, d-e)). Interestingly, the optimal ELR for training from scratch is much larger and very similar across different target datasets, which indicates the distance from a random initialization is uniformly similar to different target dataset.
104
+
105
+ ![](images/e5a0e5125739ed10559077ba3ac4435aaa5f0a2a7c00133874ea8625039fe3c0.jpg)
106
+ Figure 4: The best validation errors obtained by different ELRs for different source-target domains. Note that the optimal ELR for each target dataset falls in the interior of search space. Each point in (a-e) is the lowest validation error obtained with different weight decay values while ELR is fixed. The first row suggests that the connection between optimal ELR and domain similarity is architecture agnostic. The second row verifies that optimal ELR depends on the similarity between source domain and target domain.
107
+
108
+ Table 4: The connection between domain similarity and optimal ELR. The values in the second column is provided by Cui et al. (2018), in which JFT pretrained ResNet-101 was used as the feature extractor. Note that neither the pre-trained model or the dataset is released and we cannot calculate the metric for other datasets. In other columns, we calculate domain similarity using ImageNet pre-trained model as the feature extractor. The 1st, 2nd, 3rd and 4th highest scores are color coded. The optimal ELRs are also listed, which corresponds to the values in Fig 4.
109
+
110
+ <table><tr><td rowspan="3"></td><td>JFT</td><td colspan="4">ImageNet</td><td colspan="2">iNat2017</td><td colspan="2">Places365</td></tr><tr><td>ResNet-101</td><td>ResNet-101</td><td colspan="2">DenseNet-121</td><td colspan="2">MobileNet</td><td colspan="2">ResNet-101</td><td colspan="2">ResNet-101</td></tr><tr><td>sim</td><td>sim 川</td><td>sim</td><td>八</td><td>sim</td><td>八</td><td>sim</td><td>川</td><td>sim</td><td>川</td></tr><tr><td>Dogs</td><td>0.619</td><td>0.862 0.001</td><td>0.851</td><td>0.01</td><td>0.852</td><td>0.01</td><td>0.854</td><td>0.05</td><td>0.856</td><td>0.5</td></tr><tr><td>Caltech</td><td>-</td><td>0.892 0.005</td><td>0.881</td><td>0.01</td><td>0.878</td><td>0.01</td><td>0.871</td><td>0.1</td><td>0.888</td><td>0.05</td></tr><tr><td>Indoor</td><td>-</td><td>0.856 0.01</td><td>0.850</td><td>0.05</td><td>0.839</td><td>0.01</td><td>0.843</td><td>0.1</td><td>0.901</td><td>0.05</td></tr><tr><td>Birds</td><td>0.563</td><td>0.860 0.05</td><td>0.842</td><td>0.05</td><td>0.849</td><td>0.1</td><td>0.901</td><td>0.005</td><td>0.861</td><td>0.5</td></tr><tr><td>Cars</td><td>0.560</td><td>0.845 0.5</td><td>0.831</td><td>0.5</td><td>0.830</td><td>1.0</td><td>0.847</td><td>1.0</td><td>0.864</td><td>1.0</td></tr><tr><td>Aircrafts</td><td>0.556</td><td>0.840 1.0</td><td>0.817</td><td>0.1</td><td>0.831</td><td>1.0</td><td>0.846</td><td>0.5</td><td>0.853</td><td>0.5</td></tr><tr><td>Flowers</td><td>0.525</td><td>0.844 0.1</td><td>0.821</td><td>0.5</td><td></td><td>0.825 0.1</td><td>0.879</td><td>0.1</td><td>0.851</td><td>1.0</td></tr></table>
111
+
112
+ Optimal ELR selection based on domain similarity Now we have made qualitative observations about the relationship between domain similarity and optimal ELR. A quantitative characterization of the relationship could reduce the hyperparameter search ranges for HPO or even eliminate HPO by accurately predicting hyperparameters. We followed the domain similarity calculation in (Cui et al., 2018) and recalculate similarity scores for all source-target domain pairs. Note the original domain similarity calculation in (Cui et al., 2018) use pre-trained JFT (Sun et al., 2017) models as feature extractor, which are not public available. We alternatively use ImageNet pre-trained model or the source model as feature extractor. As shown in Table 4, there is a good correlation between domain similarity score and the scale of optimal ELR. Generally, the more similar the two domains, the smaller the optimal ELR. Though it is not strictly corresponding to the domain similarity score, the score provides reasonable prediction about the scale of optimal ELR, such as [0.001, 0.01], [0.01, 0.1], [0.1, 1.0] and therefore can reduce the search space for optimal ELR. Based on this correlation, a simple strategy can be developed for optimal ELR selection given a frequently used source model: one can calculate domain similarities and perform exhaustive hyperparameter searches for few reference datasets, including similar and dissimilar datasets. Then given a new dataset to fine-tune, one can calculate the domain similarity and compare with the scores of reference datasets, and choose the range of ELRs with the closest domain similarity.
113
+
114
+ Weight Decay and Learning Rate The relationship between weight decay and effective learning rate is recently well-studied (van Laarhoven, 2017; Zhang et al., 2018; Loshchilov & Hutter, 2018). It was shown that the effect of weight decay on models with BN layers is equivalent to increasing the ELR by shrinking the weights scales, i.e., $\eta ^ { \prime } \sim \eta / \| \theta \| _ { 2 } ^ { 2 }$ . And if the optimal effective learning rate exists, the optimal weight decay value $\lambda$ is inversely related with the optimal learning rate $\eta$ . The ‘effective’ weight decay is $\lambda ^ { \prime } = \lambda / \eta$ . We show in Figure 5 that the optimal effective weight decay is also correlated with domain similarity.
115
+
116
+ ![](images/c5d9915d147e187cb3653b42aa59b97f78d56de7e90f01a50644f871ac7a2361.jpg)
117
+ Figure 5: The relationship between optimal effective weight decay and source datasets. The optimal effective weight decay is larger when the source domain is similar with the target domain.
118
+
119
+ # 3.4 THE CHOICE OF REGULARIZATION
120
+
121
+ $L _ { 2 }$ regularization or weight decay is widely used for constraining the model capacity (Hanson & Pratt, 1989; Krogh & Hertz, 1992). Recently Li et al. (2018; 2019) pointed out that standard $L _ { 2 }$ regularization, which drives the parameters towards the origin, is not adequate in transfer learning. To retain the knowledge learned by the pre-trained model, reference-based regularization was used to regularize the distance between fine-tuned weights and the pre-trained weights, so that the finetuned model is not too different from the initial model. Li et al. (2018) propose $L _ { 2 }$ -SP norm, i.e., $\begin{array} { r } { \frac { \lambda _ { 1 } } { 2 } \| \theta ^ { \prime } - \theta _ { 0 } \| _ { 2 } ^ { 2 } + \frac { \lambda _ { 2 } } { 2 } \| \theta ^ { \prime \prime } \| _ { 2 } ^ { 2 } } \end{array}$ , where $\theta ^ { \prime }$ refers to the part of network that shared with the source network, and $\theta ^ { \prime \prime }$ refers to the novel part, e.g., the last layer with different number of neurons. While the motivation is intuitive, there are several issues for adopting reference based regularization for fine-tuning:
122
+
123
+ • Many applications actually adopt fine-tuning on target domains that are quite different from source domain, such as fine-tuning ImageNet models for medical imaging (Mormont et al., 2018; Raghu et al., 2019). The fine-tuned model does not necessarily have to be close with the initial model.
124
+ • The scale invariance introduced by Batch Normalization (BN) (Ioffe & Szegedy, 2015) layers enable models with different parameter scales to function the same, i.e., $\dot { f } ( \theta ) = f ( \overset { \cdot } { \alpha } \theta )$ . Therefore, when $L _ { 2 }$ regularization drives $\| \theta \| _ { 2 } ^ { 2 }$ towards zeros, it could still have the same functionality as the initial model. On the contrary, a model could still be different even when the $L _ { 2 }$ -SP norm is small.
125
+ • $L _ { 2 }$ -SP regularization would constrain $\theta ^ { \prime \prime }$ to be close to $\theta _ { 0 }$ , so that $\| \theta \| _ { 2 } ^ { 2 }$ is relatively stable in comparison with $L _ { 2 }$ regularization. Given that ELR is approximately proportional to $\eta / \lVert \boldsymbol { \theta } \rVert _ { 2 } ^ { 2 }$ and a smaller ELR is beneficial for fine-tuning from similar domains, it may explain why $L _ { 2 }$ -SP provides better performance. If this is true, then by decreasing the initial ELR, $L _ { 2 }$ -norm may function the same.
126
+
127
+ To examine these conjectures, we revisited the work of (Li et al., 2018) with additional experiments. To show the effectiveness of $L _ { 2 }$ -SP norm, the authors conducted experiments on datasets such as Dogs, Caltech and Indoor, which are all close to the source domain (ImageNet or Places-365). We extend their experiments by fine-tuning on both “similar” and “dissimilar” datasets, including Birds, Cars, Aircrafts and Flowers, with both $L _ { 2 }$ and $L _ { 2 }$ -SP regularization (details in Appendix D). For fair comparison, we perform the same hyperparameter search for both methods. As expected, Table 5 shows that $L _ { 2 }$ regularization is very competitive with $L _ { 2 }$ -SP on Birds, Cars, Aircrafts and Flowers, which indicates that reference based regularization may not generalize well for fine-tuning on dissimilar domains.
128
+
129
+ Table 5: The average class error of (Li et al., 2018) and the extension of their experiments of on “dissimilar” datasets. The italic datasets and numbers are our experimental results. Note that the original Indoor result is fine-tuned from Places-365, while we fine-tune just from ImageNet pre-trained models.
130
+
131
+ <table><tr><td>Method</td><td>Dogs</td><td>Caltech</td><td>Indoor</td><td>Birds</td><td>Cars</td><td>Flowers</td><td>Aircrafts</td></tr><tr><td>L2 (Li et al., 2018)</td><td>18.6</td><td>14.7</td><td>20.4</td><td>1</td><td></td><td>-</td><td></td></tr><tr><td>L2-SP (Li et al., 2018)</td><td>14.9</td><td>13.6</td><td>15.8</td><td>1</td><td>1</td><td>1</td><td>1</td></tr><tr><td>L2 with HPO</td><td>16.79</td><td>14.98</td><td>23.00</td><td>22.51</td><td>10.10</td><td>5.70</td><td>13.03</td></tr><tr><td>L2-SP with HPO</td><td>13.86</td><td>14.45</td><td>21.77</td><td>22.32</td><td>9.59</td><td>5.28</td><td>13.31</td></tr></table>
132
+
133
+ We also check the change of regularization terms during training for both methods as well as their best hyperparameters. As shown in Figure 6, the $L _ { 2 }$ regularization usually decrease the weights norm more aggressively, depending on the value of $\lambda$ , while $L _ { 2 }$ -SP regularization keeps the norm less changed. We can see that the optimal learning rate of $L _ { 2 }$ regularization is mostly smaller than $L _ { 2 }$ -SP, which may compensate for the decreased weight norm or increased ELR. Interestingly, for Dogs dataset, both regularization terms grow much larger after a few iterations and then become stable, which means constraining the weights to be close to initialization is not necessarily the reason for $L _ { 2 }$ -SP to work even for close domains. It also seems contradicting to previous finding (Zhang et al., 2018) that weight decay functions as increasing ELR by decreasing weight norms. However, it might be reasonable as large norm actually decreases the ELR, which could be helpful due to the close domain similarity between Dogs and ImageNet.
134
+
135
+ ![](images/bd0d6388dea8abde7f04a6ba9f9521d805a08f943845b42e48c9ab2d86457140.jpg)
136
+ Figure 6: The normalized $L _ { 2 }$ norm and $L _ { 2 }$ -SP norm during training. The $_ y$ -axis is the relative change of the regularization term in comparison to the initial value, i.e., $\ \overline { { | | { \theta } _ { t } | | _ { 2 } ^ { 2 } } } / \| \overline { { { \theta } } } _ { 0 } \| _ { 2 } ^ { 2 }$ for $L _ { 2 }$ norm and $( \lambda _ { 1 } \| \theta _ { t } ^ { \prime } - \theta _ { 0 } \| _ { 2 } ^ { 2 } +$ $\lambda _ { 2 } \| \theta _ { t } ^ { \prime \prime } \| _ { 2 } ^ { 2 } ) / ( \lambda _ { 2 } \| \theta _ { 0 } ^ { \prime \prime } \| _ { 2 } ^ { 2 } )$ for $\small { \cal L } _ { 2 } { \bf - S P }$ norm. Optimal hyperparameters are also given in the legend. Note that experiment uses batch size 64 instead of 256, which results in smaller optimal learning rate comparing to previous result.
137
+
138
+ # 4 DISCUSSION
139
+
140
+ The two extreme ways for selecting hyperparameters—performing exhaustive hyperparameter search or taking ad-hoc hyperparameters from scratch training—could be either too computationally expensive or yield inferior performance. Different from training from scratch, where the default hyperparameter setting may work well for random initialization, the choice of hyperparameters for fine-tuning is not only dataset dependent but is also influenced by the similarity between the target and source domains. The rarely tuned momentum value could also improve or impede the performance when the target domain and source domain are close given insufficiently searched learning rate. These observations connect with previous theoretical works on decreasing momentum at the end of training and effective learning rate. We further identify that the optimal effective learning rate correlates with the similarity between the source and target domains. With this understanding, one can significantly reduce the hyperparameter search space. We hope these findings could be one step towards better and efficient hyperparameter selection for fine-tuning.
141
+
142
+ # ACKNOWLEDGMENTS
143
+
144
+ The authors would like to thank all anonymous reviewers for their valuable feedback.
145
+
146
+ # REFERENCES
147
+
148
+ Alessandro Achille, Michael Lam, Rahul Tewari, Avinash Ravichandran, Subhransu Maji, Charless Fowlkes, Stefano Soatto, and Pietro Perona. Task2vec: Task embedding for meta-learning. arXiv preprint arXiv:1902.03545, 2019.
149
+ Liang-Chieh Chen, George Papandreou, Iasonas Kokkinos, Kevin Murphy, and Alan L Yuille. Deeplab: Semantic image segmentation with deep convolutional nets, atrous convolution, and fully connected crfs. IEEE T-PAMI, 40(4):834–848, 2017.
150
+ Ekin D Cubuk, Barret Zoph, Dandelion Mane, Vijay Vasudevan, and Quoc V Le. Autoaugment: Learning augmentation policies from data. arXiv preprint arXiv:1805.09501, 2018.
151
+ Yin Cui, Yang Song, Chen Sun, Andrew Howard, and Serge Belongie. Large scale fine-grained categorization and domain-specific transfer learning. In CVPR, 2018.
152
+ Jia Deng, Alexander C Berg, Kai Li, and Li Fei-Fei. What does classifying more than 10,000 image categories tell us? In ECCV, 2010.
153
+
154
+ Jeff Donahue, Yangqing Jia, Oriol Vinyals, Judy Hoffman, Ning Zhang, Eric Tzeng, and Trevor Darrell. Decaf: A deep convolutional activation feature for generic visual recognition. In ICML, 2014.
155
+
156
+ Weifeng Ge and Yizhou Yu. Borrowing treasures from the wealthy: Deep transfer learning through selective joint fine-tuning. In CPVR, 2017.
157
+
158
+ Ross Girshick, Jeff Donahue, Trevor Darrell, and Jitendra Malik. Rich feature hierarchies for accurate object detection and semantic segmentation. In CVPR, 2014.
159
+
160
+ Gabriel Goh. Why momentum really works. Distill, 2(4):e6, 2017.
161
+
162
+ 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.
163
+
164
+ Gregory Griffin, Alex Holub, and Pietro Perona. Caltech-256 object category dataset. 2007.
165
+
166
+ Stephen Jose Hanson and Lorien Y. Pratt. Comparing biases for minimal network construction with back-propagation. In NIPS, 1989.
167
+
168
+ Kaiming He, Xiangyu Zhang, Shaoqing Ren, and Jian Sun. Identity mappings in deep residual networks. In ECCV, 2016a.
169
+
170
+ Kaiming He, Xiangyu Zhang, Shaoqing Ren, and Jian Sun. Deep residual learning for image recognition. In CVPR, 2016b.
171
+
172
+ Kaiming He, Georgia Gkioxari, Piotr Dollár, and Ross Girshick. Mask R-CNN. In ICCV, 2017.
173
+
174
+ Kaiming He, Ross Girshick, and Piotr Dollár. Rethinking imagenet pre-training. In ICCV, 2019.
175
+
176
+ John Hertz, A Krogh, and Richard G Palmer. Introduction to the theory of neural computation. 1991.
177
+
178
+ Andrew G Howard, Menglong Zhu, Bo Chen, Dmitry Kalenichenko, Weijun Wang, Tobias Weyand, Marco Andreetto, and Hartwig Adam. Mobilenets: Efficient convolutional neural networks for mobile vision applications. arXiv preprint arXiv:1704.04861, 2017.
179
+
180
+ Gao Huang, Zhuang Liu, Laurens Van Der Maaten, and Kilian Q Weinberger. Densely connected convolutional networks. In CVPR, 2017.
181
+
182
+ Minyoung Huh, Pulkit Agrawal, and Alexei A Efros. What makes imagenet good for transfer learning? arXiv preprint arXiv:1608.08614, 2016.
183
+
184
+ Sergey Ioffe and Christian Szegedy. Batch normalization: Accelerating deep network training by reducing internal covariate shift. In ICML, 2015.
185
+
186
+ Aditya Khosla, Nityananda Jayadevaprakash, Bangpeng Yao, and Li Fei-Fei. Novel dataset for fine-grained image categorization. In First Workshop on Fine-Grained Visual Categorization, CVPR, 2011.
187
+
188
+ Simon Kornblith, Jonathon Shlens, and Quoc V Le. Do better imagenet models transfer better? In CVPR, 2019.
189
+
190
+ Jonathan Krause, Michael Stark, Jia Deng, and Li Fei-Fei. 3d object representations for fine-grained categorization. In 4th International IEEE Workshop on 3D Representation and Recognition (3dRR-13), Sydney, Australia, 2013.
191
+
192
+ Alex Krizhevsky, Ilya Sutskever, and Geoffrey E Hinton. Imagenet classification with deep convolutional neural networks. In NIPS, 2012.
193
+
194
+ Anders Krogh and John A Hertz. A simple weight decay can improve generalization. In NIPS, 1992.
195
+
196
+ Xingjian Li, Haoyi Xiong, Hanchao Wang, Yuxuan Rao, Liping Liu, and Jun Huan. Delta: Deep learning transfer using feature map with attention for convolutional networks. In ICLR, 2019.
197
+
198
+ Xuhong Li, Yves Grandvalet, and Franck Davoine. Explicit inductive bias for transfer learning with convolutional networks. In ICML, 2018.
199
+
200
+ Tianyi Liu, Zhehui Chen, Enlu Zhou, and Tuo Zhao. Toward deeper understanding of nonconvex stochastic optimization with momentum using diffusion approximations. arXiv preprint arXiv:1802.05155, 2018.
201
+
202
+ Ilya Loshchilov and Frank Hutter. Decoupled weight decay regularization. In ICLR, 2018.
203
+
204
+ Dhruv Mahajan, Ross Girshick, Vignesh Ramanathan, Kaiming He, Manohar Paluri, Yixuan Li, Ashwin Bharambe, and Laurens van der Maaten. Exploring the limits of weakly supervised pretraining. In ECCV, 2018.
205
+
206
+ S. Maji, J. Kannala, E. Rahtu, M. Blaschko, and A. Vedaldi. Fine-grained visual classification of aircraft. Technical report, 2013.
207
+
208
+ Romain Mormont, Pierre Geurts, and Raphaël Marée. Comparison of deep transfer learning strategies for digital pathology. In CVPR Workshops, 2018.
209
+
210
+ Yurixi E Nesterov. A method for solving the convex programming problem with convergence rate o $( 1 / \mathrm { k } ^ { \cdot } 2 )$ ). In Dokl. akad. nauk Sssr, volume 269, pp. 543–547, 1983.
211
+
212
+ Jiquan Ngiam, Daiyi Peng, Vijay Vasudevan, Simon Kornblith, Quoc V Le, and Ruoming Pang. Domain adaptive transfer learning with specialist models. arXiv preprint arXiv:1811.07056, 2018.
213
+
214
+ Maria-Elena Nilsback and Andrew Zisserman. Automated flower classification over a large number of classes. In Indian Conference on Computer Vision, Graphics & Image Processing. IEEE, 2008.
215
+
216
+ Boris T Polyak. Some methods of speeding up the convergence of iteration methods. USSR Computational Mathematics and Mathematical Physics, 4(5):1–17, 1964.
217
+
218
+ Maithra Raghu, Chiyuan Zhang, Jon Kleinberg, and Samy Bengio. Transfusion: Understanding transfer learning with applications to medical imaging. In NIPS, 2019.
219
+
220
+ Shaoqing Ren, Kaiming He, Ross Girshick, and Jian Sun. Faster r-cnn: Towards real-time object detection with region proposal networks. In NIPS, 2015.
221
+
222
+ Olga Russakovsky, Jia Deng, Hao Su, Jonathan Krause, Sanjeev Satheesh, Sean Ma, Zhiheng Huang, Andrej Karpathy, Aditya Khosla, Michael Bernstein, Alexander C. Berg, and Li Fei-Fei. ImageNet Large Scale Visual Recognition Challenge. IJCV, 115(3):211–252, 2015.
223
+
224
+ Ali Sharif Razavian, Hossein Azizpour, Josephine Sullivan, and Stefan Carlsson. Cnn features off-the-shelf: an astounding baseline for recognition. In CVPR workshops, pp. 806–813, 2014.
225
+
226
+ Karen Simonyan and Andrew Zisserman. Very deep convolutional networks for large-scale image recognition. In ICLR, 2015.
227
+
228
+ Leslie N Smith. Cyclical learning rates for training neural networks. In WACV, 2017.
229
+
230
+ Leslie N Smith. A disciplined approach to neural network hyper-parameters: Part 1–learning rate, batch size, momentum, and weight decay. arXiv preprint arXiv:1803.09820, 2018.
231
+
232
+ Leslie N Smith and Nicholay Topin. Super-convergence: Very fast training of neural networks using large learning rates. In Artificial Intelligence and Machine Learning for Multi-Domain Operations Applications, volume 11006, pp. 1100612. International Society for Optics and Photonics, 2019.
233
+
234
+ Samuel L Smith and Quoc V Le. A bayesian perspective on generalization and stochastic gradient descent. In ICLR, 2018.
235
+
236
+ Samuel L Smith, Pieter-Jan Kindermans, Chris Ying, and Quoc V Le. Don’t decay the learning rate, increase the batch size. In ICLR, 2018.
237
+
238
+ Chen Sun, Abhinav Shrivastava, Saurabh Singh, and Abhinav Gupta. Revisiting unreasonable effectiveness of data in deep learning era. In CVPR, 2017.
239
+
240
+ Ilya Sutskever, James Martens, George Dahl, and Geoffrey Hinton. On the importance of initialization and momentum in deep learning. In ICML, 2013.
241
+
242
+ Christian Szegedy, Wei Liu, Yangqing Jia, Pierre Sermanet, Scott Reed, Dragomir Anguelov, Dumitru Erhan, Vincent Vanhoucke, and Andrew Rabinovich. Going deeper with convolutions. In CVPR, 2015.
243
+
244
+ Grant Van Horn, Oisin Mac Aodha, Yang Song, Yin Cui, Chen Sun, Alex Shepard, Hartwig Adam, Pietro Perona, and Serge Belongie. The inaturalist species classification and detection dataset. In CVPR, 2018.
245
+
246
+ Twan van Laarhoven. L2 regularization versus batch and weight normalization. In NIPS, 2017.
247
+
248
+ C. Wah, S. Branson, P. Welinder, P. Perona, and S. Belongie. The Caltech-UCSD Birds-200-2011 Dataset. Technical Report CNS-TR-2011-001, California Institute of Technology, 2011.
249
+
250
+ Junyuan Xie, Tong He, Zhi Zhang, Hang Zhang, Zhongyue Zhang, and Mu Li. Bag of tricks for image classification with convolutional neural networks. arXiv preprint arXiv:1812.01187, 2018.
251
+
252
+ Jason Yosinski, Jeff Clune, Yoshua Bengio, and Hod Lipson. How transferable are features in deep neural networks? In NIPS, 2014.
253
+
254
+ Guodong Zhang, Chaoqi Wang, Bowen Xu, and Roger Grosse. Three mechanisms of weight decay regularization. arXiv preprint arXiv:1810.12281, 2018.
255
+
256
+ Jian Zhang and Ioannis Mitliagkas. Yellowfin and the art of momentum tuning. arXiv preprint arXiv:1706.03471, 2017.
257
+
258
+ Bolei Zhou, Agata Lapedriza, Aditya Khosla, Aude Oliva, and Antonio Torralba. Places: A 10 million image database for scene recognition. IEEE T-PAMI, 40(6):1452–1464, 2018.
259
+
260
+ # A THE EFFECTIVENESS OF MOMENTUM
261
+
262
+ Searching for Optimal Momentum To check the effectiveness of momentum on fine-tuning, we can search the best momentum values for fine-tuning with fixed learning rate but different weight decay and batch size. Taking Birds dataset as an example, Figure 7 provides the convergence curves for the results shown in Figure 1(a), which shows the learning curves of fine-tuning with 6 different batch sizes and weight decay combinations. Zero momentum outperforms the nonzero momentum in 5 out of 6 configurations.
263
+
264
+ ![](images/8beae2447809ec4270e59fee2f970afcb8a9b4714c2b111c7115aad152104e0c.jpg)
265
+ Figure 7: Searching for the optimal momentum on Birds dataset with fixed learning rate and weight decays. The solid lines are training errors and the dashed lines are validation errors.
266
+
267
+ Effective learning rate increases after disabling momentum. Figure 8 compares the performance of with and without momentum for Dogs dataset with a range of different learning rates. Note that the learning rate with similar performance generally increases $1 0 \mathrm { x }$ after changing $m$ from 0.9 to 0.0, which is coherent with the rule of effective learning rate $\eta ^ { \prime } = \eta / ( 1 - m )$ . Same observations can be made on other datasets as shown in Figure 9.
268
+
269
+ ![](images/d272a7bfcd1b13889839f52478efe383627211480fe1e0bd6e539537315f620c.jpg)
270
+ Figure 8: The effect of momentum when learning rate is allowed to change. The learning rate for the best performance increases 10x after changing $m$ from 0.9 to 0.0, which is coherent with the rule of effective learning rate. Note that weight decay $\lambda$ is fixed at 0.0001.
271
+
272
+ ![](images/6975d095fde1cce98ef4cfbcacd6896129b345a222c1c8fa715c18ac86cd55aa.jpg)
273
+ Figure 9: The effect of momentum when learning rate is allowed to change (Figure 8 continued). The learning rate for the best performance increases $1 0 \mathrm { x }$ after changing $m$ from 0.9 to 0.0, which is coherent with the rule of effective learning rate.
274
+
275
+ # B DOMAIN SIMILARITY
276
+
277
+ The domain similarity calculation based on Earth Mover Distance (EMD) is introduced in the section 4.1 of (Cui et al., 2018)4. Here we briefly introduce the steps. In (Cui et al., 2018), the authors first train ResNet-101 on the large scale JFT dataset (Sun et al., 2017) and use it as a feature extractor. They extracted features from the penultimate layer of the model for each image of the training set of the source domain and target domain. For ResNet-101, the length of the feature vector is 2048. The features of images belonging to the same category are averaged and $g ( s _ { i } )$ denotes the average feature vector of ith label in source domain $S$ , similarly, $g ( t _ { j } )$ denotes the average feature vector of $j$ th label in target domain $T$ . The distance between the averaged features of two labels is $d _ { i , j } = \lVert g ( s _ { i } ) - g ( t _ { j } ) \rVert$ . Each label is associated with a weight $w \in [ 0 , 1 ]$ corresponding to the percentage of images with this label in the dataset. So the source domain $S$ with $m$ labels and the target domain $T$ with $n$ labels can be represented as ${ \cal { S } } = \{ ( s _ { i } , w _ { s _ { i } } ) \} _ { i = 1 } ^ { m }$ and $T = \{ ( t _ { j } , w _ { t _ { j } } ) \} _ { i = 1 } ^ { n }$ . The EMD between the two domains is defined as
278
+
279
+ $$
280
+ d ( S , T ) = \operatorname { E M D } ( S , T ) = { \frac { \sum _ { i = 1 , j = 1 } ^ { m , n } f _ { i , j } d _ { i , j } } { \sum _ { i = 1 , j = 1 } ^ { m , n } f _ { i , j } } }
281
+ $$
282
+
283
+ where the optimal flow $f _ { i , j }$ corresponds to the least amount of total work by solving the EMD optimization problem. The domain similarity is defined as
284
+
285
+ $$
286
+ \sin ( S , T ) = e ^ { - \gamma d ( S , T ) }
287
+ $$
288
+
289
+ where $\gamma$ is 0.01. Note that the domain similarity value is not ranging from 0 to 1.
290
+
291
+ Due to the unavailability of the large-scale JFT dataset ( $3 0 0 \mathrm { x }$ larger than ImageNet) and its pre-trained ResNet-101 model, we cannot use it for extracting features for new datasets, such as Caltech256 and
292
+
293
+ MIT67-Indoor. Instead of using the powerful feature representation, we use our pre-trained ImageNet model (ResNet-101) as the feature extractor. Table 4 compares the domain similarities calculated by different pre-trained models and we can see some consistent patterns across different architectures: e.g., The 1st and 2nd highest similarity scores are Caltech and Dogs regardless of architectures; the 3rd and 4th highest similarity scores refers to Birds and Indoor; the most dissimilar datasets are Cars, Aircrafts and Flowers, though the relative orders for them are not exactly the same. Besides using fixed feature extractor, an alternative way is to use the source domain model directly as the feature extractor for both source domain and target domain, which may captures the transfer learning process more precisely than a uniform feature extractor.
294
+
295
+ # C THE EFFECTIVENESS OF BN MOMENTUM
296
+
297
+ Kornblith et al. (2019) conducted extensive fine-tuning experiments with different hyperparameters. One observation they made is that the momentum parameter of BN layer is essential for finetuning. They found it useful to decrease the BN momentum parameter from its ImageNet value to $\operatorname* { m a x } ( 1 - \mathrm { \tilde { 1 0 } } / s , 0 . 9 )$ where $s$ is the number of steps per epoch. This will change the default BN momentum value (0.9) when $s$ is larger than 100, but it only applies when the dataset size is larger than 25.6K with batch size 256. The maximum data size used in our experiments is Caltech-256, which is 15K, so this strategy seems not applicable.
298
+
299
+ We further validate the effect of BN momentum by performing a similar study as to ELR. The goal is to identify whether there is an optimal BN momentum for a given task. For each dataset, we fine-tune the pre-trained model using previously obtained best hyperparameters and only vary BN momentum. In addition to the default value 0.9, we also set it to 0.0, 0.95 and 0.99. The rational is that if BN mommentum is a critical hyperparameter, we should expect significant performance differences when the value is changed from the optimal value. As shown in Figure 10, we can see $m _ { b n } = 0 . 9 9$ slightly improves the performance for some datasets, however, there is no significant performance difference among values greater than 0.9. One hypothesis is that similar domains will share similar BN parameters and statistics, BN momentum may affect the parameter adaptation. More investigation is still needed to fully understand its effectiveness.
300
+
301
+ ![](images/950c08dfafbcd1c62591b4bd179a0a8940ce2fd4429f42a85e25295a82ad1fae.jpg)
302
+ Figure 10: Performance of different BN momentum for each dataset with existing optimal hyperparameters.
303
+
304
+ # D EXPERIMENTAL SETTINGS FOR COMPARISON OF $L _ { 2 }$ AND $L _ { 2 }$ -SP
305
+
306
+ The experiments in Section 3.4 is based the code5 provided by (Li et al., 2018). The base network is ImageNet pretrained ResNet-101-V1. The model is fine-tuned with batch size 64 for 9000 iterations, and learning rate is decayed once at iteration 6000. Following the original setting, we use momentum 0.9. We performed grid search on learning rate and weight decay, with the range of $\eta : \{ 0 . 0 2 , 0 . 0 1 , 0 . 0 0 5 , 0 . 0 0 1 , 0 . 0 \bar { 0 } 0 1 \}$ and $\lambda _ { 1 } : \{ 0 . 1 , \bar { 0 . 0 1 } , 0 . 0 0 1 , 0 . 0 \bar { 0 } 0 1 \}$ , and report the best average class error (1 - average accuracy) for both methods. For $L _ { 2 }$ -SP norm, we follow the authors’ setting to use constant $\lambda _ { 2 } = 0 . 0 1$ . Different with the original setting for $L _ { 2 }$ regularization, we set $\lambda _ { 2 } = \lambda _ { 1 }$ to simulate normal $L _ { 2 }$ -norm.
307
+
308
+ # E DATA AUGMENTATION
309
+
310
+ Data augmentation is an important way of increasing data quantity and diversity to make models more robust. It is even critical for transfer learning with few instances. The effect of data augmentation can be viewed as a regularization and the choice of data augmentation can be also viewed as a hyperparameter. Most current widely used data augmentation methods have verified their effectiveness on training ImageNet models, such as random mirror flipping, random rescaled cropping6, color jittering and etc (Szegedy et al., 2015; Xie et al., 2018).
311
+
312
+ Do these methods transfer for fine-tuning on other datasets? Here we compare three settings for data augmentation with different momentum settings: 1) random resized cropping: our default data augmentation; 2) random cropping: the same as standard data augmentation except that we use random cropping with fixed size; 3) random flip: simply random horizontal flipping. The training and validation errors of fine-tuning with different data augmentation strategies and hyperparameters are shown in Figure 11 and Figure 12.
313
+
314
+ ![](images/b853f9f9663c5bbe1027d13c3b70378ace602276659025eeecce79608702402f.jpg)
315
+ Figure 11: Fine-tuning with different data augmentation methods and hyperparameters. Dashed curves are the validation errors. Strong data augmentation is harder to train as it converge slowly and needs more number of epochs to observe the advanced performance on datasets such as Aircrafts. Simple data augmentation (red curves) converges much faster in training error. Strong data augmentation (blue curves) overfits the Dogs dataset with default hyperparameter but performs well with $m = 0$ .
316
+
317
+ The effect of data augmentation is dataset dependent and is also influenced by other hyperparameters The first row in Figure 11 shows that advanced data augmentation with default hyperparameters ( $m = 0 . 9$ and $\eta = 0 . 0 1 $ ) leads to overfitting for Dogs while generalize better on Aircrafts and Flowers. Similar observations can be made in Figure 12. However, when momentum is disabled, the overfitting disappears for Dogs and Caltech. This is explainable since random resized cropping adds more variance to the gradient direction, and disabling momentum will lead to a smaller ELR which will be helpful for fine-tuning from a similar domain. On the other hand, the performance of random cropping decreases when momentum is disabled. As random cropping produces training samples with less variation than random resized cropping, disabling momentum or decreasing the ELR might lead to underfitting or stucking in poor local minima. This can be mitigated as we increase the learning rate for random cropping, which adds variation to the gradients. As shown in Table 6, when learning rate increased fro 0.01 to 0.05, disabling momentum shows better performance than nonzero momentum on datasets that are close, similar to previous findings with random resized cropping.
318
+
319
+ ![](images/4abd77ff6555d3fc005e908f20f3a82181f6489f569f34344fadd7221496ed3c.jpg)
320
+ Figure 12: Comparison of data augmentation methods with different momentum values (Figure 11 continued). The other hyperparameters are: $n = 2 5 6$ , $\eta = 0 . 0 1$ and $\lambda = 0 . 0 0 0 1$ .
321
+
322
+ Table 6: Comparison of data augmentation methods with different momentum values. The rest of the hyperparameters are: $n = 2 5 6$ and $\lambda = 0 . 0 0 0 1$ .
323
+
324
+ <table><tr><td colspan="2">Data Augmentation</td><td>m m</td><td>Dogs</td><td>Caltech</td><td>Indoor</td><td>Birds</td><td>Cars</td><td>Flowers</td><td>Aircrafts</td></tr><tr><td rowspan="2">Rand resized crop</td><td>0.9</td><td>0.01</td><td>17.20</td><td>14.85</td><td>23.76</td><td>18.10</td><td>9.10</td><td>3.12</td><td>17.55</td></tr><tr><td>0</td><td>0.01</td><td>11.00</td><td>12.11</td><td>21.14</td><td>17.41</td><td>11.06</td><td>5.48</td><td>20.58</td></tr><tr><td rowspan="4">Rand crop</td><td>0.9</td><td>0.01</td><td>11.99</td><td>12.42</td><td>23.39</td><td>20.31</td><td>17.77</td><td>5.63</td><td>21.72</td></tr><tr><td>0</td><td>0.01</td><td>11.35</td><td>12.89</td><td>25.19</td><td>22.11</td><td>23.87</td><td>7.76</td><td>29.04</td></tr><tr><td>0.9</td><td>0.05</td><td>16.85</td><td>14.80</td><td>23.46</td><td>18.81</td><td>13.70</td><td>4.85</td><td>17.64</td></tr><tr><td>0</td><td>0.05</td><td>11.79</td><td>12.52</td><td>23.24</td><td>20.69</td><td>20.00</td><td>7.06</td><td>23.43</td></tr></table>
325
+
326
+ # F SOURCE DOMAINS
327
+
328
+ Pre-trained models For most of our experiments, we use the pre-trained ResNet-101_v2 model from the model zoo of MXNet GluonCV 7. To get the pre-trained models for iNat-2017 and Places365, we fine-tune from the ImageNet pre-trained model with the default fine-tuning hyperparameters for 60 epochs, where learning rate is decayed at epoch 45 by a factor of 10. Table 7 illustrates the Top-1 errors of each pre-trained model on their validation sets.
329
+
330
+ Table 7: The Top-1 error of ResNet-101 pre-trained on different source dataset.
331
+
332
+ <table><tr><td>Dataset</td><td>class</td><td>Top-1 error</td></tr><tr><td>ImageNet</td><td>1000</td><td>21.4</td></tr><tr><td>iNat2017</td><td>5,089</td><td>32.2</td></tr><tr><td>Places-365</td><td>365</td><td>31.5</td></tr></table>
333
+
334
+ Training from Scratch with HPO The default hyperparameters for training from scratch are $\eta = 0 . 1$ , $\lambda = 0 . 0 0 0 1$ , $m = 0 . 9$ and $n = 2 5 6$ . We train 600 epochs, and decay the learning rate at epoch 400 and 550 by a factor of 10. To perform Hyperparameter Optimization (HPO), we search hyperparameters in the following space: $\eta \in [ 0 . 1 , 0 . 2 , 0 . 5 ]$ and $\lambda \in [ 0 . 0 0 0 1 , 0 . 0 0 0 5 ]$ . Figure 13 shows the training/validation errors of training from scratch on each dataset with different learning rate and weight decay. We observe weight decay 0.0005 consistently performs better than 0.0001.
335
+
336
+ Insufficient hyperparameter search may lead to miss-leading conclusion To show the importance of hyperparameter tuning, Table 8 compares the performance with and without hyperparameter tuning for both fine-tuning and training from scratch tasks. With the default hyperparameters, some inappropriate conclusions might be made, e.g., “there is significant gap between fine-tuning and training from scratch", “fine-tuning always surpass training from scratch" or “fine-tuning from iNat cannot beat the performance of ImageNet". However, with HPO, those statements may not be valid. For example, training from scratch surpass the default fine-tuning result on Cars and Aircrafts and the gap between fine-tuning and training from scratch is much smaller. Previous studies (Kornblith et al., 2019; Cui et al., 2018) also identified that datasets like Cars and Aircrafts do not benefit too much from fine-tuning.
337
+
338
+ Table 8: Comparison of default hyperparameters and HPO for both fine-tuning (FT) and training from scratch (ST) tasks. FT Default and ST Default use their default hyperparameters, respectively. HPO refers to the finding the best hyperparameters with grid search.
339
+
340
+ <table><tr><td>Method</td><td>Source</td><td>Dogs</td><td>Caltech</td><td>Indoor</td><td>Birds</td><td>Cars</td><td>Aircrafts</td><td>Flowers</td></tr><tr><td>FT Default</td><td>ImageNet</td><td>17.20</td><td>13.42</td><td>23.76</td><td>18.10</td><td>9.10</td><td>17.55</td><td>3.12</td></tr><tr><td>FT Default</td><td>iNat2017</td><td>24.74</td><td>20.12</td><td>30.73</td><td>14.69</td><td>11.16</td><td>19.86</td><td>3.19</td></tr><tr><td>FT Default</td><td>Places-365</td><td>30.84</td><td>22.53</td><td>22.19</td><td>27.72</td><td>11.06</td><td>21.27</td><td>5.66</td></tr><tr><td>ST Default</td><td>1</td><td>38.26</td><td>36.21</td><td>45.28</td><td>43.72</td><td>16.73</td><td>26.49</td><td>22.88</td></tr><tr><td>FT HPO</td><td>ImageNet</td><td>9.83</td><td>11.61</td><td>20.54</td><td>16.34</td><td>7.61</td><td>12.33</td><td>2.91</td></tr><tr><td>FT HPO</td><td>iNat2017</td><td>23.51</td><td>18.82</td><td>28.11</td><td>12.06</td><td>9.58</td><td>15.45</td><td>2.70</td></tr><tr><td>FT HPO</td><td>Places-365</td><td>26.24</td><td>22.14</td><td>19.42</td><td>22.90</td><td>9.13</td><td>15.48</td><td>5.06</td></tr><tr><td>ST HPO</td><td>1</td><td>29.32</td><td>29.62</td><td>39.36</td><td>30.08</td><td>8.37</td><td>14.34</td><td>16.51</td></tr></table>
341
+
342
+ ![](images/909d1a42088de344fe2672db84061fc6962fdb4c76f2a65e81205b92b034c96d.jpg)
343
+ Figure 13: Training from scratch with various learning rate and weight decay. The batch size is 256 and the momentum is 0.9. The solid curves are training error and the dashed lines are valdiation error.
parse/train/B1g8VkHFPH/B1g8VkHFPH_content_list.json ADDED
@@ -0,0 +1,1812 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ [
2
+ {
3
+ "type": "text",
4
+ "text": "RETHINKING THE HYPERPARAMETERS FOR FINE-TUNING ",
5
+ "text_level": 1,
6
+ "bbox": [
7
+ 173,
8
+ 99,
9
+ 640,
10
+ 146
11
+ ],
12
+ "page_idx": 0
13
+ },
14
+ {
15
+ "type": "text",
16
+ "text": "Hao $\\mathbf { L i } ^ { 1 }$ , Pratik Chaudhari2∗, Hao Yang1, Michael Lam1, Avinash Ravichandran1, Rahul Bhotika1, Stefano Soatto1,3 ",
17
+ "bbox": [
18
+ 183,
19
+ 169,
20
+ 758,
21
+ 199
22
+ ],
23
+ "page_idx": 0
24
+ },
25
+ {
26
+ "type": "text",
27
+ "text": "1Amazon Web Services, 2University of Pennsylvania, 3University of California, Los Angeles {haolimax, haoyng, michlam, ravinash, bhotikar, soattos} $@$ amazon.com, pratikac@seas.upenn.edu ",
28
+ "bbox": [
29
+ 186,
30
+ 203,
31
+ 767,
32
+ 236
33
+ ],
34
+ "page_idx": 0
35
+ },
36
+ {
37
+ "type": "text",
38
+ "text": "ABSTRACT ",
39
+ "text_level": 1,
40
+ "bbox": [
41
+ 454,
42
+ 272,
43
+ 544,
44
+ 287
45
+ ],
46
+ "page_idx": 0
47
+ },
48
+ {
49
+ "type": "text",
50
+ "text": "Fine-tuning from pre-trained ImageNet models has become the de-facto standard for various computer vision tasks. Current practices for fine-tuning typically involve selecting an ad-hoc choice of hyperparameters and keeping them fixed to values normally used for training from scratch. This paper re-examines several common practices of setting hyperparameters for fine-tuning. Our findings are based on extensive empirical evaluation for fine-tuning on various transfer learning benchmarks. (1) While prior works have thoroughly investigated learning rate and batch size, momentum for fine-tuning is a relatively unexplored parameter. We find that the value of momentum also affects fine-tuning performance and connect it with previous theoretical findings. (2) Optimal hyperparameters for fine-tuning, in particular, the effective learning rate, are not only dataset dependent but also sensitive to the similarity between the source domain and target domain. This is in contrast to hyperparameters for training from scratch. (3) Reference-based regularization that keeps models close to the initial model does not necessarily apply for “dissimilar” datasets. Our findings challenge common practices of finetuning and encourages deep learning practitioners to rethink the hyperparameters for fine-tuning. ",
51
+ "bbox": [
52
+ 233,
53
+ 305,
54
+ 766,
55
+ 540
56
+ ],
57
+ "page_idx": 0
58
+ },
59
+ {
60
+ "type": "text",
61
+ "text": "1 INTRODUCTION ",
62
+ "text_level": 1,
63
+ "bbox": [
64
+ 176,
65
+ 569,
66
+ 336,
67
+ 584
68
+ ],
69
+ "page_idx": 0
70
+ },
71
+ {
72
+ "type": "text",
73
+ "text": "Many real-world applications often have a limited number of training instances, which makes directly training deep neural networks hard and prone to overfitting. Transfer learning with the knowledge of models learned on a similar task can help to avoid overfitting. Fine-tuning is a simple and effective approach of transfer learning and has become popular for solving new tasks in which pre-trained models are fine-tuned with the target dataset. Specifically, fine-tuning on pre-trained ImageNet classification models (Simonyan & Zisserman, 2015; He et al., 2016b) has achieved impressive results for tasks such as object detection (Ren et al., 2015) and segmentation (He et al., 2017; Chen et al., 2017) and is becoming the de-facto standard of solving computer vision problems. It is believed that the weights learned on the source dataset with a large number of instances provide better initialization for the target task than random initialization. Even when there is enough training data, fine-tuning is still preferred as it often reduces training time significantly (He et al., 2019). ",
74
+ "bbox": [
75
+ 174,
76
+ 601,
77
+ 825,
78
+ 753
79
+ ],
80
+ "page_idx": 0
81
+ },
82
+ {
83
+ "type": "text",
84
+ "text": "The common practice of fine-tuning is to adopt the default hyperparameters for training large models while using smaller initial learning rate and shorter learning rate schedule. It is believed that adhering to the original hyperparameters for fine-tuning with small learning rate prevents destroying the originally learned knowledge or features. For instance, many studies conduct fine-tuning of ResNets (He et al., 2016b) with these default hyperparameters: learning rate 0.01, momentum 0.9 and weight decay 0.0001. However, the default setting is not necessarily optimal for fine-tuning on other tasks. While few studies have performed extensive hyperparameter search for learning rate and weight decay (Mahajan et al., 2018; Kornblith et al., 2019), the momentum coefficient is rarely changed. Though the effectiveness of the hyperparameters has been studied extensively for training a model from scratch, how to set the hyperparameters for fine-tuning is not yet fully understood. ",
85
+ "bbox": [
86
+ 174,
87
+ 761,
88
+ 825,
89
+ 900
90
+ ],
91
+ "page_idx": 0
92
+ },
93
+ {
94
+ "type": "text",
95
+ "text": "In addition to using ad-hoc hyperparameters, commonly held beliefs for fine-tuning also include: ",
96
+ "bbox": [
97
+ 169,
98
+ 103,
99
+ 808,
100
+ 118
101
+ ],
102
+ "page_idx": 1
103
+ },
104
+ {
105
+ "type": "text",
106
+ "text": "• Fine-tuning pre-trained networks outperforms training from scratch; recent work (He et al., 2019) has already revisited this. \n• Fine-tuning from similar domains and tasks works better (Ge & Yu, 2017; Cui et al., 2018; Achille et al., 2019; Ngiam et al., 2018). \n• Explicit regularization with initial models matters for transfer learning performance (Li et al., 2018; 2019). ",
107
+ "bbox": [
108
+ 215,
109
+ 127,
110
+ 826,
111
+ 219
112
+ ],
113
+ "page_idx": 1
114
+ },
115
+ {
116
+ "type": "text",
117
+ "text": "Are these practices or beliefs always valid? From an optimization perspective, the difference between fine-tuning and training from scratch is all about the initialization. However, the loss landscape of the pre-trained model and the fine-tuned solution could be much different, so as their optimization strategies and hyperparameters. Would the hyperparameters for training from scratch still be useful for fine-tuning? In addition, most of the hyperparameters (e.g., batch size, momentum, weight decay) are frozen; will the conclusion differ when some of them are changed? ",
118
+ "bbox": [
119
+ 174,
120
+ 229,
121
+ 825,
122
+ 314
123
+ ],
124
+ "page_idx": 1
125
+ },
126
+ {
127
+ "type": "text",
128
+ "text": "With these questions in mind, we re-examined the common practices for fine-tuning. We conducted extensive hyperparameter search for fine-tuning on various transfer learning benchmarks with different source models. The goal of our work is not to obtain state-of-the-art performance on each fine-tuning task, but to understand the effectiveness of each hyperparameter for fine-tuning, avoiding unnecessary computation. We explain why certain hyperparameters work so well on certain datasets while fail on others, which can guide hyperparameter search for fine-tuning. ",
129
+ "bbox": [
130
+ 174,
131
+ 320,
132
+ 825,
133
+ 404
134
+ ],
135
+ "page_idx": 1
136
+ },
137
+ {
138
+ "type": "text",
139
+ "text": "Our main findings are as follows: ",
140
+ "bbox": [
141
+ 174,
142
+ 411,
143
+ 393,
144
+ 425
145
+ ],
146
+ "page_idx": 1
147
+ },
148
+ {
149
+ "type": "text",
150
+ "text": "• Optimal hyperparameters for fine-tuning are not only dataset dependent, but are also dependent on the similarity between the source and target domains, which is different from training from scratch. Therefore, the common practice of using optimization schedules derived from ImageNet training cannot guarantee good performance. It explains why some tasks are not achieving satisfactory results after fine-tuning because of inappropriate hyperparameter selection. Specifically, as opposed to the common practice of rarely tuning the momentum value beyond 0.9, we find that zero momentum sometimes work better for fine-tuning on tasks that are similar with the source domain, while nonzero momentum works better for target domains that are different from the source domain. \nHyperparameters are coupled together and it is the effective learning rate—which encapsulates the learning rate and momentum—that matters for fine-tuning performance. While effective learning rate has been studied for training from scratch, to the best of our knowledge, no previous work investigates effective learning rate for fine-tuning and is less used in practice. Our observation of momentum can be explained as small momentum actually decreases the effective learning rate, which is more suitable for fine-tuning on similar tasks. We show that the optimal effective learning rate depends on the similarity between the source and target domains. We find regularization methods that were designed to keep models close to the initial model does not necessarily work for “dissimilar” datasets, especially for nets with Batch Normalization. Simple weight decay can result in as good performance as the referencebased regularization methods for fine-tuning with better search space. ",
151
+ "bbox": [
152
+ 215,
153
+ 435,
154
+ 825,
155
+ 734
156
+ ],
157
+ "page_idx": 1
158
+ },
159
+ {
160
+ "type": "text",
161
+ "text": "2 RELATED WORK ",
162
+ "text_level": 1,
163
+ "bbox": [
164
+ 174,
165
+ 753,
166
+ 343,
167
+ 770
168
+ ],
169
+ "page_idx": 1
170
+ },
171
+ {
172
+ "type": "text",
173
+ "text": "In transfer learning for image classification, the last layer of a pre-trained network is usually replaced with a randomly initialized fully connected layer with the same size as the number of classes in the target task (Simonyan & Zisserman, 2015). It has been shown that fine-tuning the whole network usually results in better performance than using the network as a static feature extractor (Yosinski et al., 2014; Donahue et al., 2014; Huh et al., 2016; Mormont et al., 2018; Kornblith et al., 2019). Ge & Yu (2017) select images that have similar local features from source domain to jointly fine-tune pre-trained networks. Cui et al. (2018) estimate domain similarity with ImageNet and demonstrate that transfer learning benefits from pre-training on a similar source domain. Besides image classification, many object detection frameworks also rely on fine-tuning to improve over training from scratch (Girshick et al., 2014; Ren et al., 2015). ",
174
+ "bbox": [
175
+ 173,
176
+ 785,
177
+ 825,
178
+ 924
179
+ ],
180
+ "page_idx": 1
181
+ },
182
+ {
183
+ "type": "text",
184
+ "text": "Many researchers re-examined whether fine-tuning is a necessity for obtaining good performance. Ngiam et al. (2018) find that when domains are mismatched, the effectiveness of transfer learning is negative, even when domains are intuitively similar. Kornblith et al. (2019) examine the fine-tuning performance of various ImageNet models and find a strong correlation between ImageNet top-1 accuracy and the transfer accuracy. They also find that pre-training on ImageNet provides minimal benefits for some fine-grained object classification dataset. He et al. (2019) questioned whether ImageNet pre-training is necessary for training object detectors. They find the solution of training from scratch is no worse than the fine-tuning counterpart as long as the target dataset is large enough. Raghu et al. (2019) find that transfer learning has negligible performance boost on medical imaging applications, but speed up the convergence significantly. ",
185
+ "bbox": [
186
+ 174,
187
+ 103,
188
+ 825,
189
+ 242
190
+ ],
191
+ "page_idx": 2
192
+ },
193
+ {
194
+ "type": "text",
195
+ "text": "There are many literatures on hyperparameter selection for training neural networks from scratch, mostly on batch size, learning rate and weight decay (Goyal et al., 2017; Smith et al., 2018; Smith & Topin, 2019). There are few works on the selection of momentum (Sutskever et al., 2013). Zhang & Mitliagkas (2017) proposed an automatic tuner for momentum and learning rate in SGD. There are also studies on the correlations of the hyperparameters, such as linear scaling rule between batch size and learning (Goyal et al., 2017; Smith et al., 2018; Smith, 2017). However, most of these advances on hyperparameter tuning are designed for training from scratch and have not examined on fine-tuning tasks for computer vision problems. Most work on fine-tuning simply choose fixed hyperparameters (Cui et al., 2018) or use dataset-dependent learning rates (Li et al., 2018) in their experiments. Due to the huge computational cost for hyperparameter search, only a few works (Kornblith et al., 2019; Mahajan et al., 2018) performed large-scale grid search of learning rate and weight decay for obtaining the best performance. ",
196
+ "bbox": [
197
+ 174,
198
+ 250,
199
+ 825,
200
+ 416
201
+ ],
202
+ "page_idx": 2
203
+ },
204
+ {
205
+ "type": "text",
206
+ "text": "3 TUNING HYPERPARAMETERS FOR FINE-TUNING ",
207
+ "text_level": 1,
208
+ "bbox": [
209
+ 176,
210
+ 436,
211
+ 607,
212
+ 453
213
+ ],
214
+ "page_idx": 2
215
+ },
216
+ {
217
+ "type": "text",
218
+ "text": "In this section, we first introduce the notations and experimental settings, and then present our observations on momentum, effective learning rate and regularization. The fine-tuning process is not different from learning from scratch except for the weights initialization. The goal of the process is still to minimize the objective function L = 1N PNi=1 \\` $\\begin{array} { r } { L = \\frac { 1 } { N } \\sum _ { i = 1 } ^ { N } \\ell ( f ( x _ { i } , \\theta ) , y _ { i } ) + \\frac { \\lambda } { 2 } \\| \\theta \\| _ { 2 } ^ { 2 } } \\end{array}$ , where $\\ell$ is the loss function, $N$ is the number of samples, $x _ { i }$ is the input data, $y _ { i }$ is its label, $f$ is the neural network, $\\theta$ is the model parameters and $\\lambda$ is the regularization hyperparameter or weight decay. Momentum is widely used for accelerating and smoothing the convergence of SGD by accumulating a velocity vector in the direction of persistent loss reduction (Polyak, 1964; Sutskever et al., 2013; Goh, 2017). The commonly used Nesterov’s Accelerated Gradient (Nesterov, 1983) is given by: ",
219
+ "bbox": [
220
+ 173,
221
+ 467,
222
+ 825,
223
+ 595
224
+ ],
225
+ "page_idx": 2
226
+ },
227
+ {
228
+ "type": "equation",
229
+ "img_path": "images/b26689ac1dc48c7c192e3fd62aad63679257d95ee86a6b954a9d12907411b4fd.jpg",
230
+ "text": "$$\n\\begin{array} { l } { { \\displaystyle v _ { t + 1 } = m v _ { t } - \\eta _ { t } \\frac { 1 } { n } \\sum _ { i = 1 } ^ { n } \\nabla \\ell \\big ( f \\big ( x _ { i } , \\theta _ { t } + m v _ { t } \\big ) , y _ { i } \\big ) } } \\\\ { { \\theta _ { t + 1 } = \\theta _ { t } + v _ { t + 1 } - \\eta \\lambda \\theta _ { t } } } \\end{array}\n$$",
231
+ "text_format": "latex",
232
+ "bbox": [
233
+ 338,
234
+ 599,
235
+ 658,
236
+ 661
237
+ ],
238
+ "page_idx": 2
239
+ },
240
+ {
241
+ "type": "text",
242
+ "text": "where $\\theta _ { t }$ indicates the model parameters at iteration $t$ . The hyperparameters include the learning rate $\\eta _ { t }$ , batch size $n$ , momentum coefficient $m \\in [ 0 , 1 )$ , and the weight decay $\\lambda$ . ",
243
+ "bbox": [
244
+ 171,
245
+ 665,
246
+ 823,
247
+ 694
248
+ ],
249
+ "page_idx": 2
250
+ },
251
+ {
252
+ "type": "text",
253
+ "text": "3.1 EXPERIMENTAL SETTINGS ",
254
+ "text_level": 1,
255
+ "bbox": [
256
+ 176,
257
+ 709,
258
+ 398,
259
+ 723
260
+ ],
261
+ "page_idx": 2
262
+ },
263
+ {
264
+ "type": "text",
265
+ "text": "We evaluate fine-tuning on seven widely used image classification datasets, which covers tasks for fine-grained object recognition, scene recognition and general object recognition. Detailed statistics of each dataset can be seen in Table 1. We use ImageNet (Russakovsky et al., 2015), Places-365 (Zhou et al., 2018) and iNaturalist (Van Horn et al., 2018) as source domains for pre-trained models. We resize the input images such that the aspect ratio is preserved and the shorter side is 256 pixels. The images are normalized with mean and std values calculated over ImageNet. For data augmentation, we adopt the common practices used for training ImageNet models (Szegedy et al., 2015): random mirror, random scaled cropping with scale and aspect variations, and color jittering. The augmented images are resized to $2 2 4 \\times 2 2 4$ . Note that state-of-the-art results could achieve even better performance by using higher resolution images (Cui et al., 2018) or better data augmentation (Cubuk et al., 2018). ",
266
+ "bbox": [
267
+ 174,
268
+ 734,
269
+ 825,
270
+ 875
271
+ ],
272
+ "page_idx": 2
273
+ },
274
+ {
275
+ "type": "text",
276
+ "text": "We mainly use ResNet-101-V2 (He et al., 2016a) as our base network, which is pre-trained on ImageNet (Russakovsky et al., 2015). Similar observations are also made on DenseNets (Huang et al., 2017) and MobileNet (Howard et al., 2017). The hyperparameters to be tuned (and ranges) ",
277
+ "bbox": [
278
+ 176,
279
+ 882,
280
+ 825,
281
+ 924
282
+ ],
283
+ "page_idx": 2
284
+ },
285
+ {
286
+ "type": "table",
287
+ "img_path": "images/6d06580cb1e0badf4031c906f244f27cc1e5b287ce3c4eaf9d71ecbaccee4395.jpg",
288
+ "table_caption": [
289
+ "Table 1: Datasets statistics. For the Caltech-256 dataset, we randomly sampled 60 images for each class following the procedure used in (Li et al., 2018). For the Aircraft and Flower dataset, we combined the original training set and validation set and evaluated on the test set. For iNat 2017, we combined the original training set and $90 \\%$ of the validation set following (Cui et al., 2018). "
290
+ ],
291
+ "table_footnote": [],
292
+ "table_body": "<table><tr><td>Datasets</td><td>Task Category</td><td>Classes</td><td>Training</td><td>Test</td></tr><tr><td>Oxford Flowers (Nilsback &amp; Zisserman, 2008)</td><td>fine-grained object recog.</td><td>102</td><td>2,040</td><td>6,149</td></tr><tr><td>CUB-Birds 200-2011 (Wah et al., 2011)</td><td>fine-grained object recog.</td><td>200</td><td>5,994</td><td>5,794</td></tr><tr><td>FGVC Aircrafts (Maji et al., 2013)</td><td>fine-grained object recog.</td><td>100</td><td>6,667</td><td>3,333</td></tr><tr><td>Stanford Cars (Krause etal., 2013)</td><td>fine-grained object recog.</td><td>196</td><td>8,144</td><td>8,041</td></tr><tr><td>Stanford Dogs (Khosla et al., 2011)</td><td>fine-grained object recog.</td><td>120</td><td>12.000</td><td>8,580</td></tr><tr><td>MIT Indoor-67 (Sharif Razavian et al., 2014)</td><td>scene classification</td><td>67</td><td>5,360</td><td>1,340</td></tr><tr><td>Caltech-256-60 (Griffin et al., 2007)</td><td>general object recog.</td><td>256</td><td>15,360</td><td>15,189</td></tr><tr><td>iNaturalist 2017 (Van Horn et al., 2018)</td><td>fine-grained object recog.</td><td>5,089</td><td>665,571</td><td>9,599</td></tr><tr><td>Place365 (Zhou et al., 2018)</td><td>scene classification</td><td>365</td><td>1,803,460</td><td>36,500</td></tr></table>",
293
+ "bbox": [
294
+ 171,
295
+ 164,
296
+ 843,
297
+ 332
298
+ ],
299
+ "page_idx": 3
300
+ },
301
+ {
302
+ "type": "text",
303
+ "text": "are: learning rate (0.1, 0.05, 0.01, 0.005, 0.001, 0.0001), momentum (0.9, 0.99, 0.95, 0.9, 0.8, 0.0) and weight decay (0.0, 0.0001, 0.0005, 0.001). We set the default hyperparameters to be batch size $2 5 6 ^ { 1 }$ , learning rate 0.01, momentum 0.9 and weight decay 0.0001. To avoid insufficient training and observe the complete convergence behavior, we use 300 epochs for fine-tuning and 600 epochs for scratch-training, which is long enough for the training curves to converge. The learning rate is decayed by a factor of 0.1 at epoch 150 and 250. We report the Top-1 validation (test) error at the end of training. The total computation time for the experiments is more than 10K GPU hours. ",
304
+ "bbox": [
305
+ 173,
306
+ 358,
307
+ 826,
308
+ 457
309
+ ],
310
+ "page_idx": 3
311
+ },
312
+ {
313
+ "type": "text",
314
+ "text": "3.2 EFFECT OF MOMENTUM AND DOMAIN SIMILARITY ",
315
+ "text_level": 1,
316
+ "bbox": [
317
+ 174,
318
+ 474,
319
+ 571,
320
+ 489
321
+ ],
322
+ "page_idx": 3
323
+ },
324
+ {
325
+ "type": "text",
326
+ "text": "Momentum 0.9 is the most widely used value for training from scratch (Krizhevsky et al., 2012; Simonyan & Zisserman, 2015; He et al., 2016b) and is also widely adopted for fine-tuning (Kornblith et al., 2019). To the best of our knowledge, it is rarely changed, regardless of the network architectures or target tasks. To check the influence of momentum on fine-tuning, we first search for the best momentum value for fine-tuning on the Birds dataset with different weight decay and learning rate. Figure 1(a) shows the performance of fine-tuning with and without weight decays. Surprisingly, momentum zero actually outperforms the nonzero momentum. The optimal learning rate also increases when the momentum is disabled as shown in Figure 1(b). ",
327
+ "bbox": [
328
+ 173,
329
+ 502,
330
+ 826,
331
+ 613
332
+ ],
333
+ "page_idx": 3
334
+ },
335
+ {
336
+ "type": "image",
337
+ "img_path": "images/0c290ddf7caa7aebc7d4a1743b9b33e47aa7d70c53ddde6baf696ba1ecd2aad5.jpg",
338
+ "image_caption": [
339
+ "Figure 1: (a) Searching for the optimal momentum on Birds dataset with fixed learning rate 0.01 and different weight decays. Detailed learning curves and results of other hyperparameters can be found in Appendix A. (b) Comparison of momentum 0.9 and 0.0 with different learning rates on the Birds dataset, $\\lambda$ is fixed at 0.0001. "
340
+ ],
341
+ "image_footnote": [],
342
+ "bbox": [
343
+ 251,
344
+ 622,
345
+ 709,
346
+ 762
347
+ ],
348
+ "page_idx": 3
349
+ },
350
+ {
351
+ "type": "text",
352
+ "text": "To verify this observation, we further compare momentum 0.9 and 0.0 on other datasets. Table 2 shows the performance of 8 hyperparameter settings on 7 datasets. We observe a clear pattern that disabling momentum works better for Dogs, Caltech and Indoor, while momentum 0.9 works better for Cars, Aircrafts and Flowers. ",
353
+ "bbox": [
354
+ 174,
355
+ 829,
356
+ 825,
357
+ 883
358
+ ],
359
+ "page_idx": 3
360
+ },
361
+ {
362
+ "type": "table",
363
+ "img_path": "images/3a9b8aa448f691fa46085bd6a99c522117cf1ae0d54a6a6f131b352ff69f1da9.jpg",
364
+ "table_caption": [
365
+ "Table 2: Top-1 validation errors on seven datasets by fine-tuning ImageNet pre-trained ResNet-101 with different hyperparmeters. Each row represents a network fine-tuned by a set of hyperparameters (left four columns). The datasets are ranked by the relative improvement by disabling momentum. The lowest error rates with the same momentum are marked as bold. Note that the performance difference for Birds is not very significant. "
366
+ ],
367
+ "table_footnote": [],
368
+ "table_body": "<table><tr><td>m</td><td>n</td><td>入</td><td>Dogs</td><td>Caltech</td><td>Indoor</td><td>Birds</td><td>Cars</td><td>Aircrafts</td><td>Flowers</td></tr><tr><td>0.9</td><td>0.01</td><td>0.0001</td><td>17.20</td><td>14.85</td><td>23.76</td><td>18.10</td><td>9.10</td><td>17.55</td><td>3.12</td></tr><tr><td>0.9</td><td>0.01</td><td>0</td><td>17.41</td><td>14.51</td><td>24.59</td><td>18.42</td><td>9.60</td><td>17.40</td><td>3.33</td></tr><tr><td>0.9</td><td>0.005</td><td>0.0001</td><td>14.14</td><td>13.42</td><td>24.59</td><td>17.24</td><td>9.08</td><td>18.21</td><td>3.50</td></tr><tr><td>0.9</td><td>0.005</td><td>0</td><td>14.80</td><td>13.67</td><td>22.79</td><td>17.54</td><td>9.31</td><td>17.82</td><td>3.53</td></tr><tr><td>0</td><td>0.01</td><td>0.0001</td><td>11.00</td><td>12.11</td><td>21.14</td><td>17.41</td><td>11.07</td><td>20.58</td><td>5.48</td></tr><tr><td>0</td><td>0.01</td><td>0</td><td>10.87</td><td>12.16</td><td>21.29</td><td>17.21</td><td>10.65</td><td>20.46</td><td>5.25</td></tr><tr><td>0</td><td>0.005</td><td>0.0001</td><td>10.21</td><td>11.86</td><td>21.96</td><td>18.24</td><td>13.22</td><td>24.39</td><td>7.03</td></tr><tr><td>0</td><td>0.005</td><td>0</td><td>10.12</td><td>11.61</td><td>20.76</td><td>18.40</td><td>13.11</td><td>23.91</td><td>6.78</td></tr></table>",
369
+ "bbox": [
370
+ 212,
371
+ 181,
372
+ 785,
373
+ 332
374
+ ],
375
+ "page_idx": 4
376
+ },
377
+ {
378
+ "type": "table",
379
+ "img_path": "images/4822e17d69f41546c9fa8f9101aaf3797dbc39dd969852da56be4edeb5b353bd.jpg",
380
+ "table_caption": [
381
+ "Table 3: Verification of the effect of momentum on other source domains rather than ImageNet. The hyperparameters are $n = 2 5 6$ , $\\eta = 0 . 0 1$ , and $\\lambda = 0 . 0 0 0 1$ . Momentum 0 works better for transferring from iNat-2017 to Birds and transferring from Places-365 to Indoor comparing to momentum 0.9 counterparts. "
382
+ ],
383
+ "table_footnote": [],
384
+ "table_body": "<table><tr><td>Source domain</td><td>m</td><td>Indoor</td><td>Birds</td><td>Dogs</td><td>Caltech</td><td>Cars</td><td>Aircrafts</td></tr><tr><td rowspan=\"2\">iNat-2017</td><td>0.9</td><td>30.73</td><td>14.69</td><td>24.74</td><td>20.12</td><td>11.16</td><td>19.86</td></tr><tr><td>0</td><td>34.11</td><td>12.29</td><td>23.87</td><td>21.47</td><td>16.89</td><td>27.21</td></tr><tr><td rowspan=\"2\">Places-365</td><td>0.9</td><td>22.19</td><td>27.72</td><td>30.84</td><td>22.53</td><td>11.06</td><td>21.27</td></tr><tr><td>0</td><td>20.16</td><td>32.17</td><td>32.47</td><td>22.60</td><td>14.67</td><td>25.29</td></tr></table>",
385
+ "bbox": [
386
+ 248,
387
+ 402,
388
+ 750,
389
+ 489
390
+ ],
391
+ "page_idx": 4
392
+ },
393
+ {
394
+ "type": "text",
395
+ "text": "Interestingly, datasets such as Dogs, Caltech, Indoor and Birds are known to have high overlap with ImageNet dataset2, while Cars and Aircrafts are identified to be difficult to benefit from fine-tuning from pre-trained ImageNet models (Kornblith et al., 2019). According to Cui et al. (2018), in which the Earth Mover’s Distance (EMD) is used to calculate the similarity between ImageNet and other domains, the similarity to Dogs and Birds are 0.619 and 0.563, while the similarity to Cars, Aircrafts and Flowers are 0.560, 0.556 and $0 . 5 2 5$ . The relative order of similarities to ImageNet is ",
396
+ "bbox": [
397
+ 173,
398
+ 515,
399
+ 825,
400
+ 599
401
+ ],
402
+ "page_idx": 4
403
+ },
404
+ {
405
+ "type": "text",
406
+ "text": "Dogs, Birds, Cars, Aircrafts and Flowers ",
407
+ "bbox": [
408
+ 364,
409
+ 612,
410
+ 633,
411
+ 626
412
+ ],
413
+ "page_idx": 4
414
+ },
415
+ {
416
+ "type": "text",
417
+ "text": "which aligns well with the transition of optimal momentum value from 0.0 to 0.9. Following the similarity calculation, we can also verified Caltech and Indoor are more close to ImageNet than Cars/Aircrafts/Flowers (Table 3.3). ",
418
+ "bbox": [
419
+ 176,
420
+ 638,
421
+ 821,
422
+ 681
423
+ ],
424
+ "page_idx": 4
425
+ },
426
+ {
427
+ "type": "text",
428
+ "text": "To verify the connection between momentum and domain similarity, we further fine-tune from different source domains such as Places-365 and iNaturalist, which are known to be better source domains than ImageNet for fine-tuning on Indoor and Birds dataset (Cui et al., 2018). We may expect that fine-tuning from iNaturalist works better for Birds with $m = 0$ and similarly, Places for Indoor. Indeed, as shown in Table 3, disabling momentum improves the performance when the source and target domain are similar, such as Places for Indoor and iNaturalist for Birds. ",
429
+ "bbox": [
430
+ 174,
431
+ 688,
432
+ 825,
433
+ 771
434
+ ],
435
+ "page_idx": 4
436
+ },
437
+ {
438
+ "type": "text",
439
+ "text": "Small momentum works better for fine-tuning on domains that are close to the source domain One explanation for the above observations is that because the Dogs dataset is very close to ImageNet, the pre-trained ImageNet model is expected to be close to the fine-tuned solution on the Dogs dataset. In this case, momentum may not help much as the gradient direction around the minimum could be much random and accumulating the momentum direction could be meaningless. Whereas, for faraway target domains (e.g., Cars and Aircrafts) where the pre-trained ImageNet model could be much different with the fine-tuned solution, the fine-tuning process is more similar with training from scratch, where large momentum stabilizes the decent directions towards the minimum. An illustration of the difference can be found in Figure 2. ",
440
+ "bbox": [
441
+ 174,
442
+ 789,
443
+ 825,
444
+ 858
445
+ ],
446
+ "page_idx": 4
447
+ },
448
+ {
449
+ "type": "image",
450
+ "img_path": "images/8710eb91220c9eed34f7e6c7a190bb7a5badb9469fe7ade7fb1849f922d09bec.jpg",
451
+ "image_caption": [
452
+ "Figure 2: An illustration of the effect of momentum on different fine-tuning scenarios from the loss-landscape perspective. The red point is the pre-trained model and the blue point is the fine-tuned solution. The dashed lines are loss contours. Assuming the step size is fixed, large momentum accelerates the convergence when the initialization is far from the minimum ((a) and (b)). On the contrary, large momentum may impede the convergence as shown in (c) and (d) when the initialization is close to the minimum. "
453
+ ],
454
+ "image_footnote": [],
455
+ "bbox": [
456
+ 207,
457
+ 94,
458
+ 787,
459
+ 210
460
+ ],
461
+ "page_idx": 5
462
+ },
463
+ {
464
+ "type": "text",
465
+ "text": "",
466
+ "bbox": [
467
+ 174,
468
+ 309,
469
+ 825,
470
+ 364
471
+ ],
472
+ "page_idx": 5
473
+ },
474
+ {
475
+ "type": "text",
476
+ "text": "Connections to early observations on decreasing momentum Early work (Sutskever et al., 2013) actually pointed out that reducing momentum during the final stage of training allows finer convergence while aggressive momentum would prevent this. They recommended reducing momentum from 0.99 to 0.9 in the last 1000 parameter updates but not disabling it completely. Recent work (Liu et al., 2018; Smith, 2018) showed that a large momentum helps escape from saddle points but can hurt the final convergence within the neighborhood of the optima, implying that momentum should be reduced at the end of training. Liu et al. (2018) find that a larger momentum introduces higher variance of noise and encourages more exploration at the beginning of optimization, and encourages more aggressive exploitation at the end of training. They suggest that at the final stage of the step size annealing, momentum SGD should use a much smaller step size than that of vanilla SGD. When applied to fine-tuning, we can interpret that if the pre-trained model lies in the neighborhood of the optimal solution on the target dataset, the momentum should be small. Our work identifies the empirical evidence of disabling momentum helps final convergence, and fine-tuning on close domains is a good exemplar. ",
477
+ "bbox": [
478
+ 174,
479
+ 380,
480
+ 825,
481
+ 574
482
+ ],
483
+ "page_idx": 5
484
+ },
485
+ {
486
+ "type": "text",
487
+ "text": "3.3 COUPLED HYPERPARAMETERS AND THE VIEW OF EFFECTIVE LEARNING RATE ",
488
+ "text_level": 1,
489
+ "bbox": [
490
+ 173,
491
+ 590,
492
+ 763,
493
+ 604
494
+ ],
495
+ "page_idx": 5
496
+ },
497
+ {
498
+ "type": "text",
499
+ "text": "Now that we had discovered the effect of momentum by fixing other hyperparameters and only allowed momentum to change. But note that the two difficult scenarios shown in Figure 2 (b) and (c) might also be mitigated by increasing or decreasing learning rate. That is, hyperparameters are coupled and varying one hyperparameter can change the optimal values of the other hyperparameters that lead to the best performance. In addition, optimal values of certain hyperparameters depend on the values of other hyperparameters in systematic ways. For example, learning rate is entangled with batch size, momentum and weight decay. There is a notion of effective learning rate (ELR) (Hertz et al., 1991; Smith et al., 2018; Smith & Le, 2018) for SGD with momentum: $\\eta ^ { \\prime } = \\eta / ( 1 - m )$ , which was shown to be more closely related with training dynamics and final performance rather than $\\eta$ . The effective learning rate with $m = 0 . 9$ is $1 0 \\times$ higher than the one with $m = 0 . 0$ if other hyperparameters are fixed, which is probably why we see an increase in optimal learning rate when momentum is disabled in Figure 1(b) and Appendix A. ",
500
+ "bbox": [
501
+ 176,
502
+ 616,
503
+ 581,
504
+ 880
505
+ ],
506
+ "page_idx": 5
507
+ },
508
+ {
509
+ "type": "image",
510
+ "img_path": "images/4ce32bf9da77a8f4482b67fb5d03fa2a987b1a28a539865b05840b1064f3263c.jpg",
511
+ "image_caption": [
512
+ "Figure 3: The effect of momentum w/ and w/o fixing ELR $\\eta ^ { \\prime }$ . When $\\eta ^ { \\prime }$ is the same, momentum 0 and 0.9 are almost equivalent. If $\\eta ^ { \\prime }$ is allowed to change, there is almost no difference between optimal performance obtained by different $m$ . "
513
+ ],
514
+ "image_footnote": [],
515
+ "bbox": [
516
+ 593,
517
+ 636,
518
+ 813,
519
+ 768
520
+ ],
521
+ "page_idx": 5
522
+ },
523
+ {
524
+ "type": "text",
525
+ "text": "It is the effective learning rate that matters for fine-tuning performance Because hyperparameters are coupled, looking at the performance with only one hyperparameter varied may give a misleading understanding of the effect of hyperparameters. Therefore, to examine the effect of momentum, we should report the best result obtainable with and without momentum, as long as other hyperparameters explored are sufficiently explored. We re-examine previous experiments that demonstrated the importance of momentum tuning when the ELR $\\eta ^ { \\prime } \\bar { = } \\eta / ( 1 - \\bar { m } )$ is held fixed instead of simply fixing learning rate $\\eta$ . Figure 3 shows that when $\\eta ^ { \\prime }$ is constant, the best performance obtained by $m = 0 . 9$ and $m = 0$ are almost equivalent when other hyperparameters are allowed to change. However, different ELR does result in different performance, which indicates its importance for the best performance. It explains why the common practice of changing only learning rate generally works, though changing momentum may results in the same result, they both change the ELR. In fact, as long as the initial learning rate is small enough, we can always search for the optimal momentum as it is an amplifier, making the ELR larger by a factor of $1 / ( 1 - m )$ . Therefore, momentum does determine the search ranges of learning rate. ",
526
+ "bbox": [
527
+ 174,
528
+ 896,
529
+ 821,
530
+ 924
531
+ ],
532
+ "page_idx": 5
533
+ },
534
+ {
535
+ "type": "text",
536
+ "text": "",
537
+ "bbox": [
538
+ 174,
539
+ 103,
540
+ 825,
541
+ 270
542
+ ],
543
+ "page_idx": 6
544
+ },
545
+ {
546
+ "type": "text",
547
+ "text": "Optimal ELR depends on the similarity between source domain and target domain Now that we have shown ELR is critical for fine-tuning performance, we are interested in the factors that determine the optimal ELR for a given task. Previous work (Smith & Le, 2018) found that there is an optimum ELR which maximizes the test accuracy. However, the observations are only based on scratch training on small datasets (e.g., CIFAR-10); the relationship between ELR and domain similarity, especially for fine-tuning, is still unexplored. To examine this, we search the best ELR on each fine-tuning task and reports in Fig. 4 the best validation error obtained by each ELR while allowing other hyperparameters to change. It shows the optimal ELR depends on both source domain and target domain. As shown in Fig. 4 (a-c), the optimal ELR for Dogs/Caltech/Indoor are much smaller than these for Aircrafts/Flowers/Cars when fine-tuned from ImageNet pre-trained model. Similar observations can be made on DenseNets and MobileNet. Though the optimal ELR value is different, the relative order of domain similarity is consistent and architecture agnostic. We can also see a smaller ELR works better when source domain and target domain are similar, such as Dogs for ImageNet and Birds for iNat2017 (Fig. 4 (a, d-e)). Interestingly, the optimal ELR for training from scratch is much larger and very similar across different target datasets, which indicates the distance from a random initialization is uniformly similar to different target dataset. ",
548
+ "bbox": [
549
+ 173,
550
+ 297,
551
+ 825,
552
+ 520
553
+ ],
554
+ "page_idx": 6
555
+ },
556
+ {
557
+ "type": "image",
558
+ "img_path": "images/e5a0e5125739ed10559077ba3ac4435aaa5f0a2a7c00133874ea8625039fe3c0.jpg",
559
+ "image_caption": [
560
+ "Figure 4: The best validation errors obtained by different ELRs for different source-target domains. Note that the optimal ELR for each target dataset falls in the interior of search space. Each point in (a-e) is the lowest validation error obtained with different weight decay values while ELR is fixed. The first row suggests that the connection between optimal ELR and domain similarity is architecture agnostic. The second row verifies that optimal ELR depends on the similarity between source domain and target domain. "
561
+ ],
562
+ "image_footnote": [],
563
+ "bbox": [
564
+ 156,
565
+ 536,
566
+ 820,
567
+ 833
568
+ ],
569
+ "page_idx": 6
570
+ },
571
+ {
572
+ "type": "table",
573
+ "img_path": "images/0678e8db737a401ccbf321045f5db18d777f6426dec5a8612d31ba464920e4fa.jpg",
574
+ "table_caption": [
575
+ "Table 4: The connection between domain similarity and optimal ELR. The values in the second column is provided by Cui et al. (2018), in which JFT pretrained ResNet-101 was used as the feature extractor. Note that neither the pre-trained model or the dataset is released and we cannot calculate the metric for other datasets. In other columns, we calculate domain similarity using ImageNet pre-trained model as the feature extractor. The 1st, 2nd, 3rd and 4th highest scores are color coded. The optimal ELRs are also listed, which corresponds to the values in Fig 4. "
576
+ ],
577
+ "table_footnote": [],
578
+ "table_body": "<table><tr><td rowspan=\"3\"></td><td>JFT</td><td colspan=\"4\">ImageNet</td><td colspan=\"2\">iNat2017</td><td colspan=\"2\">Places365</td></tr><tr><td>ResNet-101</td><td>ResNet-101</td><td colspan=\"2\">DenseNet-121</td><td colspan=\"2\">MobileNet</td><td colspan=\"2\">ResNet-101</td><td colspan=\"2\">ResNet-101</td></tr><tr><td>sim</td><td>sim 川</td><td>sim</td><td>八</td><td>sim</td><td>八</td><td>sim</td><td>川</td><td>sim</td><td>川</td></tr><tr><td>Dogs</td><td>0.619</td><td>0.862 0.001</td><td>0.851</td><td>0.01</td><td>0.852</td><td>0.01</td><td>0.854</td><td>0.05</td><td>0.856</td><td>0.5</td></tr><tr><td>Caltech</td><td>-</td><td>0.892 0.005</td><td>0.881</td><td>0.01</td><td>0.878</td><td>0.01</td><td>0.871</td><td>0.1</td><td>0.888</td><td>0.05</td></tr><tr><td>Indoor</td><td>-</td><td>0.856 0.01</td><td>0.850</td><td>0.05</td><td>0.839</td><td>0.01</td><td>0.843</td><td>0.1</td><td>0.901</td><td>0.05</td></tr><tr><td>Birds</td><td>0.563</td><td>0.860 0.05</td><td>0.842</td><td>0.05</td><td>0.849</td><td>0.1</td><td>0.901</td><td>0.005</td><td>0.861</td><td>0.5</td></tr><tr><td>Cars</td><td>0.560</td><td>0.845 0.5</td><td>0.831</td><td>0.5</td><td>0.830</td><td>1.0</td><td>0.847</td><td>1.0</td><td>0.864</td><td>1.0</td></tr><tr><td>Aircrafts</td><td>0.556</td><td>0.840 1.0</td><td>0.817</td><td>0.1</td><td>0.831</td><td>1.0</td><td>0.846</td><td>0.5</td><td>0.853</td><td>0.5</td></tr><tr><td>Flowers</td><td>0.525</td><td>0.844 0.1</td><td>0.821</td><td>0.5</td><td></td><td>0.825 0.1</td><td>0.879</td><td>0.1</td><td>0.851</td><td>1.0</td></tr></table>",
579
+ "bbox": [
580
+ 173,
581
+ 190,
582
+ 848,
583
+ 338
584
+ ],
585
+ "page_idx": 7
586
+ },
587
+ {
588
+ "type": "text",
589
+ "text": "Optimal ELR selection based on domain similarity Now we have made qualitative observations about the relationship between domain similarity and optimal ELR. A quantitative characterization of the relationship could reduce the hyperparameter search ranges for HPO or even eliminate HPO by accurately predicting hyperparameters. We followed the domain similarity calculation in (Cui et al., 2018) and recalculate similarity scores for all source-target domain pairs. Note the original domain similarity calculation in (Cui et al., 2018) use pre-trained JFT (Sun et al., 2017) models as feature extractor, which are not public available. We alternatively use ImageNet pre-trained model or the source model as feature extractor. As shown in Table 4, there is a good correlation between domain similarity score and the scale of optimal ELR. Generally, the more similar the two domains, the smaller the optimal ELR. Though it is not strictly corresponding to the domain similarity score, the score provides reasonable prediction about the scale of optimal ELR, such as [0.001, 0.01], [0.01, 0.1], [0.1, 1.0] and therefore can reduce the search space for optimal ELR. Based on this correlation, a simple strategy can be developed for optimal ELR selection given a frequently used source model: one can calculate domain similarities and perform exhaustive hyperparameter searches for few reference datasets, including similar and dissimilar datasets. Then given a new dataset to fine-tune, one can calculate the domain similarity and compare with the scores of reference datasets, and choose the range of ELRs with the closest domain similarity. ",
590
+ "bbox": [
591
+ 173,
592
+ 363,
593
+ 826,
594
+ 599
595
+ ],
596
+ "page_idx": 7
597
+ },
598
+ {
599
+ "type": "text",
600
+ "text": "Weight Decay and Learning Rate The relationship between weight decay and effective learning rate is recently well-studied (van Laarhoven, 2017; Zhang et al., 2018; Loshchilov & Hutter, 2018). It was shown that the effect of weight decay on models with BN layers is equivalent to increasing the ELR by shrinking the weights scales, i.e., $\\eta ^ { \\prime } \\sim \\eta / \\| \\theta \\| _ { 2 } ^ { 2 }$ . And if the optimal effective learning rate exists, the optimal weight decay value $\\lambda$ is inversely related with the optimal learning rate $\\eta$ . The ‘effective’ weight decay is $\\lambda ^ { \\prime } = \\lambda / \\eta$ . We show in Figure 5 that the optimal effective weight decay is also correlated with domain similarity. ",
601
+ "bbox": [
602
+ 173,
603
+ 618,
604
+ 825,
605
+ 715
606
+ ],
607
+ "page_idx": 7
608
+ },
609
+ {
610
+ "type": "image",
611
+ "img_path": "images/c5d9915d147e187cb3653b42aa59b97f78d56de7e90f01a50644f871ac7a2361.jpg",
612
+ "image_caption": [
613
+ "Figure 5: The relationship between optimal effective weight decay and source datasets. The optimal effective weight decay is larger when the source domain is similar with the target domain. "
614
+ ],
615
+ "image_footnote": [],
616
+ "bbox": [
617
+ 156,
618
+ 733,
619
+ 823,
620
+ 877
621
+ ],
622
+ "page_idx": 7
623
+ },
624
+ {
625
+ "type": "text",
626
+ "text": "3.4 THE CHOICE OF REGULARIZATION ",
627
+ "text_level": 1,
628
+ "bbox": [
629
+ 176,
630
+ 103,
631
+ 454,
632
+ 117
633
+ ],
634
+ "page_idx": 8
635
+ },
636
+ {
637
+ "type": "text",
638
+ "text": "$L _ { 2 }$ regularization or weight decay is widely used for constraining the model capacity (Hanson & Pratt, 1989; Krogh & Hertz, 1992). Recently Li et al. (2018; 2019) pointed out that standard $L _ { 2 }$ regularization, which drives the parameters towards the origin, is not adequate in transfer learning. To retain the knowledge learned by the pre-trained model, reference-based regularization was used to regularize the distance between fine-tuned weights and the pre-trained weights, so that the finetuned model is not too different from the initial model. Li et al. (2018) propose $L _ { 2 }$ -SP norm, i.e., $\\begin{array} { r } { \\frac { \\lambda _ { 1 } } { 2 } \\| \\theta ^ { \\prime } - \\theta _ { 0 } \\| _ { 2 } ^ { 2 } + \\frac { \\lambda _ { 2 } } { 2 } \\| \\theta ^ { \\prime \\prime } \\| _ { 2 } ^ { 2 } } \\end{array}$ , where $\\theta ^ { \\prime }$ refers to the part of network that shared with the source network, and $\\theta ^ { \\prime \\prime }$ refers to the novel part, e.g., the last layer with different number of neurons. While the motivation is intuitive, there are several issues for adopting reference based regularization for fine-tuning: ",
639
+ "bbox": [
640
+ 173,
641
+ 131,
642
+ 825,
643
+ 271
644
+ ],
645
+ "page_idx": 8
646
+ },
647
+ {
648
+ "type": "text",
649
+ "text": "• Many applications actually adopt fine-tuning on target domains that are quite different from source domain, such as fine-tuning ImageNet models for medical imaging (Mormont et al., 2018; Raghu et al., 2019). The fine-tuned model does not necessarily have to be close with the initial model. \n• The scale invariance introduced by Batch Normalization (BN) (Ioffe & Szegedy, 2015) layers enable models with different parameter scales to function the same, i.e., $\\dot { f } ( \\theta ) = f ( \\overset { \\cdot } { \\alpha } \\theta )$ . Therefore, when $L _ { 2 }$ regularization drives $\\| \\theta \\| _ { 2 } ^ { 2 }$ towards zeros, it could still have the same functionality as the initial model. On the contrary, a model could still be different even when the $L _ { 2 }$ -SP norm is small. \n• $L _ { 2 }$ -SP regularization would constrain $\\theta ^ { \\prime \\prime }$ to be close to $\\theta _ { 0 }$ , so that $\\| \\theta \\| _ { 2 } ^ { 2 }$ is relatively stable in comparison with $L _ { 2 }$ regularization. Given that ELR is approximately proportional to $\\eta / \\lVert \\boldsymbol { \\theta } \\rVert _ { 2 } ^ { 2 }$ and a smaller ELR is beneficial for fine-tuning from similar domains, it may explain why $L _ { 2 }$ -SP provides better performance. If this is true, then by decreasing the initial ELR, $L _ { 2 }$ -norm may function the same. ",
650
+ "bbox": [
651
+ 215,
652
+ 284,
653
+ 825,
654
+ 492
655
+ ],
656
+ "page_idx": 8
657
+ },
658
+ {
659
+ "type": "text",
660
+ "text": "To examine these conjectures, we revisited the work of (Li et al., 2018) with additional experiments. To show the effectiveness of $L _ { 2 }$ -SP norm, the authors conducted experiments on datasets such as Dogs, Caltech and Indoor, which are all close to the source domain (ImageNet or Places-365). We extend their experiments by fine-tuning on both “similar” and “dissimilar” datasets, including Birds, Cars, Aircrafts and Flowers, with both $L _ { 2 }$ and $L _ { 2 }$ -SP regularization (details in Appendix D). For fair comparison, we perform the same hyperparameter search for both methods. As expected, Table 5 shows that $L _ { 2 }$ regularization is very competitive with $L _ { 2 }$ -SP on Birds, Cars, Aircrafts and Flowers, which indicates that reference based regularization may not generalize well for fine-tuning on dissimilar domains. ",
661
+ "bbox": [
662
+ 173,
663
+ 505,
664
+ 826,
665
+ 631
666
+ ],
667
+ "page_idx": 8
668
+ },
669
+ {
670
+ "type": "table",
671
+ "img_path": "images/f326a1aa783f99e894e7d1b9fe9455bece81305f1a5f1d5d5c07c5d1d9aa24f0.jpg",
672
+ "table_caption": [
673
+ "Table 5: The average class error of (Li et al., 2018) and the extension of their experiments of on “dissimilar” datasets. The italic datasets and numbers are our experimental results. Note that the original Indoor result is fine-tuned from Places-365, while we fine-tune just from ImageNet pre-trained models. "
674
+ ],
675
+ "table_footnote": [],
676
+ "table_body": "<table><tr><td>Method</td><td>Dogs</td><td>Caltech</td><td>Indoor</td><td>Birds</td><td>Cars</td><td>Flowers</td><td>Aircrafts</td></tr><tr><td>L2 (Li et al., 2018)</td><td>18.6</td><td>14.7</td><td>20.4</td><td>1</td><td></td><td>-</td><td></td></tr><tr><td>L2-SP (Li et al., 2018)</td><td>14.9</td><td>13.6</td><td>15.8</td><td>1</td><td>1</td><td>1</td><td>1</td></tr><tr><td>L2 with HPO</td><td>16.79</td><td>14.98</td><td>23.00</td><td>22.51</td><td>10.10</td><td>5.70</td><td>13.03</td></tr><tr><td>L2-SP with HPO</td><td>13.86</td><td>14.45</td><td>21.77</td><td>22.32</td><td>9.59</td><td>5.28</td><td>13.31</td></tr></table>",
677
+ "bbox": [
678
+ 202,
679
+ 684,
680
+ 825,
681
+ 780
682
+ ],
683
+ "page_idx": 8
684
+ },
685
+ {
686
+ "type": "text",
687
+ "text": "We also check the change of regularization terms during training for both methods as well as their best hyperparameters. As shown in Figure 6, the $L _ { 2 }$ regularization usually decrease the weights norm more aggressively, depending on the value of $\\lambda$ , while $L _ { 2 }$ -SP regularization keeps the norm less changed. We can see that the optimal learning rate of $L _ { 2 }$ regularization is mostly smaller than $L _ { 2 }$ -SP, which may compensate for the decreased weight norm or increased ELR. Interestingly, for Dogs dataset, both regularization terms grow much larger after a few iterations and then become stable, which means constraining the weights to be close to initialization is not necessarily the reason for $L _ { 2 }$ -SP to work even for close domains. It also seems contradicting to previous finding (Zhang et al., 2018) that weight decay functions as increasing ELR by decreasing weight norms. However, it might be reasonable as large norm actually decreases the ELR, which could be helpful due to the close domain similarity between Dogs and ImageNet. ",
688
+ "bbox": [
689
+ 173,
690
+ 797,
691
+ 825,
692
+ 924
693
+ ],
694
+ "page_idx": 8
695
+ },
696
+ {
697
+ "type": "text",
698
+ "text": "",
699
+ "bbox": [
700
+ 173,
701
+ 103,
702
+ 825,
703
+ 132
704
+ ],
705
+ "page_idx": 9
706
+ },
707
+ {
708
+ "type": "image",
709
+ "img_path": "images/bd0d6388dea8abde7f04a6ba9f9521d805a08f943845b42e48c9ab2d86457140.jpg",
710
+ "image_caption": [
711
+ "Figure 6: The normalized $L _ { 2 }$ norm and $L _ { 2 }$ -SP norm during training. The $_ y$ -axis is the relative change of the regularization term in comparison to the initial value, i.e., $\\ \\overline { { | | { \\theta } _ { t } | | _ { 2 } ^ { 2 } } } / \\| \\overline { { { \\theta } } } _ { 0 } \\| _ { 2 } ^ { 2 }$ for $L _ { 2 }$ norm and $( \\lambda _ { 1 } \\| \\theta _ { t } ^ { \\prime } - \\theta _ { 0 } \\| _ { 2 } ^ { 2 } +$ $\\lambda _ { 2 } \\| \\theta _ { t } ^ { \\prime \\prime } \\| _ { 2 } ^ { 2 } ) / ( \\lambda _ { 2 } \\| \\theta _ { 0 } ^ { \\prime \\prime } \\| _ { 2 } ^ { 2 } )$ for $\\small { \\cal L } _ { 2 } { \\bf - S P }$ norm. Optimal hyperparameters are also given in the legend. Note that experiment uses batch size 64 instead of 256, which results in smaller optimal learning rate comparing to previous result. "
712
+ ],
713
+ "image_footnote": [],
714
+ "bbox": [
715
+ 215,
716
+ 152,
717
+ 743,
718
+ 318
719
+ ],
720
+ "page_idx": 9
721
+ },
722
+ {
723
+ "type": "text",
724
+ "text": "4 DISCUSSION ",
725
+ "text_level": 1,
726
+ "bbox": [
727
+ 176,
728
+ 425,
729
+ 310,
730
+ 440
731
+ ],
732
+ "page_idx": 9
733
+ },
734
+ {
735
+ "type": "text",
736
+ "text": "The two extreme ways for selecting hyperparameters—performing exhaustive hyperparameter search or taking ad-hoc hyperparameters from scratch training—could be either too computationally expensive or yield inferior performance. Different from training from scratch, where the default hyperparameter setting may work well for random initialization, the choice of hyperparameters for fine-tuning is not only dataset dependent but is also influenced by the similarity between the target and source domains. The rarely tuned momentum value could also improve or impede the performance when the target domain and source domain are close given insufficiently searched learning rate. These observations connect with previous theoretical works on decreasing momentum at the end of training and effective learning rate. We further identify that the optimal effective learning rate correlates with the similarity between the source and target domains. With this understanding, one can significantly reduce the hyperparameter search space. We hope these findings could be one step towards better and efficient hyperparameter selection for fine-tuning. ",
737
+ "bbox": [
738
+ 174,
739
+ 457,
740
+ 825,
741
+ 622
742
+ ],
743
+ "page_idx": 9
744
+ },
745
+ {
746
+ "type": "text",
747
+ "text": "ACKNOWLEDGMENTS ",
748
+ "text_level": 1,
749
+ "bbox": [
750
+ 176,
751
+ 640,
752
+ 326,
753
+ 652
754
+ ],
755
+ "page_idx": 9
756
+ },
757
+ {
758
+ "type": "text",
759
+ "text": "The authors would like to thank all anonymous reviewers for their valuable feedback. ",
760
+ "bbox": [
761
+ 176,
762
+ 662,
763
+ 730,
764
+ 676
765
+ ],
766
+ "page_idx": 9
767
+ },
768
+ {
769
+ "type": "text",
770
+ "text": "REFERENCES ",
771
+ "text_level": 1,
772
+ "bbox": [
773
+ 176,
774
+ 698,
775
+ 285,
776
+ 713
777
+ ],
778
+ "page_idx": 9
779
+ },
780
+ {
781
+ "type": "text",
782
+ "text": "Alessandro Achille, Michael Lam, Rahul Tewari, Avinash Ravichandran, Subhransu Maji, Charless Fowlkes, Stefano Soatto, and Pietro Perona. Task2vec: Task embedding for meta-learning. arXiv preprint arXiv:1902.03545, 2019. \nLiang-Chieh Chen, George Papandreou, Iasonas Kokkinos, Kevin Murphy, and Alan L Yuille. Deeplab: Semantic image segmentation with deep convolutional nets, atrous convolution, and fully connected crfs. IEEE T-PAMI, 40(4):834–848, 2017. \nEkin D Cubuk, Barret Zoph, Dandelion Mane, Vijay Vasudevan, and Quoc V Le. Autoaugment: Learning augmentation policies from data. arXiv preprint arXiv:1805.09501, 2018. \nYin Cui, Yang Song, Chen Sun, Andrew Howard, and Serge Belongie. Large scale fine-grained categorization and domain-specific transfer learning. In CVPR, 2018. \nJia Deng, Alexander C Berg, Kai Li, and Li Fei-Fei. What does classifying more than 10,000 image categories tell us? In ECCV, 2010. ",
783
+ "bbox": [
784
+ 173,
785
+ 719,
786
+ 826,
787
+ 924
788
+ ],
789
+ "page_idx": 9
790
+ },
791
+ {
792
+ "type": "text",
793
+ "text": "Jeff Donahue, Yangqing Jia, Oriol Vinyals, Judy Hoffman, Ning Zhang, Eric Tzeng, and Trevor Darrell. Decaf: A deep convolutional activation feature for generic visual recognition. In ICML, 2014. ",
794
+ "bbox": [
795
+ 176,
796
+ 103,
797
+ 825,
798
+ 146
799
+ ],
800
+ "page_idx": 10
801
+ },
802
+ {
803
+ "type": "text",
804
+ "text": "Weifeng Ge and Yizhou Yu. Borrowing treasures from the wealthy: Deep transfer learning through selective joint fine-tuning. In CPVR, 2017. ",
805
+ "bbox": [
806
+ 174,
807
+ 155,
808
+ 823,
809
+ 184
810
+ ],
811
+ "page_idx": 10
812
+ },
813
+ {
814
+ "type": "text",
815
+ "text": "Ross Girshick, Jeff Donahue, Trevor Darrell, and Jitendra Malik. Rich feature hierarchies for accurate object detection and semantic segmentation. In CVPR, 2014. ",
816
+ "bbox": [
817
+ 174,
818
+ 194,
819
+ 823,
820
+ 223
821
+ ],
822
+ "page_idx": 10
823
+ },
824
+ {
825
+ "type": "text",
826
+ "text": "Gabriel Goh. Why momentum really works. Distill, 2(4):e6, 2017. ",
827
+ "bbox": [
828
+ 173,
829
+ 232,
830
+ 612,
831
+ 247
832
+ ],
833
+ "page_idx": 10
834
+ },
835
+ {
836
+ "type": "text",
837
+ "text": "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. ",
838
+ "bbox": [
839
+ 173,
840
+ 256,
841
+ 826,
842
+ 300
843
+ ],
844
+ "page_idx": 10
845
+ },
846
+ {
847
+ "type": "text",
848
+ "text": "Gregory Griffin, Alex Holub, and Pietro Perona. Caltech-256 object category dataset. 2007. ",
849
+ "bbox": [
850
+ 173,
851
+ 308,
852
+ 776,
853
+ 324
854
+ ],
855
+ "page_idx": 10
856
+ },
857
+ {
858
+ "type": "text",
859
+ "text": "Stephen Jose Hanson and Lorien Y. Pratt. Comparing biases for minimal network construction with back-propagation. In NIPS, 1989. ",
860
+ "bbox": [
861
+ 174,
862
+ 333,
863
+ 820,
864
+ 362
865
+ ],
866
+ "page_idx": 10
867
+ },
868
+ {
869
+ "type": "text",
870
+ "text": "Kaiming He, Xiangyu Zhang, Shaoqing Ren, and Jian Sun. Identity mappings in deep residual networks. In ECCV, 2016a. ",
871
+ "bbox": [
872
+ 173,
873
+ 371,
874
+ 823,
875
+ 401
876
+ ],
877
+ "page_idx": 10
878
+ },
879
+ {
880
+ "type": "text",
881
+ "text": "Kaiming He, Xiangyu Zhang, Shaoqing Ren, and Jian Sun. Deep residual learning for image recognition. In CVPR, 2016b. ",
882
+ "bbox": [
883
+ 174,
884
+ 410,
885
+ 823,
886
+ 439
887
+ ],
888
+ "page_idx": 10
889
+ },
890
+ {
891
+ "type": "text",
892
+ "text": "Kaiming He, Georgia Gkioxari, Piotr Dollár, and Ross Girshick. Mask R-CNN. In ICCV, 2017. ",
893
+ "bbox": [
894
+ 173,
895
+ 448,
896
+ 802,
897
+ 464
898
+ ],
899
+ "page_idx": 10
900
+ },
901
+ {
902
+ "type": "text",
903
+ "text": "Kaiming He, Ross Girshick, and Piotr Dollár. Rethinking imagenet pre-training. In ICCV, 2019. ",
904
+ "bbox": [
905
+ 173,
906
+ 473,
907
+ 803,
908
+ 488
909
+ ],
910
+ "page_idx": 10
911
+ },
912
+ {
913
+ "type": "text",
914
+ "text": "John Hertz, A Krogh, and Richard G Palmer. Introduction to the theory of neural computation. 1991. ",
915
+ "bbox": [
916
+ 169,
917
+ 497,
918
+ 823,
919
+ 513
920
+ ],
921
+ "page_idx": 10
922
+ },
923
+ {
924
+ "type": "text",
925
+ "text": "Andrew G Howard, Menglong Zhu, Bo Chen, Dmitry Kalenichenko, Weijun Wang, Tobias Weyand, Marco Andreetto, and Hartwig Adam. Mobilenets: Efficient convolutional neural networks for mobile vision applications. arXiv preprint arXiv:1704.04861, 2017. ",
926
+ "bbox": [
927
+ 173,
928
+ 522,
929
+ 825,
930
+ 565
931
+ ],
932
+ "page_idx": 10
933
+ },
934
+ {
935
+ "type": "text",
936
+ "text": "Gao Huang, Zhuang Liu, Laurens Van Der Maaten, and Kilian Q Weinberger. Densely connected convolutional networks. In CVPR, 2017. ",
937
+ "bbox": [
938
+ 174,
939
+ 574,
940
+ 825,
941
+ 603
942
+ ],
943
+ "page_idx": 10
944
+ },
945
+ {
946
+ "type": "text",
947
+ "text": "Minyoung Huh, Pulkit Agrawal, and Alexei A Efros. What makes imagenet good for transfer learning? arXiv preprint arXiv:1608.08614, 2016. ",
948
+ "bbox": [
949
+ 174,
950
+ 612,
951
+ 825,
952
+ 642
953
+ ],
954
+ "page_idx": 10
955
+ },
956
+ {
957
+ "type": "text",
958
+ "text": "Sergey Ioffe and Christian Szegedy. Batch normalization: Accelerating deep network training by reducing internal covariate shift. In ICML, 2015. ",
959
+ "bbox": [
960
+ 171,
961
+ 651,
962
+ 825,
963
+ 680
964
+ ],
965
+ "page_idx": 10
966
+ },
967
+ {
968
+ "type": "text",
969
+ "text": "Aditya Khosla, Nityananda Jayadevaprakash, Bangpeng Yao, and Li Fei-Fei. Novel dataset for fine-grained image categorization. In First Workshop on Fine-Grained Visual Categorization, CVPR, 2011. ",
970
+ "bbox": [
971
+ 173,
972
+ 689,
973
+ 825,
974
+ 732
975
+ ],
976
+ "page_idx": 10
977
+ },
978
+ {
979
+ "type": "text",
980
+ "text": "Simon Kornblith, Jonathon Shlens, and Quoc V Le. Do better imagenet models transfer better? In CVPR, 2019. ",
981
+ "bbox": [
982
+ 171,
983
+ 741,
984
+ 825,
985
+ 770
986
+ ],
987
+ "page_idx": 10
988
+ },
989
+ {
990
+ "type": "text",
991
+ "text": "Jonathan Krause, Michael Stark, Jia Deng, and Li Fei-Fei. 3d object representations for fine-grained categorization. In 4th International IEEE Workshop on 3D Representation and Recognition (3dRR-13), Sydney, Australia, 2013. ",
992
+ "bbox": [
993
+ 173,
994
+ 780,
995
+ 825,
996
+ 823
997
+ ],
998
+ "page_idx": 10
999
+ },
1000
+ {
1001
+ "type": "text",
1002
+ "text": "Alex Krizhevsky, Ilya Sutskever, and Geoffrey E Hinton. Imagenet classification with deep convolutional neural networks. In NIPS, 2012. ",
1003
+ "bbox": [
1004
+ 174,
1005
+ 832,
1006
+ 823,
1007
+ 861
1008
+ ],
1009
+ "page_idx": 10
1010
+ },
1011
+ {
1012
+ "type": "text",
1013
+ "text": "Anders Krogh and John A Hertz. A simple weight decay can improve generalization. In NIPS, 1992. ",
1014
+ "bbox": [
1015
+ 173,
1016
+ 871,
1017
+ 823,
1018
+ 886
1019
+ ],
1020
+ "page_idx": 10
1021
+ },
1022
+ {
1023
+ "type": "text",
1024
+ "text": "Xingjian Li, Haoyi Xiong, Hanchao Wang, Yuxuan Rao, Liping Liu, and Jun Huan. Delta: Deep learning transfer using feature map with attention for convolutional networks. In ICLR, 2019. ",
1025
+ "bbox": [
1026
+ 173,
1027
+ 895,
1028
+ 823,
1029
+ 924
1030
+ ],
1031
+ "page_idx": 10
1032
+ },
1033
+ {
1034
+ "type": "text",
1035
+ "text": "Xuhong Li, Yves Grandvalet, and Franck Davoine. Explicit inductive bias for transfer learning with convolutional networks. In ICML, 2018. ",
1036
+ "bbox": [
1037
+ 171,
1038
+ 103,
1039
+ 823,
1040
+ 132
1041
+ ],
1042
+ "page_idx": 11
1043
+ },
1044
+ {
1045
+ "type": "text",
1046
+ "text": "Tianyi Liu, Zhehui Chen, Enlu Zhou, and Tuo Zhao. Toward deeper understanding of nonconvex stochastic optimization with momentum using diffusion approximations. arXiv preprint arXiv:1802.05155, 2018. ",
1047
+ "bbox": [
1048
+ 174,
1049
+ 141,
1050
+ 823,
1051
+ 184
1052
+ ],
1053
+ "page_idx": 11
1054
+ },
1055
+ {
1056
+ "type": "text",
1057
+ "text": "Ilya Loshchilov and Frank Hutter. Decoupled weight decay regularization. In ICLR, 2018. ",
1058
+ "bbox": [
1059
+ 171,
1060
+ 193,
1061
+ 766,
1062
+ 209
1063
+ ],
1064
+ "page_idx": 11
1065
+ },
1066
+ {
1067
+ "type": "text",
1068
+ "text": "Dhruv Mahajan, Ross Girshick, Vignesh Ramanathan, Kaiming He, Manohar Paluri, Yixuan Li, Ashwin Bharambe, and Laurens van der Maaten. Exploring the limits of weakly supervised pretraining. In ECCV, 2018. ",
1069
+ "bbox": [
1070
+ 176,
1071
+ 218,
1072
+ 825,
1073
+ 261
1074
+ ],
1075
+ "page_idx": 11
1076
+ },
1077
+ {
1078
+ "type": "text",
1079
+ "text": "S. Maji, J. Kannala, E. Rahtu, M. Blaschko, and A. Vedaldi. Fine-grained visual classification of aircraft. Technical report, 2013. ",
1080
+ "bbox": [
1081
+ 173,
1082
+ 270,
1083
+ 823,
1084
+ 299
1085
+ ],
1086
+ "page_idx": 11
1087
+ },
1088
+ {
1089
+ "type": "text",
1090
+ "text": "Romain Mormont, Pierre Geurts, and Raphaël Marée. Comparison of deep transfer learning strategies for digital pathology. In CVPR Workshops, 2018. ",
1091
+ "bbox": [
1092
+ 173,
1093
+ 308,
1094
+ 821,
1095
+ 338
1096
+ ],
1097
+ "page_idx": 11
1098
+ },
1099
+ {
1100
+ "type": "text",
1101
+ "text": "Yurixi E Nesterov. A method for solving the convex programming problem with convergence rate o $( 1 / \\mathrm { k } ^ { \\cdot } 2 )$ ). In Dokl. akad. nauk Sssr, volume 269, pp. 543–547, 1983. ",
1102
+ "bbox": [
1103
+ 173,
1104
+ 347,
1105
+ 823,
1106
+ 376
1107
+ ],
1108
+ "page_idx": 11
1109
+ },
1110
+ {
1111
+ "type": "text",
1112
+ "text": "Jiquan Ngiam, Daiyi Peng, Vijay Vasudevan, Simon Kornblith, Quoc V Le, and Ruoming Pang. Domain adaptive transfer learning with specialist models. arXiv preprint arXiv:1811.07056, 2018. ",
1113
+ "bbox": [
1114
+ 174,
1115
+ 383,
1116
+ 825,
1117
+ 414
1118
+ ],
1119
+ "page_idx": 11
1120
+ },
1121
+ {
1122
+ "type": "text",
1123
+ "text": "Maria-Elena Nilsback and Andrew Zisserman. Automated flower classification over a large number of classes. In Indian Conference on Computer Vision, Graphics & Image Processing. IEEE, 2008. ",
1124
+ "bbox": [
1125
+ 174,
1126
+ 422,
1127
+ 826,
1128
+ 452
1129
+ ],
1130
+ "page_idx": 11
1131
+ },
1132
+ {
1133
+ "type": "text",
1134
+ "text": "Boris T Polyak. Some methods of speeding up the convergence of iteration methods. USSR Computational Mathematics and Mathematical Physics, 4(5):1–17, 1964. ",
1135
+ "bbox": [
1136
+ 174,
1137
+ 460,
1138
+ 825,
1139
+ 489
1140
+ ],
1141
+ "page_idx": 11
1142
+ },
1143
+ {
1144
+ "type": "text",
1145
+ "text": "Maithra Raghu, Chiyuan Zhang, Jon Kleinberg, and Samy Bengio. Transfusion: Understanding transfer learning with applications to medical imaging. In NIPS, 2019. ",
1146
+ "bbox": [
1147
+ 174,
1148
+ 498,
1149
+ 823,
1150
+ 529
1151
+ ],
1152
+ "page_idx": 11
1153
+ },
1154
+ {
1155
+ "type": "text",
1156
+ "text": "Shaoqing Ren, Kaiming He, Ross Girshick, and Jian Sun. Faster r-cnn: Towards real-time object detection with region proposal networks. In NIPS, 2015. ",
1157
+ "bbox": [
1158
+ 174,
1159
+ 536,
1160
+ 825,
1161
+ 566
1162
+ ],
1163
+ "page_idx": 11
1164
+ },
1165
+ {
1166
+ "type": "text",
1167
+ "text": "Olga Russakovsky, Jia Deng, Hao Su, Jonathan Krause, Sanjeev Satheesh, Sean Ma, Zhiheng Huang, Andrej Karpathy, Aditya Khosla, Michael Bernstein, Alexander C. Berg, and Li Fei-Fei. ImageNet Large Scale Visual Recognition Challenge. IJCV, 115(3):211–252, 2015. ",
1168
+ "bbox": [
1169
+ 176,
1170
+ 575,
1171
+ 825,
1172
+ 619
1173
+ ],
1174
+ "page_idx": 11
1175
+ },
1176
+ {
1177
+ "type": "text",
1178
+ "text": "Ali Sharif Razavian, Hossein Azizpour, Josephine Sullivan, and Stefan Carlsson. Cnn features off-the-shelf: an astounding baseline for recognition. In CVPR workshops, pp. 806–813, 2014. ",
1179
+ "bbox": [
1180
+ 171,
1181
+ 627,
1182
+ 823,
1183
+ 657
1184
+ ],
1185
+ "page_idx": 11
1186
+ },
1187
+ {
1188
+ "type": "text",
1189
+ "text": "Karen Simonyan and Andrew Zisserman. Very deep convolutional networks for large-scale image recognition. In ICLR, 2015. ",
1190
+ "bbox": [
1191
+ 173,
1192
+ 666,
1193
+ 823,
1194
+ 695
1195
+ ],
1196
+ "page_idx": 11
1197
+ },
1198
+ {
1199
+ "type": "text",
1200
+ "text": "Leslie N Smith. Cyclical learning rates for training neural networks. In WACV, 2017. ",
1201
+ "bbox": [
1202
+ 173,
1203
+ 704,
1204
+ 733,
1205
+ 719
1206
+ ],
1207
+ "page_idx": 11
1208
+ },
1209
+ {
1210
+ "type": "text",
1211
+ "text": "Leslie N Smith. A disciplined approach to neural network hyper-parameters: Part 1–learning rate, batch size, momentum, and weight decay. arXiv preprint arXiv:1803.09820, 2018. ",
1212
+ "bbox": [
1213
+ 171,
1214
+ 728,
1215
+ 825,
1216
+ 758
1217
+ ],
1218
+ "page_idx": 11
1219
+ },
1220
+ {
1221
+ "type": "text",
1222
+ "text": "Leslie N Smith and Nicholay Topin. Super-convergence: Very fast training of neural networks using large learning rates. In Artificial Intelligence and Machine Learning for Multi-Domain Operations Applications, volume 11006, pp. 1100612. International Society for Optics and Photonics, 2019. ",
1223
+ "bbox": [
1224
+ 173,
1225
+ 766,
1226
+ 825,
1227
+ 810
1228
+ ],
1229
+ "page_idx": 11
1230
+ },
1231
+ {
1232
+ "type": "text",
1233
+ "text": "Samuel L Smith and Quoc V Le. A bayesian perspective on generalization and stochastic gradient descent. In ICLR, 2018. ",
1234
+ "bbox": [
1235
+ 169,
1236
+ 819,
1237
+ 823,
1238
+ 848
1239
+ ],
1240
+ "page_idx": 11
1241
+ },
1242
+ {
1243
+ "type": "text",
1244
+ "text": "Samuel L Smith, Pieter-Jan Kindermans, Chris Ying, and Quoc V Le. Don’t decay the learning rate, increase the batch size. In ICLR, 2018. ",
1245
+ "bbox": [
1246
+ 173,
1247
+ 856,
1248
+ 823,
1249
+ 886
1250
+ ],
1251
+ "page_idx": 11
1252
+ },
1253
+ {
1254
+ "type": "text",
1255
+ "text": "Chen Sun, Abhinav Shrivastava, Saurabh Singh, and Abhinav Gupta. Revisiting unreasonable effectiveness of data in deep learning era. In CVPR, 2017. ",
1256
+ "bbox": [
1257
+ 174,
1258
+ 895,
1259
+ 821,
1260
+ 924
1261
+ ],
1262
+ "page_idx": 11
1263
+ },
1264
+ {
1265
+ "type": "text",
1266
+ "text": "Ilya Sutskever, James Martens, George Dahl, and Geoffrey Hinton. On the importance of initialization and momentum in deep learning. In ICML, 2013. ",
1267
+ "bbox": [
1268
+ 171,
1269
+ 103,
1270
+ 825,
1271
+ 132
1272
+ ],
1273
+ "page_idx": 12
1274
+ },
1275
+ {
1276
+ "type": "text",
1277
+ "text": "Christian Szegedy, Wei Liu, Yangqing Jia, Pierre Sermanet, Scott Reed, Dragomir Anguelov, Dumitru Erhan, Vincent Vanhoucke, and Andrew Rabinovich. Going deeper with convolutions. In CVPR, 2015. ",
1278
+ "bbox": [
1279
+ 176,
1280
+ 140,
1281
+ 825,
1282
+ 184
1283
+ ],
1284
+ "page_idx": 12
1285
+ },
1286
+ {
1287
+ "type": "text",
1288
+ "text": "Grant Van Horn, Oisin Mac Aodha, Yang Song, Yin Cui, Chen Sun, Alex Shepard, Hartwig Adam, Pietro Perona, and Serge Belongie. The inaturalist species classification and detection dataset. In CVPR, 2018. ",
1289
+ "bbox": [
1290
+ 176,
1291
+ 193,
1292
+ 823,
1293
+ 234
1294
+ ],
1295
+ "page_idx": 12
1296
+ },
1297
+ {
1298
+ "type": "text",
1299
+ "text": "Twan van Laarhoven. L2 regularization versus batch and weight normalization. In NIPS, 2017. ",
1300
+ "bbox": [
1301
+ 173,
1302
+ 244,
1303
+ 797,
1304
+ 260
1305
+ ],
1306
+ "page_idx": 12
1307
+ },
1308
+ {
1309
+ "type": "text",
1310
+ "text": "C. Wah, S. Branson, P. Welinder, P. Perona, and S. Belongie. The Caltech-UCSD Birds-200-2011 Dataset. Technical Report CNS-TR-2011-001, California Institute of Technology, 2011. ",
1311
+ "bbox": [
1312
+ 173,
1313
+ 267,
1314
+ 823,
1315
+ 297
1316
+ ],
1317
+ "page_idx": 12
1318
+ },
1319
+ {
1320
+ "type": "text",
1321
+ "text": "Junyuan Xie, Tong He, Zhi Zhang, Hang Zhang, Zhongyue Zhang, and Mu Li. Bag of tricks for image classification with convolutional neural networks. arXiv preprint arXiv:1812.01187, 2018. ",
1322
+ "bbox": [
1323
+ 171,
1324
+ 305,
1325
+ 825,
1326
+ 335
1327
+ ],
1328
+ "page_idx": 12
1329
+ },
1330
+ {
1331
+ "type": "text",
1332
+ "text": "Jason Yosinski, Jeff Clune, Yoshua Bengio, and Hod Lipson. How transferable are features in deep neural networks? In NIPS, 2014. ",
1333
+ "bbox": [
1334
+ 171,
1335
+ 343,
1336
+ 823,
1337
+ 372
1338
+ ],
1339
+ "page_idx": 12
1340
+ },
1341
+ {
1342
+ "type": "text",
1343
+ "text": "Guodong Zhang, Chaoqi Wang, Bowen Xu, and Roger Grosse. Three mechanisms of weight decay regularization. arXiv preprint arXiv:1810.12281, 2018. ",
1344
+ "bbox": [
1345
+ 171,
1346
+ 381,
1347
+ 825,
1348
+ 410
1349
+ ],
1350
+ "page_idx": 12
1351
+ },
1352
+ {
1353
+ "type": "text",
1354
+ "text": "Jian Zhang and Ioannis Mitliagkas. Yellowfin and the art of momentum tuning. arXiv preprint arXiv:1706.03471, 2017. ",
1355
+ "bbox": [
1356
+ 171,
1357
+ 419,
1358
+ 825,
1359
+ 448
1360
+ ],
1361
+ "page_idx": 12
1362
+ },
1363
+ {
1364
+ "type": "text",
1365
+ "text": "Bolei Zhou, Agata Lapedriza, Aditya Khosla, Aude Oliva, and Antonio Torralba. Places: A 10 million image database for scene recognition. IEEE T-PAMI, 40(6):1452–1464, 2018. ",
1366
+ "bbox": [
1367
+ 174,
1368
+ 457,
1369
+ 823,
1370
+ 486
1371
+ ],
1372
+ "page_idx": 12
1373
+ },
1374
+ {
1375
+ "type": "text",
1376
+ "text": "A THE EFFECTIVENESS OF MOMENTUM ",
1377
+ "text_level": 1,
1378
+ "bbox": [
1379
+ 176,
1380
+ 102,
1381
+ 522,
1382
+ 118
1383
+ ],
1384
+ "page_idx": 13
1385
+ },
1386
+ {
1387
+ "type": "text",
1388
+ "text": "Searching for Optimal Momentum To check the effectiveness of momentum on fine-tuning, we can search the best momentum values for fine-tuning with fixed learning rate but different weight decay and batch size. Taking Birds dataset as an example, Figure 7 provides the convergence curves for the results shown in Figure 1(a), which shows the learning curves of fine-tuning with 6 different batch sizes and weight decay combinations. Zero momentum outperforms the nonzero momentum in 5 out of 6 configurations. ",
1389
+ "bbox": [
1390
+ 173,
1391
+ 133,
1392
+ 826,
1393
+ 217
1394
+ ],
1395
+ "page_idx": 13
1396
+ },
1397
+ {
1398
+ "type": "image",
1399
+ "img_path": "images/8beae2447809ec4270e59fee2f970afcb8a9b4714c2b111c7115aad152104e0c.jpg",
1400
+ "image_caption": [
1401
+ "Figure 7: Searching for the optimal momentum on Birds dataset with fixed learning rate and weight decays. The solid lines are training errors and the dashed lines are validation errors. "
1402
+ ],
1403
+ "image_footnote": [],
1404
+ "bbox": [
1405
+ 158,
1406
+ 236,
1407
+ 820,
1408
+ 534
1409
+ ],
1410
+ "page_idx": 13
1411
+ },
1412
+ {
1413
+ "type": "text",
1414
+ "text": "Effective learning rate increases after disabling momentum. Figure 8 compares the performance of with and without momentum for Dogs dataset with a range of different learning rates. Note that the learning rate with similar performance generally increases $1 0 \\mathrm { x }$ after changing $m$ from 0.9 to 0.0, which is coherent with the rule of effective learning rate $\\eta ^ { \\prime } = \\eta / ( 1 - m )$ . Same observations can be made on other datasets as shown in Figure 9. ",
1415
+ "bbox": [
1416
+ 174,
1417
+ 609,
1418
+ 825,
1419
+ 680
1420
+ ],
1421
+ "page_idx": 13
1422
+ },
1423
+ {
1424
+ "type": "image",
1425
+ "img_path": "images/d272a7bfcd1b13889839f52478efe383627211480fe1e0bd6e539537315f620c.jpg",
1426
+ "image_caption": [
1427
+ "Figure 8: The effect of momentum when learning rate is allowed to change. The learning rate for the best performance increases 10x after changing $m$ from 0.9 to 0.0, which is coherent with the rule of effective learning rate. Note that weight decay $\\lambda$ is fixed at 0.0001. "
1428
+ ],
1429
+ "image_footnote": [],
1430
+ "bbox": [
1431
+ 235,
1432
+ 700,
1433
+ 759,
1434
+ 869
1435
+ ],
1436
+ "page_idx": 13
1437
+ },
1438
+ {
1439
+ "type": "image",
1440
+ "img_path": "images/6975d095fde1cce98ef4cfbcacd6896129b345a222c1c8fa715c18ac86cd55aa.jpg",
1441
+ "image_caption": [
1442
+ "Figure 9: The effect of momentum when learning rate is allowed to change (Figure 8 continued). The learning rate for the best performance increases $1 0 \\mathrm { x }$ after changing $m$ from 0.9 to 0.0, which is coherent with the rule of effective learning rate. "
1443
+ ],
1444
+ "image_footnote": [],
1445
+ "bbox": [
1446
+ 156,
1447
+ 104,
1448
+ 841,
1449
+ 460
1450
+ ],
1451
+ "page_idx": 14
1452
+ },
1453
+ {
1454
+ "type": "text",
1455
+ "text": "B DOMAIN SIMILARITY ",
1456
+ "text_level": 1,
1457
+ "bbox": [
1458
+ 176,
1459
+ 534,
1460
+ 388,
1461
+ 549
1462
+ ],
1463
+ "page_idx": 14
1464
+ },
1465
+ {
1466
+ "type": "text",
1467
+ "text": "The domain similarity calculation based on Earth Mover Distance (EMD) is introduced in the section 4.1 of (Cui et al., 2018)4. Here we briefly introduce the steps. In (Cui et al., 2018), the authors first train ResNet-101 on the large scale JFT dataset (Sun et al., 2017) and use it as a feature extractor. They extracted features from the penultimate layer of the model for each image of the training set of the source domain and target domain. For ResNet-101, the length of the feature vector is 2048. The features of images belonging to the same category are averaged and $g ( s _ { i } )$ denotes the average feature vector of ith label in source domain $S$ , similarly, $g ( t _ { j } )$ denotes the average feature vector of $j$ th label in target domain $T$ . The distance between the averaged features of two labels is $d _ { i , j } = \\lVert g ( s _ { i } ) - g ( t _ { j } ) \\rVert$ . Each label is associated with a weight $w \\in [ 0 , 1 ]$ corresponding to the percentage of images with this label in the dataset. So the source domain $S$ with $m$ labels and the target domain $T$ with $n$ labels can be represented as ${ \\cal { S } } = \\{ ( s _ { i } , w _ { s _ { i } } ) \\} _ { i = 1 } ^ { m }$ and $T = \\{ ( t _ { j } , w _ { t _ { j } } ) \\} _ { i = 1 } ^ { n }$ . The EMD between the two domains is defined as ",
1468
+ "bbox": [
1469
+ 173,
1470
+ 564,
1471
+ 826,
1472
+ 731
1473
+ ],
1474
+ "page_idx": 14
1475
+ },
1476
+ {
1477
+ "type": "equation",
1478
+ "img_path": "images/7a64d6f898ec7c43f399691626958bc8f9c60afeed24ca2dc13417b9ce376d1e.jpg",
1479
+ "text": "$$\nd ( S , T ) = \\operatorname { E M D } ( S , T ) = { \\frac { \\sum _ { i = 1 , j = 1 } ^ { m , n } f _ { i , j } d _ { i , j } } { \\sum _ { i = 1 , j = 1 } ^ { m , n } f _ { i , j } } }\n$$",
1480
+ "text_format": "latex",
1481
+ "bbox": [
1482
+ 351,
1483
+ 733,
1484
+ 647,
1485
+ 773
1486
+ ],
1487
+ "page_idx": 14
1488
+ },
1489
+ {
1490
+ "type": "text",
1491
+ "text": "where the optimal flow $f _ { i , j }$ corresponds to the least amount of total work by solving the EMD optimization problem. The domain similarity is defined as ",
1492
+ "bbox": [
1493
+ 171,
1494
+ 779,
1495
+ 823,
1496
+ 806
1497
+ ],
1498
+ "page_idx": 14
1499
+ },
1500
+ {
1501
+ "type": "equation",
1502
+ "img_path": "images/21cf57964a4ab2ca927bac9a5b87dd89b1db8c66181aeb1540c3f33916cab5ad.jpg",
1503
+ "text": "$$\n\\sin ( S , T ) = e ^ { - \\gamma d ( S , T ) }\n$$",
1504
+ "text_format": "latex",
1505
+ "bbox": [
1506
+ 421,
1507
+ 813,
1508
+ 576,
1509
+ 832
1510
+ ],
1511
+ "page_idx": 14
1512
+ },
1513
+ {
1514
+ "type": "text",
1515
+ "text": "where $\\gamma$ is 0.01. Note that the domain similarity value is not ranging from 0 to 1. ",
1516
+ "bbox": [
1517
+ 174,
1518
+ 837,
1519
+ 702,
1520
+ 853
1521
+ ],
1522
+ "page_idx": 14
1523
+ },
1524
+ {
1525
+ "type": "text",
1526
+ "text": "Due to the unavailability of the large-scale JFT dataset ( $3 0 0 \\mathrm { x }$ larger than ImageNet) and its pre-trained ResNet-101 model, we cannot use it for extracting features for new datasets, such as Caltech256 and ",
1527
+ "bbox": [
1528
+ 176,
1529
+ 858,
1530
+ 823,
1531
+ 888
1532
+ ],
1533
+ "page_idx": 14
1534
+ },
1535
+ {
1536
+ "type": "text",
1537
+ "text": "MIT67-Indoor. Instead of using the powerful feature representation, we use our pre-trained ImageNet model (ResNet-101) as the feature extractor. Table 4 compares the domain similarities calculated by different pre-trained models and we can see some consistent patterns across different architectures: e.g., The 1st and 2nd highest similarity scores are Caltech and Dogs regardless of architectures; the 3rd and 4th highest similarity scores refers to Birds and Indoor; the most dissimilar datasets are Cars, Aircrafts and Flowers, though the relative orders for them are not exactly the same. Besides using fixed feature extractor, an alternative way is to use the source domain model directly as the feature extractor for both source domain and target domain, which may captures the transfer learning process more precisely than a uniform feature extractor. ",
1538
+ "bbox": [
1539
+ 173,
1540
+ 103,
1541
+ 825,
1542
+ 229
1543
+ ],
1544
+ "page_idx": 15
1545
+ },
1546
+ {
1547
+ "type": "text",
1548
+ "text": "C THE EFFECTIVENESS OF BN MOMENTUM ",
1549
+ "text_level": 1,
1550
+ "bbox": [
1551
+ 174,
1552
+ 251,
1553
+ 557,
1554
+ 267
1555
+ ],
1556
+ "page_idx": 15
1557
+ },
1558
+ {
1559
+ "type": "text",
1560
+ "text": "Kornblith et al. (2019) conducted extensive fine-tuning experiments with different hyperparameters. One observation they made is that the momentum parameter of BN layer is essential for finetuning. They found it useful to decrease the BN momentum parameter from its ImageNet value to $\\operatorname* { m a x } ( 1 - \\mathrm { \\tilde { 1 0 } } / s , 0 . 9 )$ where $s$ is the number of steps per epoch. This will change the default BN momentum value (0.9) when $s$ is larger than 100, but it only applies when the dataset size is larger than 25.6K with batch size 256. The maximum data size used in our experiments is Caltech-256, which is 15K, so this strategy seems not applicable. ",
1561
+ "bbox": [
1562
+ 174,
1563
+ 282,
1564
+ 825,
1565
+ 381
1566
+ ],
1567
+ "page_idx": 15
1568
+ },
1569
+ {
1570
+ "type": "text",
1571
+ "text": "We further validate the effect of BN momentum by performing a similar study as to ELR. The goal is to identify whether there is an optimal BN momentum for a given task. For each dataset, we fine-tune the pre-trained model using previously obtained best hyperparameters and only vary BN momentum. In addition to the default value 0.9, we also set it to 0.0, 0.95 and 0.99. The rational is that if BN mommentum is a critical hyperparameter, we should expect significant performance differences when the value is changed from the optimal value. As shown in Figure 10, we can see $m _ { b n } = 0 . 9 9$ slightly improves the performance for some datasets, however, there is no significant performance difference among values greater than 0.9. One hypothesis is that similar domains will share similar BN parameters and statistics, BN momentum may affect the parameter adaptation. More investigation is still needed to fully understand its effectiveness. ",
1572
+ "bbox": [
1573
+ 173,
1574
+ 387,
1575
+ 825,
1576
+ 526
1577
+ ],
1578
+ "page_idx": 15
1579
+ },
1580
+ {
1581
+ "type": "image",
1582
+ "img_path": "images/950c08dfafbcd1c62591b4bd179a0a8940ce2fd4429f42a85e25295a82ad1fae.jpg",
1583
+ "image_caption": [
1584
+ "Figure 10: Performance of different BN momentum for each dataset with existing optimal hyperparameters. "
1585
+ ],
1586
+ "image_footnote": [],
1587
+ "bbox": [
1588
+ 287,
1589
+ 542,
1590
+ 671,
1591
+ 690
1592
+ ],
1593
+ "page_idx": 15
1594
+ },
1595
+ {
1596
+ "type": "text",
1597
+ "text": "D EXPERIMENTAL SETTINGS FOR COMPARISON OF $L _ { 2 }$ AND $L _ { 2 }$ -SP ",
1598
+ "text_level": 1,
1599
+ "bbox": [
1600
+ 176,
1601
+ 753,
1602
+ 736,
1603
+ 770
1604
+ ],
1605
+ "page_idx": 15
1606
+ },
1607
+ {
1608
+ "type": "text",
1609
+ "text": "The experiments in Section 3.4 is based the code5 provided by (Li et al., 2018). The base network is ImageNet pretrained ResNet-101-V1. The model is fine-tuned with batch size 64 for 9000 iterations, and learning rate is decayed once at iteration 6000. Following the original setting, we use momentum 0.9. We performed grid search on learning rate and weight decay, with the range of $\\eta : \\{ 0 . 0 2 , 0 . 0 1 , 0 . 0 0 5 , 0 . 0 0 1 , 0 . 0 \\bar { 0 } 0 1 \\}$ and $\\lambda _ { 1 } : \\{ 0 . 1 , \\bar { 0 . 0 1 } , 0 . 0 0 1 , 0 . 0 \\bar { 0 } 0 1 \\}$ , and report the best average class error (1 - average accuracy) for both methods. For $L _ { 2 }$ -SP norm, we follow the authors’ setting to use constant $\\lambda _ { 2 } = 0 . 0 1$ . Different with the original setting for $L _ { 2 }$ regularization, we set $\\lambda _ { 2 } = \\lambda _ { 1 }$ to simulate normal $L _ { 2 }$ -norm. ",
1610
+ "bbox": [
1611
+ 174,
1612
+ 785,
1613
+ 825,
1614
+ 898
1615
+ ],
1616
+ "page_idx": 15
1617
+ },
1618
+ {
1619
+ "type": "text",
1620
+ "text": "E DATA AUGMENTATION ",
1621
+ "text_level": 1,
1622
+ "bbox": [
1623
+ 176,
1624
+ 102,
1625
+ 397,
1626
+ 117
1627
+ ],
1628
+ "page_idx": 16
1629
+ },
1630
+ {
1631
+ "type": "text",
1632
+ "text": "Data augmentation is an important way of increasing data quantity and diversity to make models more robust. It is even critical for transfer learning with few instances. The effect of data augmentation can be viewed as a regularization and the choice of data augmentation can be also viewed as a hyperparameter. Most current widely used data augmentation methods have verified their effectiveness on training ImageNet models, such as random mirror flipping, random rescaled cropping6, color jittering and etc (Szegedy et al., 2015; Xie et al., 2018). ",
1633
+ "bbox": [
1634
+ 174,
1635
+ 133,
1636
+ 825,
1637
+ 217
1638
+ ],
1639
+ "page_idx": 16
1640
+ },
1641
+ {
1642
+ "type": "text",
1643
+ "text": "Do these methods transfer for fine-tuning on other datasets? Here we compare three settings for data augmentation with different momentum settings: 1) random resized cropping: our default data augmentation; 2) random cropping: the same as standard data augmentation except that we use random cropping with fixed size; 3) random flip: simply random horizontal flipping. The training and validation errors of fine-tuning with different data augmentation strategies and hyperparameters are shown in Figure 11 and Figure 12. ",
1644
+ "bbox": [
1645
+ 173,
1646
+ 223,
1647
+ 825,
1648
+ 308
1649
+ ],
1650
+ "page_idx": 16
1651
+ },
1652
+ {
1653
+ "type": "image",
1654
+ "img_path": "images/b853f9f9663c5bbe1027d13c3b70378ace602276659025eeecce79608702402f.jpg",
1655
+ "image_caption": [
1656
+ "Figure 11: Fine-tuning with different data augmentation methods and hyperparameters. Dashed curves are the validation errors. Strong data augmentation is harder to train as it converge slowly and needs more number of epochs to observe the advanced performance on datasets such as Aircrafts. Simple data augmentation (red curves) converges much faster in training error. Strong data augmentation (blue curves) overfits the Dogs dataset with default hyperparameter but performs well with $m = 0$ . "
1657
+ ],
1658
+ "image_footnote": [],
1659
+ "bbox": [
1660
+ 174,
1661
+ 327,
1662
+ 838,
1663
+ 622
1664
+ ],
1665
+ "page_idx": 16
1666
+ },
1667
+ {
1668
+ "type": "text",
1669
+ "text": "The effect of data augmentation is dataset dependent and is also influenced by other hyperparameters The first row in Figure 11 shows that advanced data augmentation with default hyperparameters ( $m = 0 . 9$ and $\\eta = 0 . 0 1 $ ) leads to overfitting for Dogs while generalize better on Aircrafts and Flowers. Similar observations can be made in Figure 12. However, when momentum is disabled, the overfitting disappears for Dogs and Caltech. This is explainable since random resized cropping adds more variance to the gradient direction, and disabling momentum will lead to a smaller ELR which will be helpful for fine-tuning from a similar domain. On the other hand, the performance of random cropping decreases when momentum is disabled. As random cropping produces training samples with less variation than random resized cropping, disabling momentum or decreasing the ELR might lead to underfitting or stucking in poor local minima. This can be mitigated as we increase the learning rate for random cropping, which adds variation to the gradients. As shown in Table 6, when learning rate increased fro 0.01 to 0.05, disabling momentum shows better performance than nonzero momentum on datasets that are close, similar to previous findings with random resized cropping. ",
1670
+ "bbox": [
1671
+ 173,
1672
+ 734,
1673
+ 826,
1674
+ 888
1675
+ ],
1676
+ "page_idx": 16
1677
+ },
1678
+ {
1679
+ "type": "image",
1680
+ "img_path": "images/4abd77ff6555d3fc005e908f20f3a82181f6489f569f34344fadd7221496ed3c.jpg",
1681
+ "image_caption": [
1682
+ "Figure 12: Comparison of data augmentation methods with different momentum values (Figure 11 continued). The other hyperparameters are: $n = 2 5 6$ , $\\eta = 0 . 0 1$ and $\\lambda = 0 . 0 0 0 1$ . "
1683
+ ],
1684
+ "image_footnote": [],
1685
+ "bbox": [
1686
+ 156,
1687
+ 119,
1688
+ 839,
1689
+ 354
1690
+ ],
1691
+ "page_idx": 17
1692
+ },
1693
+ {
1694
+ "type": "text",
1695
+ "text": "",
1696
+ "bbox": [
1697
+ 174,
1698
+ 431,
1699
+ 825,
1700
+ 474
1701
+ ],
1702
+ "page_idx": 17
1703
+ },
1704
+ {
1705
+ "type": "table",
1706
+ "img_path": "images/24ea3066a39944bfed2ad9be552bbd291fef262299566a7b73fc9c61ed15cf2b.jpg",
1707
+ "table_caption": [
1708
+ "Table 6: Comparison of data augmentation methods with different momentum values. The rest of the hyperparameters are: $n = 2 5 6$ and $\\lambda = 0 . 0 0 0 1$ . "
1709
+ ],
1710
+ "table_footnote": [],
1711
+ "table_body": "<table><tr><td colspan=\"2\">Data Augmentation</td><td>m m</td><td>Dogs</td><td>Caltech</td><td>Indoor</td><td>Birds</td><td>Cars</td><td>Flowers</td><td>Aircrafts</td></tr><tr><td rowspan=\"2\">Rand resized crop</td><td>0.9</td><td>0.01</td><td>17.20</td><td>14.85</td><td>23.76</td><td>18.10</td><td>9.10</td><td>3.12</td><td>17.55</td></tr><tr><td>0</td><td>0.01</td><td>11.00</td><td>12.11</td><td>21.14</td><td>17.41</td><td>11.06</td><td>5.48</td><td>20.58</td></tr><tr><td rowspan=\"4\">Rand crop</td><td>0.9</td><td>0.01</td><td>11.99</td><td>12.42</td><td>23.39</td><td>20.31</td><td>17.77</td><td>5.63</td><td>21.72</td></tr><tr><td>0</td><td>0.01</td><td>11.35</td><td>12.89</td><td>25.19</td><td>22.11</td><td>23.87</td><td>7.76</td><td>29.04</td></tr><tr><td>0.9</td><td>0.05</td><td>16.85</td><td>14.80</td><td>23.46</td><td>18.81</td><td>13.70</td><td>4.85</td><td>17.64</td></tr><tr><td>0</td><td>0.05</td><td>11.79</td><td>12.52</td><td>23.24</td><td>20.69</td><td>20.00</td><td>7.06</td><td>23.43</td></tr></table>",
1712
+ "bbox": [
1713
+ 178,
1714
+ 526,
1715
+ 821,
1716
+ 643
1717
+ ],
1718
+ "page_idx": 17
1719
+ },
1720
+ {
1721
+ "type": "text",
1722
+ "text": "F SOURCE DOMAINS ",
1723
+ "text_level": 1,
1724
+ "bbox": [
1725
+ 176,
1726
+ 676,
1727
+ 364,
1728
+ 693
1729
+ ],
1730
+ "page_idx": 17
1731
+ },
1732
+ {
1733
+ "type": "text",
1734
+ "text": "Pre-trained models For most of our experiments, we use the pre-trained ResNet-101_v2 model from the model zoo of MXNet GluonCV 7. To get the pre-trained models for iNat-2017 and Places365, we fine-tune from the ImageNet pre-trained model with the default fine-tuning hyperparameters for 60 epochs, where learning rate is decayed at epoch 45 by a factor of 10. Table 7 illustrates the Top-1 errors of each pre-trained model on their validation sets. ",
1735
+ "bbox": [
1736
+ 173,
1737
+ 709,
1738
+ 825,
1739
+ 780
1740
+ ],
1741
+ "page_idx": 17
1742
+ },
1743
+ {
1744
+ "type": "table",
1745
+ "img_path": "images/afcbf78a684270d955a116db648dc39fea7dc3e74d6f0351a68429569fb7c6c2.jpg",
1746
+ "table_caption": [
1747
+ "Table 7: The Top-1 error of ResNet-101 pre-trained on different source dataset. "
1748
+ ],
1749
+ "table_footnote": [],
1750
+ "table_body": "<table><tr><td>Dataset</td><td>class</td><td>Top-1 error</td></tr><tr><td>ImageNet</td><td>1000</td><td>21.4</td></tr><tr><td>iNat2017</td><td>5,089</td><td>32.2</td></tr><tr><td>Places-365</td><td>365</td><td>31.5</td></tr></table>",
1751
+ "bbox": [
1752
+ 375,
1753
+ 821,
1754
+ 622,
1755
+ 886
1756
+ ],
1757
+ "page_idx": 17
1758
+ },
1759
+ {
1760
+ "type": "text",
1761
+ "text": "Training from Scratch with HPO The default hyperparameters for training from scratch are $\\eta = 0 . 1$ , $\\lambda = 0 . 0 0 0 1$ , $m = 0 . 9$ and $n = 2 5 6$ . We train 600 epochs, and decay the learning rate at epoch 400 and 550 by a factor of 10. To perform Hyperparameter Optimization (HPO), we search hyperparameters in the following space: $\\eta \\in [ 0 . 1 , 0 . 2 , 0 . 5 ]$ and $\\lambda \\in [ 0 . 0 0 0 1 , 0 . 0 0 0 5 ]$ . Figure 13 shows the training/validation errors of training from scratch on each dataset with different learning rate and weight decay. We observe weight decay 0.0005 consistently performs better than 0.0001. ",
1762
+ "bbox": [
1763
+ 174,
1764
+ 103,
1765
+ 825,
1766
+ 188
1767
+ ],
1768
+ "page_idx": 18
1769
+ },
1770
+ {
1771
+ "type": "text",
1772
+ "text": "Insufficient hyperparameter search may lead to miss-leading conclusion To show the importance of hyperparameter tuning, Table 8 compares the performance with and without hyperparameter tuning for both fine-tuning and training from scratch tasks. With the default hyperparameters, some inappropriate conclusions might be made, e.g., “there is significant gap between fine-tuning and training from scratch\", “fine-tuning always surpass training from scratch\" or “fine-tuning from iNat cannot beat the performance of ImageNet\". However, with HPO, those statements may not be valid. For example, training from scratch surpass the default fine-tuning result on Cars and Aircrafts and the gap between fine-tuning and training from scratch is much smaller. Previous studies (Kornblith et al., 2019; Cui et al., 2018) also identified that datasets like Cars and Aircrafts do not benefit too much from fine-tuning. ",
1773
+ "bbox": [
1774
+ 173,
1775
+ 203,
1776
+ 825,
1777
+ 342
1778
+ ],
1779
+ "page_idx": 18
1780
+ },
1781
+ {
1782
+ "type": "table",
1783
+ "img_path": "images/15ce8af6e2a4f6519d35073b6bc5707be3a8f3b2802a212d4b99d9a1ea29e1e9.jpg",
1784
+ "table_caption": [
1785
+ "Table 8: Comparison of default hyperparameters and HPO for both fine-tuning (FT) and training from scratch (ST) tasks. FT Default and ST Default use their default hyperparameters, respectively. HPO refers to the finding the best hyperparameters with grid search. "
1786
+ ],
1787
+ "table_footnote": [],
1788
+ "table_body": "<table><tr><td>Method</td><td>Source</td><td>Dogs</td><td>Caltech</td><td>Indoor</td><td>Birds</td><td>Cars</td><td>Aircrafts</td><td>Flowers</td></tr><tr><td>FT Default</td><td>ImageNet</td><td>17.20</td><td>13.42</td><td>23.76</td><td>18.10</td><td>9.10</td><td>17.55</td><td>3.12</td></tr><tr><td>FT Default</td><td>iNat2017</td><td>24.74</td><td>20.12</td><td>30.73</td><td>14.69</td><td>11.16</td><td>19.86</td><td>3.19</td></tr><tr><td>FT Default</td><td>Places-365</td><td>30.84</td><td>22.53</td><td>22.19</td><td>27.72</td><td>11.06</td><td>21.27</td><td>5.66</td></tr><tr><td>ST Default</td><td>1</td><td>38.26</td><td>36.21</td><td>45.28</td><td>43.72</td><td>16.73</td><td>26.49</td><td>22.88</td></tr><tr><td>FT HPO</td><td>ImageNet</td><td>9.83</td><td>11.61</td><td>20.54</td><td>16.34</td><td>7.61</td><td>12.33</td><td>2.91</td></tr><tr><td>FT HPO</td><td>iNat2017</td><td>23.51</td><td>18.82</td><td>28.11</td><td>12.06</td><td>9.58</td><td>15.45</td><td>2.70</td></tr><tr><td>FT HPO</td><td>Places-365</td><td>26.24</td><td>22.14</td><td>19.42</td><td>22.90</td><td>9.13</td><td>15.48</td><td>5.06</td></tr><tr><td>ST HPO</td><td>1</td><td>29.32</td><td>29.62</td><td>39.36</td><td>30.08</td><td>8.37</td><td>14.34</td><td>16.51</td></tr></table>",
1789
+ "bbox": [
1790
+ 202,
1791
+ 409,
1792
+ 794,
1793
+ 545
1794
+ ],
1795
+ "page_idx": 18
1796
+ },
1797
+ {
1798
+ "type": "image",
1799
+ "img_path": "images/909d1a42088de344fe2672db84061fc6962fdb4c76f2a65e81205b92b034c96d.jpg",
1800
+ "image_caption": [
1801
+ "Figure 13: Training from scratch with various learning rate and weight decay. The batch size is 256 and the momentum is 0.9. The solid curves are training error and the dashed lines are valdiation error. "
1802
+ ],
1803
+ "image_footnote": [],
1804
+ "bbox": [
1805
+ 156,
1806
+ 208,
1807
+ 839,
1808
+ 773
1809
+ ],
1810
+ "page_idx": 19
1811
+ }
1812
+ ]
parse/train/B1g8VkHFPH/B1g8VkHFPH_middle.json ADDED
The diff for this file is too large to render. See raw diff
 
parse/train/B1g8VkHFPH/B1g8VkHFPH_model.json ADDED
The diff for this file is too large to render. See raw diff
 
parse/train/BJgQfkSYDS/BJgQfkSYDS_layout.pdf ADDED
@@ -0,0 +1,3 @@
 
 
 
 
1
+ version https://git-lfs.github.com/spec/v1
2
+ oid sha256:bc2eb0f8051b7b90953cf55c75f2e65b8d2d478dd92c79bab8c20da33ef77d3a
3
+ size 1835859
parse/train/BJgQfkSYDS/BJgQfkSYDS_origin.pdf ADDED
@@ -0,0 +1,3 @@
 
 
 
 
1
+ version https://git-lfs.github.com/spec/v1
2
+ oid sha256:d314ab4a26e20ae9ad8de8b3462e5eb29cebe2aba4cacd836acd16692e4da96b
3
+ size 611394
parse/train/BJgQfkSYDS/BJgQfkSYDS_span.pdf ADDED
@@ -0,0 +1,3 @@
 
 
 
 
1
+ version https://git-lfs.github.com/spec/v1
2
+ oid sha256:afe41723e41bc5dce2bfe1560dca7644083e7b0aa9b8a0b8e110b407ba337a80
3
+ size 1845651
parse/train/BJlVeyHFwH/BJlVeyHFwH_layout.pdf ADDED
@@ -0,0 +1,3 @@
 
 
 
 
1
+ version https://git-lfs.github.com/spec/v1
2
+ oid sha256:9a9c1d51158ec4e16b0892cf0fb22cfabd5d364b26892f0672cafdc045327914
3
+ size 2584725
parse/train/BJlVeyHFwH/BJlVeyHFwH_origin.pdf ADDED
@@ -0,0 +1,3 @@
 
 
 
 
1
+ version https://git-lfs.github.com/spec/v1
2
+ oid sha256:342b558a24e51d79402619841dc4cb56ee6183acd96b436d9c5fcda6282ab72d
3
+ size 2298831
parse/train/BJlVeyHFwH/BJlVeyHFwH_span.pdf ADDED
@@ -0,0 +1,3 @@
 
 
 
 
1
+ version https://git-lfs.github.com/spec/v1
2
+ oid sha256:f126f702b0cfbfbe57379ac04dd152c6c414f7dd430396065db4789edbcdc641
3
+ size 2579568
parse/train/BJlZ5ySKPH/BJlZ5ySKPH_layout.pdf ADDED
@@ -0,0 +1,3 @@
 
 
 
 
1
+ version https://git-lfs.github.com/spec/v1
2
+ oid sha256:f2519348687647c0c81868a5b7ed49acab9a56c7ec37e5f4ef094c1f5624184c
3
+ size 9803522
parse/train/BJlZ5ySKPH/BJlZ5ySKPH_origin.pdf ADDED
@@ -0,0 +1,3 @@
 
 
 
 
1
+ version https://git-lfs.github.com/spec/v1
2
+ oid sha256:d05aad21063e21589eaded9b5005f92c2189b567710f2bca9002334f40a4a7f2
3
+ size 9590667
parse/train/BJlZ5ySKPH/BJlZ5ySKPH_span.pdf ADDED
@@ -0,0 +1,3 @@
 
 
 
 
1
+ version https://git-lfs.github.com/spec/v1
2
+ oid sha256:714981f99ffc7b88fe640845f8fb440d507cb1658fcdba79423227afb40f4c36
3
+ size 9804991
parse/train/Bkxbrn0cYX/Bkxbrn0cYX_layout.pdf ADDED
@@ -0,0 +1,3 @@
 
 
 
 
1
+ version https://git-lfs.github.com/spec/v1
2
+ oid sha256:fdb2ca85431d834699f7ad089d82a60cc118fb00383df357f54ff83159f53db3
3
+ size 891901
parse/train/Bkxbrn0cYX/Bkxbrn0cYX_origin.pdf ADDED
@@ -0,0 +1,3 @@
 
 
 
 
1
+ version https://git-lfs.github.com/spec/v1
2
+ oid sha256:949f87d5979360921e9a457aacbfc30a3eedf0e9f49943210a4e8d9d8436023f
3
+ size 709376
parse/train/Bkxbrn0cYX/Bkxbrn0cYX_span.pdf ADDED
@@ -0,0 +1,3 @@
 
 
 
 
1
+ version https://git-lfs.github.com/spec/v1
2
+ oid sha256:b2a37506678ad2de3a03df810abaf1bd457b8ff27afabbe8d91c5bf107d4f52d
3
+ size 896415
parse/train/Byey7n05FQ/Byey7n05FQ_layout.pdf ADDED
@@ -0,0 +1,3 @@
 
 
 
 
1
+ version https://git-lfs.github.com/spec/v1
2
+ oid sha256:499990c96b062a1aa6fb7fae4c62e74b34b1ca6e7604f4c8a392e3e846682cc6
3
+ size 3968382
parse/train/Byey7n05FQ/Byey7n05FQ_origin.pdf ADDED
@@ -0,0 +1,3 @@
 
 
 
 
1
+ version https://git-lfs.github.com/spec/v1
2
+ oid sha256:1cbbd0bd0a0a6281228545dd720a8cbed4f83142904e339ff229a53281089490
3
+ size 3795956
parse/train/Byey7n05FQ/Byey7n05FQ_span.pdf ADDED
@@ -0,0 +1,3 @@
 
 
 
 
1
+ version https://git-lfs.github.com/spec/v1
2
+ oid sha256:70809c6aa21671cc34f3f6169e669db39060a10f91068e66f31cec67e3c20132
3
+ size 3972494
parse/train/D2TE6VTJG9/D2TE6VTJG9_span.pdf ADDED
@@ -0,0 +1,3 @@
 
 
 
 
1
+ version https://git-lfs.github.com/spec/v1
2
+ oid sha256:ccddb4f6f1ac38eaf84d3436c3f942475d28250aef45caca96875c13f983ab76
3
+ size 2066318
parse/train/DNl5s5BXeBn/DNl5s5BXeBn_layout.pdf ADDED
@@ -0,0 +1,3 @@
 
 
 
 
1
+ version https://git-lfs.github.com/spec/v1
2
+ oid sha256:1213387b7abfa980e375c92db0ca4cc2cda9c0e58540c8b392cd0055f386fdb1
3
+ size 3755592
parse/train/DNl5s5BXeBn/DNl5s5BXeBn_origin.pdf ADDED
@@ -0,0 +1,3 @@
 
 
 
 
1
+ version https://git-lfs.github.com/spec/v1
2
+ oid sha256:0e7063d0738b531da42319d04f7e201ce7cabb6033f959dd44c14650c90f0b5d
3
+ size 3559813
parse/train/DNl5s5BXeBn/DNl5s5BXeBn_span.pdf ADDED
@@ -0,0 +1,3 @@
 
 
 
 
1
+ version https://git-lfs.github.com/spec/v1
2
+ oid sha256:e9292919754f1345c6e706a019d556c8753fce2d580c943da8ef0846425696da
3
+ size 3761063
parse/train/Ec85b0tUwbA/Ec85b0tUwbA_layout.pdf ADDED
@@ -0,0 +1,3 @@
 
 
 
 
1
+ version https://git-lfs.github.com/spec/v1
2
+ oid sha256:e2e51f8709e18901bf3c0dcfbd5954892a2c3df0cd5aad467bc59eae4146e5eb
3
+ size 4450003
parse/train/Ec85b0tUwbA/Ec85b0tUwbA_origin.pdf ADDED
@@ -0,0 +1,3 @@
 
 
 
 
1
+ version https://git-lfs.github.com/spec/v1
2
+ oid sha256:9cda99eb46677323ecb98982b9d4d7088e8c884c72a9198ea464224a8f7c68ce
3
+ size 3989031
parse/train/Ec85b0tUwbA/Ec85b0tUwbA_span.pdf ADDED
@@ -0,0 +1,3 @@
 
 
 
 
1
+ version https://git-lfs.github.com/spec/v1
2
+ oid sha256:5926effb21542ccfffd69e9a07d9505bd8e41063ee2cfac8dfc23d7d636f46f5
3
+ size 4457549
parse/train/FjnCWyzXu8m/FjnCWyzXu8m_layout.pdf ADDED
@@ -0,0 +1,3 @@
 
 
 
 
1
+ version https://git-lfs.github.com/spec/v1
2
+ oid sha256:9c258d64e1319baf86716d82cf9e80313f94e9f081477bdcf78282fd567a967a
3
+ size 343594
parse/train/FjnCWyzXu8m/FjnCWyzXu8m_origin.pdf ADDED
@@ -0,0 +1,3 @@
 
 
 
 
1
+ version https://git-lfs.github.com/spec/v1
2
+ oid sha256:7dc1c4ad77c74be8125bc7c8c6c721275595e596b1bb0677e6db5da465d6eb68
3
+ size 203364
parse/train/FjnCWyzXu8m/FjnCWyzXu8m_span.pdf ADDED
@@ -0,0 +1,3 @@
 
 
 
 
1
+ version https://git-lfs.github.com/spec/v1
2
+ oid sha256:aa96210311ad4d232f27fec4ccc260d95b01d78e25dc2f6425cbf40128cf1c67
3
+ size 365895
parse/train/H1q-TM-AW/H1q-TM-AW_layout.pdf ADDED
@@ -0,0 +1,3 @@
 
 
 
 
1
+ version https://git-lfs.github.com/spec/v1
2
+ oid sha256:a81da54eec6b84a04f06d82e079269052817f7193fced42367c98f7ebc89df47
3
+ size 2149477
parse/train/H1q-TM-AW/H1q-TM-AW_origin.pdf ADDED
@@ -0,0 +1,3 @@
 
 
 
 
1
+ version https://git-lfs.github.com/spec/v1
2
+ oid sha256:f4adb9f3dea6730d48716feada178c8129f73d1cac00d19873fe40242dedab11
3
+ size 1920496
parse/train/H1q-TM-AW/H1q-TM-AW_span.pdf ADDED
@@ -0,0 +1,3 @@
 
 
 
 
1
+ version https://git-lfs.github.com/spec/v1
2
+ oid sha256:14ec8974c31c5b76674cf605d19c0a832699acdb546ceb15fbaa5c942c3b0ee3
3
+ size 2152972
parse/train/HJMC_iA5tm/HJMC_iA5tm_layout.pdf ADDED
@@ -0,0 +1,3 @@
 
 
 
 
1
+ version https://git-lfs.github.com/spec/v1
2
+ oid sha256:0fb36a02115aff6f4b54594765e821ca085aec666346c192fbe0ccfc6c2ed316
3
+ size 1905110
parse/train/HJMC_iA5tm/HJMC_iA5tm_origin.pdf ADDED
@@ -0,0 +1,3 @@
 
 
 
 
1
+ version https://git-lfs.github.com/spec/v1
2
+ oid sha256:09f77e2778c43e807211029ec4076ecf904e651a8d0ae96d44d167bdd57f438e
3
+ size 1776887
parse/train/HJMC_iA5tm/HJMC_iA5tm_span.pdf ADDED
@@ -0,0 +1,3 @@
 
 
 
 
1
+ version https://git-lfs.github.com/spec/v1
2
+ oid sha256:b24d9d8e3bb57aded4852ddea3ec56804d35a6bc426c6837d60f0a5726d4d9f9
3
+ size 1915861
parse/train/Hk95PK9le/Hk95PK9le.md ADDED
@@ -0,0 +1,162 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ # DEEP BIAFFINE ATTENTION FOR NEURALDEPENDENCY PARSING
2
+
3
+ Timothy Dozat Stanford University tdozat@stanford.edu
4
+
5
+ Christopher D. Manning Stanford University manning@stanford.edu
6
+
7
+ # ABSTRACT
8
+
9
+ This paper builds off recent work from Kiperwasser & Goldberg (2016) using neural attention in a simple graph-based dependency parser. We use a larger but more thoroughly regularized parser than other recent BiLSTM-based approaches, with biaffine classifiers to predict arcs and labels. Our parser gets state of the art or near state of the art performance on standard treebanks for six different languages, achieving $9 5 . 7 \%$ UAS and $9 4 . 1 \%$ LAS on the most popular English PTB dataset. This makes it the highest-performing graph-based parser on this benchmark— outperforming Kiperwasser & Goldberg (2016) by $1 . 8 \%$ and $2 . 2 \%$ —and comparable to the highest performing transition-based parser (Kuncoro et al., 2016), which achieves $9 5 . 8 \%$ UAS and $9 4 . 6 \%$ LAS. We also show which hyperparameter choices had a significant effect on parsing accuracy, allowing us to achieve large gains over other graph-based approaches.
10
+
11
+ # 1 INTRODUCTION
12
+
13
+ Dependency parsers—which annotate sentences in a way designed to be easy for humans and computers alike to understand—have been found to be extremely useful for a sizable number of NLP tasks, especially those involving natural language understanding in some way (Bowman et al., 2016; Angeli et al., 2015; Levy & Goldberg, 2014; Toutanova et al., 2016; Parikh et al., 2015). However, frequent incorrect parses can severely inhibit final performance, so improving the quality of dependency parsers is needed for the improvement and success of these downstream tasks.
14
+
15
+ The current state-of-the-art transition-based neural dependency parser (Kuncoro et al., 2016) substantially outperforms many much simpler neural graph-based parsers. We modify the neural graphbased approach first proposed by Kiperwasser & Goldberg (2016) in a few ways to achieve competitive performance: we build a network that’s larger but uses more regularization; we replace the traditional MLP-based attention mechanism and affine label classifier with biaffine ones; and rather than using the top recurrent states of the LSTM in the biaffine transformations, we first put them through MLP operations that reduce their dimensionality. Furthermore, we compare models trained with different architectures and hyperparameters to motivate our approach empirically. The resulting parser maintains most of the simplicity of neural graph-based approaches while approaching the performance of the SOTA transition-based one.
16
+
17
+ # 2 BACKGROUND AND RELATED WORK
18
+
19
+ Transition-based parsers—such as shift-reduce parsers—parse sentences from left to right, maintaining a “buffer” of words that have not yet been parsed and a “stack” of words whose head has not been seen or whose dependents have not all been fully parsed. At each step, transition-based parsers can access and manipulate the stack and buffer and assign arcs from one word to another. One can then train any multi-class machine learning classifier on features extracted from the stack, buffer, and previous arc actions in order to predict the next action.
20
+
21
+ Chen & Manning (2014) make the first successful attempt at incorporating deep learning into a transition-based dependency parser. At each step, the (feedforward) network assigns a probability to each action the parser can take based on word, tag, and label embeddings from certain words on the stack and buffer. A number of other researchers have attempted to address some limitations of Chen & Manning’s Chen & Manning parser by augmenting it with additional complexity: Weiss et al. (2015) and Andor et al. (2016) augment it with a beam search and a conditional random field loss objective to allow the parser to “undo” previous actions once it finds evidence that they may have been incorrect; and Dyer et al. (2015) and (Kuncoro et al., 2016) instead use LSTMs to represent the stack and buffer, getting state-of-the-art performance by building in a way of composing parsed phrases together.
22
+
23
+ ![](images/3c86e6d6639eb509b92a7249dbffb402b66471676ee758343d444ef7d150c8ce.jpg)
24
+ Figure 1: A dependency tree parse for Casey hugged Kim, including part-of-speech tags and a special root token. Directed edges (or arcs) with labels (or relations) connect the verb to the root and the arguments to the verb head.
25
+
26
+ Transition-based parsing processes a sentence sequentially to build up a parse tree one arc at a time. Consequently, these parsers don’t use machine learning for directly predicting edges; they use it for predicting the operations of the transition algorithm. Graph-based parsers, by contrast, use machine learning to assign a weight or probability to each possible edge and then construct a maximum spaning tree (MST) from these weighted edges. Kiperwasser & Goldberg (2016) present a neural graph-based parser (in addition to a transition-based one) that uses the same kind of attention mechanism as Bahdanau et al. (2014) for machine translation. In Kiperwasser & Goldberg’s 2016 model, the (bidirectional) LSTM’s recurrent output vector for each word is concatenated with each possible head’s recurrent vector, and the result is used as input to an MLP that scores each resulting arc. The predicted tree structure at training time is the one where each word depends on its highestscoring head. Labels are generated analogously, with each word’s recurrent output vector and its gold or predicted head word’s recurrent vector being used in a multi-class MLP.
27
+
28
+ Similarly, Hashimoto et al. (2016) include a graph-based dependency parser in their multi-task neural model. In addition to training the model with multiple distinct objectives, they replace the traditional MLP-based attention mechanism that Kiperwasser & Goldberg (2016) use with a bilinear one (but still using an MLP label classifier). This makes it analogous to Luong et al.’s 2015 proposed attention mechanism for neural machine translation. Cheng et al. (2016) likewise propose a graph-based neural dependency parser, but in a way that attempts to circumvent the limitation of other neural graph-based parsers being unable to condition the scores of each possible arc on previous parsing decisions. In addition to having one bidirectional recurrent network that computes a recurrent hidden vector for each word, they have additional, unidirectional recurrent networks (leftto-right and right-to-left) that keep track of the probabilities of each previous arc, and use these together to predict the scores for the next arc.
29
+
30
+ # 3 PROPOSED DEPENDENCY PARSER
31
+
32
+ # 3.1 DEEP BIAFFINE ATTENTION
33
+
34
+ We make a few modifications to the graph-based architectures of Kiperwasser & Goldberg (2016), Hashimoto et al. (2016), and Cheng et al. (2016), shown in Figure 2: we use biaffine attention instead of bilinear or traditional MLP-based attention; we use a biaffine dependency label classifier; and we apply dimension-reducing MLPs to each recurrent output vector $\mathbf { r } _ { i }$ before applying the biaffine transformation.1 The choice of biaffine rather than bilinear or MLP mechanisms makes the classifiers in our model analogous to traditional affine classifiers, which use an affine transformation over a single LSTM output state $\mathbf { r } _ { i }$ (or other vector input) to predict the vector of scores $\mathbf { s } _ { i }$ for all classes (1). We can think of the proposed biaffine attention mechanism as being a traditional affine classifier, but using a $( d \times d )$ linear transformation of the stacked LSTM output $R U ^ { ( 1 ) }$ in place of the weight matrix $W$ and a $( d \times 1 )$ transformation $R \mathbf { u } ^ { ( 2 ) }$ for the bias term b (2).
35
+
36
+ ![](images/df61acdde66f08c0e970082361116ea01a5a7284ba8130276012844153fbbc8f.jpg)
37
+ Figure 2: BiLSTM with deep biaffine attention to score each possible head for each dependent, applied to the sentence “Casey hugged Kim”. We reverse the order of the biaffine transformation here for clarity.
38
+
39
+ $$
40
+ { \begin{array} { r l r } & { \qquad \mathbf { s } _ { i } = W \mathbf { r } _ { i } + \mathbf { b } } & { { \mathrm { F i r e d - c l a s s ~ a f f i n e ~ c l a s s i f i e r } } } \\ & { \mathbf { s } _ { i } ^ { ( a r c ) } = \left( R U ^ { ( 1 ) } \right) \mathbf { r } _ { i } + \left( R \mathbf { u } ^ { ( 2 ) } \right) } & { { \mathrm { V a r i a b l e - c l a s s ~ b i a f f i n e ~ c l a s s i f i e r } } } \end{array} }
41
+ $$
42
+
43
+ In addition to being arguably simpler than the MLP-based approach (involving one bilinear layer rather than two linear layers and a nonlinearity), this has the conceptual advantage of directly modeling both the prior probability of a word $j$ receiving any dependents in the term $\mathbf { r } _ { j } ^ { \top } \mathbf { u } ^ { ( 2 ) }$ and the likelihood of $j$ receiving a specific dependent $i$ in the term $\mathbf { r } _ { j } ^ { \top } U ^ { ( 1 ) } \mathbf { r } _ { i }$ . Analogously, we also use a biaffine classifier to predict dependency labels given the gold or predicted head $y _ { i }$ (3).
44
+
45
+ $$
46
+ \mathbf { s } _ { i } ^ { ( l a b e l ) } = \mathbf { r } _ { y _ { i } } ^ { \top } \mathbf { U } ^ { ( 1 ) } \mathbf { r } _ { i } + \left( \mathbf { r } _ { y _ { i } } \oplus \mathbf { r } _ { i } \right) ^ { \top } U ^ { ( 2 ) } + \mathbf { b }
47
+ $$
48
+
49
+ Fixed-class biaffine classifier
50
+
51
+ This likewise directly models each of the prior probability of each class, the likelihood of a class given just word $i$ (how probable a word is to take a particular label), the likelihood of a class given just the head word $y _ { i }$ (how probable a word is to take dependents with a particular label), and the likelihood of a class given both word $i$ and its head (how probable a word is to take a particular label given that word’s head).
52
+
53
+ Applying smaller MLPs to the recurrent output states before the biaffine classifier has the advantage of stripping away information not relevant to the current decision. That is, every top recurrent state $\mathbf { r } _ { i }$ will need to carry enough information to identify word $i$ ’s head, find all its dependents, exclude all its non-dependents, assign itself the correct label, and assign all its dependents their correct labels, as well as transfer any relevant information to the recurrent states of words before and after it. Thus $\mathbf { r } _ { i }$ necessarily contains significantly more information than is needed to compute any individual score, and training on this superfluous information needlessly reduces parsing speed and increases the risk of overfitting. Reducing dimensionality and applying a nonlinearity $( 4 - 6 )$ addresses both of these problems. We call this a deep bilinear attention mechanism, as opposed to shallow bilinear attention, which uses the recurrent states directly.
54
+
55
+ $$
56
+ \begin{array} { r l } & { \mathbf { h } _ { i } ^ { ( a r c - d e p ) } = \mathbf { M } \mathbf { L } \mathbf { P } ^ { ( a r c - d e p ) } ( \mathbf { r } _ { i } ) } \\ & { \mathbf { h } _ { j } ^ { ( a r c - h e a d ) } = \mathbf { M } \mathbf { L } \mathbf { P } ^ { ( a r c - h e a d ) } ( \mathbf { r } _ { j } ) } \\ & { \qquad \mathbf { s } _ { i } ^ { ( a r c ) } = H ^ { ( a r c - h e a d ) } U ^ { ( 1 ) } \mathbf { h } _ { i } ^ { ( a r c - d e p ) } } \\ & { \qquad + H ^ { ( a r c - h e a d ) } \mathbf { u } ^ { ( 2 ) } } \end{array}
57
+ $$
58
+
59
+ We apply MLPs to the recurrent states before using them in the label classifier as well. As with other graph-based models, the predicted tree at training time is the one where each word is a dependent of its highest scoring head (although at test time we ensure that the parse is a well-formed tree via the MST algorithm).
60
+
61
+ # 3.2 HYPERPARAMETER CONFIGURATION
62
+
63
+ Table 1: Model hyperparameters
64
+
65
+ <table><tr><td>Param</td><td>Value</td><td>Param</td><td>Value</td></tr><tr><td>Embedding size</td><td>100</td><td>Embedding dropout</td><td>33%</td></tr><tr><td>LSTM size</td><td>400</td><td>LSTM dropout</td><td>33%</td></tr><tr><td>Arc MLP size</td><td>500</td><td>Arc MLP dropout</td><td>33%</td></tr><tr><td>Label MLP size</td><td>100</td><td>Label MLP dropout</td><td>33%</td></tr><tr><td>LSTM depth</td><td>3</td><td>MLP depth</td><td>1</td></tr><tr><td>α</td><td>2e-3</td><td>β1,β2</td><td>.9</td></tr><tr><td>Annealing</td><td>.755000</td><td>tmax</td><td>50.000</td></tr></table>
66
+
67
+ Aside from architectural differences between ours and the other graph-based parsers, we make a number of hyperparameter choices that allow us to outperform theirs, laid out in Table 1. We use 100-dimensional uncased word vectors2 and POS tag vectors; three BiLSTM layers (400 dimensions in each direction); and 500- and 100-dimensional ReLU MLP layers. We also apply dropout at every stage of the model: we drop words and tags (independently); we drop nodes in the LSTM layers (input and recurrent connections), applying the same dropout mask at every recurrent timestep (cf. the Bayesian dropout of Gal & Ghahramani (2015)); and we drop nodes in the MLP layers and classifiers, likewise applying the same dropout mask at every timestep. We optimize the network with annealed Adam (Kingma & Ba, 2014) for about 50,000 steps, rounded up to the nearest epoch.
68
+
69
+ # 4 EXPERIMENTS & RESULTS
70
+
71
+ # 4.1 DATASETS
72
+
73
+ We show test results for the proposed model on the English Penn Treebank, converted into Stanford Dependencies using both version 3.3.0 and version 3.5.0 of the Stanford Dependency converter (PTB-SD 3.3.0 and PTB-SD 3.5.0); the Chinese Penn Treebank; and the CoNLL 09 shared task dataset,3 following standard practices for each dataset. We omit punctuation from evaluation only for the PTB-SD and CTB. For the English PTB-SD datasets, we use POS tags generated from the Stanford POS tagger (Toutanova et al., 2003); for the Chinese PTB dataset we use gold tags; and for the CoNLL 09 dataset we use the provided predicted tags. Our hyperparameter search was done with the PTB-SD 3.5.0 validation dataset in order to minimize overfitting to the more popular PTB-SD 3.3.0 benchmark, and in our hyperparameter analysis in the following section we report performance on the PTB-SD 3.5.0 test set, shown in Tables 2 and 3.
74
+
75
+ # 4.2 HYPERPARAMETER CHOICES
76
+
77
+ # 4.2.1 ATTENTION MECHANISM
78
+
79
+ We examined the effect of different classifier architectures on accuracy and performance. What we see is that the deep bilinear model outperforms the others with respect to both speed and accuracy. The model with shallow bilinear arc and label classifiers gets the same unlabeled performance as the deep model with the same settings, but because the label classifier is much larger ( $( 8 0 1 \times c \times 8 0 1 )$ as opposed to $( 1 0 1 \times c \times 1 0 1 )$ ), it runs much slower and overfits. One way to decrease this overfitting is by increasing the MLP dropout, but that of course doesn’t change parsing speed; another way is to decrease the recurrent size to 300, but this hinders unlabeled accuracy without increasing parsing speed up to the same levels as our deeper model. We also implemented the MLP-based approach to attention and classification used in Kiperwasser & Goldberg (2016).4 We found this version to likewise be somewhat slower and significantly underperform the deep biaffine approach in both labeled and unlabeled accuracy.
80
+
81
+ <table><tr><td colspan="5">Classifier</td><td colspan="3">Size</td></tr><tr><td>Model</td><td>UAS</td><td>LAS</td><td>Sents/sec</td><td>Model</td><td>UAS</td><td>LAS</td><td></td><td>Sents/sec</td></tr><tr><td>Deep</td><td>95.75</td><td>94.22</td><td>410.91</td><td>3 layers,400d</td><td>95.75</td><td></td><td>94.22</td><td>410.91</td></tr><tr><td>Shallow</td><td>95.74</td><td>94.00*</td><td>298.99</td><td>3 layers,300d</td><td>95.82</td><td></td><td>94.24</td><td>460.01</td></tr><tr><td>Shallow, 50% drop</td><td>95.73</td><td>94.05*</td><td>300.04</td><td></td><td>3 layers,200d</td><td>95.55*</td><td>93.89*</td><td>469.45</td></tr><tr><td>Shallow, 300d</td><td>95.63*</td><td>93.86*</td><td>373.24</td><td>2 layers,400d</td><td></td><td>95.62*</td><td>93.98*</td><td>497.99</td></tr><tr><td>MLP</td><td>95.53*</td><td>93.91*</td><td>367.44</td><td>4 layers, 400d</td><td></td><td>95.83</td><td>94.22</td><td>362.09</td></tr><tr><td></td><td>Recurrent Cell</td><td></td><td></td><td></td><td></td><td></td><td></td><td></td></tr><tr><td>Model</td><td>UAS</td><td>LAS</td><td></td><td>Sents/sec</td><td></td><td></td><td></td><td></td></tr><tr><td>LSTM</td><td>95.75</td><td>94.22</td><td>410.91</td><td></td><td></td><td></td><td></td><td></td></tr><tr><td>GRU</td><td>93.18*</td><td>91.08*</td><td>435.32</td><td></td><td></td><td></td><td></td><td></td></tr><tr><td>Cif-LSTM</td><td>95.67</td><td>94.06*</td><td>463.25</td><td></td><td></td><td></td><td></td><td></td></tr></table>
82
+
83
+ Table 2: Test accuracy and speed on PTB-SD 3.5.0. Statistically significant differences are marked with an asterisk.
84
+ Table 3: Test Accuracy on PTB-SD 3.5.0. Statistically significant differences are marked with an asterisk.
85
+
86
+ <table><tr><td colspan="4">Input Dropout</td><td colspan="2">Adam</td></tr><tr><td>Model</td><td>UAS</td><td>LAS</td><td>Model</td><td>UAS</td><td>LAS</td></tr><tr><td>Default</td><td>95.75</td><td>94.22</td><td>β=.9</td><td>95.75</td><td>94.22</td></tr><tr><td>No word dropout</td><td>95.74</td><td>94.08*</td><td>β2= .999</td><td>95.53*</td><td>93.91*</td></tr><tr><td>No tag dropout</td><td>95.28*</td><td>93.60*</td><td></td><td></td><td></td></tr><tr><td>No tags</td><td>95.77</td><td>93.91*</td><td></td><td></td><td></td></tr></table>
87
+
88
+ # 4.2.2 NETWORK SIZE
89
+
90
+ We also examine more closely how network size influences speed and accuracy. In Kiperwasser & Goldberg’s 2016 model, the network uses 2 layers of 125-dimensional bidirectional LSTMs; in Hashimoto et al.’s 2016 model, it has one layer of 100-dimensional bidirectional LSTMs dedicated to parsing (two lower layers are also trained on other objectives); and Cheng et al.’s 2016 model has one layer of 368-dimensional GRU cells. We find that using three or four layers gets significantly better performance than two layers, and increasing the LSTM sizes from 200 to 300 or 400 dimensions likewise signficantly improves performance.5
91
+
92
+ # 4.2.3 RECURRENT CELL
93
+
94
+ GRU cells have been promoted as a faster and simpler alternative to LSTM cells, and are used in the approach of Cheng et al. (2016); however, in our model they drastically underperformed LSTM cells. We also implemented the coupled input-forget gate LSTM cells (Cif-LSTM) suggested by Greff et al. (2015),6 finding that while the resulting model still slightly underperforms the more popular LSTM cells, the difference between the two is much smaller. Additionally, because the gate and candidate cell activations can be computed simultaneously with one matrix multiplication, the Cif-LSTM model is faster than the GRU version even though they have the same number of parameters. We hypothesize that the output gate in the Cif-LSTM model allows it to maintain a sparse recurrent output state, which helps it adapt to the high levels of dropout needed to prevent overfitting in a way that GRU cells are unable to do.
95
+
96
+ Table 4: Results on the English PTB and Chinese PTB parsing datasets
97
+
98
+ <table><tr><td rowspan="2">Type Model</td><td rowspan="2"></td><td colspan="2">English PTB-SD3.3.0</td><td colspan="2">Chinese PTB 5.1</td></tr><tr><td>UAS</td><td>LAS</td><td>UAS</td><td>LAS</td></tr><tr><td rowspan="4">Transition</td><td>Ballesteros et al. (2016)</td><td>93.56</td><td>91.42</td><td>87.65</td><td>86.21</td></tr><tr><td>Andor et al. (2016)</td><td>94.61</td><td>92.79</td><td>1</td><td>1</td></tr><tr><td>Kuncoro et al. (2016)</td><td>95.8</td><td>94.6</td><td>1</td><td>一</td></tr><tr><td>Kiperwasser &amp; Goldberg (2016)</td><td>93.9</td><td>91.9</td><td>87.6</td><td>86.1</td></tr><tr><td rowspan="3">Graph</td><td>Cheng et al. (2016)</td><td>94.10</td><td>91.49</td><td>88.1</td><td>85.7</td></tr><tr><td>Hashimoto et al. (2016)</td><td>94.67</td><td>92.90</td><td>一</td><td></td></tr><tr><td>Deep Biaffine</td><td>95.74</td><td>94.08</td><td>89.30</td><td>88.23</td></tr></table>
99
+
100
+ Table 5: Results on the CoNLL $^ { , 0 9 }$ shared task datasets
101
+
102
+ <table><tr><td colspan="3">Catalan</td><td colspan="2">Chinese</td><td colspan="2">Czech</td></tr><tr><td>Model</td><td>UAS</td><td>LAS</td><td>UAS</td><td>LAS</td><td>UAS</td><td>LAS</td></tr><tr><td>Andor et al.</td><td>92.67</td><td>89.83</td><td>84.72</td><td>80.85</td><td>88.94</td><td>84.56</td></tr><tr><td>Deep Biaffine</td><td>94.69</td><td>92.02</td><td>88.90</td><td>85.38</td><td>92.08</td><td>87.38</td></tr><tr><td></td><td colspan="2">English</td><td colspan="2">German</td><td colspan="2">Spanish</td></tr><tr><td>Model</td><td>UAS</td><td>LAS</td><td>UAS</td><td>LAS</td><td>UAS</td><td>LAS</td></tr><tr><td>Andor et al.</td><td>93.22</td><td>91.23</td><td>90.91</td><td>89.15</td><td>92.62</td><td>89.95</td></tr><tr><td>Deep Biaffine</td><td>95.21</td><td>93.20</td><td>93.46</td><td>91.44</td><td>94.34</td><td>91.65</td></tr></table>
103
+
104
+ # 4.2.4 EMBEDDING DROPOUT
105
+
106
+ Because we increase the parser’s power, we also have to increase its regularization. In addition to using relatively extreme dropout in the recurrent and MLP layers mentioned in Table 1, we also regularize the input layer. We drop $33 \%$ of words and $33 \%$ of tags during training: when one is dropped the other is scaled by a factor of two to compensate, and when both are dropped together, the model simply gets an input of zeros. Models trained with only word or tag dropout but not both wind up signficantly overfitting, hindering label accuracy and—in the latter case—attachment accuracy. Interestingly, not using any tags at all actually results in better performance than using tags without dropout.
107
+
108
+ # 4.2.5 OPTIMIZER
109
+
110
+ We choose to optimize with Adam (Kingma & Ba, 2014), which (among other things) keeps a moving average of the $L _ { 2 }$ norm of the gradient for each parameter throughout training and divides the gradient for each parameter by this moving average, ensuring that the magnitude of the gradients will on average be close to one. However, we find that the value for $\beta _ { 2 }$ recommended by Kingma & Ba—which controls the decay rate for this moving average—is too high for this task (and we suspect more generally). When this value is very large, the magnitude of the current update is heavily influenced by the larger magnitude of gradients very far in the past, with the effect that the optimizer can’t adapt quickly to recent changes in the model. Thus we find that setting $\beta _ { 2 }$ to .9 instead of .999 makes a large positive impact on final performance.
111
+
112
+ # 4.3 RESULTS
113
+
114
+ Our model gets nearly the same UAS performance on PTB-SD 3.3.0 as the current SOTA model from Kuncoro et al. (2016) in spite of its substantially simpler architecture, and gets SOTA UAS performance on CTB $5 . 1 ^ { 7 }$ as well as SOTA performance on all CoNLL 09 languages. It is worth noting that the CoNLL 09 datasets contain many non-projective dependencies, which are difficult or impossible for transition-based—but not graph-based—parsers to predict. This may account for some of the large, consistent difference between our model and Andor et al.’s 2016 transition-based model applied to these datasets.
115
+
116
+ Where our model appears to lag behind the SOTA model is in LAS, indicating one of a few possibilities. Firstly, it may be the result of inefficiencies or errors in the GloVe embeddings or POS tagger, in which case using alternative pretrained embeddings or a more accurate tagger might improve label classification. Secondly, the SOTA model is specifically designed to capture phrasal compositionality; so another possibility is that ours doesn’t capture this compositionality as effectively, and that this results in a worse label score. Similarly, it may be the result of a more general limitation of graph-based parsers, which have access to less explicit syntactic information than transition-based parsers when making decisions. Addressing these latter two limitations would require a more innovative architecture than the relatively simple one used in current neural graph-based parsers.
117
+
118
+ # 5 CONCLUSION
119
+
120
+ In this paper we proposed using a modified version of bilinear attention in a neural dependency parser that increases parsing speed without hurting performance. We showed that our larger but more regularized network outperforms other neural graph-based parsers and gets comparable performance to the current SOTA transition-based parser. We also provided empirical motivation for the proposed architecture and configuration over similar ones in the existing literature. Future work will involve exploring ways of bridging the gap between labeled and unlabeled accuracy and augment the parser with a smarter way of handling out-of-vocabulary tokens for morphologically richer languages.
121
+
122
+ # REFERENCES
123
+
124
+ Daniel Andor, Chris Alberti, David Weiss, Aliaksei Severyn, Alessandro Presta, Kuzman Ganchev, Slav Petrov, and Michael Collins. Globally normalized transition-based neural networks. In Association for Computational Linguistics, 2016. URL https://arxiv.org/abs/1603. 06042.
125
+
126
+ Gabor Angeli, Melvin Johnson Premkumar, and Christopher D Manning. Leveraging linguistic structure for open domain information extraction. In Proceedings of the 53rd Annual Meeting of the Association for Computational Linguistics (ACL 2015), 2015.
127
+
128
+ Dzmitry Bahdanau, Kyunghyun Cho, and Yoshua Bengio. Neural machine translation by jointly learning to align and translate. International Conference on Learning Representations, 2014.
129
+
130
+ Miguel Ballesteros, Yoav Goldberg, Chris Dyer, and Noah A Smith. Training with exploration improves a greedy stack-LSTM parser. Proceedings of the conference on empirical methods in natural language processing, 2016.
131
+
132
+ Samuel R Bowman, Jon Gauthier, Abhinav Rastogi, Raghav Gupta, Christopher D Manning, and Christopher Potts. A fast unified model for parsing and sentence understanding. ACL 2016, 2016.
133
+
134
+ Danqi Chen and Christopher D Manning. A fast and accurate dependency parser using neural networks. In Proceedings of the conference on empirical methods in natural language processing, pp. 740–750, 2014.
135
+
136
+ Hao Cheng, Hao Fang, Xiaodong He, Jianfeng Gao, and Li Deng. Bi-directional attention with agreement for dependency parsing. arXiv preprint arXiv:1608.02076, 2016.
137
+
138
+ Chris Dyer, Miguel Ballesteros, Wang Ling, Austin Matthews, and Noah A Smith. Transitionbased dependency parsing with stack long short-term memory. Proceedings of the conference on empirical methods in natural language processing, 2015.
139
+
140
+ Yarin Gal and Zoubin Ghahramani. Dropout as a bayesian approximation: Representing model uncertainty in deep learning. International Conference on Machine Learning, 2015.
141
+
142
+ Klaus Greff, Rupesh Kumar Srivastava, Jan Koutn´ık, Bas R Steunebrink, and Jurgen Schmidhuber. ¨ LSTM: A search space odyssey. IEEE Transactions on Neural Networks and Learning Systems, 2015.
143
+
144
+ Kazuma Hashimoto, Caiming Xiong, Yoshimasa Tsuruoka, and Richard Socher. A joint many-task model: Growing a neural network for multiple nlp tasks. arXiv preprint arXiv:1611.01587, 2016.
145
+
146
+ Diederik Kingma and Jimmy Ba. Adam: A method for stochastic optimization. International Conference on Learning Representations, 2014.
147
+
148
+ Eliyahu Kiperwasser and Yoav Goldberg. Simple and accurate dependency parsing using bidirectional LSTM feature representations. Transactions of the Association for Computational Linguistics, 4:313–327, 2016.
149
+
150
+ Adhiguna Kuncoro, Miguel Ballesteros, Lingpeng Kong, Chris Dyer, Graham Neubig, and Noah A. Smith. What do recurrent neural network grammars learn about syntax? CoRR, abs/1611.05774, 2016. URL http://arxiv.org/abs/1611.05774.
151
+
152
+ Omer Levy and Yoav Goldberg. Dependency-based word embeddings. In ACL 2014, pp. 302–308, 2014.
153
+
154
+ Minh-Thang Luong, Hieu Pham, and Christopher D Manning. Effective approaches to attentionbased neural machine translation. Empirical Methods in Natural Language Processing, 2015.
155
+
156
+ Ankur P Parikh, Hoifung Poon, and Kristina Toutanova. Grounded semantic parsing for complex knowledge extraction. In Proceedings of North American Chapter of the Association for Computational Linguistics, pp. 756–766, 2015.
157
+
158
+ Kristina Toutanova, Dan Klein, Christopher D Manning, and Yoram Singer. Feature-rich part-ofspeech tagging with a cyclic dependency network. In Proceedings of the 2003 Conference of the North American Chapter of the Association for Computational Linguistics on Human Language Technology-Volume 1, pp. 173–180. Association for Computational Linguistics, 2003.
159
+
160
+ Kristina Toutanova, Xi Victoria Lin, and Wen-tau Yih. Compositional learning of embeddings for relation paths in knowledge bases and text. In ACL, 2016.
161
+
162
+ David Weiss, Chris Alberti, Michael Collins, and Slav Petrov. Structured training for neural network transition-based parsing. Annual Meeting of the Association for Computational Linguistics, 2015.