Chelsea707 commited on
Commit
421039b
·
verified ·
1 Parent(s): 66eedd4

Add Batch 12f090a6-2fbe-4182-8066-d30f6e10f898 data

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 +64 -0
  2. 2024/SALMONN_ Towards Generic Hearing Abilities for Large Language Models/53cff767-5ca4-4ca6-a888-059c218f3649_content_list.json +0 -0
  3. 2024/SALMONN_ Towards Generic Hearing Abilities for Large Language Models/53cff767-5ca4-4ca6-a888-059c218f3649_model.json +0 -0
  4. 2024/SALMONN_ Towards Generic Hearing Abilities for Large Language Models/53cff767-5ca4-4ca6-a888-059c218f3649_origin.pdf +3 -0
  5. 2024/SALMONN_ Towards Generic Hearing Abilities for Large Language Models/full.md +711 -0
  6. 2024/SALMONN_ Towards Generic Hearing Abilities for Large Language Models/images.zip +3 -0
  7. 2024/SALMONN_ Towards Generic Hearing Abilities for Large Language Models/layout.json +0 -0
  8. 2024/SALMON_ Self-Alignment with Instructable Reward Models/cd081d37-dfd2-4be4-a4b9-51c32b23ccf7_content_list.json +0 -0
  9. 2024/SALMON_ Self-Alignment with Instructable Reward Models/cd081d37-dfd2-4be4-a4b9-51c32b23ccf7_model.json +0 -0
  10. 2024/SALMON_ Self-Alignment with Instructable Reward Models/cd081d37-dfd2-4be4-a4b9-51c32b23ccf7_origin.pdf +3 -0
  11. 2024/SALMON_ Self-Alignment with Instructable Reward Models/full.md +0 -0
  12. 2024/SALMON_ Self-Alignment with Instructable Reward Models/images.zip +3 -0
  13. 2024/SALMON_ Self-Alignment with Instructable Reward Models/layout.json +0 -0
  14. 2024/SAN_ Inducing Metrizability of GAN with Discriminative Normalized Linear Layer/9b66a8aa-e3da-4b12-a6c5-a1964dd9c67e_content_list.json +0 -0
  15. 2024/SAN_ Inducing Metrizability of GAN with Discriminative Normalized Linear Layer/9b66a8aa-e3da-4b12-a6c5-a1964dd9c67e_model.json +0 -0
  16. 2024/SAN_ Inducing Metrizability of GAN with Discriminative Normalized Linear Layer/9b66a8aa-e3da-4b12-a6c5-a1964dd9c67e_origin.pdf +3 -0
  17. 2024/SAN_ Inducing Metrizability of GAN with Discriminative Normalized Linear Layer/full.md +0 -0
  18. 2024/SAN_ Inducing Metrizability of GAN with Discriminative Normalized Linear Layer/images.zip +3 -0
  19. 2024/SAN_ Inducing Metrizability of GAN with Discriminative Normalized Linear Layer/layout.json +0 -0
  20. 2024/SAS_ Structured Activation Sparsification/f4b70f0a-5725-4b01-9a73-6fa2819e4c27_content_list.json +0 -0
  21. 2024/SAS_ Structured Activation Sparsification/f4b70f0a-5725-4b01-9a73-6fa2819e4c27_model.json +0 -0
  22. 2024/SAS_ Structured Activation Sparsification/f4b70f0a-5725-4b01-9a73-6fa2819e4c27_origin.pdf +3 -0
  23. 2024/SAS_ Structured Activation Sparsification/full.md +387 -0
  24. 2024/SAS_ Structured Activation Sparsification/images.zip +3 -0
  25. 2024/SAS_ Structured Activation Sparsification/layout.json +0 -0
  26. 2024/SCHEMA_ State CHangEs MAtter for Procedure Planning in Instructional Videos/a25a3d49-2e2d-49a1-b878-39675fb39e91_content_list.json +0 -0
  27. 2024/SCHEMA_ State CHangEs MAtter for Procedure Planning in Instructional Videos/a25a3d49-2e2d-49a1-b878-39675fb39e91_model.json +0 -0
  28. 2024/SCHEMA_ State CHangEs MAtter for Procedure Planning in Instructional Videos/a25a3d49-2e2d-49a1-b878-39675fb39e91_origin.pdf +3 -0
  29. 2024/SCHEMA_ State CHangEs MAtter for Procedure Planning in Instructional Videos/full.md +444 -0
  30. 2024/SCHEMA_ State CHangEs MAtter for Procedure Planning in Instructional Videos/images.zip +3 -0
  31. 2024/SCHEMA_ State CHangEs MAtter for Procedure Planning in Instructional Videos/layout.json +0 -0
  32. 2024/SEABO_ A Simple Search-Based Method for Offline Imitation Learning/430a3b73-fa5b-41bf-be8d-859b294c6e4c_content_list.json +0 -0
  33. 2024/SEABO_ A Simple Search-Based Method for Offline Imitation Learning/430a3b73-fa5b-41bf-be8d-859b294c6e4c_model.json +0 -0
  34. 2024/SEABO_ A Simple Search-Based Method for Offline Imitation Learning/430a3b73-fa5b-41bf-be8d-859b294c6e4c_origin.pdf +3 -0
  35. 2024/SEABO_ A Simple Search-Based Method for Offline Imitation Learning/full.md +566 -0
  36. 2024/SEABO_ A Simple Search-Based Method for Offline Imitation Learning/images.zip +3 -0
  37. 2024/SEABO_ A Simple Search-Based Method for Offline Imitation Learning/layout.json +0 -0
  38. 2024/SEA_ Sparse Linear Attention with Estimated Attention Mask/677e089e-2f24-4b16-920d-bdef731c9804_content_list.json +0 -0
  39. 2024/SEA_ Sparse Linear Attention with Estimated Attention Mask/677e089e-2f24-4b16-920d-bdef731c9804_model.json +0 -0
  40. 2024/SEA_ Sparse Linear Attention with Estimated Attention Mask/677e089e-2f24-4b16-920d-bdef731c9804_origin.pdf +3 -0
  41. 2024/SEA_ Sparse Linear Attention with Estimated Attention Mask/full.md +408 -0
  42. 2024/SEA_ Sparse Linear Attention with Estimated Attention Mask/images.zip +3 -0
  43. 2024/SEA_ Sparse Linear Attention with Estimated Attention Mask/layout.json +0 -0
  44. 2024/SEINE_ Short-to-Long Video Diffusion Model for Generative Transition and Prediction/4e0669d7-b95d-4ff4-97bd-d87bb4ad89af_content_list.json +1706 -0
  45. 2024/SEINE_ Short-to-Long Video Diffusion Model for Generative Transition and Prediction/4e0669d7-b95d-4ff4-97bd-d87bb4ad89af_model.json +2342 -0
  46. 2024/SEINE_ Short-to-Long Video Diffusion Model for Generative Transition and Prediction/4e0669d7-b95d-4ff4-97bd-d87bb4ad89af_origin.pdf +3 -0
  47. 2024/SEINE_ Short-to-Long Video Diffusion Model for Generative Transition and Prediction/full.md +293 -0
  48. 2024/SEINE_ Short-to-Long Video Diffusion Model for Generative Transition and Prediction/images.zip +3 -0
  49. 2024/SEINE_ Short-to-Long Video Diffusion Model for Generative Transition and Prediction/layout.json +0 -0
  50. 2024/SEPT_ Towards Efficient Scene Representation Learning for Motion Prediction/96a0a7fc-6af1-4e6b-b9d3-714a11bd3b55_content_list.json +1885 -0
.gitattributes CHANGED
@@ -5221,3 +5221,67 @@ saved_model/**/* filter=lfs diff=lfs merge=lfs -text
5221
  2024/Robustness[[:space:]]of[[:space:]]AI-Image[[:space:]]Detectors_[[:space:]]Fundamental[[:space:]]Limits[[:space:]]and[[:space:]]Practical[[:space:]]Attacks/2557f37e-e96e-4a44-8ae6-24e9ce502a17_origin.pdf filter=lfs diff=lfs merge=lfs -text
5222
  2024/S$2$AC_[[:space:]]Energy-Based[[:space:]]Reinforcement[[:space:]]Learning[[:space:]]with[[:space:]]Stein[[:space:]]Soft[[:space:]]Actor[[:space:]]Critic/cad66925-4aba-49fe-b982-1bbf316767b3_origin.pdf filter=lfs diff=lfs merge=lfs -text
5223
  2024/SAFLEX_[[:space:]]Self-Adaptive[[:space:]]Augmentation[[:space:]]via[[:space:]]Feature[[:space:]]Label[[:space:]]Extrapolation/b05c7200-dd4a-4af1-bc50-a7417be6d0b9_origin.pdf filter=lfs diff=lfs merge=lfs -text
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
5221
  2024/Robustness[[:space:]]of[[:space:]]AI-Image[[:space:]]Detectors_[[:space:]]Fundamental[[:space:]]Limits[[:space:]]and[[:space:]]Practical[[:space:]]Attacks/2557f37e-e96e-4a44-8ae6-24e9ce502a17_origin.pdf filter=lfs diff=lfs merge=lfs -text
5222
  2024/S$2$AC_[[:space:]]Energy-Based[[:space:]]Reinforcement[[:space:]]Learning[[:space:]]with[[:space:]]Stein[[:space:]]Soft[[:space:]]Actor[[:space:]]Critic/cad66925-4aba-49fe-b982-1bbf316767b3_origin.pdf filter=lfs diff=lfs merge=lfs -text
5223
  2024/SAFLEX_[[:space:]]Self-Adaptive[[:space:]]Augmentation[[:space:]]via[[:space:]]Feature[[:space:]]Label[[:space:]]Extrapolation/b05c7200-dd4a-4af1-bc50-a7417be6d0b9_origin.pdf filter=lfs diff=lfs merge=lfs -text
5224
+ 2024/SALMONN_[[:space:]]Towards[[:space:]]Generic[[:space:]]Hearing[[:space:]]Abilities[[:space:]]for[[:space:]]Large[[:space:]]Language[[:space:]]Models/53cff767-5ca4-4ca6-a888-059c218f3649_origin.pdf filter=lfs diff=lfs merge=lfs -text
5225
+ 2024/SALMON_[[:space:]]Self-Alignment[[:space:]]with[[:space:]]Instructable[[:space:]]Reward[[:space:]]Models/cd081d37-dfd2-4be4-a4b9-51c32b23ccf7_origin.pdf filter=lfs diff=lfs merge=lfs -text
5226
+ 2024/SAN_[[:space:]]Inducing[[:space:]]Metrizability[[:space:]]of[[:space:]]GAN[[:space:]]with[[:space:]]Discriminative[[:space:]]Normalized[[:space:]]Linear[[:space:]]Layer/9b66a8aa-e3da-4b12-a6c5-a1964dd9c67e_origin.pdf filter=lfs diff=lfs merge=lfs -text
5227
+ 2024/SAS_[[:space:]]Structured[[:space:]]Activation[[:space:]]Sparsification/f4b70f0a-5725-4b01-9a73-6fa2819e4c27_origin.pdf filter=lfs diff=lfs merge=lfs -text
5228
+ 2024/SCHEMA_[[:space:]]State[[:space:]]CHangEs[[:space:]]MAtter[[:space:]]for[[:space:]]Procedure[[:space:]]Planning[[:space:]]in[[:space:]]Instructional[[:space:]]Videos/a25a3d49-2e2d-49a1-b878-39675fb39e91_origin.pdf filter=lfs diff=lfs merge=lfs -text
5229
+ 2024/SEABO_[[:space:]]A[[:space:]]Simple[[:space:]]Search-Based[[:space:]]Method[[:space:]]for[[:space:]]Offline[[:space:]]Imitation[[:space:]]Learning/430a3b73-fa5b-41bf-be8d-859b294c6e4c_origin.pdf filter=lfs diff=lfs merge=lfs -text
5230
+ 2024/SEA_[[:space:]]Sparse[[:space:]]Linear[[:space:]]Attention[[:space:]]with[[:space:]]Estimated[[:space:]]Attention[[:space:]]Mask/677e089e-2f24-4b16-920d-bdef731c9804_origin.pdf filter=lfs diff=lfs merge=lfs -text
5231
+ 2024/SEINE_[[:space:]]Short-to-Long[[:space:]]Video[[:space:]]Diffusion[[:space:]]Model[[:space:]]for[[:space:]]Generative[[:space:]]Transition[[:space:]]and[[:space:]]Prediction/4e0669d7-b95d-4ff4-97bd-d87bb4ad89af_origin.pdf filter=lfs diff=lfs merge=lfs -text
5232
+ 2024/SEPT_[[:space:]]Towards[[:space:]]Efficient[[:space:]]Scene[[:space:]]Representation[[:space:]]Learning[[:space:]]for[[:space:]]Motion[[:space:]]Prediction/96a0a7fc-6af1-4e6b-b9d3-714a11bd3b55_origin.pdf filter=lfs diff=lfs merge=lfs -text
5233
+ 2024/SF(DA)$^2$_[[:space:]]Source-free[[:space:]]Domain[[:space:]]Adaptation[[:space:]]Through[[:space:]]the[[:space:]]Lens[[:space:]]of[[:space:]]Data[[:space:]]Augmentation/722c0971-a9aa-4097-8fe9-b1d61d88fae4_origin.pdf filter=lfs diff=lfs merge=lfs -text
5234
+ 2024/SKILL-MIX_[[:space:]]a[[:space:]]Flexible[[:space:]]and[[:space:]]Expandable[[:space:]]Family[[:space:]]of[[:space:]]Evaluations[[:space:]]for[[:space:]]AI[[:space:]]Models/4f019da0-e017-48b1-ad53-589a7258e700_origin.pdf filter=lfs diff=lfs merge=lfs -text
5235
+ 2024/SLiMe_[[:space:]]Segment[[:space:]]Like[[:space:]]Me/463c496c-482c-415a-82a1-09b6532100fd_origin.pdf filter=lfs diff=lfs merge=lfs -text
5236
+ 2024/SOHES_[[:space:]]Self-supervised[[:space:]]Open-world[[:space:]]Hierarchical[[:space:]]Entity[[:space:]]Segmentation/dcd44bb3-2dbf-4c46-8e0d-5739c1ff1ddf_origin.pdf filter=lfs diff=lfs merge=lfs -text
5237
+ 2024/SOInter_[[:space:]]A[[:space:]]Novel[[:space:]]Deep[[:space:]]Energy-Based[[:space:]]Interpretation[[:space:]]Method[[:space:]]for[[:space:]]Explaining[[:space:]]Structured[[:space:]]Output[[:space:]]Models/e5b71c9d-caaf-4bb8-ad0b-ca99446c720b_origin.pdf filter=lfs diff=lfs merge=lfs -text
5238
+ 2024/SPDER_[[:space:]]Semiperiodic[[:space:]]Damping-Enabled[[:space:]]Object[[:space:]]Representation/838999e8-7afa-4814-9439-d739ec22b8fa_origin.pdf filter=lfs diff=lfs merge=lfs -text
5239
+ 2024/SPTNet_[[:space:]]An[[:space:]]Efficient[[:space:]]Alternative[[:space:]]Framework[[:space:]]for[[:space:]]Generalized[[:space:]]Category[[:space:]]Discovery[[:space:]]with[[:space:]]Spatial[[:space:]]Prompt[[:space:]]Tuning/94c488ec-a5df-4efc-be57-8e8820d026ac_origin.pdf filter=lfs diff=lfs merge=lfs -text
5240
+ 2024/SRL_[[:space:]]Scaling[[:space:]]Distributed[[:space:]]Reinforcement[[:space:]]Learning[[:space:]]to[[:space:]]Over[[:space:]]Ten[[:space:]]Thousand[[:space:]]Cores/119a93e6-9fef-49ba-826d-2b3a8d1eaab9_origin.pdf filter=lfs diff=lfs merge=lfs -text
5241
+ 2024/STARC_[[:space:]]A[[:space:]]General[[:space:]]Framework[[:space:]]For[[:space:]]Quantifying[[:space:]]Differences[[:space:]]Between[[:space:]]Reward[[:space:]]Functions/45b34ab4-0504-430b-9955-09b2c1b8a027_origin.pdf filter=lfs diff=lfs merge=lfs -text
5242
+ 2024/STREAM_[[:space:]]Spatio-TempoRal[[:space:]]Evaluation[[:space:]]and[[:space:]]Analysis[[:space:]]Metric[[:space:]]for[[:space:]]Video[[:space:]]Generative[[:space:]]Models/afa5bde2-2394-4084-91a4-d684b32640ed_origin.pdf filter=lfs diff=lfs merge=lfs -text
5243
+ 2024/STanHop_[[:space:]]Sparse[[:space:]]Tandem[[:space:]]Hopfield[[:space:]]Model[[:space:]]for[[:space:]]Memory-Enhanced[[:space:]]Time[[:space:]]Series[[:space:]]Prediction/4f5f5450-6b57-4458-9524-3a7bff04083e_origin.pdf filter=lfs diff=lfs merge=lfs -text
5244
+ 2024/SWAP_[[:space:]]Sparse[[:space:]]Entropic[[:space:]]Wasserstein[[:space:]]Regression[[:space:]]for[[:space:]]Robust[[:space:]]Network[[:space:]]Pruning/72216b33-7963-442f-9f24-e45ca18e0d73_origin.pdf filter=lfs diff=lfs merge=lfs -text
5245
+ 2024/SYMBOL_[[:space:]]Generating[[:space:]]Flexible[[:space:]]Black-Box[[:space:]]Optimizers[[:space:]]through[[:space:]]Symbolic[[:space:]]Equation[[:space:]]Learning/38a1ff54-7ae2-4dcb-8605-012bb30f9eea_origin.pdf filter=lfs diff=lfs merge=lfs -text
5246
+ 2024/Safe[[:space:]]Collaborative[[:space:]]Filtering/0a10d656-03a0-462d-a644-fdc20addeec4_origin.pdf filter=lfs diff=lfs merge=lfs -text
5247
+ 2024/Safe[[:space:]]Offline[[:space:]]Reinforcement[[:space:]]Learning[[:space:]]with[[:space:]]Feasibility-Guided[[:space:]]Diffusion[[:space:]]Model/ca869c72-0de0-4525-9e60-32c097f30db8_origin.pdf filter=lfs diff=lfs merge=lfs -text
5248
+ 2024/Safe[[:space:]]and[[:space:]]Robust[[:space:]]Watermark[[:space:]]Injection[[:space:]]with[[:space:]]a[[:space:]]Single[[:space:]]OoD[[:space:]]Image/9c1848c0-0d70-4598-9ef8-67c821e0f734_origin.pdf filter=lfs diff=lfs merge=lfs -text
5249
+ 2024/SafeDreamer_[[:space:]]Safe[[:space:]]Reinforcement[[:space:]]Learning[[:space:]]with[[:space:]]World[[:space:]]Models/fc29bf3f-4b80-46cf-9616-2f99bdf6e501_origin.pdf filter=lfs diff=lfs merge=lfs -text
5250
+ 2024/Safety-Tuned[[:space:]]LLaMAs_[[:space:]]Lessons[[:space:]]From[[:space:]]Improving[[:space:]]the[[:space:]]Safety[[:space:]]of[[:space:]]Large[[:space:]]Language[[:space:]]Models[[:space:]]that[[:space:]]Follow[[:space:]]Instructions/5c9cd375-b0c8-4347-a3cd-7991c5a759a0_origin.pdf filter=lfs diff=lfs merge=lfs -text
5251
+ 2024/Sample[[:space:]]Efficient[[:space:]]Myopic[[:space:]]Exploration[[:space:]]Through[[:space:]]Multitask[[:space:]]Reinforcement[[:space:]]Learning[[:space:]]with[[:space:]]Diverse[[:space:]]Tasks/d405887a-fcee-4246-8cac-e4eb578f2d9b_origin.pdf filter=lfs diff=lfs merge=lfs -text
5252
+ 2024/Sample-Efficiency[[:space:]]in[[:space:]]Multi-Batch[[:space:]]Reinforcement[[:space:]]Learning_[[:space:]]The[[:space:]]Need[[:space:]]for[[:space:]]Dimension-Dependent[[:space:]]Adaptivity/1f882a72-74af-4124-8928-12a5e028e370_origin.pdf filter=lfs diff=lfs merge=lfs -text
5253
+ 2024/Sample-Efficient[[:space:]]Learning[[:space:]]of[[:space:]]POMDPs[[:space:]]with[[:space:]]Multiple[[:space:]]Observations[[:space:]]In[[:space:]]Hindsight/7b051506-4591-4b5b-a95a-8345c0ab7d79_origin.pdf filter=lfs diff=lfs merge=lfs -text
5254
+ 2024/Sample-Efficient[[:space:]]Multi-Agent[[:space:]]RL_[[:space:]]An[[:space:]]Optimization[[:space:]]Perspective/00863550-536d-43a4-a8a4-8d2f8e883598_origin.pdf filter=lfs diff=lfs merge=lfs -text
5255
+ 2024/Sample-efficient[[:space:]]Learning[[:space:]]of[[:space:]]Infinite-horizon[[:space:]]Average-reward[[:space:]]MDPs[[:space:]]with[[:space:]]General[[:space:]]Function[[:space:]]Approximation/14e99bd8-5769-4c9f-ab40-f3daf4676bad_origin.pdf filter=lfs diff=lfs merge=lfs -text
5256
+ 2024/Sampling[[:space:]]Multimodal[[:space:]]Distributions[[:space:]]with[[:space:]]the[[:space:]]Vanilla[[:space:]]Score_[[:space:]]Benefits[[:space:]]of[[:space:]]Data-Based[[:space:]]Initialization/b42e3711-7ade-4532-abf5-fb93a7c50361_origin.pdf filter=lfs diff=lfs merge=lfs -text
5257
+ 2024/Scalable[[:space:]]Diffusion[[:space:]]for[[:space:]]Materials[[:space:]]Generation/c06589fd-26cb-4fd4-b799-d406394d64f4_origin.pdf filter=lfs diff=lfs merge=lfs -text
5258
+ 2024/Scalable[[:space:]]Language[[:space:]]Model[[:space:]]with[[:space:]]Generalized[[:space:]]Continual[[:space:]]Learning/e6e73da2-3d36-48d0-bf31-519ec06e0e1d_origin.pdf filter=lfs diff=lfs merge=lfs -text
5259
+ 2024/Scalable[[:space:]]Modular[[:space:]]Network_[[:space:]]A[[:space:]]Framework[[:space:]]for[[:space:]]Adaptive[[:space:]]Learning[[:space:]]via[[:space:]]Agreement[[:space:]]Routing/d2a47c22-6799-4718-a754-e73409f70488_origin.pdf filter=lfs diff=lfs merge=lfs -text
5260
+ 2024/Scalable[[:space:]]Monotonic[[:space:]]Neural[[:space:]]Networks/125bd756-c6ce-4317-98d5-51fad3aeb42b_origin.pdf filter=lfs diff=lfs merge=lfs -text
5261
+ 2024/Scalable[[:space:]]Neural[[:space:]]Network[[:space:]]Kernels/4f536ddb-5ad0-4124-a398-0784e90dfec9_origin.pdf filter=lfs diff=lfs merge=lfs -text
5262
+ 2024/Scalable[[:space:]]and[[:space:]]Effective[[:space:]]Implicit[[:space:]]Graph[[:space:]]Neural[[:space:]]Networks[[:space:]]on[[:space:]]Large[[:space:]]Graphs/fe7bff6f-c6ba-443d-87df-a22da40d8504_origin.pdf filter=lfs diff=lfs merge=lfs -text
5263
+ 2024/Scale-Adaptive[[:space:]]Diffusion[[:space:]]Model[[:space:]]for[[:space:]]Complex[[:space:]]Sketch[[:space:]]Synthesis/48d35bb5-0efc-4cea-84c0-513f651b80ed_origin.pdf filter=lfs diff=lfs merge=lfs -text
5264
+ 2024/Scaling[[:space:]]Convex[[:space:]]Neural[[:space:]]Networks[[:space:]]with[[:space:]]Burer-Monteiro[[:space:]]Factorization/10da4996-8e17-4786-b433-ec3f6fde0033_origin.pdf filter=lfs diff=lfs merge=lfs -text
5265
+ 2024/Scaling[[:space:]]Laws[[:space:]]of[[:space:]]RoPE-based[[:space:]]Extrapolation/00f786a9-0d2e-4e06-879d-17d38eaa0ef9_origin.pdf filter=lfs diff=lfs merge=lfs -text
5266
+ 2024/Scaling[[:space:]]Supervised[[:space:]]Local[[:space:]]Learning[[:space:]]with[[:space:]]Augmented[[:space:]]Auxiliary[[:space:]]Networks/7e2bf1f4-8c6d-4848-afb2-babfb3546544_origin.pdf filter=lfs diff=lfs merge=lfs -text
5267
+ 2024/Scaling[[:space:]]for[[:space:]]Training[[:space:]]Time[[:space:]]and[[:space:]]Post-hoc[[:space:]]Out-of-distribution[[:space:]]Detection[[:space:]]Enhancement/891dc503-db6b-43c8-b232-4115f1db2b34_origin.pdf filter=lfs diff=lfs merge=lfs -text
5268
+ 2024/Scaling[[:space:]]physics-informed[[:space:]]hard[[:space:]]constraints[[:space:]]with[[:space:]]mixture-of-experts/f2b3cb59-40f5-4e09-9371-df10e2c5135c_origin.pdf filter=lfs diff=lfs merge=lfs -text
5269
+ 2024/Score[[:space:]]Models[[:space:]]for[[:space:]]Offline[[:space:]]Goal-Conditioned[[:space:]]Reinforcement[[:space:]]Learning/405c635e-9dda-4ecb-b38b-331faa049613_origin.pdf filter=lfs diff=lfs merge=lfs -text
5270
+ 2024/Score[[:space:]]Regularized[[:space:]]Policy[[:space:]]Optimization[[:space:]]through[[:space:]]Diffusion[[:space:]]Behavior/b45ca620-6fae-4b3e-9c75-ede5231676df_origin.pdf filter=lfs diff=lfs merge=lfs -text
5271
+ 2024/Score-based[[:space:]]generative[[:space:]]models[[:space:]]break[[:space:]]the[[:space:]]curse[[:space:]]of[[:space:]]dimensionality[[:space:]]in[[:space:]]learning[[:space:]]a[[:space:]]family[[:space:]]of[[:space:]]sub-Gaussian[[:space:]]distributions/95376387-f2b9-405a-af27-3441a0c2ffce_origin.pdf filter=lfs diff=lfs merge=lfs -text
5272
+ 2024/Searching[[:space:]]for[[:space:]]High-Value[[:space:]]Molecules[[:space:]]Using[[:space:]]Reinforcement[[:space:]]Learning[[:space:]]and[[:space:]]Transformers/ac657474-5f8a-4b93-906f-043ac550d4a6_origin.pdf filter=lfs diff=lfs merge=lfs -text
5273
+ 2024/Seeking[[:space:]]Neural[[:space:]]Nuggets_[[:space:]]Knowledge[[:space:]]Transfer[[:space:]]in[[:space:]]Large[[:space:]]Language[[:space:]]Models[[:space:]]from[[:space:]]a[[:space:]]Parametric[[:space:]]Perspective/9dc47d46-abff-4f42-8a8d-07724d26cb80_origin.pdf filter=lfs diff=lfs merge=lfs -text
5274
+ 2024/Seer_[[:space:]]Language[[:space:]]Instructed[[:space:]]Video[[:space:]]Prediction[[:space:]]with[[:space:]]Latent[[:space:]]Diffusion[[:space:]]Models/3bfa39a9-4c2c-4b50-9669-8c3fba3421f0_origin.pdf filter=lfs diff=lfs merge=lfs -text
5275
+ 2024/Select[[:space:]]to[[:space:]]Perfect_[[:space:]]Imitating[[:space:]]desired[[:space:]]behavior[[:space:]]from[[:space:]]large[[:space:]]multi-agent[[:space:]]data/1daf43a2-9efe-42f6-9255-d91db8b53cdf_origin.pdf filter=lfs diff=lfs merge=lfs -text
5276
+ 2024/Self-Consuming[[:space:]]Generative[[:space:]]Models[[:space:]]Go[[:space:]]MAD/5def343c-8a62-4954-a3e0-813ba13ac147_origin.pdf filter=lfs diff=lfs merge=lfs -text
5277
+ 2024/Self-Guided[[:space:]]Masked[[:space:]]Autoencoders[[:space:]]for[[:space:]]Domain-Agnostic[[:space:]]Self-Supervised[[:space:]]Learning/4fa1c5c1-28c0-4fa9-b268-ac37e595e644_origin.pdf filter=lfs diff=lfs merge=lfs -text
5278
+ 2024/Self-Supervised[[:space:]]Contrastive[[:space:]]Learning[[:space:]]for[[:space:]]Long-term[[:space:]]Forecasting/c7b37655-2ce2-4c17-a587-6216de7356fb_origin.pdf filter=lfs diff=lfs merge=lfs -text
5279
+ 2024/Self-Supervised[[:space:]]Dataset[[:space:]]Distillation[[:space:]]for[[:space:]]Transfer[[:space:]]Learning/29a6f81c-e801-4b11-b4bc-cacadb99fa4a_origin.pdf filter=lfs diff=lfs merge=lfs -text
5280
+ 2024/Self-Supervised[[:space:]]Heterogeneous[[:space:]]Graph[[:space:]]Learning_[[:space:]]a[[:space:]]Homophily[[:space:]]and[[:space:]]Heterogeneity[[:space:]]View/2e918fe3-ddef-48d6-a7f7-71d3f471fa6e_origin.pdf filter=lfs diff=lfs merge=lfs -text
5281
+ 2024/Self-Supervised[[:space:]]High[[:space:]]Dynamic[[:space:]]Range[[:space:]]Imaging[[:space:]]with[[:space:]]Multi-Exposure[[:space:]]Images[[:space:]]in[[:space:]]Dynamic[[:space:]]Scenes/fcf13e0e-2465-4d4b-b865-3bced6396b19_origin.pdf filter=lfs diff=lfs merge=lfs -text
5282
+ 2024/Self-Supervised[[:space:]]Speech[[:space:]]Quality[[:space:]]Estimation[[:space:]]and[[:space:]]Enhancement[[:space:]]Using[[:space:]]Only[[:space:]]Clean[[:space:]]Speech/6015d2ef-05c0-4de8-ae34-53c4df62fe1e_origin.pdf filter=lfs diff=lfs merge=lfs -text
5283
+ 2024/Self-contradictory[[:space:]]Hallucinations[[:space:]]of[[:space:]]Large[[:space:]]Language[[:space:]]Models_[[:space:]]Evaluation,[[:space:]]Detection[[:space:]]and[[:space:]]Mitigation/f6df15ab-7c8c-4887-9447-d05f83e766f2_origin.pdf filter=lfs diff=lfs merge=lfs -text
5284
+ 2024/Self-supervised[[:space:]]Pocket[[:space:]]Pretraining[[:space:]]via[[:space:]]Protein[[:space:]]Fragment-Surroundings[[:space:]]Alignment/1e24c955-ad2e-4df3-b282-8757dcb4ccb1_origin.pdf filter=lfs diff=lfs merge=lfs -text
5285
+ 2024/Self-supervised[[:space:]]Representation[[:space:]]Learning[[:space:]]from[[:space:]]Random[[:space:]]Data[[:space:]]Projectors/8a413231-03c1-4e23-aacd-50878ea84b84_origin.pdf filter=lfs diff=lfs merge=lfs -text
5286
+ 2024/SelfCheck_[[:space:]]Using[[:space:]]LLMs[[:space:]]to[[:space:]]Zero-Shot[[:space:]]Check[[:space:]]Their[[:space:]]Own[[:space:]]Step-by-Step[[:space:]]Reasoning/fdea2f58-b047-48e2-a729-acbd763c2c17_origin.pdf filter=lfs diff=lfs merge=lfs -text
5287
+ 2024/Semantic[[:space:]]Flow_[[:space:]]Learning[[:space:]]Semantic[[:space:]]Fields[[:space:]]of[[:space:]]Dynamic[[:space:]]Scenes[[:space:]]from[[:space:]]Monocular[[:space:]]Videos/57f8af69-2118-4d66-a8bc-588c2925e782_origin.pdf filter=lfs diff=lfs merge=lfs -text
2024/SALMONN_ Towards Generic Hearing Abilities for Large Language Models/53cff767-5ca4-4ca6-a888-059c218f3649_content_list.json ADDED
The diff for this file is too large to render. See raw diff
 
2024/SALMONN_ Towards Generic Hearing Abilities for Large Language Models/53cff767-5ca4-4ca6-a888-059c218f3649_model.json ADDED
The diff for this file is too large to render. See raw diff
 
2024/SALMONN_ Towards Generic Hearing Abilities for Large Language Models/53cff767-5ca4-4ca6-a888-059c218f3649_origin.pdf ADDED
@@ -0,0 +1,3 @@
 
 
 
 
1
+ version https://git-lfs.github.com/spec/v1
2
+ oid sha256:0edd2c5419ec687c6f67d307cae8721d13c9e6dc0773b8f6b1d99636a73ef46f
3
+ size 1477641
2024/SALMONN_ Towards Generic Hearing Abilities for Large Language Models/full.md ADDED
@@ -0,0 +1,711 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ # SALMONN: TOWARDS GENERIC HEARING ABILITIES FOR LARGE LANGUAGE MODELS
2
+
3
+ Changli Tang $^{1*}$ , Wenyi Yu $^{1*}$ , Guangzhi Sun $^{1}$ , Xianzhao Chen $^{2}$ , Tian Tan $^{2}$
4
+
5
+ Wei Li $^{2}$ , Lu Lu $^{2}$ , Zejun Ma $^{2}$ , Chao Zhang $^{1\dagger}$
6
+
7
+ Department of Electronic Engineering, Tsinghua University<sup>1</sup>
8
+
9
+ ByteDance2
10
+
11
+ {tcl20,ywy22}@mails.tsinghua.edu.cn, cz277@tsinghua.edu.cn
12
+
13
+ # ABSTRACT
14
+
15
+ Hearing is arguably an essential ability of artificial intelligence (AI) agents in the physical world, which refers to the perception and understanding of general auditory information consisting of at least three types of sounds: speech, audio events, and music. In this paper, we propose SALMONN, a speech audio language music open neural network, built by integrating a pre-trained text-based large language model (LLM) with speech and audio encoders into a single multimodal model. SALMONN enables the LLM to directly process and understand general audio inputs and achieve competitive performances on a number of speech and audio tasks used in training, such as automatic speech recognition and translation, auditory-information-based question answering, emotion recognition, speaker verification, and music and audio captioning etc. SALMONN also has a diverse set of emergent abilities unseen in the training, which includes but is not limited to speech translation to untrained languages, speech-based slot filling, spoken-query-based question answering, audio-based storytelling, and speech audio co-reasoning etc. The presence of cross-modal emergent abilities is studied, and a novel few-shot activation tuning approach is proposed to activate such abilities. To our knowledge, SALMONN is the first model of its type and can be regarded as a step towards AI with generic hearing abilities. The source code, model checkpoints and data are available at https://github.com/bytedance/SALMONN.
16
+
17
+ # 1 INTRODUCTION
18
+
19
+ Text-based large language models (LLMs) (Brown et al., 2020; Touvron et al., 2023; Chiang et al., 2023; Anil et al., 2023; Du et al., 2022) have demonstrated remarkable and even human-level performance in many natural language processing (NLP) tasks (OpenAI, 2023). Meanwhile, instruction tuning (Wei et al., 2022a; Chung et al., 2022; Ouyang et al., 2022; Peng et al., 2023), where data is organised as pairs of user instruction (or prompt) and reference response, has emerged as an LLM training paradigm that allows LLMs to follow open-ended user instructions. There is a burgeoning research interest in empowering LLMs with multimodal perception abilities. Recent studies focus on connecting LLMs with either the encoder of one additional type of input, such as image (Li et al., 2023a; Alayrac et al., 2022; Dai et al., 2023), silent video (Maaz et al., 2023; Chen et al., 2023b; Zhao et al., 2022), audio events (Gong et al., 2023b; Lyu et al., 2023) or speech (Chen et al., 2023a), or the encoders of multiple input types together (Su et al., 2023; Zhang et al., 2023b). A connection module and LLM adaptors can be used to align the encoder output spaces with the LLM input space, which are often trained by cross-modal pre-training and instruction tuning.
20
+
21
+ In this paper, we propose a speech audio language music open neural network (SALMONN), which is a single audio-text multimodal LLM that can perceive and understand three basic types of sounds including speech, audio events, and music. To enhance the performance on both speech and non-speech audio tasks, SALMONN uses a dual encoder structure consisting of a speech encoder from the Whisper speech model (Radford et al., 2023) and a BEATs audio encoder (Chen et al., 2023c). A
22
+
23
+ window-level query Transformer (Q-Former) (Li et al., 2023a) is used as the connection module to convert a variable-length encoder output sequence to a variable number of augmented audio tokens input to the Vicuna LLM (Chiang et al., 2023) and can achieve audio-text alignment with high temporal resolution. The low-rank adaptation (LoRA) approach (Hu et al., 2022) is applied to Vicuna as a cross-modal adaptor to align Vicuna's augmented input space with its output space and further improve its performance. A number of speech, audio, and music tasks are used in the cross-modal pre-training and instruction tuning stages of the window-level Q-Former and LoRA. The resulting multimodal LLMs can be confined to the specific types of tasks used in instruction tuning, particularly speech recognition and audio captioning, and exhibit limited or no cross-modal emergent abilities, which we refer to as the task over-fitting issue. In this paper, cross-modal emergent abilities refer to the abilities to perform cross-modal tasks unseen in training, which are essentially the emergent abilities of LLMs (Wei et al., 2022b) that are lost during instruction tuning. As a solution, we propose an extra few-shot activation tuning stage so that SALMONN regains the emergent abilities of LLMs and alleviates the considerable catastrophic forgetting to the trained tasks.
24
+
25
+ In order to evaluate SALMONN's cognitive hearing abilities, a wide range of speech, audio events, and music benchmarks are used. The tasks can be divided into three levels. The first level benchmarks eight tasks that are trained in instruction tuning, such as speech recognition, translation and audio captioning, while the other two levels benchmark untrained tasks. The second level includes five speech-based NLP tasks, such as translation to untrained languages and slot filling, which relies on multilingual and high-quality alignments between speech and text tokens. The last level of tasks, including audio-based storytelling and speech audio co-reasoning etc, requires understanding not only speech but also non-speech auditory information. Experimental results show that SALMONN as a single model can perform all these tasks and achieve competitive performance on standard benchmarks, which reveals the feasibility of building artificial intelligence (AI) that can "hear" and understand general audio inputs consisting of mixtures of speech, audio events, and music.
26
+
27
+ The main contribution of this paper can be summarised as follows.
28
+
29
+ - We propose SALMONN, the first multimodal LLM that can perceive and understand general audio inputs with speech, audio events, and music, to the best of our knowledge.
30
+ - We study the presence of cross-modal emergent abilities by playing with the LoRA scaling factor, and propose a cheap activation tuning method as an extra training stage that can activate the cross-modal emergent abilities and alleviate catastrophic forgetting to tasks seen in training.
31
+ - We evaluate SALMONN on a range of tasks reflecting a degree of generic hearing abilities, and propose two novel tasks, audio-based storytelling and speech audio co-reasoning.
32
+
33
+ # 2 RELATED WORK
34
+
35
+ LLMs, as text-based dialogue models, have a fundamental connection with speech, and several studies have attempted to extend LLMs to support direct speech inputs with a connection module (Chen et al., 2023a; Wu et al., 2023; Fathullah et al., 2023; Yu et al., 2023; Huang et al., 2023a). To avoid the LLMs having overly long input speech token sequences caused by long-form speech inputs, different frame-rate reduction approaches have been developed, including stacking-based fixed-rate reduction approach (Fathullah et al., 2023; Yu et al., 2023), speech-recognition-based variable frame-rate reduction approach (Wu et al., 2023; Chen et al., 2023a), and Q-Former-based approach with a fixed number of output frames (Yu et al., 2023) etc. When LLM-based speech synthesis is also considered, the LLM output space can be augmented with speech tokens as well, such as SpeechGPT (Zhang et al., 2023a) and AudioPaLM (Rubenstein et al., 2023).
36
+
37
+ Unlike speech, audio event inputs are often treated as fixed-sized spectrogram images that can be processed using visual-language LLM methods without explicitly modelling temporal correlations (Gong et al., 2023a;b; Zhang et al., 2023b). These methods are therefore unable to handle speech. Although Lyu et al. (2023) uses the speech encoder from the Whisper model, only audio event inputs are supported, which indicates the difficulty of the joint modelling of speech and audio events. Without using LLMs, Narisetty et al. (2022) studies achieving speech recognition and audio captioning separately using the same model. Regarding music inputs, Liu et al. (2023) integrates the MERT music encoder (Li et al., 2023b) with an LLM for music understanding tasks. AudioGPT allows a text-based LLM to process speech, audio events, and music by interacting with other models in
38
+
39
+ a pipeline based on a set of pre-defined tasks (Huang et al., 2023b). Compared with AudioGPT, SALMONN is an end-to-end model with cross-modal emergent abilities for open-ended tasks.
40
+
41
+ In addition to audio, multimodal LLMs are more widely studied in visual modalities, such as image (Zhu et al., 2023; Li et al., 2023a), video (Maaz et al., 2023; Chen et al., 2023b) and audio-visual (Su et al., 2023; Lyu et al., 2023; Sun et al., 2023). Modality alignment in those models is often achieved via either a fully connected layer or an attention-based module. In particular, the Q-Former structure (Li et al., 2023a) used by SALMONN is commonly applied to visual modalities, such as in MiniGPT-4 (Zhu et al., 2023), InstructBLIP (Dai et al., 2023), Video-LLaMA (Zhang et al., 2023b).
42
+
43
+ # 3 METHODOLOGY
44
+
45
+ The model architecture of SALMONN is introduced in Section 3.1. Our training method is presented in Section 3.2, which includes the pre-training and fine-tuning stages, and the proposed activation tuning stage as a solution to the task over-fitting issue.
46
+
47
+ # 3.1 MODEL ARCHITECTURE
48
+
49
+ The model architecture of SALMONN is shown in Fig. 1. The output features of the two complementary auditory encoders are synchronised and combined. Q-Former is used as the connection module and applied at the frame level, whose output sequence is integrated with the text instruction prompt and fed into the LLM with LoRA adaptors to generate the text response.
50
+
51
+ Dual Auditory Encoders: A speech encoder from OpenAI's Whisper model (Radford et al., 2023) and a non-speech BEATs audio encoder (Chen et al., 2023c) are used. The Whisper model is trained for speech recognition and translation based on a large amount of weakly supervised data, whose encoder output features are suitable to model speech and include information about the background noises (Gong et al., 2023a). BEATs is trained to extract high-level non-speech audio semantics information using iterative self-supervised learning. The input audio is first tokenised then masked and predicted in training. The tokeniser is updated by distilling the semantic knowledge of the audio tokens (Chen et al., 2023c). Therefore, the resulting auditory features of these two encoders are complementary and suitable for general audio inputs with both speech and non-speech information.
52
+
53
+ Since both encoders have the same output frame rate of $50\mathrm{Hz}$ , the concatenated output features are
54
+
55
+ $$
56
+ \mathbf {Z} = \operatorname {C o n c a t} \left(\operatorname {E n c o d e r} _ {\text {w h i s p e r}} (\mathbf {X}), \operatorname {E n c o d e r} _ {\text {b e a t s}} (\mathbf {X})\right), \tag {1}
57
+ $$
58
+
59
+ where $\mathbf{X}$ is a variable-length general audio input sequence, $\mathrm{Encoder}_{\mathrm{whisper}}(\cdot)$ and $\mathrm{Encoder_{beats}}(\cdot)$ are the Whisper and BEATs encoder, $\mathrm{Concat}(\cdot)$ is the frame-by-frame concatenation operation along the feature dimension, $\mathbf{Z}$ is the concatenated encoder output sequence with $T$ frames.
60
+
61
+ Window-level Q-Former: The Q-Former structure is commonly used to convert the output of an image encoder into a fixed number of textual input tokens of an LLM (Li et al., 2023a), which requires modification when applied to handle audio inputs of variable lengths. Specifically, regarding the encoder output of an input image $l$ as a $\mathbf{Z}_l$ , Q-Former employs a fixed number of $N$ trainable queries $\mathbf{Q}$ to transform $\mathbf{Z}_l$ into $N$ textual tokens $\mathbf{H}_l$ using a number of stacked Q-Former blocks. A Q-Former block is similar to a Transformer decoder block (Vaswani et al., 2017), apart from the use of a fixed number of trainable static queries $\mathbf{Q}$ in the first block and the removal of the causal masks from the self-attention layers. In this way, Q-Former allows the queries in $\mathbf{Q}$ to refer to each other first using a self-attention layer and then interact with $\mathbf{Z}_l$ using cross-attention layers.
62
+
63
+ Regarding a variable-length general audio input with $\mathbf{Z} = [\mathbf{Z}_t]_{t=1}^T$ , by segmenting $\mathbf{Z}$ into $L$ -sized windows and padding the last window with zeros, it becomes $[\{\mathbf{Z}_t\}_{t=(l-1)\times L+1}]_{l=1}^{[T/L]}$ , instead of using Q-Former at the sequence level to convert the entire $\mathbf{Z}$ into $N$ textual tokens, SALMONN uses Q-Former at the window level as if the encoder output frames stacked in each window were an image. As a result, the textual token sequence $\mathbf{H}$ becomes
64
+
65
+ $$
66
+ \left[ \mathbf {H} _ {l} \right] _ {l = 1} ^ {\left[ T / L \right]} = \left[ \mathbf {Q} - \operatorname {F o r m e r} \left(\mathbf {Q}, \mathbf {Z} _ {l}\right) \right] _ {l = 1} ^ {\left[ T / L \right]}, \tag {2}
67
+ $$
68
+
69
+ where $\mathrm{Q - Former}(\cdot)$ is the Q-Former function and $\mathbf{H}$ has $\lceil T / L\rceil \times N$ textual tokens. The window-level Q-Former uses a variable number of textual tokens and is more efficient for variable-length
70
+
71
+ ![](images/c48b59ef81a44a4c525993c15d3a405f2ee57c0a6aff05e08eb9844aebb566a4.jpg)
72
+ Figure 1: The model architecture of SALMONN. A window-level Q-Former is used as the connection module to fuse the outputs from a Whisper speech encoder and a BEATs audio encoder as augmented audio tokens, which are aligned with the LLM input space. The LoRA adaptor aligns the augmented LLM input space with its output space. The text prompt is used to instruct SALMONN to answer open-ended questions about the general audio inputs and the answers are in the LLM text responses. The LLM and encoders are kept frozen while the rest can be updated in training.
73
+
74
+ sequences. In addition, $\mathbf{H}$ is enforced to have a monotonic alignment with $\mathbf{Z}$ , resulting in better temporal resolution which is important for speech recognition.
75
+
76
+ LLM and LoRA: A pre-trained Vicuna LLM is used in this work (Chiang et al., 2023) which is a LLaMA LLM (Touvron et al., 2023) fine-tuned to follow instructions. LoRA (Hu et al., 2022) is a widely used parameter-efficient fine-tuning method for LLM adaptation, which is used in SALMONN to adapt the query and value weight matrices in the self-attention layers of Vicuna. In this work, LoRA is trainable while Vicuna is not.
77
+
78
+ # 3.2 TRAINING METHOD
79
+
80
+ A three-stage cross-modal training method of SALMONN is introduced in this section. Besides the pre-training and instruction tuning stages used by recent visual LLMs (Dai et al., 2023; Zhang et al., 2023b), an additional activation tuning stage is proposed to resolve the issue of over-fitting to the speech recognition and audio captioning tasks in instruction tuning.
81
+
82
+ Pre-training Stage: To mitigate the gap between the pre-trained parameters (LLM and encoders) and the randomly initialised parameters (connection module and adaptor), a large amount of speech recognition and audio captioning data is used to pre-train the window-level Q-Former and LoRA. These two tasks contain key auditory information about the contents of speech and non-speech audio events, and both do not require complex reasoning and understanding and therefore can help SALMONN to learn high-quality alignment between the auditory and textual information.
83
+
84
+ Instruction Tuning Stage: Similar to NLP (Wei et al., 2022a) and visual-language (Dai et al., 2023), audio-text instruction tuning with a list of supervised speech, audio event, and music tasks, as shown in Section 4.2 and Table 1, is used as the second stage of SALMONN training. The tasks are selected based on their importance (e.g. speech recognition and audio captioning) and the indispensability of having such ability in tests (e.g. overlapping speech recognition, phone recognition and music captioning). The instruction prompts are generated based on the texts paired with the audio data.
85
+
86
+ Task Over-fitting: Although SALMONN built with only the first two stages of training can produce competitive results on the tasks trained in instruction tuning, it exhibits limited or almost no ability to perform untrained cross-modal tasks, especially the tasks that require cross-modal co-reasoning abilities. In particular, the model sometimes violates the instruction prompts and generates irrelevant responses as if it received an instruction related to a task commonly seen in training (e.g. speech
87
+
88
+ recognition). We refer to this phenomenon as task over-fitting. A theoretical analysis of the issue is presented here and detailed experimental verification is provided in Sections 5.3 and 5.4.
89
+
90
+ We attribute task over-fitting to two reasons. First, compared to the text-only data used in LLM training, only simpler instruction prompts are used in our cross-modal instruction tuning (Wei et al., 2022a) and the resulting responses are not as complex and diverse. Meanwhile, some tasks included in instruction tuning, in particular speech recognition and audio captioning, have more deterministic outputs than the other tasks, such as speech and audio question answering. These two reasons combined to cause the intrinsic conditional language model (LM) to bias to an ill-formed distribution with poor generalisation ability, which prohibits SALMONN from performing untrained cross-modal tasks. More specifically, at test time the response text sequence $\hat{\mathbf{Y}}$ of a test input $\mathbf{X}$ given a new instruction prompt $\mathbf{I}$ can be generated according to $\hat{\mathbf{Y}} = \arg \max_{\mathbf{Y}} P_{\Lambda}(\mathbf{Y}|\mathbf{X},\mathbf{I})$ , which is also the objective to maximise in training. Using the Bayes' Rule, there is
91
+
92
+ $$
93
+ P _ {\boldsymbol {\Lambda}} (\mathbf {Y} | \mathbf {X}, \mathbf {I}) = P _ {\boldsymbol {\Lambda}} (\mathbf {Y} | \mathbf {X}) \cdot P _ {\boldsymbol {\Lambda}} (\mathbf {I} | \mathbf {Y}, \mathbf {X}) / P _ {\boldsymbol {\Lambda}} (\mathbf {I} | \mathbf {X}). \tag {3}
94
+ $$
95
+
96
+ Since only limited text responses are seen in SALMONN training, the intrinsic conditional LM $P_{\Lambda}(\mathbf{Y}|\mathbf{X})$ is biased towards the $\mathbf{Y}$ sequences that are strongly-aligned with $\mathbf{X}$ , such as the transcriptions of automatic speech recognition (ASR) and automatic audio captioning (AAC) tasks, especially simple and short transcriptions. From Eqn. (3), this causes $\mathbf{I}'$ , zero-shot instructions with more diverse responses, to have small $P_{\Lambda}(\mathbf{Y}|\mathbf{X},\mathbf{I}')$ .
97
+
98
+ Activation Tuning Stage: An effective approach to alleviating task over-fitting is to regularise the intrinsic conditional LM $P_{\Lambda}(\mathbf{Y}|\mathbf{X})$ . An easy way to achieve this is to fine-tune SALMONN on tasks with longer and more diverse responses, such as auditory-information-based question answering and storytelling. Paired training data for such tasks can be generated based on the text paired with speech recognition or audio and music caption data, either manually by human annotators or automatically by prompting a text-based LLM.
99
+
100
+ We use an efficient approach that can enable SALMONN to generate long and diverse responses for zero-shot instructions by simply reducing the scaling factor of the LoRA adaptor. This is an alternative way to regularise $P_{\Lambda}(\mathbf{Y}|\mathbf{X})$ since the intrinsic conditional LM can only be learned with the window-level Q-Former and LoRA, since they are the only modules that are updated in training. The effect of reducing the LoRA scaling factor can be found in Section 5.2, which can indeed activate question-answering and storytelling abilities and produce long and diversified responses but also considerably degrade the results on the trained tasks. To retain competitive results while restoring the cross-modal emergent abilities, we propose to use the responses generated by SALMONN with a discounted LoRA scaling factor to perform the third stage of fine-tuning termed activation tuning. Experimental results showed later in Section 5.4 demonstrate that activation tuning is an efficient and effective few-shot self-supervised training approach.
101
+
102
+ # 4 EXPERIMENTAL SETUP
103
+
104
+ # 4.1 MODEL SPECIFICATIONS
105
+
106
+ SALMONN uses the encoder part of Whisper-Large-v2 (Radford et al., 2023) model as the speech encoder, the fine-tuned BEATs (Chen et al., 2023c) encoder as the audio encoder, and a Vicuna LLM with 13 billion parameters (Chiang et al., 2023) as the backbone LLM. For the window-level Q-Former, we use $N = 1$ resulting in only one trainable query, and use $L = 17$ which is approximately 0.33 seconds per window. This leads to 88 textual tokens output by Q-Former for a 30-second audio. Regarding the hyper-parameters of LoRA (Hu et al., 2022), we set the rank to 8 and the scaling factor to 4.0. Only the parameters of Q-Former and LoRA are updated in training, which resulted in $\sim 33$ million (M) parameters that is $\sim 0.24\%$ of the entire SALMONN model.
107
+
108
+ # 4.2 DATA SPECIFICATIONS
109
+
110
+ The three-stage training proposed in Section 3.2 is used. The data used for the first pre-training stage consists of both 960-hour LibriSpeech training set (Panayotov et al., 2015) and 1000-hour GigaSpeech M-set (Chen et al., 2021) for speech recognition, as well as 2800-hour WavCaps (Mei et al., 2023) (with audio clips longer than 180 seconds removed), AudioCaps (Kim et al., 2019) and Clotho (Drossos et al., 2020) datasets for audio captioning.
111
+
112
+ The second instruction tuning stage involves multiple tasks, including ASR, automatic speech translation (AST), AAC, phone recognition (PR), emotion recognition (ER), music captioning (MC), overlapped speech recognition (OSR), speaker verification (SV), gender recognition (GR) and speech question answering (SQA), audio question answering (AQA) and music question answering (MQA). In the SQA, AQA and MQA tasks, the questions are generated based on the text caption labels using ChatGPT, and the model needs to provide answers based on the general audio input and the text prompt with a question. The data used in this stage is listed in Table 1, where "En2Zh" refers to AST from English to Chinese.
113
+
114
+ For the final activation tuning stage, twelve stories were written based on the audio clips by SALMONN with a reduced LoRA. Then the model is trained using teacher-forcing-based cross-entropy training for 12 steps, with each step using only one story sample, when activating the cross-modal emergent abilities of SALMONN.
115
+
116
+ Table 1: Training data used in the cross-modal instruction tuning stage.
117
+
118
+ <table><tr><td>Task</td><td>Data Source</td><td>#Hours</td><td>#Samples</td></tr><tr><td>ASR</td><td>LibriSpeech + GigaSpeech</td><td>960 + 220</td><td>280K + 200K</td></tr><tr><td>En2Zh</td><td>CoVoST2-En2Zh (Wang et al., 2021)</td><td>430</td><td>290K</td></tr><tr><td>AAC</td><td>AudioCaps + Clotho</td><td>130 + 24</td><td>48K + 4K</td></tr><tr><td>PR</td><td>LibriSpeech</td><td>960</td><td>280K</td></tr><tr><td>ER</td><td>IEMOCAP Session 1-4 (Busso et al., 2008)</td><td>5</td><td>4K</td></tr><tr><td>MC</td><td>MusicCaps (Agostinelli et al., 2023)</td><td>14</td><td>3K</td></tr><tr><td>OSR</td><td>LibriMix (Cosentino et al., 2020)</td><td>260</td><td>64K</td></tr><tr><td>SV</td><td>VoxCeleb1 (Nagrani et al., 2019)</td><td>1200</td><td>520K</td></tr><tr><td>GR</td><td>LibriSpeech</td><td>100</td><td>28K</td></tr><tr><td>SQA</td><td>LibriSpeech</td><td>960</td><td>280K</td></tr><tr><td>AQA</td><td>WavCaps + AudioCaps</td><td>760 + 130</td><td>270K + 48K</td></tr><tr><td>MQA</td><td>MillionSong¹ + MusicNet (Thickstun et al., 2017)</td><td>400 + 3</td><td>48K + 0.3K</td></tr><tr><td>Total</td><td>-</td><td>~4400</td><td>~2.3M</td></tr></table>
119
+
120
+ # 4.3 TASK SPECIFICATIONS
121
+
122
+ Since text LLMs have the abilities of zero-shot learning via instruction tuning (Wei et al., 2022a), the emergence of such abilities is expected when high-quality cross-modal alignment is achieved when connecting the backbone text-based LLM with multimodal encoders. To evaluate the zero-shot cross-modal emergent abilities of SALMONN, 15 types of speech, audio, and music tasks are selected and divided into three different levels.
123
+
124
+ Task level 1 consists of the tasks used in instruction tuning and are therefore easiest for SALMONN to perform. The list of such tasks and their training data are given in Section 4.2, and the evaluation metrics for each task are presented in Table 2.
125
+
126
+ Task level 2 includes untrained tasks and is therefore more difficult than level 1. The level 2 tasks are speech-based NLP tasks including speech keyword extracting (KE), which evaluates the accuracy of the keywords extracted based on the speech content; spoken-query-based question answering (SQQA), which evaluates the common sense knowledge retrieved based on the question in speech; speech-based slot filling (SF) that evaluates the accuracy of the required slot values, usually named entities, obtained from the speech content. Two AST tasks, En2De (English to German) and En2Ja (English to Japanese) are also included, which are also considered as cross-modal emergent abilities since only En2Zh is trained in instruction tuning. Vicuna, the backbone LLM of SALMONN, can perform all level 2 tasks based on speech transcriptions. Therefore, SALMONN is to achieve such tasks based on speech in a fully end-to-end way without requiring any explicit speech recognition.
127
+
128
+ Task level 3 has the most difficult tasks including audio-based storytelling (Story) and speech audio co-reasoning (SAC). Audio-based storytelling is to write a meaningful story based on the auditory information from the general audio inputs. SAC requires the model to understand a spoken question embedded in the input audio clip, find evidence from the background audio events or music, and
129
+
130
+ reason from it to answer the question. Both level 3 tasks are new tasks that are first proposed in this paper, to the best of our knowledge, which requires SALMONN to perceive speech, audio, and music, and to understand and reason based on the auditory information in a fully end-to-end way.
131
+
132
+ Table 2 lists all test sets and their evaluation metrics. Following rate (FR) is an extra metric used for some level 2 and level 3 tasks, which measures the percentage that SALMONN can successfully follow the instructions. FR is considered since the selected tasks are complex and easier to suffer from the violation of instructions caused by task over-fitting. It is worth noting that we only calculate the diversity metric of the Story task by counting the number of different words in the story, which simply represents the richness of the story instead of the quality.
133
+
134
+ Table 2: Test sets, metrics, and sources of the reference values used in the three levels of tasks. The speech data used in SQQA and KE are synthesised using a commercial text-to-speech product. For reference values: "Whisper" refers to using Whisper-Large-v2 for ASR, "Whisper + Vicuna" refers to feeding the Whisper-Large-v2 ASR output transcriptions into Vicuna, and the rest are the state-of-the-art results to the best of our knowledge.
135
+
136
+ <table><tr><td>Task</td><td>Test Data</td><td>Eval Metrics</td><td>Reference Value</td></tr><tr><td>ASR</td><td>LibriSpeech test-clean/-other,</td><td>%WER</td><td>Whisper</td></tr><tr><td>ASR</td><td>GigaSpeech test</td><td>%WER</td><td>Whisper</td></tr><tr><td>En2Zh</td><td>CoVoST2-En2Zh</td><td>BLEU4</td><td>(Wang et al., 2021)</td></tr><tr><td>AAC</td><td>AudioCaps</td><td>METEOR | SPIDER</td><td>(Mei et al., 2023)</td></tr><tr><td>PR</td><td>LibriSpeech test-clean</td><td>%PER</td><td>WavLM (Chen et al., 2022)</td></tr><tr><td>ER</td><td>IEMOCAP Session 5</td><td>Accuracy</td><td>(Wu et al., 2021)</td></tr><tr><td>MC</td><td>MusicCaps</td><td>BLEU4, RougeL</td><td>(Doh et al., 2023)</td></tr><tr><td>OSR</td><td>LibriMix</td><td>%WER</td><td>(Huang et al., 2023c)</td></tr><tr><td>SV</td><td>Voxceleb1</td><td>Accuracy</td><td>-</td></tr><tr><td>En2De</td><td>CoVoST2-En2De</td><td>BLEU4</td><td>Whisper + Vicuna</td></tr><tr><td>En2Ja</td><td>CoVoST2-En2Ja</td><td>BLEU4</td><td>Whisper + Vicuna</td></tr><tr><td>KE</td><td>Inspec (Hulth, 2003)</td><td>Accuracy</td><td>Whisper + Vicuna</td></tr><tr><td>SQQA</td><td>WikiQA (Yang et al., 2015)</td><td>Accuracy (FR)</td><td>Whisper + Vicuna</td></tr><tr><td>SF</td><td>SLURP (Bastianelli et al., 2020)</td><td>Accuracy (FR)</td><td>Whisper + Vicuna</td></tr><tr><td>Story</td><td>AudioCaps</td><td>Diversity (FR)</td><td>-</td></tr><tr><td>SAC</td><td>In-house Data</td><td>Accuracy (FR)</td><td>-</td></tr></table>
137
+
138
+ # 5 EXPERIMENTAL RESULTS
139
+
140
+ # 5.1 FULL RESULTS ON ALL 15 TASKS
141
+
142
+ The results on all 15 tasks produced by SALMONN are shown in Table 3. From the results, SALMONN, without or with activation tuning, can produce competitive results on all level 1 tasks. However, the model without activation tuning suffers severely from task over-fitting and can barely perform level 2 and level 3 tasks. In particular, in SQQA, Story, and SAC, where multimodal interactions are emphasised, SALMONN without activation tuning can hardly follow the instructions. The FRs of performing SQQA, SF, Story and SAC tasks improve considerably with activation tuning.
143
+
144
+ Fig. 2 illustrates the trends of model performance change on ASR & PR, SQQA, Story, and SAC at different training steps of activation tuning, which reveals that activation tuning only needs a few training samples and steps to activate the emergent abilities: the results of ASR and PR remain almost unchanged, while the results of SQQA, Story and SAC have an emergent trend.
145
+
146
+ More detailed analysis about the results are discussed in Appendix B due to page limit.
147
+
148
+ # 5.2 DISCOUNTING LORA SCALING FACTOR
149
+
150
+ This section explores the influence of the use of test-time discounting of the LoRA scaling factor for alleviating the task over-fitting issue without activation tuning. As shown in Fig. 3, when the LoRA scaling factor decreases to around 2.0, i.e. to half of its original value, the model suddenly emerges
151
+
152
+ Table 3: Results of all 15 tasks produced by SALMONN without & with activation tuning (w/o & w/ Activation). The ASR results are presented in a tuple with three the %WERs evaluated on 3 test sets, namely (LibriSpeech test-clean, LibriSpeech test-other, GigaSpeech).
153
+
154
+ <table><tr><td>Method</td><td>ASR↓</td><td>En2Zh↑</td><td>AAC↑</td><td>PR↓</td><td>ER↑</td><td>MC↑</td><td>OSR↓</td><td>SV↑</td></tr><tr><td>w/o Activation</td><td>(2.1, 4.9, 9.1)</td><td>34.4</td><td>25.6</td><td>47.6</td><td>4.2</td><td>0.63</td><td>3.5, 22.1</td><td>20.7</td></tr><tr><td>w/ Activation</td><td>(2.1, 4.9, 10.0)</td><td>33.1</td><td>24.0</td><td>40.3</td><td>4.2</td><td>0.69</td><td>5.5, 21.8</td><td>23.0</td></tr><tr><td>Reference Value</td><td>(2.2, 5.1, 9.2)</td><td>38.9</td><td>25.0</td><td>48.5</td><td>3.1</td><td>0.81</td><td>6.1, 21.5</td><td>7.6</td></tr></table>
155
+
156
+ (a) Results of the level 1 tasks.
157
+
158
+ <table><tr><td>Method</td><td>En2De↑</td><td>En2Ja↑</td><td>KE↑</td><td>SQQA↑</td><td>SF↑</td><td>Story↑</td><td>SAC↑</td></tr><tr><td>w/o Activation</td><td>19.7</td><td>22.0</td><td>0.30</td><td>0.19 (0.29)</td><td>0.33 (0.77)</td><td>7.77 (0.00)</td><td>0.02 (0.04)</td></tr><tr><td>w/ Activation</td><td>18.6</td><td>22.7</td><td>0.32</td><td>0.41 (0.98)</td><td>0.41 (0.99)</td><td>82.57 (1.00)</td><td>0.50 (0.73)</td></tr><tr><td>Reference Value</td><td>16.5</td><td>15.6</td><td>0.31</td><td>0.77 (1.00)</td><td>0.46 (1.00)</td><td>-</td><td>-</td></tr></table>
159
+
160
+ (b) Results of the level 2 and level 3 tasks.
161
+
162
+ ![](images/d551cac1ef50feb821f4035c6fe94dfd0ef61e0c2cdb1dfac9106024e4760186.jpg)
163
+ (a)
164
+
165
+ ![](images/b8467bf0d78d369e7378445b051811a4b76643d07051cb202d14694d8dcba8dd.jpg)
166
+ (c)
167
+ Figure 2: Performance changes on ASR & PR (a), SQQA (b), Story (c) and SAC (d) along with the FR of the emergent abilities against the number of training steps during activation tuning.
168
+
169
+ with cross-modal reasoning abilities, which, together with the drops in $\% \mathrm{PER}$ , proves the existence of the intrinsic conditional LM embedded in LoRA.
170
+
171
+ ![](images/7ec23d658d7ea77dde30cc5d3db6eb93b8bfccae2fd903d31409336f440da3d0.jpg)
172
+ (a)
173
+
174
+ ![](images/06f700f16dc91ea8d879a291f1c59847cffcc8cc99c7051935fa13f5025497e9.jpg)
175
+ (b)
176
+
177
+ ![](images/238a866fb57cfc509d63eca1fb7fbb03afd9023030cf73fd1f95ba0fe76439df.jpg)
178
+ (c)
179
+ Figure 3: Performance changes on ASR & PR (a), SQQA (b), Story (c) and SAC (d) together with the FR of the emergent abilities when discounting the LoRA scaling factor at test time.
180
+
181
+ ![](images/c40edf078cb472f1692af0fda5328408a6e548a319702f26dc8c3961efe146cf.jpg)
182
+ (d)
183
+
184
+ # 5.3 ANALYSIS OF TASK OVER-FITTING AND ACTIVATION TUNING
185
+
186
+ To verify the influences of the intrinsic conditional LM, we calculate the perplexities (PPLs) of $P_{\Lambda}(\mathbf{Y}|\mathbf{X},\mathbf{I})$ and $P_{\Lambda}(\mathbf{Y}|\mathbf{X})$ of each step of the activation tuning stage. In detail, for a given audio $\mathbf{X}$ , the probability of the $\mathbf{Y}$ sequence corresponding to the probed task is calculated using teacher forcing based on the text instruction prompt $\mathbf{I}$ of a certain task or without using any $\mathbf{I}$ .
187
+
188
+ As shown in Fig. 4, PPLs were compared between the ground-truth responses of the task of Story/SAC (generated by discounting the LoRA scaling factor) and the responses of the task that the model performed incorrectly due to task over-fitting (AAC in this example). In sub-figures (a) and (b), no text instruction prompt was used when computing $P_{\Lambda}(\mathbf{Y}|\mathbf{X})$ , showing that without activation tuning the PPL of the $\mathbf{Y}$ of AAC was obviously lower than that of the $\mathbf{Y}$ of Story/SAC. During activation tuning, the PPL gaps between these tasks were mitigated, meaning the bias to the dominant AAC task was considerably reduced. In sub-figures (c) and (d), we probed $P_{\Lambda}(\mathbf{Y}|\mathbf{X},\mathbf{I})$ , the PPLs with the instructions of Story and SAC respectively. It is revealed that before activation tuning, the PPL of AAC is lower than that of Story/SAC even if the text instruction prompt is to perform Story/SAC, which explains the failure of the model to follow the instruction. During activation
189
+
190
+ tuning, the PPL values of the $\mathbf{Y}$ of Story/SAC gradually become lower than those of AAC, and the model can eventually perform the instructed task.
191
+
192
+ ![](images/6f805a6ad46f94e457ff6cbb5a835ca9cddbce12a46c9918bc39fb083d5b1f75.jpg)
193
+ (a)
194
+
195
+ ![](images/b60a176217c6cde926530b239b313d0eba33cbd1faf7cc1fa3d6a96bf6522b6f.jpg)
196
+ (b)
197
+ Figure 4: Changes in PPL during the activation tuning stage. (a) shows - $\ln P_{\Lambda}(\mathbf{Y}|\mathbf{X})$ for AAC and Story, (b) shows - $\ln P_{\Lambda}(\mathbf{Y}|\mathbf{X})$ for AAC and SAC, (c) shows - $\ln P_{\Lambda}(\mathbf{Y}|\mathbf{X},\mathbf{I} = \mathbf{Story})$ , and (d) shows - $\ln P_{\Lambda}(\mathbf{Y}|\mathbf{X},\mathbf{I} = \mathbf{SAC})$ .
198
+
199
+ ![](images/eba1a51d8cee7a1560b675878ee0bce94e55743bcea0fdda8857336baff7d12e.jpg)
200
+ (c)
201
+
202
+ ![](images/fffc32c0e0a0cfc96385f6e5533791a3610d38311f8874420af984b94d03527e.jpg)
203
+ (d)
204
+
205
+ # 5.4 ACTIVATION TUNING USING DIFFERENT TASKS AND DATA
206
+
207
+ We have explored several activation methods to activate the model, including training on long stories written based on the audio, text-based question-answering (QA) task pairs with long answers, and the ASR task with long speech transcriptions. Both LoRA and Q-Former are fine-tuned with these three methods. By ignoring the Q-Former and audio inputs, Vicuna and LoRA are fine-tuned as an adapted text-based LLM. As another control group, the experiment of using both LoRA and Q-Former but without tuning the Q-Former is also conducted.
208
+
209
+ The results are shown in Table 4. From the results, neither ASR (Long), training ASR with long labels, nor Story (Text based), training LoRA based on only text prompt input, can activate the model. Training with stories or QA with long answers, Story or QA (Long), can. This lies in the fact that the ASR task emphasises improving high-quality cross-modal alignments that make the distribution even more biased towards the intrinsic conditional LM. As for text-based fine-tuning on stories, this actually affects $P(\mathbf{Y}|\mathbf{T}_{\mathbf{x}},\mathbf{I})$ instead of $P(\mathbf{Y}|\mathbf{X},\mathbf{I})$ , where $\mathbf{T}_{\mathbf{x}}$ is the reference text of the speech. Therefore, text-based training cannot alleviate task over-fitting. QA data with long answers can activate the LLM, but the performance of the activated model is worse than that activated using the Story task, which especially results in a higher repeat rate of the response generation. That is possibly due to the fact that the paired answer to the QA task is less diverse than the Story task, which leads to less effective regularisation of the intrinsic conditional LM $P_{\Lambda}(\mathbf{Y}|\mathbf{X})$ .
210
+
211
+ Table 4: Results of selected tasks with activation tuning performed based on different tasks. "Repeat Rate" is the percentage of test samples that SALMONN generated responses repeatedly.
212
+
213
+ <table><tr><td>Activation Method</td><td>ASR↓</td><td>PR↓</td><td>SQQA↑</td><td>Story↑</td><td>SAC↑</td><td>Repeat Rate↓</td></tr><tr><td>w/o Activation</td><td>2.1</td><td>4.2</td><td>0.19 (0.29)</td><td>7.77 (0.00)</td><td>0.02 (0.04)</td><td>0.2%</td></tr><tr><td>Story</td><td>2.1</td><td>4.2</td><td>0.41 (0.98)</td><td>82.57 (1.00)</td><td>0.50 (0.73)</td><td>0.1%</td></tr><tr><td>QA (Long)</td><td>2.1</td><td>4.3</td><td>0.40 (0.93)</td><td>59.82 (1.00)</td><td>0.34 (0.71)</td><td>4.6%</td></tr><tr><td>ASR (Long)</td><td>2.2</td><td>4.2</td><td>0.22 (0.28)</td><td>7.87 (0.00)</td><td>0.12 (0.03)</td><td>0.1%</td></tr><tr><td>Story (Text based)</td><td>2.1</td><td>4.2</td><td>0.23 (0.32)</td><td>8.45 (0.03)</td><td>0.11 (0.03)</td><td>0.1%</td></tr><tr><td>Story (LoRA only)</td><td>2.1</td><td>4.2</td><td>0.44 (0.96)</td><td>82.29 (1.00)</td><td>0.34 (0.65)</td><td>0.2%</td></tr></table>
214
+
215
+ # 6 CONCLUSION
216
+
217
+ This work proposes SALMONN, a speech audio language music open neural network that can be regarded as a step towards generic hearing abilities for LLMs. Equipped with dual auditory encoders, SALMONN achieved competitive performances on trained tasks including speech recognition, audio captioning and speech translation etc., while generalising to a range of untrained understanding tasks such as slot filling, speech translation for untrained languages and keyword extracting. Moreover, a proposed activation tuning stage enables SALMONN with remarkable emergent abilities, such as audio-based storytelling and speech audio co-reasoning. As a result, with thorough and comprehensive experimental evaluations, SALMONN has demonstrated a promising direction for developing generic hearing AI in the future.
218
+
219
+ # 7 REPRODUCIBILITY STATEMENT
220
+
221
+ To make the experiments and models reproducible, the training data and the benchmark details are provided in Section 4.2 and Section 4.3. The source code, model checkpoints, and data are released on the SALMONN project GitHub page.
222
+
223
+ # REFERENCES
224
+
225
+ Andrea Agostinelli, Timo I Denk, Zalán Borsos, Jesse Engel, Mauro Verzetti, Antoine Caillon, Qingqing Huang, Aren Jansen, Adam Roberts, Marco Tagliasacchi, et al. MusicLM: Generating music from text. arXiv:2301.11325, 2023.
226
+ Jean-Baptiste Alayrac, Jeff Donahue, Pauline Luc, Antoine Miech, Iain Barr, et al. Flamingo: a visual language model for few-shot learning. In Proc. NeurIPS, New Orleans, 2022.
227
+ Rohan Anil, Andrew M Dai, Orhan First, Melvin Johnson, Dmitry Lepikhin, Alexandre Passos, Siamak Shakeri, Emanuel Taropa, Paige Bailey, Zhifeng Chen, et al. PaLM 2 technical report. arXiv:2305.10403, 2023.
228
+ Emanuele Bastianelli, Andrea Vanzo, Pawel Swietojanski, and Verena Rieser. SLURP: A spoken language understanding resource package. In Proc. EMNLP, 2020.
229
+ Tom Brown, Benjamin Mann, Nick Ryder, Melanie Subbiah, Jared D Kaplan, Prafulla Dhariwal, Arvind Neelakantan, Pranav Shyam, Girish Sastry, Amanda Askell, et al. Language models are few-shot learners. In Proc. NeurlPS, New Orleans, 2020.
230
+ Carlos Busso, Murtaza Bulut, Chi-Chun Lee, Abe Kazemzadeh, Emily Mower, Samuel Kim, Jeannette N Chang, Sungbok Lee, and Shrikanth S Narayanan. IEMOCAP: Interactive emotional dyadic motion capture database. Language resources and evaluation, 42:335-359, 2008.
231
+ Feilong Chen, Minglun Han, Haozhi Zhao, Qingyang Zhang, Jing Shi, Shuang Xu, and Bo Xu. X-LLM: Bootstrapping advanced large language models by treating multi-modalities as foreign languages. arXiv:2305.04160, 2023a.
232
+ Guo Chen, Yin-Dong Zheng, Jiahao Wang, Jilan Xu, Yifei Huang, Junting Pan, Yi Wang, Yali Wang, Yu Qiao, Tong Lu, et al. VideoLLM: Modeling video sequence with large language models. arXiv:2305.13292, 2023b.
233
+ Guoguo Chen, Shuzhou Chai, Guanbo Wang, Jiayu Du, Wei-Qiang Zhang, Chao Weng, Dan Su, Daniel Povey, Jan Trmal, Junbo Zhang, et al. GigaSpeech: An evolving, multi-domain ASR corpus with 10,000 hours of transcribed audio. In Proc. Interspeech, Brno, 2021.
234
+ Sanyuan Chen, Chengyi Wang, Zhengyang Chen, Yu Wu, Shujie Liu, Zhuo Chen, Jinyu Li, Naoyuki Kanda, Takuya Yoshioka, Xiong Xiao, et al. WavLM: Large-scale self-supervised pre-training for full stack speech processing. IEEE Journal of Selected Topics in Signal Processing, 16(6):1505-1518, 2022.
235
+ Sanyuan Chen, Yu Wu, Chengyi Wang, Shujie Liu, Daniel Tompkins, Zhuo Chen, and Furu Wei. BEATS: Audio pre-training with acoustic tokenizers. In Proc. ICML, Honolulu, 2023c.
236
+ Wei-Lin Chiang, Zhuohan Li, Zi Lin, Ying Sheng, Zhanghao Wu, Hao Zhang, Lianmin Zheng, Siyuan Zhuang, Yonghao Zhuang, Joseph E. Gonzalez, Ion Stoica, and Eric P. Xing. Vicuna: An open-source chatbot impressing GPT-4 with $90\%$ ChatGPT quality, March 2023. URL https://lmsys.org/blog/2023-03-30-vicuna/.
237
+ Hyung Won Chung, Le Hou, Shayne Longpre, Barret Zoph, Yi Tay, et al. Scaling instructionfinetuned language models. arXiv:2210.11416, 2022.
238
+ Joris Cosentino, Manuel Pariente, Samuele Cornell, Antoine Deleforge, and Emmanuel Vincent. LibriMix: An open-source dataset for generalizable speech separation. arXiv:2005.11262, 2020.
239
+
240
+ Wenliang Dai, Junnan Li, Dongxu Li, Anthony Meng Huat Tiong, Junqi Zhao, et al. InstructBLIP: Towards general-purpose vision-language models with instruction tuning. arXiv:2305.06500, 2023.
241
+ SeungHeon Doh, Keunwoo Choi, Jongpil Lee, and Juhan Nam. LP-MusicCaps: LLM-based pseudo music captioning. arXiv:2307.16372, 2023.
242
+ Konstantinos Drossos, Samuel Lipping, and Tuomas Virtanen. Cloth: An audio captioning dataset. In Proc. ICASSP, Barcelona, 2020.
243
+ Zhengxiao Du, Yujie Qian, Xiao Liu, Ming Ding, Jiezhong Qiu, Zhilin Yang, and Jie Tang. GLM: General language model pretraining with autoregressive blank infilling. In Proc. ACL, Dublin, Ireland, 2022.
244
+ Yassir Fathullah, Chunyang Wu, Egor Lakomkin, Junteng Jia, Yuan Shangguan, Ke Li, Jinxi Guo, Wenhan Xiong, Jay Mahadeokar, Ozlem Kalinli, et al. Prompting large language models with speech recognition abilities. arXiv preprint arXiv:2307.11795, 2023.
245
+ Yuan Gong, Sameer Khurana, Leonid Karlinsky, and James Glass. Whisper-AT: Noise-robust automatic speech recognizers are also strong general audio event taggers. In Proc. Interspeech, Dublin, Ireland, 2023a.
246
+ Yuan Gong, Hongyin Luo, Alexander H. Liu, Leonid Karlinsky, and James Glass. Listen, think, and understand. arXiv:2305.10790, 2023b.
247
+ Haohan Guo, Shaofei Zhang, Frank K. Soong, Lei He, and Lei Xie. Conversational end-to-end TTS for voice agents. In Proc. SLT, 2021.
248
+ Edward J Hu, Phillip Wallis, Zeyuan Allen-Zhu, Yanzhi Li, Shean Wang, Lu Wang, Weizhu Chen, et al. LoRA: Low-Rank Adaptation of large language models. In Proc. ICLR, 2022.
249
+ Chien-yu Huang, Ke-Han Lu, Shih-Heng Wang, Chi-Yuan Hsiao, Chun-Yi Kuan, Haibin Wu, Siddhant Arora, Kai-Wei Chang, Jiatong Shi, Yifan Peng, et al. Dynamic-SUPERB: Towards a dynamic, collaborative, and comprehensive instruction-tuning benchmark for speech. arXiv:2309.09510, 2023a.
250
+ Rongjie Huang, Mingze Li, Dongchao Yang, Jiatong Shi, Xuankai Chang, Zhenhui Ye, Yuning Wu, Zhiqing Hong, Jiawei Huang, Jinglin Liu, et al. AudioGPT: Understanding and generating speech, music, sound, and talking head. arXiv:2304.12995, 2023b.
251
+ Zili Huang, Desh Raj, Paola García, and Sanjeev Khudanpur. Adapting self-supervised models to multi-talker speech recognition using speaker embeddings. In Proc. ICASSP, Rhodes, Greek, 2023c.
252
+ Anette Hulth. Improved automatic keyword extraction given more linguistic knowledge. In Proc. EMNLP, Sapporo, Japan, 2003.
253
+ Chris Dongjoo Kim, Byeongchang Kim, Hyunmin Lee, and Gunhee Kim. AudioCaps: Generating captions for audiios in the wild. In Proc. NAACL-HLT, Minneapolis, 2019.
254
+ Harlen Lane and Bernard Tranel. The Lombard sign and the role of hearing in speech. Journal of Speech Hearing Research, 14:677-709, 1971.
255
+ Junnan Li, Dongxu Li, Silvio Savarese, and Steven Hoi. BLIP-2: Bootstrapping language-image pre-training with frozen image encoders and large language models. In Proc. ICML, Hawaii, 2023a.
256
+ Yizhi Li, Ruibin Yuan, Ge Zhang, Yinghao Ma, Xingran Chen, Hanzhi Yin, Chenghua Lin, Anton Ragni, Emmanouil Benetos, Norbert Gyenge, et al. MERT: Acoustic music understanding model with large-scale self-supervised training. arXiv:2306.00107, 2023b.
257
+ Shansong Liu, Atin Sakkeer Hussain, Chenshuo Sun, and Ying Shan. Music understanding LLaMA: Advancing text-to-music generation with question answering and captioning. arXiv:2308.11276, 2023.
258
+
259
+ Chenyang Lyu, Minghao Wu, Longyue Wang, Xinting Huang, Bingshuai Liu, et al. Macaw-LLM: Multi-modal language modeling with image, audio, video, and text integration. arXiv:2306.09093, 2023.
260
+ Muhammad Maaz, Hanoona Rasheed, Salman Khan, and Fahad Shahbaz Khan. Video-ChatGPT: Towards detailed video understanding via large vision and language models. arXiv:2306.05424, 2023.
261
+ Xinhao Mei, Chutong Meng, Haohe Liu, Qiuqiang Kong, Tom Ko, Chengqi Zhao, Mark D Plumbley, Yuexian Zou, and Wenwu Wang. WavCaps: A ChatGPT-assisted weakly-labelled audio captioning dataset for audio-language multimodal research. arXiv:2303.17395, 2023.
262
+ Arsha Nagrani, Joon Son Chung, Weidi Xie, and Andrew Zisserman. Voxceleb: Large-scale speaker verification in the wild. Computer Speech & Language, 60:101027, 2019.
263
+ Chaitanya Narisetty, Emiru Tsunoo, Xuankai Chang, Yosuke Kashiwagi, Michael Hentschel, and Shinji Watanabe. Joint speech recognition and audio captioning. In Proc. ICASSP, Singapore, 2022.
264
+ OpenAI. GPT-4 technical report. arXiv:2303.08774, 2023.
265
+ Pilar Oplustil-Gallegos, Johannah O'Mahony, and Simon King. Comparing acoustic and textual representations of previous linguistic context for improving text-to-speech. In Proc. SSW, 2021.
266
+ Long Ouyang, Jeffrey Wu, Xu Jiang, Diogo Almeida, Carroll Wainwright, Pamela Mishkin, Chong Zhang, Sandhini Agarwal, Katarina Slama, Alex Ray, et al. Training language models to follow instructions with human feedback. In Proc. NeurIPS, New Orleans, 2022.
267
+ Vassil Panayotov, Guoguo Chen, Daniel Povey, and Sanjeev Khudanpur. Librispeech: An ASR corpus based on public domain audio books. In Proc. ICASSP, South Brisbane, 2015.
268
+ Baolin Peng, Chunyuan Li, Pengcheng He, Michel Galley, and Jianfeng Gao. Instruction tuning with GPT-4. arXiv:2304.03277, 2023.
269
+ Alec Radford, Jong Wook Kim, Tao Xu, Greg Brockman, Christine McLeavey, and Ilya Sutskever. Robust speech recognition via large-scale weak supervision. In Proc. ICML, Honolulu, 2023.
270
+ Paul K. Rubenstein, Chulayuth Asawaroengchai, Duc Dung Nguyen, Ankur Bapna, Zalán Borsos, Félix de Chaumont Quitry, Peter Chen, Dalia El Badawy, Wei Han, Eugene Kharitonov, et al. AudioPaLM: A large language model that can speak and listen. arXiv:2306.12925, 2023.
271
+ Yixuan Su, Tian Lan, Huayang Li, Jialu Xu, Yan Wang, and Deng Cai. PandaGPT: One model to instruction-follow them all. arXiv:2305.16355, 2023.
272
+ Guangzhi Sun, Wenyi Yu, Changli Tang, Xianzhao Chen, Tian Tan, Wei Li, Lu Lu, Zejun Ma, and Chao Zhang. Fine-grained audio-visual joint representations for multimodal large language models. arXiv preprint arXiv:2310.05863, 2023.
273
+ John Thickstun, Zaid Harchaoui, and Sham Kakade. Learning features of music from scratch. In Proc. ICLR, Toulon, France, 2017.
274
+ Hugo Touvron, Thibaut Lavril, Gautier Izacard, Xavier Martinet, Marie-Anne Lachaux, et al. LLaMA: Open and efficient foundation language models. arXiv:2302.13971, 2023.
275
+ Ashish Vaswani, Noam Shazeer, Niki Parmar, Jakob Uszkoreit, Llion Jones, Aidan N Gomez, Lukasz Kaiser, and Illia Polosukhin. Attention is all you need. In Proc. NeurIPS, Long Beach, 2017.
276
+ Changhan Wang, Anne Wu, and Juan Pino. CoVoST 2 and massively multilingual speech translation. In Proc. Interspeech, Brno, Czech Republic, 2021.
277
+ Jason Wei, Maarten Bosma, Vincent Y Zhao, Kelvin Guu, Adams Wei Yu, Brian Lester, Nan Du, Andrew M Dai, and Quoc V Le. Finetuned language models are zero-shot learners. In Proc. ICLR, 2022a.
278
+
279
+ Jason Wei, Yi Tay, Rishi Bommasani, Colin Raffel, Barret Zoph, Sebastian Borgeaud, Dani Yogatama, Maarten Bosma, Denny Zhou, Donald Metzler, et al. Emergent abilities of large language models. Transactions on Machine Learning Research, 2022b.
280
+ Jian Wu, Yashesh Gaur, Zhuo Chen, Long Zhou, Yimeng Zhu, Tianrui Wang, Jinyu Li, Shujie Liu, Bo Ren, Linquan Liu, et al. On decoder-only architecture for speech-to-text and large language model integration. arXiv:2307.03917, 2023.
281
+ Wen Wu, Chao Zhang, and Philip C Woodland. Emotion recognition by fusing time synchronous and time asynchronous representations. In Proc. ICASSP, Toronto, Canada, 2021.
282
+ Guanghui Xu, Wei Song, Zhengchen Zhang, Chao ZHang, Xiaodong He, and Bowen Zhou. Improving prosody modelling with cross-utterance BERT embeddings for end-to-end speech synthesis. In Proc. ICASSP, 2021.
283
+ Yi Yang, Wen-tau Yih, and Christopher Meek. WikiQA: A challenge dataset for open-domain question answering. In Proc. EMNLP, Lisbon, Portugal, 2015.
284
+ Wenyi Yu, Changli Tang, Guangzhi Sun, Xianzhao Chen, Tian Tan, Wei Li, Lu Lu, Zejun Ma, and Chao Zhang. Connecting speech encoder and large language model for asr. arXiv preprint arXiv:2309.13963, 2023.
285
+ Dong Zhang, Shimin Li, Xin Zhang, Jun Zhan, Pengyu Wang, Yaqian Zhou, and Xipeng Qiu. SpeechGPT: Empowering large language models with intrinsic cross-modal conversational abilities. arXiv:2305.11000, 2023a.
286
+ Hang Zhang, Xin Li, and Lidong Bing. Video-LLaMA: An instruction-tuned audio-visual language model for video understanding. arXiv:2306.02858, 2023b.
287
+ Ya-Jie Zhang, Chao Zhang, Wei Song, Zhengchen Zhang, Yonghui Wu, and Xiaodong He. Prosody modelling with pre-trained cross-utterance representations for improved speech synthesis. IEEE/ACM Transactions on Audio, Speech, and Language Processing, 31:2812-2823, 2023c.
288
+ Yue Zhao, Ishan Misra, Philipp Krahenbuhl, and Rohit Girdhar. Learning video representations from large language models. In Proc. CVPR, New Orleans, 2022.
289
+ Deyao Zhu, Jun Chen, Xiaogian Shen, Xiang Li, and Mohamed Elhoseiny. Minigpt-4: Enhancing vision-language understanding with advanced large language models. arXiv:2304.10592, 2023.
290
+
291
+ # A EXAMPLES OF SALMONN
292
+
293
+ SALMONN is capable of a large range of auditory tasks. Here we list some examples in Fig. 5-21.
294
+
295
+ ![](images/dba8cb5e62df0ffc743a5044199e24f99ea802afd9701a33abf889609c06677c.jpg)
296
+ Figure 5: Automatic Speech Recognition
297
+
298
+ ![](images/36c9f3851303d9c0fd8b23d304c2fb0a71fa436dead601d17ce64b058b206e8d.jpg)
299
+
300
+ (A man asks "Can you guess where I am right now", and explosions and gunshots can be heard in the background.)
301
+
302
+ ![](images/a2dd6d7464e0a631809c0beed19d80a6ea8498e04b5a0cb3705505a447a4e60c.jpg)
303
+
304
+ Recognize the speech and give me the transcription.
305
+
306
+ USER
307
+
308
+ Can you guess where I am right now?
309
+
310
+ ![](images/32cb7507381b4a0e0e2710d6ec1d9b7767314967d2464b9edf388db57de73801.jpg)
311
+
312
+ SALMONN
313
+
314
+ ![](images/006aa7906b1bd74fa61c95fd06e2731a8c0bd9521562d81d7e051913b643f49b.jpg)
315
+ Figure 6: Automatic Speech Translation (En2De)
316
+
317
+ ![](images/f853086c6bccce4bd49631fe6965496ba0cfc8b26de81e1b7ef1ae15762eccd1.jpg)
318
+
319
+ (A man asks "Can you guess where I am right now", and explosions and gunshots can be heard in the background.)
320
+
321
+ ![](images/cbd9f8ac78616c70add695d90dcc8854f99df248684727c0c246d650df6f22df.jpg)
322
+
323
+ Listen to the speech and translate it into German.
324
+
325
+ USER
326
+
327
+ Kannst du erraten, wohin ich gerade fahre?
328
+
329
+ ![](images/50c7c8eb0e73343edd1aac1967a466442a50df0958f04a5f611f949088d584b7.jpg)
330
+
331
+ SALMONN
332
+
333
+ ![](images/bde69d2eeeeb73aafe65a92418c2a513f14a3e822fc0a2ee06258b254e5185af.jpg)
334
+ Figure 7: Phone Recognition
335
+
336
+ ![](images/2c6310dd0d10d3307d811e84442bff5f2011ee603390e26069ade5fa259ee2e6.jpg)
337
+
338
+ (A man asks "Can you guess where I am right now", and explosions and gunshots can be heard in the background.)
339
+
340
+ ![](images/c71452daa639621d25c0c359045938f9e714988fe5d8a58bcbbe69dbc37e8cd6.jpg)
341
+
342
+ Provide the phonetic transcription for the speech.
343
+
344
+ USER
345
+
346
+ sil K AH0 N Y UW1 G EH1 S W EH1 RAY1 EY1 EH1 M RAY1 T N AW1 si
347
+
348
+ ![](images/50c3fd30844106ec78f2caedc7029ee632edfc1480acc73fdcd1386e71efe81c.jpg)
349
+
350
+ SALMONN
351
+
352
+ ![](images/1f861ccaeb98553bd89b989b7afa132921445875f544e0d7608780eb9dd39eb5.jpg)
353
+ Figure 8: Automatic Audio Captioning
354
+
355
+ ![](images/1e1d8b050aea31979e11860ade71db5528b390f71367305d66077cf3dee7e3c5.jpg)
356
+
357
+ (A man asks "Can you guess where I am right now", and explosions and gunshots can be heard in the background.)
358
+
359
+ ![](images/6c1728ab0a8e96276af9f29d0cf2895ff76b990a9f6d02ff2e7e0a46807205e0.jpg)
360
+
361
+ Please describe the audio.
362
+
363
+ USER
364
+
365
+ A person is speaking while gunshots are being fired in the background.
366
+
367
+ ![](images/48f54febc160f737cde90b3da8fe021bf83a74bcb3e65039e4efe7122eec594a.jpg)
368
+
369
+ SALMONN
370
+
371
+ ![](images/2cc81873e2750547af32a1c543bec630edb32a3c394044c2f80ccad8457c6d7c.jpg)
372
+ Figure 9: Joint Speech and Audio Captioning
373
+
374
+ ![](images/cf817879efd4ff66cc5084c710db22716d22726b708677f5438fc329af0a8d2c.jpg)
375
+
376
+ (A man asks "Can you guess where I am right now", and explosions and gunshots can be heard in the background.)
377
+
378
+ ![](images/e3c505c90f840589581eb0389dc409cb8cd1e3091c75c6107a7ae6476fdb6fee.jpg)
379
+
380
+ Recognize what the speaker says and describe the background audio at the same time.
381
+
382
+ USER
383
+
384
+ The speaker says "Can you guess where I am right now?" while the background audio has gunshots and explosions.
385
+
386
+ ![](images/177284308ee2e4396975d6b9bfd306f0e8f16c0eccc5e5d8acd087d5c6d24785.jpg)
387
+
388
+ SALMONN
389
+
390
+ ![](images/52a86b58bbca9aedb42de6fd10525a551754526fb30b95008fa84440d1cba362.jpg)
391
+ Figure 10: Speech Audio Coreasoning
392
+
393
+ ![](images/319b8e38e924a613eb395cdb739528218658caef7c53cfc87986154b080610b2.jpg)
394
+
395
+ (A man asks "Can you guess where I am right now", and explosions and gunshots can be heard in the background.)
396
+
397
+ ![](images/908eee37f38f5067bb48e5d7c1419cad4f6433865a0fbec49b9ec1a1082afa26.jpg)
398
+
399
+ Please answer the speaker's question in detail based on the background sound.
400
+
401
+ USER
402
+
403
+ Based on the background sound, it seems like the speaker is in a war zone or a combat situation. The sound of gunfire and explosions can be heard in the background. The speaker is asking if the listener can guess where they are.
404
+
405
+ ![](images/c8a73ef9ee75bed65b62e4f89d3d4ce45c3538355d3144cf69187027030125d4.jpg)
406
+
407
+ SALMONN
408
+
409
+ ![](images/bf1df3401946c31bae5af83a7def72b1be3edf32806014fb781b05379de24832.jpg)
410
+ Figure 11: Audio Event Detection
411
+
412
+ ![](images/4255d6a7cf2dca7bf00e61a5512579ae1d67c979b8ea280b5c8ef4f6bb67f01e.jpg)
413
+
414
+ (Birds chirping, a woman singing, a man speaking and a duck quacking.)
415
+
416
+ ![](images/d7441215ded9890f3f46dff38aa5dfedc4e399c022cdf4df5a2c93b2c199240c.jpg)
417
+
418
+ Please list each event in the audio in order.
419
+
420
+ # USER
421
+
422
+ 1. Birds chirping in the distance.
423
+ 2. A woman singing.
424
+ 3. A man speaking.
425
+ 4. A duck quacking.
426
+
427
+ ![](images/53f9a872a2d93ce7344733109442e51fc94e9f0c7d6b8081a23e0920c612bcb3.jpg)
428
+
429
+ # SALMONN
430
+
431
+ ![](images/681c3de5ddaae42443ddc9bab000c22098704101884b140d77a76898f2cce429.jpg)
432
+
433
+ ![](images/b86f97041b6c4ceb978d3250dc33219eb32206f74ffa98561f9232cb0e786be9.jpg)
434
+
435
+ (Birds chirping, a woman singing, a man speaking and a duck quacking.)
436
+
437
+ ![](images/420accdf06c75372be8c43bdb68f21f9fdf0eecebc2ba9216a0f01b85e80111f.jpg)
438
+ Figure 12: Audio Story Telling
439
+
440
+ Based on the audio, write a story in detail. Your story should be highly related to the audio.
441
+
442
+ # USER
443
+
444
+ It was a beautiful day in the countryside. The sun was shining, the birds were singing, and the wind was blowing gently through the fields. In the midst of all this natural beauty, a group of ducks were swimming in a pond.
445
+
446
+ As they swam, one of the ducks began to quack in a unique way. It was as if the duck was trying to say something important. The other ducks noticed this and began to listen.
447
+
448
+ Suddenly, a man appeared on the edge of the pond. He had heard the duck's quacking and had come to see what was going on. The duck continued to quack, and the man began to speak ....
449
+
450
+ ![](images/0ad7012e4e59d545b54114a7090ef5ea6f8c4a9938189789905f4d633bb8f83b.jpg)
451
+
452
+ # SALMONN
453
+
454
+ ![](images/08677c5739dcdc0d196415383ffe4ea15f6417950572ff0f2c1f0f7a6df72397.jpg)
455
+ Figure 13: Speaker Recognition
456
+
457
+ ![](images/5d49cc276ffd77036a5e7290f292e762cadea93df0791604d1c419e55a586c0a.jpg)
458
+
459
+ (Birds chirping, a woman singing, a man speaking and a duck quacking.)
460
+
461
+ ![](images/af35a448f59ceb52f02adf75b4c40536006f50aa40d651cc671601ca5ae3de4d.jpg)
462
+
463
+ How many speakers did you hear in this audio? Who are they?
464
+
465
+ # USER
466
+
467
+ I heard two speakers in this audio. One is a man and the other is a woman.
468
+
469
+ ![](images/87f15b7f8889b424e37151593864df3f4acf849a64903bdcf2589e5670a6749f.jpg)
470
+
471
+ # SALMONN
472
+
473
+ ![](images/2e58710eb2142f19fb8252bc0595ece06c65d6dc4cb1fad27ca4eaf1084d98f1.jpg)
474
+ Figure 14: Emotion Recognition
475
+
476
+ ![](images/0ff0fe3d8f5eeb3ff567a5199bc7cc4bb507d26e332e9ee42bce38ecd1f88f2d.jpg)
477
+
478
+ (A man says excitedly: "All right, let's do".)
479
+
480
+ ![](images/84ee306cc894b15c28cd1ea167d19ed04cd2429773efaf83f4579edf0b92852e.jpg)
481
+
482
+ Describe the emotion of the speaker.
483
+
484
+ USER
485
+
486
+ The speaker is excited.
487
+
488
+ ![](images/a750e622b9a04a85a053e9dcba900f3098e5dd4768e4412250f71ba0dd03c796.jpg)
489
+
490
+ SALMONN
491
+
492
+ ![](images/fafa942be6bcca939877bbcbb6bbe473567627a36a797fc0fdb63434a9fdfde5.jpg)
493
+ Figure 15: Spoken-query-based Question Answering
494
+
495
+ ![](images/f5f273da5fd199095f59eba5361335d89892e5409cc80907f08823083d280fbc.jpg)
496
+
497
+ (A person asks "What is the highest mountain in the world".)
498
+
499
+ ![](images/f012c07d798f68342dc66bc229b0236a9e896569a2eb637d5dc5d27ecb19807d.jpg)
500
+
501
+ Please answer the question in detail.
502
+
503
+ USER
504
+
505
+ The highest mountain in the world is Mount Everest, located in the Himalayas between Nepal and Tibet. It stands at a height of 8,848 meters (29,029 feet) above sea level.
506
+
507
+ ![](images/1fbbb728315b6212bdc2afe8c5d0ce90f31df90588de1392bdc57806032ba82c.jpg)
508
+
509
+ SALMONN
510
+
511
+ ![](images/33e6b89a5d8cd2562589a7b8294e4ebf9f57ec2674b9f481a084503d9916f5cd.jpg)
512
+ Figure 16: Keywords Extracting
513
+
514
+ ![](images/8a700ffceb083e81f3ca2097740623411f2286bbcf9e0b7939cb0b58ec810630.jpg)
515
+
516
+ (A part of Steve Jobs' speech: "Your time is limited so don't waste it living someone else's life. Don't be trapped by dogma which is living with the results of other people's thinking. Don't let the noise of other's opinions drown out your own inner voice. And most important have the courage to follow your heart and intuition. They somehow already know what you truly want to become everything else is secondary. When I was young there was an amazing publication called the whole earth catalog, which was one of the bibles of my")
517
+
518
+ ![](images/6225054be94f5349c10b191e420fc1440ac810b7730e8ba2c78928bb05cdf798.jpg)
519
+
520
+ Give me only three keywords of the text. Explain your reason.
521
+
522
+ USER
523
+
524
+ The keywords are 'time', 'limited', and 'courage'.
525
+
526
+ The reason for choosing these keywords is that the speaker emphasizes the importance of not wasting time living someone else's life, not being trapped by dogma, and having the courage to follow one's own inner voice.
527
+
528
+ ![](images/005a1a567ccb6eccd21f20f3899a8b1771177b8aa88b9f37dc22a6892baa1ace.jpg)
529
+
530
+ SALMONN
531
+
532
+ ![](images/3e363be86eb188c0e6da1e259a39cb5442785cba30176be097520e4ff64f81f3.jpg)
533
+ Figure 17: Slot Filling
534
+
535
+ ![](images/ecb8018a64620bde6f48e0c602a5a8648d5f5ce49cb8d991c32c33c7196c7e55.jpg)
536
+
537
+ (A girl says: "Schedule a meeting with the accounting department on half past two on Friday")
538
+
539
+ ![](images/28e9752885a3c04e71a8211d37687e81c207f3a805db4385ff5d76c33179ce43.jpg)
540
+
541
+ What is the time mentioned in the speech?
542
+
543
+ USER
544
+
545
+ Half past two on Friday
546
+
547
+ ![](images/2469d0b5f2b350293b3a29efd26f24fdb7b772082f67c715210879c0c20522c4.jpg)
548
+
549
+ SALMONN
550
+
551
+ ![](images/3675cb0ee00f910a6ed9ccaed140340b949df6c1baa6dcdeaffd314c00da3a6e.jpg)
552
+ Figure 18: Music Captioning
553
+
554
+ ![](images/10812c76c3a9fd76517e3dde8abe34a320fa0b6cda10e8a2c4b1d403cced9461.jpg)
555
+
556
+ (It's a soothing, elegant piano piece. At the end of the audio a woman begins to sing.)
557
+
558
+ ![](images/9a5b7757479aa0b2d5b7e4591d51609f4888c8e7ca57824fbd03a805096c96ee.jpg)
559
+
560
+ Please describe the music in detail.
561
+
562
+ USER
563
+
564
+ This is a beautiful piano and vocal piece. The piano plays a simple melody while the female vocalist sings in a high register. The atmosphere is romantic and dreamy. The piece has a soft and mellow feel to it. This piece could be used in a romantic movie scene or as a lullaby.
565
+
566
+ ![](images/eae2ba261fe7a6e83645f22d62a2e7368f19a34fca06b33c0f37e32320117c9d.jpg)
567
+
568
+ SALMONN
569
+
570
+ ![](images/5e66953321295b705cb3f6be9ec0aa68e454f6bf07455028023e402e689e7a1e.jpg)
571
+ Figure 19: Music Emotion Recognition
572
+
573
+ ![](images/ce0980d1a5c24bc6685548c2481eb3f4eb643eefc75943d8157ce7e84a0d267b.jpg)
574
+
575
+ (It's a soothing, elegant piano piece. At the end of the audio a woman begins to sing.)
576
+
577
+ ![](images/28864e09889622d539ad45f47a09814784e7bc2266772de1ba4bc41a67c8d47e.jpg)
578
+
579
+ What is the emotion of the music? Explain the reason in detail.
580
+
581
+ USER
582
+
583
+ The music is emotional and evokes feelings of love and affection. The reason for this is that the music is a love song, with lyrics that express the deep emotions and feelings of love and affection. The music is also instrumental, which means that it relies solely on the melody and harmony of the instruments to convey these emotions. This creates a more intimate and personal experience for the listener, allowing them to interpret the music in their own way and connect with it on a deeper level.
584
+
585
+ ![](images/6d153763dab9378c78fede52637a1154e5710804bd7e3a639129f7c5ad271331.jpg)
586
+
587
+ SALMONN
588
+
589
+ ![](images/7e00e2902f10ca27d1a7760427a6c809a98c33ed3d9dc4630db6949c8d58c578.jpg)
590
+ Figure 20:Lyrics Writing
591
+
592
+ ![](images/9a6f67ae9ed270b86b1c4833384b05a30053e58d3eb6d3b5510be0294bd54e2c.jpg)
593
+
594
+ (It's a soothing, elegant piano piece. At the end of the audio a woman begins to sing.)
595
+
596
+ ![](images/2cb1749873eb06783e21b8871a62bb9ab7c6db1a07f88f863ebc815438d53206.jpg)
597
+
598
+ Can you write some lyrics of the song?
599
+
600
+ USER
601
+
602
+ Sure, here are some lyrics for the song:
603
+
604
+ Verse 1:
605
+
606
+ You're the one I've been waiting for,
607
+
608
+ My heart beats faster when I'm near you,
609
+
610
+ You're the one I've been searching for,
611
+
612
+ My love for you will never fade.
613
+
614
+ Chorus:
615
+
616
+ You're perfect, you're flawless, ...
617
+
618
+ ![](images/1f65d05d94d8653966059e9ccfcd55fe485243ac7871afcd29c7be1aef0a2e35.jpg)
619
+ SALMONN
620
+
621
+ ![](images/8327e9a5033d63eeaf2f10ec09d5cb5740a0c50ebbd4e0bb124352a0fceaf3ad.jpg)
622
+ Figure 21: Titling Music
623
+
624
+ ![](images/133016864d224f72f169a631dbe00cf5c9ea056aafbda4a4cfe39436457fd8cb.jpg)
625
+
626
+ (It's a soothing, elegant piano piece. At the end of the audio a woman begins to sing.)
627
+
628
+ ![](images/42557a6d10e010b5089f0a61c1387cb08823e206e84ef35c026be1ea50b93243.jpg)
629
+
630
+ USER
631
+
632
+ Give me a title of the music based on its rhythm and emotion.
633
+
634
+ The music is a beautiful piano piece with a slow and emotional rhythm. It is a love song with a female vocalist singing in a soft and gentle tone. The title of the music could be something like 'Forever Love' or 'Endless Emotion'.
635
+
636
+ ![](images/0a63a120bd3ec0cb731dd2b2b278b551a6284eb01170b995a98a987becafd569.jpg)
637
+ SALMONN
638
+
639
+ # B PERFORMANCE ANALYSIS
640
+
641
+ As shown in Table 3, with activation tuning $^2$ , SALMONN
642
+
643
+ 1. performs close to the state-of-the-art results on the trained tasks including ASR, En2Zh, AAC and MC;
644
+ 2. learns to handle PR and OSR tasks which are difficult for the cascaded approach of "Vicuna + Whisper";
645
+ 3. generalises well on a wide range of speech-grounded NLP tasks, especially such as En2De and En2Ja where SALMONN performs better than the "Whisper+Vicuna" cascaded system, which indicates the superior of the audio-grounding system to cascade system on avoiding error propagation and the loss of non-linguistic information (e.g. prosody);
646
+ 4. tackles tasks such as audio-based storytelling and SAC which existing models can not handle to our best knowledge.
647
+
648
+ Table 5: Mean & standard deviation (in brackets) of the output sequence perplexity (PPL).
649
+
650
+ <table><tr><td>Model Checkpoint</td><td>ASR</td><td>AAC</td><td>PR</td><td>Story</td><td>SAC</td></tr><tr><td>Pre-training</td><td>1.1 (±0.078)</td><td>5.2 (±0.42)</td><td>270 (±60)</td><td>2.9 (±0.051)</td><td>5.4 (±0.69)</td></tr><tr><td>LoRA removed</td><td>5.9 (±1.5)</td><td>40 (±2.0)</td><td>100 (±1.7)</td><td>2.2 (±0.028)</td><td>2.7 (±0.18)</td></tr><tr><td>Instruction Tuning</td><td>1.1 (±0.054)</td><td>5.0 (±0.56)</td><td>1.1 (±0.015)</td><td>2.4 (±0.030)</td><td>2.6 (±0.066)</td></tr><tr><td>LoRA removed</td><td>5.7 (±1.3)</td><td>40 (±3.3)</td><td>92 (±8.2)</td><td>2.2 (±0.023)</td><td>2.2 (±0.087)</td></tr><tr><td>Activation Tuning</td><td>1.1 (±0.048)</td><td>6.3 (±0.80)</td><td>1.1 (±0.015)</td><td>1.8 (±0.026)</td><td>1.4 (±0.0046)</td></tr></table>
651
+
652
+ The underlying reason for using the cascaded Whisper + Vicuna system for reference values of the level 2 tasks lies in the fact that all level 2 tasks are zero-shot and there is no other audio-grounding system apart from SALMONN that can perform such tasks as zero-shot. An advantage of SALMONN over the cascaded system is that SALMONN can leverage both linguistic and paralinguistic information required for spoken language understanding.
653
+
654
+ Despite such advantages, SALMONN has performance limitations on some tasks.
655
+
656
+ 1. First, PR is achieved by extending the LLM to consider phonemes as a new writing system. Since recognising phonemes requires finer-grained modelling of pronunciation information than recognising the word pieces used by the original Whisper ASR, it is not easy for the SALMONN model built upon an existing Whisper speech encoder to perform as well as a specialised model on the PR task.
657
+ 2. Similarly, SALMONN has a relatively high WER on OSR since the Whisper ASR was not able to perform OSR.
658
+ 3. The success of SQQA mainly relies on the understanding of the spoken questions (e.g. "What is the highest mountain in the world") and answering the questions based on the commonsense knowledge stored in the text-based LLM. The drop in SQQA performance indicates that the use of LoRA cross-modal adaptation may cause the LLM to "forget" some text-based commonsense knowledge.
659
+
660
+ # C STATISTICS OF TASK OVER-FITTING
661
+
662
+ In this section, we analyse the changes of perplexity (PPL) in the three training stages to shed light on the underlying principle of activation tuning. As shown in Table 5, The PPL of ASR and AAC tasks come to very small values after the first pre-training stage, revealing that the model has learned cross-modal alignment. The PPL of PR drops after the instruction tuning stage since PR relies on LoRA to learn the output tokens of phonemes as a new "language". While the PPLs of Story and SAC also drop after instruction tuning, they are still not small enough for the tasks to be successfully performed, unless LoRA is removed at test time or an additional activation tuning stage is performed. Moreover, unlike the removal of LoRA, the PPLs on the ASR, AAC, and PR tasks remain almost unchanged after activation tuning, showcasing the advantages of this approach.
663
+
664
+ # D CHANGES IN PERPLEXIVITY DURING TRAINING
665
+
666
+ Changes in perplexity during the proposed three-stage training on six tasks including ASR, AAC, AST (En2Zh), OSR, Story, and SAC are visualized in Fig. 22.
667
+
668
+ # E CALCULATION OF FOLLOWING RATE (FR) OR ACCURACY (ACC) FOR SQQA, SF, STORY AND SAC TASKS
669
+
670
+ For the SQQA and SF tasks, if the WER calculated between model output and the question in the speech is less than $30\%$ , it is regarded that the model goes for ASR and does not follow instructions. For the Story task, we set the max length of output tokens to 200. Under this setting, answers shorter than 50 words are regarded as disobeying the instructions, and we count the number of different
671
+
672
+ ![](images/a6e0013bdc4378b22a12e5b280edee60a363842b17b90cfa05177cf91d3cd4b7.jpg)
673
+ (a) ASR.
674
+
675
+ ![](images/a8a6131ac1f5b968b3e6d200eeceb1f6484888ff193931787219a31250b897fc.jpg)
676
+ (b) Audio captioning.
677
+
678
+ ![](images/53a7e2998414219d39c2667f1486706c4b25b7da7384f992c9840a661cc65f51.jpg)
679
+ (c) AST (En2Zh).
680
+
681
+ ![](images/aae4b3dbbab4b95db9daa64f28479966daf5111ab1ecc61b14b84fc4db4cc968.jpg)
682
+ (d) Overlap speech recognition.
683
+
684
+ ![](images/a83b9f20074b1b05470a5c0c852f1216b35cbfeebec442a2b4d274b6a0d3be26.jpg)
685
+ (e) Audio story telling.
686
+
687
+ ![](images/7bf8a7a4e045374f574303cac44175e602aaa2524dd67207f6e737541c105fa7.jpg)
688
+ (f) Speech audio co-reasoning.
689
+ Figure 22: Changes in perplexity during the three-stage training. S1 is cross-modal pre-training stage, S2 is instruction tuning stage and S3-t is the $t^{th}$ step in the activation tuning stage.
690
+
691
+ words in the story to represent the diversity metric for storytelling. For the SAC task, we use GPT-3.5 to determine whether our model follows the instruction or answers the question correctly based on the background audio caption and the question.
692
+
693
+ # F PROMPT TEMPLATE FOR SALMONN
694
+
695
+ To train SALMONN to generate responses to a text instruction given an audio input, we utilize a prompt template as follows:
696
+
697
+ USER: [Auditory Tokens] Text Prompt \n ASSISTANT:
698
+
699
+ The "[Auditory Tokens]" are the output variable length text-like tokens of the window-level Q-Former. Noted that this template matches the one used for training Vicuna (Chiang et al., 2023).
700
+
701
+ # G PROMPTS INTERACTING WITH GPT3.5
702
+
703
+ In this work, we utilize GPT3.5 to help us generate some data and evaluate the quality of the model output automatically. We list our prompts for different purposes in Table 6. Words with all capital letters in the prompt will be replaced with the appropriate description before being fed into GPT3.5.
704
+
705
+ # H POTENTIAL TO EXTEND SALMONN TO SPEECH AND AUDIO GENERATION
706
+
707
+ Although SALMONN is designed to focus on enabling LLMs with hearing abilities, it is possible to extend SALMONN to speech generation. The human speech production mechanism is related to auditory perception. A well-known phenomenon attributed to the speech chain is the "Lombard reflex" which describes the effect where individuals raise their voice level to be heard more clearly while speaking in noisy environments (Lane & Tranel, 1971). This reveals the importance of having generic hearing abilities when empowering AI with fully human-like speaking abilities, and the opportunities in text-to-speech (TTS) synthesis enabled by SALMONN. This also matches the recent development in TTS that the text and audio contexts from the surrounding utterances are useful to achieve more natural prosody modelling and enable the use of more natural and casual speech data (Xu et al., 2021; Guo et al., 2021; Oplustil-Gallegos et al., 2021; Zhang et al., 2023c).
708
+
709
+ <table><tr><td>Purposes</td><td>Prompts</td></tr><tr><td>To generate audio QA data given audio caption text.</td><td>Below I will give you some sentences that you will need to help me generate **only one** question, and its corresponding answer. These sentences are captions of some audio. Your question should be highly related to the audio caption, and your answer must be **correct**, and should be simple and clear. \nYour response should strictly follow the format below: \n{&quot;Question&quot;:&quot;xxx&quot;, &quot;Answer&quot;: &quot;xxx&quot;}\nHere are the sentences:</td></tr><tr><td>To generate speech QA data given speech recognition text.</td><td>Below I will give you some sentences that you will need to help me generate **only one** question, and its corresponding answer. Your question should be highly related to the sentences, and your answer must be **correct**, and should be simple and clear. \nYour response should strictly follow the format below: \n{&quot;Question&quot;:&quot;xxx&quot;, &quot;Answer&quot;: &quot;xxx&quot;}\nHere are the sentences:</td></tr><tr><td>To evaluate answers of the model of spoken-query-based question answering (SQQA).</td><td>Next I will give you a question and give you the corresponding standard answer and the answer I said. You need to judge whether my answer is correct or not based on the standard answer to the question. I will give you the question and the corresponding answer in the following form: {&#x27;Question&#x27;: &#x27;xxx&#x27;, &#x27;Standard Answer&#x27;: &#x27;xxx&#x27;, &#x27;My Answer&#x27;: &#x27;xxx&#x27;}\nYou need to judge the correctness of my answer, as well as state a short justification. Your responses need to follow the Python dictionary format: \n{&#x27;Correct&#x27;: True / False, &quot;Reason&quot;: &quot;xxx&quot;}\nNow, I will give you the following question and answer: SENTENCEHERE\nYour response is:</td></tr><tr><td>To evaluate whether the model attempts to do the speech audio co-reasoning (SAC) task.</td><td>There is an audio clip, and there is a person in the audio asking questions. I now have an AI model that needs to go and answer the speaker&#x27;s question based on the background audio. I&#x27;ll tell you the question the speaker is asking the output of my AI model, and what you need to determine: whether my AI model is trying to answer the question and why. You need to be especially careful that my model may just be describing the audio without hearing your question and answering it. You don&#x27;t need to care about the correctness of the answer. All you need to focus on is whether the model is trying to answer the question. Your response needs to follow the format of the python dictionary: {&quot;Response&quot;: &quot;Yes/No&quot;, &quot;Reason&quot;: &quot;xxx&quot;}\nYour Question in audio: &lt;QUESTION&gt;\nModel Output: &lt;OUTPUT&gt;\nYour Response:</td></tr><tr><td>To evaluate whether the model successfully completes the SAC task.</td><td>There is an audio clip, and there is a person in the audio asking questions. I now have an AI model that needs to go and answer the speaker&#x27;s question based on the background audio. I&#x27;ll tell you the question asked by the speaker, some description of the background audio, and the output of my AI model, and you need to decide whether my AI model answered it correctly, and why. Your response needs to follow the format of the python dictionary: {&quot;Response&quot;: &quot;Yes/No&quot;, &quot;Reason&quot;: &quot;xxx&quot;}\nYour Question in audio: &lt;QUESTION&gt;\nBackground Audio: &lt;AUDIO&gt;\nModel Output: &lt;OUTPUT&gt;\nYour Response:</td></tr></table>
710
+
711
+ Table 6: Purposes and prompts of using GPT3.5.
2024/SALMONN_ Towards Generic Hearing Abilities for Large Language Models/images.zip ADDED
@@ -0,0 +1,3 @@
 
 
 
 
1
+ version https://git-lfs.github.com/spec/v1
2
+ oid sha256:f1d23e6b4fee982dd68cf242ab12ba52e29b85e5d865b05edbfbd2edd4d3e3dc
3
+ size 1048970
2024/SALMONN_ Towards Generic Hearing Abilities for Large Language Models/layout.json ADDED
The diff for this file is too large to render. See raw diff
 
2024/SALMON_ Self-Alignment with Instructable Reward Models/cd081d37-dfd2-4be4-a4b9-51c32b23ccf7_content_list.json ADDED
The diff for this file is too large to render. See raw diff
 
2024/SALMON_ Self-Alignment with Instructable Reward Models/cd081d37-dfd2-4be4-a4b9-51c32b23ccf7_model.json ADDED
The diff for this file is too large to render. See raw diff
 
2024/SALMON_ Self-Alignment with Instructable Reward Models/cd081d37-dfd2-4be4-a4b9-51c32b23ccf7_origin.pdf ADDED
@@ -0,0 +1,3 @@
 
 
 
 
1
+ version https://git-lfs.github.com/spec/v1
2
+ oid sha256:ee8c45c8341c4da0c147c87a9f6ee7bfb8a4f47006d4b7a5ce14b23a371c0534
3
+ size 920601
2024/SALMON_ Self-Alignment with Instructable Reward Models/full.md ADDED
The diff for this file is too large to render. See raw diff
 
2024/SALMON_ Self-Alignment with Instructable Reward Models/images.zip ADDED
@@ -0,0 +1,3 @@
 
 
 
 
1
+ version https://git-lfs.github.com/spec/v1
2
+ oid sha256:5f37c1305421a4bdccc795335dc2129fdf3010ed195abbeb92e32a735d409292
3
+ size 3872334
2024/SALMON_ Self-Alignment with Instructable Reward Models/layout.json ADDED
The diff for this file is too large to render. See raw diff
 
2024/SAN_ Inducing Metrizability of GAN with Discriminative Normalized Linear Layer/9b66a8aa-e3da-4b12-a6c5-a1964dd9c67e_content_list.json ADDED
The diff for this file is too large to render. See raw diff
 
2024/SAN_ Inducing Metrizability of GAN with Discriminative Normalized Linear Layer/9b66a8aa-e3da-4b12-a6c5-a1964dd9c67e_model.json ADDED
The diff for this file is too large to render. See raw diff
 
2024/SAN_ Inducing Metrizability of GAN with Discriminative Normalized Linear Layer/9b66a8aa-e3da-4b12-a6c5-a1964dd9c67e_origin.pdf ADDED
@@ -0,0 +1,3 @@
 
 
 
 
1
+ version https://git-lfs.github.com/spec/v1
2
+ oid sha256:6363c057ef7e6ad764ab5bc40921f451ab67cc5cfd97226712856971b7dfd15b
3
+ size 16786899
2024/SAN_ Inducing Metrizability of GAN with Discriminative Normalized Linear Layer/full.md ADDED
The diff for this file is too large to render. See raw diff
 
2024/SAN_ Inducing Metrizability of GAN with Discriminative Normalized Linear Layer/images.zip ADDED
@@ -0,0 +1,3 @@
 
 
 
 
1
+ version https://git-lfs.github.com/spec/v1
2
+ oid sha256:ed9557ab41646c54a7b12b0d06880af05c45c71f470af578830dcf49482c55cd
3
+ size 1738255
2024/SAN_ Inducing Metrizability of GAN with Discriminative Normalized Linear Layer/layout.json ADDED
The diff for this file is too large to render. See raw diff
 
2024/SAS_ Structured Activation Sparsification/f4b70f0a-5725-4b01-9a73-6fa2819e4c27_content_list.json ADDED
The diff for this file is too large to render. See raw diff
 
2024/SAS_ Structured Activation Sparsification/f4b70f0a-5725-4b01-9a73-6fa2819e4c27_model.json ADDED
The diff for this file is too large to render. See raw diff
 
2024/SAS_ Structured Activation Sparsification/f4b70f0a-5725-4b01-9a73-6fa2819e4c27_origin.pdf ADDED
@@ -0,0 +1,3 @@
 
 
 
 
1
+ version https://git-lfs.github.com/spec/v1
2
+ oid sha256:7d3e7de46a3b509b38ceb5e923a270d80cf2b60613aef20d3577e4a17d9eeb6d
3
+ size 2994865
2024/SAS_ Structured Activation Sparsification/full.md ADDED
@@ -0,0 +1,387 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ # SAS: STRUCTURED ACTIVATION SPARSIFICATION
2
+
3
+ Yusuke Sekikwa, Shingo Yashima
4
+
5
+ DENSO IT Lab. Inc., Tokyo, Japan
6
+
7
+ yusuke.sekikawa, yashima.shingo@core.d-itlab.co.jp
8
+
9
+ # ABSTRACT
10
+
11
+ Wide networks usually yield better accuracy than their narrower counterpart at the expense of the massive multi cost. To break this tradeoff, we advocate a novel concept of Structured Activation Sparsification, dubbed SAS, which boosts accuracy without increasing computation by utilizing the projected sparsity in activation maps with a specific structure. Concretely, the projected sparse activation is allowed to have $N$ nonzero value among $M$ consecutive activations. Owing to the local structure in sparsity, the wide matmul between a dense weight and the sparse activation is executed as an equivalent narrow matmul between a dense weight and dense activation, which is compatible with NVIDIA's Sparse Tensor Core developed for the $N:M$ structured sparse weight. In extensive experiments, we demonstrate that increasing sparsity monotonically improves accuracy (up to 7% on CIFAR10) without increasing the multi count. Furthermore, we show that structured sparsification of activation scales better than that of weight given the same computational budget. https://github.com/DensoITLab/sas_
12
+
13
+ # 1 INTRODUCTION
14
+
15
+ Modern deep neural networks (DNNs) consist of numerous matrix multiplications between input activation and weight matrices, making it challenging for DNNs to deploy on resource-constrained edge devices due to the enormous multi count. One could reduce the computation by narrowing the width of the activation channel; however, it trades off accuracy.
16
+
17
+ Researchers explore the way to speed up DNN inference from various perspectives such as quantization (Esser et al., 2019), knowledge distillation (Hinton et al., 2015), designing efficient model architectures (Liu et al., 2022; Howard et al., 2017), and structured weight sparsification (Wang et al., 2019; Tan et al., 2020; Li et al., 2022; 2016; Wen et al., 2016). This paper explores the unexplored spectrum, Structured Activation Sparsification, positioned at the opposite end of the structured weight sparsification.
18
+
19
+ # WEIGHT SPARSIFICATION
20
+
21
+ One could obtain an efficient model by removing unimportant weights from a wide, high-capacity model. It can be categorized into unstructured and structured.
22
+
23
+ Unstructured weight sparsification prunes individual weights independently based on the criteria for the importance of the weight connection (e.g., by their magnitude) (Frankle & Carbin, 2018; Yang et al., 2019; Wortsman et al., 2019). Although it could achieve an extremely sparse network without sacrificing accuracy, the sparsity does not translate to the practical speedup on vector-processing architectures (e.g., GPU) because it has no structure on the sparsity pattern, making the parallel execution difficult (NVIDIA, 2020). In fact, even when a matrix is highly sparse (e.g., $>95\%$ zero), wall-clock times for the sparse matmul on GPU (cuSPARSE) is still slower than dense operation (cuBLAS) (Shi et al., 2020).
24
+
25
+ Coarse-grained structured weight sparsification removes unimportant weights such that the sparsified operation can be vectorized, which includes block pruning (Wang et al., 2019; Chen et al., 2022), kernel shape sparsity (Tan et al., 2020), and channel/filter pruning (Li et al., 2022; 2016; Wen et al., 2016). The resultant network's theoretical mult count
26
+
27
+ directly translates to actual speedup on commodity vector-type hardware; however, it hurts model performance more severely than the unstructured fine-grained sparsity.
28
+
29
+ Fine-grained structured (semi-structured) weight sparsification aims at the best of both worlds. The $N:M$ structured weights sparsification (SWS) utilized the local sparse structure in weight to realize the efficient parallel execution of sparse matmul. The structure indicates that the sparse weight has $N$ nonzero value for every continuous $M$ element (section 5). NVIDIA commercialized this idea in Sparse Tensor Core<sup>1</sup>. It incorporates this local structure by the vectorized local switch, which selects corresponding $N$ elements from $M$ consecutive activation, realizing the dot-product using only $N/M$ multi count. They demonstrate the actual speedup of SWS close to the theoretical gain. This real speedup on the wide-spread hardware using local sparsity patterns motivates us to explore the opposite: structured sparsity in activation, expecting it to deliver better accuracy/speed tradeoff. Hereafter, we call the $N:M$ structured pattern as structured for brevity.
30
+
31
+ # ACTIVATION SPARSIFICATION
32
+
33
+ Sparsity also exists in activation; however, unlike sparsity in weight, much less attention has been given to exploiting sparsity in activation for DNN speedup.
34
+
35
+ Unstructured activation sparsification has been utilized to speed up the DNN inference. In many settings, DNNs' activation tends to be naturally sparse by the activation functions, e.g., rectified linear unit (ReLU). Most of the prior works utilized the activation sparsity by their novel hardware architecture (Zhu et al., 2022; Albericio et al., 2016; Rhu et al., 2018; Han et al., 2016; Parashar et al., 2017; Park et al., 2017; Georgiadis, 2019; Wang et al., 2021). (Kurtz et al., 2020) demonstrate the wall-clock speedup on a general-purpose CPU.
36
+
37
+ However, the sparsity induced by activation functions such as ReLU depends on its input; therefore, the resultant sparsity pattern is unstructured. This unstructured nature makes it difficult to parallelize the operation on vector-type processors such as GPU (Shi et al., 2020). This incompatibility with the popular vector-type processors partly explains why activation sparsity has been less explored than weight sparsity.
38
+
39
+ Structured Activation Sparsification (SAS) is an unexplored area that we expect to pioneer the new frontier for accuracy/speed tradeoff in vector-processing architecture. Our contribution is two-fold: ① We introduce the idea of SAS, open up a new research area, and ② We invent a mechanism called structured sparse projection to construct SAS, realized vectorized matmul with sparse activation on GPU for the first time. Realizing structured sparsity, i.e., controlling the nonzero counts within consecutive activation elements, is difficult because the activation value depends on its input. We realized the structured sparsity in activation by implicitly projecting the input narrow/dense activation into higher dimensional space such that the projected activation has a local sparsity pattern. This contrasts to pruning as in SWS, which sparsify the value (weight) to be fixed after training. SAS yields better accuracy by utilizing the increased flexibility of the wide weight while keeping the same mult count. In other words, SAS selects the appropriate weight depending on its input using the activation's sparsity pattern. Importantly, owing to the local structure of the projected sparsity, SAS realized the vectorized matmul with sparse activation on typical GPU by utilizing the local routing mechanism originally developed for SWS.
40
+
41
+ Our experiments (section 3-4) demonstrate that increased sparsity in the SAS network enhances its capacity and accuracy monotonically without increasing mult count; furthermore, it performs much better than the SWS for the same speed.
42
+
43
+ # 2 STRUCTURED ACTIVATION SPARSIFICATION
44
+
45
+ A matrix multiplication (matmul) is a fundamental building block of neural networks. This study mainly focuses on the matmul that appears in convolution<sup>2</sup>. Convolution with the activation $\pmb{I} \in \mathbb{R}^{C_i \times W \times H}$ and weight $\pmb{W} \in \mathbb{R}^{C_o \times C_i \times k \times k}$ is equivalent to matmul between
46
+
47
+ ![](images/2a846ae89d34cf0af3be1b13275782ad03ba984644e446bd56d6af43c488bdf7.jpg)
48
+ Figure 1: SAS overview. Conventional matmul between a dense/narrow weight and a dense/narrow activation has a lower expressive power (left). The matmul between dense/wide weight and structurally sparse/wide activation composed by implicit sparse projection (SAS) has a higher expressive power while requiring the same mult count and comparable inference time (right).
49
+
50
+ unfolded activation $\pmb{X} \in \mathbb{R}^{C_{i}kk \times WH}$ and the reshaped weight $\pmb{W} \in \mathbb{R}^{C_{o} \times C_{i}kk}$ :
51
+
52
+ $$
53
+ \boldsymbol {O} = \boldsymbol {I} * \boldsymbol {W} = \boldsymbol {W} \boldsymbol {X}. \tag {1}
54
+ $$
55
+
56
+ For dense weight $W$ and dense activation $X$ , the matmul consumes $C_i k k \times C_o \times H W = \bar{C}_i \times C_o \times H W$ mult count. One can reduce the computation by narrowing the network width; mult count is reduced by a factor or $\alpha^2$ by narrowing the number of input and output channels by $\alpha$ . Unfortunately, but apparently, this trades off accuracy.
57
+
58
+ # 2.1 STRUCTURED SPARSITY IN ACTIVATION
59
+
60
+ We study an unexplored area, exploiting structured sparsity in activation to realize a neural network model that is not only low FLOPS but also vectorizable. Concretely, the sparse activation is allowed to have $N$ nonzero value among $M$ consecutive activations. Owing to the sparsity, a matmul between sparse/wide activation $\tilde{\pmb{X}}$ and dense/wide weight $\tilde{\pmb{W}}$ could be reduced into the matmul between dense/narrow activation $\pmb{X}$ and dense/narrow weight $\pmb{W}$ as: $\pmb {O} = \tilde{\pmb{W}}\tilde{\pmb{X}} = \pmb {W}\pmb {X}$ . More importantly, it realizes the parallel vectorized execution owing to the local sparsity pattern, specifically $\pmb{W}$ is constructed by locally routing the weight elements from the sparse weight $\tilde{\pmb{W}}$ that correspond to the nonzero activation elements in $\tilde{\pmb{X}}$ . Actually, this operation is compatible with the commonly used GPU (section 2.3).
61
+
62
+ # 2.2 SAS BY SPARSE PROJECTION
63
+
64
+ How can we construct such structurally sparse activation? Realizing structured sparsity (controlling the number of nonzero counts within consecutive activation elements) is challenging because, unlike the case of SWS, the activation changes depending on the input. Therefore, existing methods utilizing activation sparsity are unstructured, such as induced by ReLU (Shi et al., 2020), which is hard to vectorize on GPU. One could construct a structurally sparse activation by max-pooling along the blocked channel dimension; however, we can not expect this to achieve a good accuracy/speed tradeoff. Because $①$ we can not control the input-dependant activation to have one $(N)$ significant value among $M$ consecutive element (otherwise, it removes crucial information); $②$ it discards most of the value in activation map (e.g., $94\%$ when $M = 16$ ) that is computed using valuable resources.
65
+
66
+ To realize the structured sparsity, we propose structured sparse projection $S$ as follows:
67
+
68
+ $$
69
+ \mathcal {S}: \boldsymbol {X} \in \mathbb {R} ^ {\bar {C} _ {i} \times H W} \mapsto \tilde {\boldsymbol {X}} \in \mathbb {R} ^ {M / N \bar {C} _ {i} \times H W}. \tag {2}
70
+ $$
71
+
72
+ In the SAS projection $\mathcal{S}$ , a single element in the source activation $\pmb{X}$ is projected into one of an $M$ consecutive elements in target sparse activation $\tilde{\pmb{X}}$ indexed by $\mathcal{I}$ . In this study, we use the sign of $\log_2 M$ neighbor activation to compute the index $\mathcal{I}_{j,u}$ for $j$ -th input channel and $u$ -th spacial location as follows:
73
+
74
+ $$
75
+ \mathcal {I} _ {j, u} = \sum_ {i = 0} ^ {\log_ {2} M - 1} \left(\boldsymbol {X} _ {j + i, u} > 0\right) 2 ^ {i}. \tag {3}
76
+ $$
77
+
78
+ ![](images/b9888b52127eddb57733e5e733e60279d2fd18365080bb013d6173d89f53f51b.jpg)
79
+ Figure 2: SAS mechanism. The matmul between sparse/wide activation $\tilde{\pmb{X}}$ and dense/wide weight $\tilde{\pmb{W}}$ could be vectorized on Sparse Tensor Core by selecting elements from the weight $\tilde{\pmb{W}}$ that correspond to the nonzero values in the activation $\tilde{\pmb{X}}$ , skipping the unnecessary mult by zero (left). A dense/narrow activation $\pmb{X} \in \mathbb{R}^{\bar{C}_i \times HW}$ is projected to a structurally sparse/wide activation $\tilde{\pmb{X}} \in \mathbb{R}^{MC_i \times HW}$ (here $M = 4$ ). Local index $\mathcal{I}$ for projecting the activation is computed by using the sign of the $\log_2 M$ consecutive activation using eq. (3) (right). Note: we do not compute the sparse activation $\tilde{\pmb{X}}$ explicitly during inference; instead, $\pmb{X}$ and $\mathcal{I}$ is directly passed to the processor.
80
+
81
+ ```prolog
82
+ 1 def sas_matmul(W, X, kSparse=2): # Activation X and Weight W, kSparse=2 indicates 50% sparsity
83
+ 2 beta, gamma, alpha = W.shape[0]*kSparse, W.shape[1], X.shape[1]
84
+ 3 Y = zeros([beta, alpha], dtype='float32') # Output
85
+ 4 E_ = zeros([gamma//kSparse//2, alpha], dtype='uint8') | 0x4
86
+ 5 # Compute index by evaluating sgn-bit (eq. (3)) and Convert to 4-bit index
87
+ 6 E_[signbit(X)] = 0xe
88
+ 7 E = bitwise_or(E_[0::2:, E_[1::2,:] << 4)
89
+ 8 E_reodered = take(E, array(numpy.load{'{}}_).npy.format(m, k)) # need re-oder (supp. E, fig. A2)
90
+ 9 # Copy compressed activation to SparseTensorCore
91
+ 10 X_compressed = zeros((alpha*gamma//kSparse)*(4+1/2), dtype='uint8') # value followed by index
92
+ 11 CUDA.getRuntime.memcpy(X_compressed.data.ptr, X.data.ptr, (int)(alpha*gamma//kSparse)*4, ...)
93
+ 12 CUDA.getRuntime.memcpy(X_compressed.data.ptr + dat_size, E_reodered.data.ptr, (alpha*gamma//kSparse//2), ...)
94
+ 13 # Execute matmul: Y = W @ X by calling cusparseLtbetaatmul
95
+ 14 cusparseMatmul(..., W.data.ptr, X_compressed.data.ptr, ..., Y.data.ptr, ...)
96
+ 15 return Y
97
+ ```
98
+
99
+ Listing 1: cuSAS: General SAS matmul library for Sparse Tensor Core. It is based on CuPy Okuta et al. (2017) wrapper of cuSPARSElt. The index needs to be reordered before execution of sparse matmul (L8). Refer to supp. E for more details about the reorder specific to NVIDIA GPUs.
100
+
101
+ The computational cost for the index is negligible (fig. 3 report its wall-clock time); it merely looks at the sign bit of the $\log_2M$ neighbor activation (fig. 2). Note: the SAS using this projection includes the ReLU network as a particular case (e.g., when odd elements of weight are zero for $M = 2$ ). Other than this simple indexing, there are various options; one could choose $N$ elements instead of 1 or incorporate another strategy for computing the index, e.g., estimating the index $\mathcal{I}$ using the previous layer's output (section 6.1).
102
+
103
+ FLOPS. The size of weight $\tilde{W}$ for the SAS network increases linearly with $M$ ; nevertheless, the number of mult count is the same as the base dense/narrow network, i.e., $\bar{C}_i \times C_o \times HW$ . The mult count is also approximately the same with the SWS network (Zhou et al., 2021) with $\sqrt{M}$ times wider input/output channel for 1:M sparsity pattern (Refer to supp. B for more detail). Both SAS and SWS require additional costs for routing the weight or activation. Sparse Tensor Core is highly engineered for this purpose and can execute the routing in parallel (section 2.3), and as reported in (NVIDIA, 2020), the time for the routing is small compared with the main matmul. The SAS network requires another negligible cost for computing index $\mathcal{I}$ of eq. (3) (fig. 3 reports the wall-clock time on actual hardware).
104
+
105
+ Memory. Although the mult count is constant for the activation sparsity $M$ , the memory footprint of SAS increases linearly. This contrasts with the SWS, where storage for weight at inference time is constant irrespective of weight sparsity $M$ . Note: the SWS network also requires $M$ times more memory during training. SAS and the SWS require additional storage for storing the index; however, it is small, requiring only $\log_2M$ -bit per element.
106
+
107
+ # 2.3 HARDWARE IMPLEMENTATION AND SPEED BENCHMARKING
108
+
109
+ The SAS matmul could be vectorized on an ordinary GPU having a local routing mechanism. For example, NVIDIA GPU equips this mechanism. During inference, we do not explicitly construct the sparse activation $\tilde{\pmb{X}}$ ; instead, we directly compute index $\mathcal{I}$ from dense activation $\pmb{X}$ ( $\tilde{\pmb{X}}$ is computed implicitly). The $\mathcal{I}$ and $\mathbf{X}$ is transferred to the core, then the
110
+
111
+ ![](images/630096951ab257cdf014638ad53b3b39b5a907ced95556095d57db63376f1f46.jpg)
112
+ Figure 3: Speed benchmarking. SAS (1:2) vs SWS (1:2) for general matmul on NVIDIA A6000 GPU. Comparing the general matmul $\mathbf{W}\mathbf{X}$ where $\mathbf{X} \in \mathbb{R}^{\gamma \times \alpha}$ and $\mathbf{W} \in \mathbb{R}^{\beta \times \gamma}$ . The extra cost for SAS, c.f., index computation is less than $1.5\%$ (when $\mathrm{M} = 20480$ ) of the entire matmul. The time of cuBLAS is an estimation based on NVIDIA's white paper and included for reference.
113
+
114
+ vectorized switch routes the corresponding weight element using the local index, executing the sparse/wide matmul as dense/narrow matmul(fig. 2) in parallel. We developed a general matmul library for SAS (listing 1) called cuSAS for Sparse Tensor Core. cuSAS realized the vectorized matmul with structured sparse activation on GPU for the first time. Figure 3 report the wall-clock time of SAS for general matmul compared with SWS using the same matrix size. The difference between SWS and SAS comes from the overhead specific to SAS (index computation, reorder (supp. E), and its memory transfer), which is less than $1.5\%$ , even with our naive implementation having several redundancies. Note: the configuration of this experiment is different from the previous discussion and the other experiments using neural networks; we use the same matrix size for dense, SWS, and SAS to reveal their difference more clearly. Therefore, mult count of SWS and SAS is $1 / M$ of that of dense when considering the sparsity. Refer to supp. C for more detail about the speed benchmarking.
115
+
116
+ # 2.4 TRAINING SAS NETWORK
117
+
118
+ One could transform most existing (narrow) neural networks into (wide) SAS networks to increase their expressive power without increasing inference speed. The conversion is simple: replacing the original non-linearity (e.g., ReLU) with our SAS projection $S$ . During the training, SAS matmul is computed as follows: it first projects the dense/narrow activation map into a structurally sparse/wide space by $S$ , constructing the sparse activation explicitly; then, it performs the conventional dense matmul. It is equivalent to the sparse matmul for efficient inference using hardware support (fig. 2).
119
+
120
+ Optimizer for SAS To train the SAS network, one wants to utilize modern optimizers such as Adam (Kingma & Ba, 2014) and AdamW (Loshchilov & Hutter, 2019), which use adaptive learning rates based on the statistics of the gradient history. However, it is known that the adaptive learning rate could be unstable in the early stage of training, where the number of experienced gradients is small (Liu et al., 2020). This is more problematic in the SAS network (when $M$ is large) because each weight element receives gradients less frequently ( $\times 1 / M$ on average) than the dense network. To achieve stable training of the SAS network, we propose Experience-RAdam (ERAdam), which slightly modifies the formulation of RAdam (Liu et al., 2020). Basically, RAdam rectifies Adam(W)'s adaptive learning rates by multiplying $r_t < 1$ to reduce the variance in the early stage of training:
121
+
122
+ $$
123
+ \rho_ {\infty} = 2 \left(1 - \beta_ {2}\right) - 1, \rho_ {t} = \rho_ {\infty} - 2 t \beta_ {2} ^ {t} \left(1 - \beta_ {2} ^ {t}\right), \tag {4}
124
+ $$
125
+
126
+ $$
127
+ r _ {t} = \sqrt {\left(\left(\rho_ {t} - 4\right) \left(\rho_ {t} - 2\right) \rho_ {\infty}\right) / \left(\left(\rho_ {\infty} - 4\right) \left(\rho_ {\infty} - 2\right) \rho_ {t}\right)}, \tag {5}
128
+ $$
129
+
130
+ where $t$ is the optimization steps, and $\beta$ is the hyperparameters used in computing the running average of gradients. As $t \to \infty$ (training proceeds), we have $r_t \to 1$ , and it recovers the original Adam(W)'s update.
131
+
132
+ Our ERAdam scales steps $t$ for calculating $r_t$ of each weight element so that it is proportional to the number of received gradients. Specifically, we use the following scaled time vector
133
+
134
+ ![](images/f8e302503bfdb3d3e9084ccf6b6a90225fbfb06e0e2b259da0ebf9354a8da99c.jpg)
135
+ Figure 4: SAS capacity analysis by trajectory length. Comparing SAS (top) with dense ReLU network and SWS network (bottom). $l$ indicates the average relative length concerning the input circle length, where a longer length (complex trajectory) indicates more expressive power.
136
+
137
+ $\mathbf{t} \in \mathbb{R}^{\bar{C}_i}$ instead of $t$ :
138
+
139
+ $$
140
+ \mathbf {t} _ {i} \leftarrow \mathbf {t} _ {i} + \left(\sum_ {u} \left(\nabla \tilde {\boldsymbol {X}} _ {., u}\right) \neq 0\right) / H W, \tag {6}
141
+ $$
142
+
143
+ where $\nabla \tilde{\boldsymbol{X}}\in \bar{C}_i\times HW$ is gradient of activation corresponding to the weight $\mathbf{W}$ . We find the optimizer with the CosineDecay (Loshchilov & Hutter, 2017) scheduler with k-decay (Zhang & Li, 2020) works well, especially for large $M$ .
144
+
145
+ # 3 EXPRESSIVE POWER ANALYSIS
146
+
147
+ We propose SAS for DNNs, but it is difficult to discuss its superiority (or inferiority) over SWS based on their accuracy on a specific task; the result often turns back depending on the model structure, training strategy (schedule, optimizer, etc), and dataset. To evaluate the difference of expressive power with SWS independently from these factors, we utilize the Trajectory Length (Raghu et al., 2017), which evaluates the expressiveness by measuring the length of the output trajectory given input sweeps along a one-dim path (e.g., circle).
148
+
149
+ We construct a two-layer neural network with 2-dim input and output (fig. A1). The base network has 32-dim intermediate channels, followed by the ReLU activation. We replace the ReLU by our SAS with different sparsity $M$ , such that they all have the same mult count, i.e., structurally sparsified activation $\hat{\pmb{X}}$ has 32 nonzero elements. We also construct the SWS variant (Zhou et al., 2021), which has approximately the same mult count (supp. section A). We evaluate their trajectory length by inputting the one-dimensional circular path to the networks by varying the sparsity $M$ and report their average output trajectory length by changing the initial random weights.
150
+
151
+ Figure 4 report the results. The trajectory length of the SAS network increases with increasing sparsity $M$ . On the other hand, the length from the SWS network is almost constant for $M$ . This trajectory analysis suggests our SAS has more expressive power than the SWS, given the same computational budget at the expense of increased memory requirement.
152
+
153
+ # 4 EXPERIMENT
154
+
155
+ Given the same matmul budget, enlarging a model by SAS with sparse projection improves accuracy? Is it better than the SWS using the same hardware?
156
+
157
+ We conducted extensive experiments to answer the questions. For the first question, we evaluated the accuracy by changing the sparsity $M$ , keeping the same mult count. For the second question, we compared the SAS with SWS (Zhou et al., 2021), which has the same sparsity and mult count; both utilize the same hardware mechanism (i.e., local routing).
158
+
159
+ ![](images/6129b498771ae5dcc90ad2764ee3b738c9d5cb5319f9876528b303c06225676a.jpg)
160
+ FAR-10
161
+
162
+ ![](images/496fb823c4537c94a6f287b01c1f75c5cd6c187b3925efc9e24cbcd44cf5a3b2.jpg)
163
+
164
+ ![](images/ad253aab2530d891b7e4d33f2641100b9d205505f84c389572542dd495c7e02d.jpg)
165
+
166
+ ![](images/c0612cb883ed7cb0588ef5f80d66b02a6525ff322e5e1f5e6c95d07b6c26d67d.jpg)
167
+
168
+ ![](images/65ef126b9cf9892c496362813b7f08cfd1099086bb16806abbf575d530a99f46.jpg)
169
+
170
+ ![](images/2fff76b1ca0fd79028ffef5e2bd0e139fad1d8b72bbcd9d434b1d0607c8ea950.jpg)
171
+
172
+ ![](images/1f8738e5b80271e2129f9b1b423d45cfb244b9a3f2035bfc67b3688e5cc63cf7.jpg)
173
+
174
+ ![](images/c689d0c4b940b5a59391b687f7e6747464fb4edde34d2bceb9098bbf4ec0af91.jpg)
175
+
176
+ ![](images/0fc97cc6bf2fb3d9e91a6aaf63470194a250ac9b561f7c36cd8cf6abac780e25.jpg)
177
+ 100 CIFAR-100
178
+
179
+ ![](images/f58f2246c38b774839947fbda9c6a23bc35ae70bb2d173904008a5e5db147e1b.jpg)
180
+
181
+ ![](images/226ac561fb287fb44b2d9965ed688a28c785850ad69b92dee6cb52115defb230.jpg)
182
+
183
+ ![](images/14d3b524eaf496427f039d6109235ce45ac7a79c09d9118c37a7d2e7277ae81f.jpg)
184
+
185
+ ![](images/47eddccbf1f796f4fe34fbeaa152616b758e14c2aadebfabded0c3eb92e780b2.jpg)
186
+ Figure 5: Accuracy of $\times \alpha$ narrow ResNet18 on CIFAR-10 and CIFAR-100 for difference SAS sparsity $M$ . The summary plot reports the best score for each setting where dashed lines are the SWS network having the same sparsity in weight, which consumes the same multi-add count.
187
+
188
+ ![](images/8fc67980524b96799ae318342231f67b71b1be79868c53adee987bc6cba4d7d6.jpg)
189
+
190
+ ![](images/5863383febccf2763c9b5580f56ed082871ad57e6af34254b4f8dbafbc4bec50.jpg)
191
+
192
+ ![](images/c16f3cfa23b01154f3d1d89cd1f8767e6fa7d7b84fc08c6f11bfae89b56c4ac4.jpg)
193
+
194
+ # 4.1 EXPERIMENTAL SETUP AND RESULTS
195
+
196
+ We evaluate the classification accuracy on CIFAR-10/100 (Krizhevsky et al., a;b), and ImageNet (Deng et al., 2009). Because the commonly used network already achieves good saturated accuracy, we adopted the narrow version as a base network to better evaluate the effects of using the sparse activation or weight. Specifically, as a base dense ReLU network, we've utilized the network with $\alpha \times$ narrow width ( $W \in \mathbb{R}^{C_o / \alpha \times \bar{C}_i / \alpha}$ ) except for the first and last layers; it approximately consume $\alpha^2 \times$ less multi count. All variants, ReLU, SWS (Zhou et al., 2021) and SAS networks, have approximately the same multi count for the same $\alpha$ . The 1:M SWS network employs $\sqrt{M} \times$ more channel to make the multi count the same as the base ReLU network (section 2.2, supp. B).
197
+
198
+ For fair comparisons, we employ the same training strategy for all variants, i.e., the training epochs, batch size, optimizer, scheduler, etc. For training the SWS network, we employed the training method of (Zhou et al., 2021). We train the networks from scratch for all experiments. Refer to supp. D for more detail about the experimental configuration.
199
+
200
+ CIFAR-10 / CIFAR-100. We use ResNet18 (He et al., 2016) as one of the most popular architectures. For all the variants, we utilize our proposed ERAdam optimizer (section 2.4) in combination with k-decay scheduler (Zhang & Li, 2020); it is equivalent to RAdam for
201
+
202
+ the base network because $\sum_{u}(\nabla \tilde{X}_{\cdot,u}) \neq 0$ in eq. (6) is approximately same for each weight elements. We trained them for $16 \times 1000 / \alpha$ epochs, utilizing the data argumentation adopted in the ConvNeXt (Liu et al., 2022). We evaluate the accuracy by changing the base network width $\alpha$ and sparsity $M$ . Figure 5 summarizes the results.
203
+
204
+ ImageNet. We use ConvNeXt (Liu et al., 2022), which is computationally efficient by its network architecture design; e.g., it heavily utilizes depthwise convolutions to reduce the number of multi. For this ImageNet experiment, we conducted an experiment only on the practical configuration (rather than changing $\alpha$ and $M$ in wider rage); we use ConvNeXt-B, having half of the original input channel $(\alpha = 2)$ as a base network and use $M = 2$ for SWS and SAS. We use their official code base only changing its activation and number of training epochs and keeping the rest of the highly optimized settings unchanged. The accuracy of the base network, SWS, and SAS is $80.7\%$ , $81.5\%$ , and $82.2\%$ , respectively.
205
+
206
+ # 4.2 DISCUSSION
207
+
208
+ As expected, the accuracy improves as we increase the activation's sparsity $M$ . For all ranges of the base network width (having different $\alpha$ ), we observed the most significant gain from the base ReLU network to a $M = 2$ sparse network. The improvement saturates around $M = 8$ or $M = 16$ . Similarly, we observe a significant gain when the base network capacity is small (large $\alpha$ ). From a perspective of the training statistics evolution, the accuracy of the SAS network having significant sparsity (large $M$ ) is worse than the less sparse network (small $M$ ) at the beginning of the training; however, it surpasses them as training proceeds; sparser network requires more training epochs to reach their best accuracy. We hypothesize this is partly due to the sparse gradient when $M$ is large. In comparison with the weight sparsification, SWS network (Zhou et al., 2021) also shows improvement for the weight sparsity $M$ . Yet, SAS scales significantly better than SWS for the same multi count.
209
+
210
+ In summary, we see the SAS realized by the projected sparsity boosts accuracy without increasing multi count; furthermore, the improvement is monotonic w.r.t. $M$ and is much better than SWS. The index $\mathcal{I}$ changes depending on its input, suggesting the different weight elements are dynamically utilized depending on their input (section 5). We hypothesize that the increased flexibility by the increases memory for weight is a primary source of SAS's superior accuracy boost over the SWS. The result also aligns with the increased capacity of SAS evaluated by the trajectory length analysis (section 3).
211
+
212
+ # 5 RELATED WORKS
213
+
214
+ This section discusses the relation to other approaches for efficient DNN inference on GPU.
215
+
216
+ Unstructured weight sparsity. It is hard to utilize the unstructured sparsity for speedup on GPU (Shi et al., 2020). For example, the wall-clock time for matmul between an $8000 \times 8000$ matrix with a sparsity of $90\%$ and a dense matrix with the same size takes 780ms by cuSPARSE, while the corresponding dense algorithm by cuBLAS only requires 121ms. Though the sparse operation reduces the mult count by $90\%$ , the dense matmul is $7 \times$ faster, suggesting the difficulty of utilizing unstructured sparsity in vector processors due to several overheads such as indexing.
217
+
218
+ Dynamic kernel. SAS dynamically selects weight elements based on activation. In this regard, it relates to a series of research exploring the input-dependent weight to increase the network expressive power (Chen et al., 2020; Jia et al., 2016), which also relates to the attention mechanism (Vaswani et al., 2017). Our SAS is different both in its motivation and mechanism (e.g., SAS selects weight instead of composing it on the fly). Possible future work would be to use attention for computing the index instead of the strategy in section 2.2.
219
+
220
+ Quantization. Discretizing the weight and/or activation into a low-bit representation is commonly used to speed up the DNN inference (Yin et al., 2019; Esser et al., 2019; Li & Baillieul, 2004); low-precision mult is more computationally efficient and consumes less energy than the floating point counterpart. Furthermore, when we adopt a lower bit weight,
221
+
222
+ memory footprints and cost for transferring the weight decrease. The main drawback of SAS is the increased memory footprint for the weight matrix $(\times M)$ ; we'll explore the combination with the lower-bit weight matrix to mitigate the issue.
223
+
224
+ Low-rank factorization. Factorization of matmul into a low-rank presentation is often utilized to reduce the number of mult count. The factorization can be integrated into network design as depthwise or 1x1 convolution; they are utilized in efficient network designs such as MobileNet (Howard et al., 2017) or ConvNeXt (which we evaluate). Recent research realized the optimization of low-rank structure (Idelbayev & Carreira-Perpinan, 2020). Ours are orthogonal to these low-rank approaches and could be combined.
225
+
226
+ # 6 CONCLUSION
227
+
228
+ We propose SAS, an unexplored but effective approach for efficient DNN inference on vector-type processors. The evaluation reveals that sparsifying activation by structured projection improves accuracy while maintaining the same mult count and inference speed. Our idea is compatible with NVIDIA's commercial GPU for $M = 2$ . It is not limited to the specific device but is a good match for a wide range of vector processes; we expect it to open the door for the new algorithm and hardware utilizing the structured sparsity in activation.
229
+
230
+ # 6.1 LIMITATIONS & FUTURE WORK
231
+
232
+ Advanced projection algorithm. In this study, we employed a straightforward strategy to compute the index $\mathcal{I}$ (section 2.2). We employed this method because it is computationally cheap, simply looking at the sign bit of the neighbor activation. It has some drawbacks for $M > 2$ when the neighbor elements are close to zero. When the neighbor oscillates around zero, the sparse activation $\tilde{\mathbf{X}}$ undergoes discontinuous changes, which may negatively affect the accuracy; this phenomenon is more likely to occur when $M$ is large. From another perspective, our current implementation determines the index by the simple rule, which is not learned end-to-end. Learning to compute the index by incorporating extra channels or attention-like mechanisms (Vaswani et al., 2017) might improve the accuracy.
233
+
234
+ Combination with SWS. We used the switching circuit developed for the SWS to utilize the sparsity in activation for speedup. Exploring the combination of SAS and SWS would be an exciting direction. Unfortunately, the current GPU supports sparse matmul where one of the matrices is sparse. More efficient DNN could be realized on future GPU, which supports matmul where both inputs are structurally sparse.
235
+
236
+ Library for DNN framework. We developed the CuPy (Okuta et al., 2017) based library cuSAS (listing 1) for general matmul for 1:2 sparse pattern, which runs on actual Sparse Tensor Core hardware and realized wall clock speedup; however, integration to popular DNN framework has not yet been completed. As an important future work, we will develop SAS (depth-wise) convolution for Pytorch (Paszke et al., 2019), TensorFlow (Abadi et al., 2015), and JAX (Bradbury et al., 2018) by CUDA programming. We expect slightly better results (in terms of the percentage of SAS-specific overhead) than the result in fig. 3 will be achieved with the custom CUDA kernel because we can integrate SAS-specific online computation such as index computation, reorder (section E), and memory copy.
237
+
238
+ Hardware consideration for significant sparsity. Current NVIDIA's GPU support only 1:2 sparsity for tf32 or float matrices<sup>3</sup>, which restricts the SAS in higher sparsity on actual hardware. In principle, larger sparsity in SAS does not increase the mult count but may increase the switching circuit's area, energy, and storage cost. Considering the saturated gain by increasing the sparsity (section 4), the best sparsity can be defined; we left this consideration for future work. Furthermore, hardware support could make the index computation (section 2.2) more efficient. In addition to the efficient implementation on existing GPUs, we'll explore the novel vector-type processor design specific to the SAS.
239
+
240
+ # REFERENCES
241
+
242
+ Martín Abadi, Ashish Agarwal, Paul Barham, Eugene Brevdo, Zhifeng Chen, Craig Citro, Greg S. Corrado, Andy Davis, Jeffrey Dean, Matthieu Devin, Sanjay Ghemawat, Ian Goodfellow, Andrew Harp, Geoffrey Irving, Michael Isard, Yangqing Jia, Rafal Jozefowicz, Lukasz Kaiser, Manjunath Kudlur, Josh Levenberg, Dan Mané, Rajat Monga, Sherry Moore, Derek Murray, Chris Olah, Mike Schuster, Jonathon Shlens, Benoit Steiner, Ilya Sutskever, Kunal Talwar, Paul Tucker, Vincent Vanhoucke, Vijay Vasudevan, Fernanda Viégas, Oriol Vinyals, Pete Warden, Martin Wattenberg, Martin Wicke, Yuan Yu, and Xiaogiang Zheng. TensorFlow: Large-scale machine learning on heterogeneous systems, 2015. URL http://tensorflow.org/. Software available from tensorflow.org.
243
+ Jorge Albericio, Patrick Judd, Tayler Hetherington, Tor Aamodt, Natalie Enright Jerger, and Andreas Moshovos. Cnvlutin: Ineffectual-neuron-free deep neural network computing. In 2016 ACM/IEEE 43rd Annual International Symposium on Computer Architecture (ISCA), pp. 1-13, 2016. doi: 10.1109/ISCA.2016.11.
244
+ James Bradbury, Roy Frostig, Peter Hawkins, Matthew James Johnson, Chris Leary, Dougal Maclaurin, George Necula, Adam Paszke, Jake VanderPlas, Skye Wanderman-Milne, and Qiao Zhang. JAX: composable transformations of Python+NumPy programs, 2018. URL http://github.com/google/jax.
245
+ Tianlong Chen, Xuxi Chen, Xiaolong Ma, Yanzhi Wang, and Zhangyang Wang. Coarsening the granularity: Towards structurally sparse lottery tickets. February 2022.
246
+ Yinpeng Chen, Xiyang Dai, Mengchen Liu, Dongdong Chen, Lu Yuan, and Zicheng Liu. Dynamic convolution: Attention over convolution kernels. In Proceedings of the IEEE/CVF conference on computer vision and pattern recognition, pp. 11030-11039, 2020.
247
+ Jia Deng, Wei Dong, Richard Socher, Li-Jia Li, Kai Li, and Li Fei-Fei. ImageNet: A large-scale hierarchical image database. In 2009 IEEE Conference on Computer Vision and Pattern Recognition. IEEE, June 2009.
248
+ Steven K Esser, Jeffrey L McKinstry, Deepika Bablani, Rathinakumar Appuswamy, and Dharmendra S Modha. Learned step size quantization. February 2019.
249
+ Jonathan Frankle and Michael Carbin. The lottery ticket hypothesis: Finding sparse, trainable neural networks. March 2018.
250
+ G. Georgiadis. Accelerating convolutional neural networks via activation map compression. In 2019 IEEE/CVF Conference on Computer Vision and Pattern Recognition (CVPR), pp. 7078-7088, Los Alamitos, CA, USA, jun 2019. IEEE Computer Society. doi: 10.1109/CVPR.2019.00725. URL https://doi.ieeecomputersociety.org/10.1109/CVPR.2019.00725.
251
+ Song Han, Xingyu Liu, Huizi Mao, Jing Pu, Ardavan Pedram, Mark A Horowitz, and William J Dally. EIE: Efficient inference engine on compressed deep neural network. February 2016.
252
+ Kaiming He, Xiangyu Zhang, Shaoqing Ren, and Jian Sun. Delving deep into rectifiers: Surpassing human-level performance on imagenet classification. In Proceedings of the IEEE international conference on computer vision, pp. 1026-1034, 2015.
253
+ Kaiming He, Xiangyu Zhang, Shaoqing Ren, and Jian Sun. Deep residual learning for image recognition. In IEEE Conference on Computer Vision and Pattern Recognition, pp. 770-778, 2016.
254
+ Geoffrey Hinton, Oriol Vinyls, and Jeff Dean. Distilling the knowledge in a neural network. arXiv preprint arXiv:1503.02531, 2015.
255
+ 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. April 2017.
256
+ Yerlan Idelbayev and Miguel A Carreira-Perpinan. Low-rank compression of neural nets: Learning the rank of each layer. In 2020 IEEE/CVF Conference on Computer Vision and Pattern Recognition (CVPR). IEEE, June 2020.
257
+ Xu Jia, Bert De Brabandere, Tinne Tuytelaars, and Luc V Gool. Dynamic filter networks. Advances in neural information processing systems, 29, 2016.
258
+
259
+ Diederik P Kingma and Jimmy Ba. Adam: A method for stochastic optimization. December 2014.
260
+ Alex Krizhevsky, Vinod Nair, and Geoffrey Hinton. Cifar-10 (canadian institute for advanced research). a. URL http://www.cs.toronto.edu/~kriz/cifar.html.
261
+ Alex Krizhevsky, Vinod Nair, and Geoffrey Hinton. Cifar-100 (canadian institute for advanced research). b. URL http://www.cs.toronto.edu/~kriz/cifar.html.
262
+ Mark Kurtz, Justin Kopinsky, Rati Gelashvili, Alexander Matveev, John Carr, Michael Goin, William Leiserson, Sage Moore, Nir Shavit, and Dan Alistarh. Inducing and exploiting activation sparsity for fast inference on deep neural networks. 119:5533-5543, 2020.
263
+ Hao Li, Asim Kadav, Igor Durdanovic, Hanan Samet, and Hans Peter Graf. Pruning filters for efficient convnets. arXiv preprint arXiv:1608.08710, 2016.
264
+ Keyong Li and John Baillieul. Robust quantization for digital finite communication bandwidth (dfcb) control. IEEE Transactions on Automatic Control, 49(9):1573-1584, 2004.
265
+ Y. Li, K. Adamczewski, W. Li, S. Gu, R. Timofte, and L. Van Gool. Revisiting random channel pruning for neural network compression. In 2022 IEEE/CVF Conference on Computer Vision and Pattern Recognition (CVPR), pp. 191-201, Los Alamitos, CA, USA, jun 2022. IEEE Computer Society. doi: 10.1109/CVPR52688.2022.00029. URL https://doi.ieeecomputersociety.org/10.1109/CVPR52688.2022.00029.
266
+ Liyuan Liu, Haoming Jiang, Pengcheng He, Weizhu Chen, Xiaodong Liu, Jianfeng Gao, and Jiawei Han. On the variance of the adaptive learning rate and beyond. In International Conference on Learning Representations, 2020. URL https://openreview.net/forum?id=rkggz2aEKDr.
267
+ Zhuang Liu, Hanzi Mao, Chao-Yuan Wu, Christoph Feichtenhofer, Trevor Darrell, and Saining Xie. A convnet for the 2020s. In Proceedings of the IEEE/CVF Conference on Computer Vision and Pattern Recognition, pp. 11976-11986, 2022.
268
+ Ilya Loshchilov and Frank Hutter. SGDR: Stochastic gradient descent with warm restarts. In International Conference on Learning Representations, 2017. URL https://openreview.net/forum?id=Skq89Scxx.
269
+ Ilya Loshchilov and Frank Hutter. Decoupled weight decay regularization. In International Conference on Learning Representations, 2019. URL https://openreview.net/forum?id=Bkg6RiCqY7.
270
+ NVIDIA. NVIDIA A100 tensor core GPU architecture. https://images.nvidia.com/aem-dam/en-zz/Solutions/data-center/nvidia-ampere-architecture-whitepaper.pdf, 2020.
271
+ Ryosuke Okuta, Yuya Unno, Daisuke Nishino, Shohei Hido, and Crissman Loomis. Copy: A numpy-compatible library for nvidia gpu calculations. In Proceedings of Workshop on Machine Learning Systems (LearningSys) in The Thirty-first Annual Conference on Neural Information Processing Systems (NIPS), 2017. URL http://learningsys.org/nips17/ assets/papers/paper_16.pdf.
272
+ Angshuman Parashar, Minsoo Rhu, Anurag Mukkara, Antonio Puglielli, Rangharajan Venkatesan, Brucek Khailany, Joel Emer, Stephen W. Keckler, and William J. Dally. Scnn: An accelerator for compressed-sparse convolutional neural networks. In Proceedings of the 44th Annual International Symposium on Computer Architecture, ISCA '17, pp. 27a 40, New York, NY, USA, 2017. Association for Computing Machinery. ISBN 9781450348928. doi: 10.1145/3079856.3080254. URL https://doi.org/10.1145/3079856.3080254.
273
+ Jongsoo Park, Sheng Li, Wei Wen, Ping Tak Peter Tang, Hai Li, Yiran Chen, and Pradeep Dubey. Faster CNNs with direct sparse convolutions and guided pruning. In International Conference on Learning Representations, 2017. URL https://openreview.net/forum?id=rJPcZ3txx.
274
+ Adam Paszke, Sam Gross, Francisco Massa, Adam Lerer, James Bradbury, Gregory Chanan, Trevor Killeen, Zeming Lin, Natalia Gimelshein, Luca Antiga, Alban Desmaison, Andreas Kopf, Edward Yang, Zachary DeVito, Martin Raison, Alykhan Tejani, Sasank Chilamkurthy, Benoit Steiner, Lu Fang, Junjie Bai, and Soumith Chintala. Pytorch: An imperative style, high-performance deep learning library. In H. Wallach, H. Larochelle, A. Beygelzimer, F. d'Alché-Buc, E. Fox, and R. Garnett (eds.), Advances in Neural Information Processing Systems 32, pp. 8024-8035. Curran Associates, Inc., 2019.
275
+ Maithra Raghu, Ben Poole, Jon Kleinberg, Surya Ganguli, and Jascha Sohl-Dickstein. On the expressive power of deep neural networks. In international conference on machine learning, pp. 2847-2854. PMLR, 2017.
276
+
277
+ Minsoo Rhu, Mike O'Connor, Niladrish Chatterjee, Jeff Pool, Youngeun Kwon, and Stephen W. Keckler. Compressing dma engine: Leveraging activation sparsity for training deep neural networks. In 2018 IEEE International Symposium on High Performance Computer Architecture (HPCA), pp. 78-91, 2018. doi: 10.1109/HPCA.2018.00017.
278
+ Shaohuai Shi, Qiang Wang, and Xiaowen Chu. Efficient sparse-dense matrix-matrix multiplication on gpus using the customized sparse storage format. In 2020 IEEE 26th International Conference on Parallel and Distributed Systems (ICPADS), pp. 19-26. IEEE, 2020.
279
+ Zhanhong Tan, Jiebo Song, Xiaolong Ma, Sia-Huat Tan, Hongyang Chen, Yuanqing Miao, Yifu Wu, Shaokai Ye, Yanzhi Wang, Dehui Li, et al. Pcnn: Pattern-based fine-grained regular pruning towards optimizing cnn accelerators. In 2020 57th ACM/IEEE Design Automation Conference (DAC), pp. 1-6. IEEE, 2020.
280
+ Ashish Vaswani, Noam Shazeer, Niki Parmar, Jakob Uszkoreit, Llion Jones, Aidan N Gomez, Lukasz Kaiser, and Illia Polosukhin. Attention is all you need. Advances in neural information processing systems, 30, 2017.
281
+ Yang Wang, Chen Zhang, Zhiqiang Xie, Cong Guo, Yunxin Liu, and Jingwen Leng. Dual-side sparse tensor core. In 2021 ACM/IEEE 48th Annual International Symposium on Computer Architecture (ISCA), pp. 1083-1095. IEEE, 2021.
282
+ Yanzhi Wang, Shaokai Ye, Zhezhi He, Xiaolong Ma, Linfeng Zhang, Sheng Lin, Geng Yuan, Sia Huat Tan, Zhengang Li, Deliang Fan, et al. Non-structured dnn weight pruning considered harmful. arXiv preprint arXiv:1907.02124, 2, 2019.
283
+ Wei Wen, Chunpeng Wu, Yandan Wang, Yiran Chen, and Hai Li. Learning structured sparsity in deep neural networks. Advances in neural information processing systems, 29, 2016.
284
+ Mitchell Wortsman, Ali Farhadi, and Mohammad Rastegari. Discovering neural wireings. June 2019.
285
+ Huanrui Yang, Wei Wen, and Hai Li. DeepHoyer: Learning sparser neural network with differentiable Scale-Invariant sparsity measures. September 2019.
286
+ Penghang Yin, Jiancheng Lyu, Shuai Zhang, Stanley Osher, Yingyong Qi, and Jack Xin. Understanding Straight-Through estimator in training activation quantized neural nets. March 2019.
287
+ Tao Zhang and Wei Li. kdecay: Just adding k-decay items on learning-rate schedule to improve neural networks. arXiv preprint arXiv:2004.05909, 2020.
288
+ Aojun Zhou, Yukun Ma, Junnan Zhu, Jianbo Liu, Zhijie Zhang, Kun Yuan, Wenxiu Sun, and Hongsheng Li. Learning N:M fine-grained structured sparse neural networks from scratch. February 2021.
289
+ Zeqi Zhu, Arash Pourtaherian, Luc Waeijen, Lennart Bamberg, Egor Bondarev, and Orlando Moreira. Arts: An adaptive regularization training schedule for activation sparsity exploration. In 2022 25th Euromicro Conference on Digital System Design (DSD), pp. 415-422, 2022. doi: 10.1109/DSD57027.2022.00062.
290
+
291
+ # SAS: Structured Activation Sparsification Supplemental Material
292
+
293
+ # A DETAIL IN TRAJECTORY LENGTH ANALYSIS
294
+
295
+ Network design for the Trajectory Length analysis (section 3) is illustrated in fig. A1. We evaluate the length by randomly initializing the weight 100 times and reporting their average. We also compose the SWS network having the same sparsity, which consumes approximately the same multi count. The SWS network uses ReLU activation.
296
+
297
+ ![](images/10cf2e1cecd91135e6d154e1ce6dccdb8aa1a2789ee49a48b39c3c6a57c79adf.jpg)
298
+ Figure A1: Network design used for the Trajectory Length Analysis (section 3). Relative output length with respect to the input circle length is an indicator of the network's expressive power; a longer length (complex trajectory) indicates more expressive power.
299
+
300
+ ![](images/1e467dd54f4ae405bb2265f1be306961fc1f3403eb10566114a576baa476bb9f.jpg)
301
+
302
+ ![](images/b72e6d4a3d8f4a8b357423365457ab63c6d2270afbdf3bbb1a7c826bb923dd83.jpg)
303
+
304
+ # B DETAIL IN SWS NETWORK
305
+
306
+ In this paper, we propose SAS to improve the network capacity or accuracy without increasing the actual mult count. Therefore, we compare the SWS in the same scenario (keeping the mult count constant while increasing the sparsity). Specifically, we consider a base layer consisting of matmul between activation $\mathbf{X}$ and weight $\mathbf{W}$ , where $\mathbf{X} \in \mathbb{R}^{\bar{C}_i \times HW}$ and $\mathbf{W} \in \mathbb{R}^{C_o \times \bar{C}_i}$ (eq. (1)). Using the proposed SAS, one could increase the network width for $M$ times while maintaining the same mult count as the base layer by utilizing the $1:M$ sparsity pattern. The sparsified matrix shape is, $\mathbf{X} \in \mathbb{R}^{M\bar{C}_i \times HW}$ and $\mathbf{W} \in \mathbb{R}^{C_o \times M\bar{C}_i}$ (eq. (3)). Note that the SAS does not change the output channel dimension $C_o$ .
307
+
308
+ On the other hand, in the case of SWS, if one increases the network width for the $M$ times and uses the $1:M$ sparse pattern on weight, the mult count of the resultant network increases by about $M \times M / M = M$ because both input and output channel is $M$ times wider. In the case of SWS, by using $\sqrt{M}$ times wider network for the $1:M$ sparsity pattern, we can construct the SWS network, which has roughly the same mult count as the base dense network and SAS. More specifically, we adopt the following configuration: We use $\sqrt{M}$ times (instead of $M$ times) wider input/output channel. In this configuration, we'll have approximately the same mult count as the base network. The network width needs to be an integer value, and it also needs to be a multiple of $M$ . Hence, we use the weight having the shape of $\lfloor \sqrt{M} \bar{C}_i^{(l)} \rceil \times \lfloor \sqrt{M} C_o^{(l)} \rceil$ for the $1:M$ SWS network, where $\lfloor \cdot \rfloor$ is a rounding operator, $\bar{C}_i^{(l)}, C_o^{(l)}$ is the input/output channel dimension of $l$ -th layer of the base dense network. For the last chunk, when it does not equal to $M$ , we use $(\lfloor \sqrt{M} \bar{C}_i^{(l)} \rceil \lfloor \sqrt{M} C_o^{(l)} \rceil$
309
+
310
+ mod $M$ ):1 sparse pattern. This way, we construct the SWS network having approximately the same mult count as the base dense network.
311
+
312
+ For example, consider the $l$ -th layer of the base network consisting of convolution with $\bar{C}_i = 288$ ( $C_i = 32$ , kernel size $k = 3$ ) and $C_o = 128$ . When $M = 8$ , then we have $\lfloor \sqrt{M} \bar{C}_i^{(l)} \rceil = 815$ and $\lfloor \sqrt{M} C_o^{(l)} \rceil = 181$ . Then mult count of the original dense layer (for single pixel) is $288 \times 64 = 18432$ , the mult count of the weight sparse layer (SWS) is 18440 ( $815 \times 181 / 8 = 18439$ with modulo 3, we use $M = 3$ for the last chunk).
313
+
314
+ # C DETAIL IN SPEED BENCHMARKING
315
+
316
+ On the wall-clock speed benchmarking reported in section 2.3, we adopt the opposite configuration as the neural network experiment. We evaluate the speed by changing the sparsity pattern while keeping the matrix dimension unchanged to report more concrete comparisons.
317
+
318
+ Specifically, in the wall-clock speed benchmarking in fig. 3, we consider the matmul WX where $\mathbf{X} \in \mathbb{R}^{\gamma \times \alpha}$ and $\mathbf{W} \in \mathbb{R}^{\beta \times \gamma}$ which is same for dense matmul, SAS matmul, and SWS matmul. The mult count of the three variants is the same ( $\gamma \times \alpha \times \beta$ ) when one does not take the sparsity into account. By utilizing the 1:2 fine-grained (or semi-structured) sparsity on Sparse Tensor Core, the mult count becomes half for SAS and SWS, i.e., ( $\gamma \times \alpha \times \beta$ )/2. As shown in fig. 3, we use fixed $\gamma = 10240$ , changing $\alpha = \beta$ from 10240 to 20480, which is the same for dense matmul SAS matmul, and SWS matmul.
319
+
320
+ We want to emphasize that the scenario in this speed benchmarking (keep the same matrix dimension) is different from the scenario for neural networks (keep the (almost) same mult count). We adopt the different configurations to evaluate the speed in a fair setting between SWS and SAS. In the neural network setting, one could construct the SWS network having approximately the same mult count with the base one by using $\sqrt{M}$ wider input/output channel (supp. B); however, it is hard to align the mult count precisely, and the shape of the matrices is different, which makes it hard to evaluate the overhead specific to SAS which we are interested in (computation of index, reorder, and memory transfer for the index). On the other hand, we can clearly evaluate this by measuring the time of the matmul of the same-sized matrix (section 2.3).
321
+
322
+ # D DETAIL IN MAIN EXPERIMENT
323
+
324
+ The primary experimental setup is summarized in table A1. The FLOPS and memory footprint of the network used in the experiments are summarized in table A2
325
+
326
+ For training the SWS network, we employed the method of (Zhou et al., 2021) instead of APEX's Automatic SParsity<sup>1</sup> because $①$ code base of (Zhou et al., 2021)<sup>2</sup> supports arbitrarily $1: M$ sparsity and $②$ it allows training from scratch which enables fair comparison with SAS.
327
+
328
+ Table A1: Experimental setup
329
+
330
+ <table><tr><td></td><td>CIFAR-10</td><td>CIFAR-100</td><td>ImageNet</td></tr><tr><td>Network</td><td colspan="2">ResNet18</td><td>ConvNeXt-B</td></tr><tr><td>Batch size</td><td colspan="2">512</td><td>4096</td></tr><tr><td>Training epochs</td><td colspan="2">16/α×1000</td><td>600</td></tr><tr><td>Optimizer</td><td colspan="2">ERAdam (section 2.4)</td><td>AdamW</td></tr><tr><td>Scheduler</td><td colspan="2">Two cycle cosine with kDecay=2.0 Zhang &amp; Li (2020)</td><td>Cosine</td></tr><tr><td>Initialization</td><td colspan="2">Kaiming-uniform He et al. (2015)</td><td>Truncated Gaussian</td></tr><tr><td>Base width α</td><td colspan="2">4/8/16</td><td>2</td></tr><tr><td>Sparsity M</td><td colspan="2">ReLU/2/4/8/16</td><td>ReLU/2</td></tr></table>
331
+
332
+ # CIFAR-10/CIFAR-100
333
+
334
+ The code for CIFAR-10 and CIFAR-100 is based on Pytorch lightning CIFAR10 tutorial code<sup>3</sup>. We use a single A6000 GPU for CIFAR10 and CIFAR100 experiments. It takes a day to train the single model.
335
+
336
+ # IMAGENET
337
+
338
+ The code for ImageNet is based on ConvNeXt's (Liu et al., 2022) official code base<sup>4</sup>. We use four A100 GPUs (each holding 256 batches) with an update frequency of four to virtually construct the batch size of 4096. It takes about two weeks to train a single SAS model for 600 epochs (double the original 300 epochs to compensate for sparse gradient); we use the default setup of ConvNeXt's (Liu et al., 2022) official repository for training ImageNet-1K (without pre-training using ImageNet-22K), only changing the original dense matmul to our proposed SAS matmul(conv2D $\rightarrow$ SASconv2D, and linear $\rightarrow$ SASlinear) and training epochs $(300\to 600)$ . We use the original AdamW optimizer to keep the original ConvNeXt's highly optimized settings intact as much as possible (furthermore, in this moderate sparsity of $M = 2$ , proposed ERAdam behaves almost identical to AdamW with warm-up). Refer to their paper for a more detailed setup.
339
+
340
+ Table A2: FLOPS and memory footprints. Note that FLOPS and the number of parameters and FLOPS of SWS are not precisely the same as the base dense network as discussed in supp. B, but the difference is less than $1\%$ for all the configurations.
341
+
342
+ <table><tr><td>Network</td><td>FLOPS (all)</td><td>Params (dense, SWS)</td><td>Params (SAS)</td></tr><tr><td>ResNet18 (α=4)</td><td>114K</td><td>731K</td><td>731K×M</td></tr><tr><td>ResNet18 (α=8)</td><td>28K</td><td>182K</td><td>182K×M</td></tr><tr><td>ResNet18 (α=16)</td><td>7K</td><td>46K</td><td>46K×M</td></tr><tr><td>ConvNeXt-B (α=2)</td><td>3850M</td><td>22M</td><td>22M×M</td></tr></table>
343
+
344
+ # TRAINING
345
+
346
+ During the training, SAS matmul is computed as follows: it first projects the dense/narrow activation map into a structurally sparse/wide space by $\mathcal{S}$ , constructing the sparse activation explicitly; then, it performs the conventional dense matmul. Note that it is equivalent to the sparse matmul for efficient inference when hardware support is available, and we do not construct the sparse matrix explicitly during inference. Still, the hardware directly processes the narrow dense feature along with the index computed online (fig. 2). Refer to the pseudo-code in listing 2 during training. When implemented this way, the gradient for the wide weight $\tilde{\boldsymbol{W}}$ could be computed using autograd mechanism.
347
+
348
+ ```python
349
+ 1 def SASProj(x, m): # m corresponds to log2(M) in the main text
350
+ 2 B, C, H, W = x.shape
351
+ 3 xa = [torch-roll(x[;, None], i, dims=1) for i in range(m)]
352
+ 4 ind = torch.cat([2*i*(torch.signbit(x_)) for i, x_ in enumerate(xa)], dim=2).sum(dim=2, keepdim=True)
353
+ 5 x_sparse = torch.zeros([B, 2^m, C, H, W]).scatter_(1, ind, x[;, None]).view([B, (2^m)*C, H, W])
354
+ 6 return x_sparse
355
+ 7 def forward(self, x): # x: input activation, m: sparsity factor (actual sparsity is 100(1-1/2^m)[%])
356
+ 8 return FConv2d(SASProj(x, m), self.weight, bias=self.bias, stride=...)
357
+ ```
358
+
359
+ Listing 2: Code of SAS conv2d layer for training (PyTorch). Note: During inference, one does not need to construct the sparse activation explicitly (L5); refer to fig. 2 for efficient inference mechanism.
360
+
361
+ # E MEMORY ARRANGEMENT FOR CUSPARSELTMATMUL
362
+
363
+ The Sparse Tensor Core and the cuSPARSELt library were originally developed to speed up the DNN having structured weight sparsity (SWS). Our SAS improved the accuracy/computation tradeoff by using the same hardware and software library. In the case of SWS, the index could be precomputed after training using cusparseLtSpMMAcompress function of cuSPARSELt library. Figure A2 illustrates the memory arrangement of value and index for cusparseLtMatmul operation for NVIDIA's Sparse Tensor Core. The value matrix follows the index matrix. In the case of a 1:2 sparse pattern (TF32), the index is stored using 4-bit (although it can be represented in 1-bit; Sparse Tensor Core use 4-bit to index a 1:2 pattern), and '0x4' and '0xe' is assigned for indexing the first and second element, respectively.
364
+
365
+ The important note for Sparse Tensor Core is that the order of the index is not aligned with its corresponding activation value; it needs to be reordered (L8 in listing 1), and the reordered index $\tilde{\mathcal{I}}$ needs to be supplied to the core to get the correct result. The arrangement depends on the size of activation matrices X (The memory arrangement in fig. A2 illustrates the specific case when the input matrix is $64\times 32$ ).
366
+
367
+ # HOW TO USE THE CUSPARSELTMATMUL FOR SAS?
368
+
369
+ One can also use the cusparseLtSpMMACompress function for SWS to executed the SAS matmul, ①compute the index $\mathcal{I}$ using equation 3, then ②explicitly computing the sparse activation $\tilde{\pmb{X}}$ and finally ③compute the reordered index $\tilde{\mathcal{I}}$ using cusparseLtSpMMACompress. However, it is redundant and inefficient. We already have compressed activation $\pmb{X}$ as an output from the previous layer; the index $\mathcal{I}$ is computed cheaply. We want to reorder the index $\mathcal{I}$ to get $\tilde{\mathcal{I}}$ without explicit construction of sparse activation $\tilde{\pmb{X}}$ as we discussed in the main text (section 2.3). The problem is that NVIDIA does not provide information about the rendering mechanism of cuSPARSELt.
370
+
371
+ # TOOLS FOR DIGGING UP THE REORDERING MATRIX
372
+
373
+ We developed a helper tool of $\mathsf{cuSAS}^5$ for finding out the rendering matrix $\pmb{O}$ for arbitrary size matrix to realize a general matmul for SAS activation. The core idea for realizing the elucidation is impulse response of cusparseLtSpMMACompress function. Specifically, we input the sparse activation $\tilde{\pmb{X}}$ ; all the odd element has a non-zero value except the $(i,j)$ element. Then, looking at the reordered index computed by cusparseLtSpMMACompress, we can find the destination index $(\tilde{i},\tilde{j})$ where $(i,j)$ element in the original index should be warped. Repeating this process for all the row-column pairs, we get the reordering matrix $\pmb{O}$ such that $\tilde{\mathcal{I}} = \mathcal{I}[O]$ . The reordering matrix $\pmb{O}$ depends only on the size of $\pmb{X}$ ; therefore could be precomputed. We'll also open-source this tool.
374
+
375
+ It is possible to implement the CUDA kernel, which runs the following operation at once for more efficient SAS matmul; ①checks the sign bit, ②assign either '0x4' or '0xe', and ③reorder.
376
+
377
+ ![](images/9f36da3b114b020f421c37e2e70f69d2d526e643bfc01bd50d6f1ac8be8065b7.jpg)
378
+ Figure A2: Memory arrangement for cusparseLtMatmul. The index is located just after the value. The index needs to be arranged for the execution of sparse matmul using cusparseLtMatmul. The formatting of the index depends on the size of the matrix X in listing 1. This figure illustrates the case for the 1:2 sparse pattern (TF32) and the input matrix size is $32 \times 64$ .
379
+
380
+ # F FINE-GRAINED (SEMI) STRUCTURED WEIGHT SPARSITY.
381
+
382
+ NVIDIA's SWS (NVIDIA, 2020) could speed up the matmul with weight having moderate rate sparsity (e.g., $50\%$ ) on GPU, which is almost impossible for the unstructured sparse pattern (section 5). They realized actual speed up by utilizing a specific pattern in their sparsity, namely $N:M$ structured sparsity. Suppose a typical matrix multiplication between activation $\mathbf{X} \in \mathbb{R}^{16 \times 32}$ and weight $\mathbf{W} \in \mathbb{R}^{32 \times 8}$ . The Dense Tensor Cores implement this matmul by two cycles. In contrast, the Sparse Tensor Core only needs one cycle if the weight tensor $\mathbf{W}$ satisfies the structured sparse pattern (fig. A3).
383
+
384
+ Our SAS could utilize the same hardware by the novel structured sparse projection mechanism. With the same computational budget and on the same hardware, SAS realizes better accuracy if one can use extra memory for storing the weight.
385
+
386
+ ![](images/c6521e20e5c046e6251775339cb9a11bdf5ef9c4515bc7d2fed47aad4c141109.jpg)
387
+ Figure A3: SWS matmul on Sparse Tensor Core NVIDIA (2020). Compare with our SAS matmul mechanism in fig. 2.
2024/SAS_ Structured Activation Sparsification/images.zip ADDED
@@ -0,0 +1,3 @@
 
 
 
 
1
+ version https://git-lfs.github.com/spec/v1
2
+ oid sha256:b782acd1156d8748cc8eb162693eba849a9af9c83cb39bb1b053abf13c2cd643
3
+ size 545209
2024/SAS_ Structured Activation Sparsification/layout.json ADDED
The diff for this file is too large to render. See raw diff
 
2024/SCHEMA_ State CHangEs MAtter for Procedure Planning in Instructional Videos/a25a3d49-2e2d-49a1-b878-39675fb39e91_content_list.json ADDED
The diff for this file is too large to render. See raw diff
 
2024/SCHEMA_ State CHangEs MAtter for Procedure Planning in Instructional Videos/a25a3d49-2e2d-49a1-b878-39675fb39e91_model.json ADDED
The diff for this file is too large to render. See raw diff
 
2024/SCHEMA_ State CHangEs MAtter for Procedure Planning in Instructional Videos/a25a3d49-2e2d-49a1-b878-39675fb39e91_origin.pdf ADDED
@@ -0,0 +1,3 @@
 
 
 
 
1
+ version https://git-lfs.github.com/spec/v1
2
+ oid sha256:c59424a7873f0c884b9723a7644263a49a4adce6d9b6c3c28401810233b6f361
3
+ size 1834220
2024/SCHEMA_ State CHangEs MAtter for Procedure Planning in Instructional Videos/full.md ADDED
@@ -0,0 +1,444 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ # SCHEMA: STATE CHANGES MATTER FOR PROCEDURE PLANNING IN INSTRUCTIONAL VIDEOS
2
+
3
+ Yulei Niu Wenliang Guo1 Long Chen2 Xudong Lin1 Shih-Fu Chang1
4
+
5
+ <sup>1</sup>Columbia University <sup>2</sup>The Hong Kong University of Science and Technology
6
+ yn.yuleiniu@gmail.com
7
+
8
+ # ABSTRACT
9
+
10
+ We study the problem of procedure planning in instructional videos, which aims to make a goal-oriented sequence of action steps given partial visual state observations. The motivation of this problem is to learn a structured and plannable state and action space. Recent works succeeded in sequence modeling of steps with only sequence-level annotations accessible during training, which overlooked the roles of states in the procedures. In this work, we point out that State CHangEs MAtter (SCHEMA) for procedure planning in instructional videos. We aim to establish a more structured state space by investigating the causal relations between steps and states in procedures. Specifically, we explicitly represent each step as state changes and track the state changes in procedures. For step representation, we leveraged the commonsense knowledge in large language models (LLMs) to describe the state changes of steps via our designed chain-of-thought prompting. For state change tracking, we align visual state observations with language state descriptions via cross-modal contrastive learning, and explicitly model the intermediate states of the procedure using LLM-generated state descriptions. Experiments on CrossTask, COIN, and NIV benchmark datasets demonstrate that our proposed SCHEMA model achieves state-of-the-art performance and obtains explainable visualizations.
11
+
12
+ # 1 INTRODUCTION
13
+
14
+ Humans are natural experts in procedure planning, i.e., arranging a sequence of instruction steps to achieve a specific goal. Procedure planning is an essential and fundamental reasoning ability for embodied AI systems and is crucial in complicated real-world problems like robotic navigation (Tellex et al., 2011; Jansen, 2020; Brohan et al., 2022). Instruction steps in procedural tasks are commonly state-modifying actions that induce state changes of objects. For example, for the task of "grilling steak", a raw steak would be first topped with pepper after "seasoning the steak", then placed on the grill before "closing the lid", and become cooked pieces after "cutting the steak". These before-states and after-states reflect fine-grained information like shape, color, size, and location of entities. Therefore, the planning agents need to figure out both the temporal relations between action steps and the causal relations between steps and states.
15
+
16
+ Instructional videos are natural resources for learning procedural activities from daily tasks. Chang et al. (2020) proposed the problem of procedure planning in instructional videos, which is to produce a sequence of action steps given the visual observations of start and goal states, as shown in Figure 1 (a). The motivation for this problem is to learn a structured and plannable state and action space (Chang et al., 2020). While earlier works (Chang et al., 2020; Sun et al., 2022; Bi et al., 2021) utilized the full annotations of step sequences and intermediate states as supervision (Figure 1(b)), recent works (Zhao et al., 2022; Wang et al., 2023b) achieved promising results with weaker supervision, where only step sequence annotations are available during training (Figure 1(c)). The weaker supervision setting reduces the expensive cost of video annotations and verifies the necessity of plannable action space. However, as the intermediate visual states are excluded during both training and evaluation, how to comprehensively represent the state information remains an open question.
17
+
18
+ This paper aims to establish a more structured state space for procedure planning by investigating the causal relations between steps and states in procedures. We first ask: how do humans recognize and
19
+
20
+ ![](images/50f56279cd48b6ef7c66b579dc4d5ebb8fac135d59dd89dde08dad456e93f8eb.jpg)
21
+ (d) LLM's descriptions as state supervision (ours)
22
+ Figure 1: (a) The procedure planning is to predict a sequence of action steps given the visual observations of start and goal states. (b) For the full supervision setting, intermediate states are annotated with timestamps in the videos. (c) For the weak supervision setting, only step names are annotated and taken as supervisions of intermediate states. (d) We represent each step as state changes and take LLMs-generated descriptions for state representation learning.
23
+
24
+ understand and distinguish steps in procedures? Instead of solely focusing on the action information, humans would track state changes in the procedures by leveraging their commonsense knowledge, which is more informative than only looking at the actions. For example, the steak is cooked and as a whole before "cutting" for "grilling steak", and becomes cooked pieces after the step. Previous NLP studies have demonstrated the helpfulness of state change modeling in various reasoning tasks, including automatic execution of biology experiments (Mysore et al., 2019), cooking recipes (Bollini et al., 2013), and daily activities (Yang & Nyberg, 2015). Recent studies further explicitly track state changes of entities in procedure texts (Mishra et al., 2018; Tandon et al., 2018; Zhang et al., 2023; Wu et al., 2023; Li & Huang, 2023). The success of state changes modeling motivates us to investigate the causal relations between steps and states for procedure planning.
25
+
26
+ In this work, we achieve this goal by representing each state-modifying step as state changes. The cores of our method are step representation and state change tracking. For step representation, motivated by the success of large language models (LLMs) in visual recognition (Menon & Vondrick, 2022), we leveraged LLMs to describe the state changes of each step. Specifically, we asked LLMs (e.g., GPT-3.5) to describe the states before and after each step with our designed chain-of-thought prompts (Sec. 3.2). For state changes tracking, as shown in Figure 1(d), we align the visual state observations with language state descriptions via cross-modal contrastive learning. Intuitively, the start visual state should be aligned with the before-state descriptions of the first step, while the goal visual state should be aligned with the after-state descriptions of the last step. As the language descriptions are more discriminative than visual states, we expect the multi-modal alignment to learn a more structured state space. We also take state descriptions as supervisions of intermediate visual states. Finally, the step prediction model is trained in a masked token prediction manner.
27
+
28
+ Our main contributions are summarized as follows:
29
+
30
+ - We pointed out that State CHangEs MAtter (SCHEMA) for procedure planning in instructional videos, and proposed a new representation of steps in procedural videos as state changes.
31
+ - We proposed to track state changes by aligning visual state observations with LLMs-generated language descriptions for a more structured state space and represent mid-states via descriptions.
32
+ - Our extensive experiments on CrossTask, COIN, and NIV datasets demonstrated the quality of state description generation and the effectiveness of our method.
33
+
34
+ # 2 RELATED WORK
35
+
36
+ Procedure Planning (Chang et al., 2020; Zhang et al., 2020) is an essential and fundamental problem for embodied agents. In this work, we followed Chang et al.'s (Chang et al., 2020) formulation of procedure planning. Recent works proposed different approaches for sequence generation, e.g., autoregressive Transformers (Sun et al., 2022), policy learning (Bi et al., 2021), probabilistic modeling (Bi et al., 2021), and diffusion models (Wang et al., 2023b). Interestingly, Zhao et al. (2022) used only language instructions as supervision for procedures and did not require full annotations of intermediate visual states, which highlights the importance of sequence generation for procedure planning. These methods commonly formulated the problem of procedure planning as conditional sequence generation, and the visual observations of states are treated as conditional inputs. However, the motivation of procedure planning is to align the state-modifying actions with their associated state changes, and expect the agents to understand how the state changes given the actions.
37
+
38
+ Instructional Videos Analysis. Instructional videos have been a good data source to obtain data for procedural activities (Rohrbach et al., 2016; Kuehne et al., 2014; Zhou et al., 2018; Zhukov et al., 2019; Tang et al., 2019; Miech et al., 2019). Existing research on this topic usually tackles understanding the step-task structures in instructional videos, where the step/task annotation can be either obtained from manual annotation on a relatively small set of videos (Zhou et al., 2018; Zhukov et al., 2019; Tang et al., 2019) or through weak/distant supervision on large unlabeled video data (Miech et al., 2019; Dvornik et al., 2023; Lin et al., 2022). For example, StepFormer (Dvornik et al., 2023) is a transformer decoder trained with video subtitles (mostly from automatic speech recognition) for discovering and localizing steps in instructional videos. Another recent research (Souček et al., 2022a) tackles a more fine-grained understanding of instructional videos, which learns to identify state-modifying actions via self-supervision. However, such approaches require training on the large collection of noisy unlabeled videos, which is expensive and inaccurate enough (Souček et al., 2022a).
39
+
40
+ Tracking State Changes is an essential reasoning ability in complex tasks like question answering and planning. Recent work has made continuous progress on explicitly tracking entity state changes in procedural texts (Mishra et al., 2018; Tandon et al., 2018; 2020; Zhang et al., 2023; Wu et al., 2023; Li & Huang, 2023). Some work in the CV area also investigated the relations between actions and states in videos (Alayrac et al., 2017; Souček et al., 2022a;b; Nishimura et al., 2021; Shirai et al., 2022; Xue et al., 2023; Souček et al., 2023; Saini et al., 2023). Especially, Nishimura et al. (2021) focused on the video procedural captioning task and proposed to model material state transition from visual observation, which introduces a visual simulator modified from a natural language understanding simulator. Shirai et al. (2022) established a multimodal dataset for object state change prediction, which consists of image pairs as state changes and workflow of receipt text as an action graph. However, the object category is limited to food or tools for cooking. Considering the similarity between procedural texts and instructional videos it is natural to explore state changes in instructional videos. In this work, we investigate state changes in procedural videos for procedure planning.
41
+
42
+ # 3 SCHEMA: STATE CHANGES MATTER
43
+
44
+ In this section, we introduce the details of our proposed framework, State CHangEs MAtter (SCHEMA). We first introduce the background of procedure planning in Sec. 3.1, and present our method in Sec. $3.2\sim 3.4$ . Specifically, we first provide the details of step representation in Sec. 3.2, model architecture in Sec. 3.3, and training and inference in Sec. 3.4.
45
+
46
+ # 3.1 PROBLEM FORMULATION
47
+
48
+ We follow Chang et al. (2020)'s formulation of procedure planning in instructional videos. As shown in Figure 1(a), given the visual observations of start state $s_0$ and goal state $s_T$ , the task is to plan a procedure, i.e., a sequence of action steps $\hat{\pi} = a_{1:T}$ , which can transform the state from $s_0$ to $s_T$ . The procedure planning problem can be formulated as $p(a_{1:T}|s_0,s_T)$ .
49
+
50
+ The motivation of this task is to learn a structured and plannable state and action space. For the training supervision, earlier works used full annotations of procedures including both action steps $a_{1:T}$ and their associated visual states, i.e., the states before and after the step, which are annotated as timestamps of videos (Figure 1(b)). Zhao et al. (2022) proposed to use weaker supervision
51
+
52
+ ![](images/1e7582f7c52e32d6a151239a7c268bd8d7de97ca1a8a948ed2209e6365f21212.jpg)
53
+ Figure 2: Examples of GPT-3.5 generated descriptions using our chain-of-thought prompting.
54
+
55
+ where only the action step annotations $a_{1:T}$ are available (Figure 1(c)), which reduces the expensive annotation cost for videos. Recent works under this setting show that the plannable action space can be established by conditional sequence generation (Zhao et al., 2022; Wang et al., 2023b). However, there remain open questions about the role of structured state space: why are intermediate states optional for procedure planning? Are there any better representations for steps and visual states?
56
+
57
+ # 3.2 STEP REPRESENTATION AS STATE CHANGES IN LANGUAGE
58
+
59
+ Our goal is to construct a more structured state space by investigating the causal relations between steps and states in procedures. Motivated by the success of state changes modeling in various reasoning tasks (Bollini et al., 2013; Yang & Nyberg, 2015; Mysore et al., 2019), we represent steps as their before-states and after-states. The state changes can be represented by visual observations or language descriptions. We observed that visual scenes in instructional videos are diverse and noisy, and the details are hard to capture if the object is far from the camera. In addition, the intermediate visual states may not be available due to the high cost of video annotations. Therefore, we represent state changes as discriminative and discrete language descriptions.
60
+
61
+ Motivated by Menon & Vondrick (2022), we leveraged large language models (LLMs), such as GPT-3.5 (Brown et al., 2020), to generate language descriptions of states based on their commonsense knowledge. In short, we fed each action step with its high-level task goal to the LLMs, and query several descriptions about the associate states before and after the action step. A baseline prompting following Menon & Vondrick (2022) for state descriptions is:
62
+
63
+ Q: What are useful features for distinguishing the states before and after [step] for [goal] in a frame?
64
+
65
+ A: There are several useful visual features to tell the state changes before and after [step] for [goal]:
66
+
67
+ However, we empirically found that this prompting does not work well for state descriptions, as LLMs disregard the commonsense knowledge behind the step. For example, given the action step "add onion" and the task "make kimchi fried rice", the before-state description is "the onion was uncut and unchopped", which is incorrect because the onion should have been cut.
68
+
69
+ Chain-of-thought Prompting. Aware of the misalignment between action and states, we proposed a chain-of-thought prompting (Wei et al., 2022) strategy to first describe the details of action steps and then describe the state changes according to the details of the steps. Our prompt is designed as:
70
+
71
+ First, describe the details of [step] for [goal] with one verb. Second, use 3 sentences to describe the status changes of objects before and after [step], avoiding using [verb].
72
+
73
+ where “[verb]” is the action name (e.g., “pour”) to increase the description diversity. We also provide several examples as context (see appendix). We fixed the number of descriptions as 3 as we empirically found that one or two descriptions cannot cover all the objects and attributes, while more than three descriptions are redundant. Figure 2 illustrates two examples of the generated descriptions based on our prompts. Overall, the step and state descriptions contain more details about attributes, locations, and relations of objects. In the following, for the step name $A_{i}$ , we denote its step description as $d_{i}^{s}$ , before-state descriptions as $\{d_{i1}^{b}, \dots, d_{iK}^{b}\}$ , and after-state descriptions as $\{d_{i1}^{a}, \dots, d_{iK}^{a}\}$ , where $K = 3$ in our implementation.
74
+
75
+ ![](images/b015c48de0885151995b51d9c14cf94025d981ad2185768fbe1ba0d36df28b9b.jpg)
76
+ Figure 3: The pipeline of our SCHEMA for procedure planning.
77
+
78
+ # 3.3 ARCHITECTURE
79
+
80
+ Figure 3 illustrates the overview of our SCHEMA pipeline. Overall, we break up the procedure planning problem $p(a_{1:T}|s_0,s_T)$ into two subproblems, i.e., mid-state prediction and step prediction. Mid-state prediction is to estimate the intermediate states $s_{1:(T - 1)}$ given $s_0$ and $s_T$ , i.e., $p(s_{1:(T - 1)}|s_0,s_T)$ . Step prediction is to predict the step sequence given the full states, i.e., $p(a_{1:T}|s_{0:T})$ . We formulate the procedure planning problem as:
81
+
82
+ $$
83
+ p \left(a _ {1: T} \mid s _ {0}, s _ {T}\right) = \int \underbrace {p \left(a _ {1 : T} \mid s _ {0 : T}\right)} _ {\text {s t e p p r e d i c t i o n}} \underbrace {p \left(s _ {1 : (T - 1)} \mid s _ {0} , s _ {T}\right)} _ {\text {m i d - s t a t e p r e d i c t i o n}} d s _ {1: (T - 1)}. \tag {1}
84
+ $$
85
+
86
+ # 3.3.1 STATE REPRESENTATION
87
+
88
+ We align visual observations with language descriptions of the same states to learn a structure state space, which will be introduced in Sec. 3.4.
89
+
90
+ State encoder. The state encoder takes the video frame as input and outputs its embedding. The state encoder $f_{s}^{enc}$ consists of a fixed pre-trained visual feature extractor $f^{vis}$ and a trainable projection (two-layer FFN) $f_{s}^{proj}$ . The embedding for state $s$ is obtained by $s^{enc} = f_{s}^{enc}(s) = f_{s}^{proj}(f^{vis}(s))$ .
91
+
92
+ Description encoder. Similar to the state encoder, the description encoder $f_{d}^{enc}$ consists of a fixed language feature extractor $f^{lang}$ and a trainable projection $f_{d}^{proj}$ . The description encoder takes description $d$ as input and outputs its embedding $d^{enc} = f_{d}^{enc}(d) = f_{d}^{proj}(f^{lang}(d))$ .
93
+
94
+ # 3.3.2 MID-STATE PREDICTION
95
+
96
+ State Decoder. The state decoder $f_{s}^{dec}$ is an non-autoregressive Transformer (Vaswani et al., 2017). The state decoder predicts the intermediate states $s_{1:(T-1)}$ given the start state $s_{0}$ and the goal state $s_{T}$ . The query for the state decoder is denoted as $Q_{s} = [s_{0}^{enc} + p_{0}, p_{1}, \dots, p_{T-1}, s_{T}^{enc} + p_{T}]$ , where $p_{i}$ denotes the $i$ -th positional embedding. The state decoder also takes the collection of state descriptions $D_{s} = \{d_{11}^{b}, \dots, d_{CK}^{b}, d_{11}^{a}, \dots, d_{CK}^{a}\}$ as the external memory $M$ , where $C$ is the number of step classes and $M = f_{d}^{enc}(D_{s})$ . The external memory interacts with the decoder via cross-attention. The state decoding process to obtain the embeddings $\hat{s}_{i}^{dec}$ is denoted as:
97
+
98
+ $$
99
+ \hat {s} _ {1} ^ {d e c}, \dots , \hat {s} _ {T - 1} ^ {d e c} = f _ {s} ^ {d e c} \left(Q _ {s}, M\right). \tag {2}
100
+ $$
101
+
102
+ # 3.3.3 STEP PREDICTION
103
+
104
+ Step Decoder. The step decoder $f_{a}^{dec}$ is a Transformer model with a similar architecture as the state decoder $f_{s}^{dec}$ . The query combines state embeddings and positional embeddings, denoted as $Q_{a} = [s_{0}^{enc} + q_{0}, q_{1}, \hat{s}_{1}^{dec} + p_{2}, \dots, \hat{s}_{T - 1}^{dec} + q_{2T - 2}, q_{2T - 1}, s_{T}^{enc} + q_{2T}]$ where $q_{i}$ denotes the
105
+
106
+ ![](images/b26510ab1f1669798a49d973cc7978020e5704ad1f4c9a7dff05c061dcb7acb9.jpg)
107
+ (a)
108
+
109
+ ![](images/c0af6612c956ab743786dd9b7d981b8ad323b207f4b3670824c28cd4781d1a8f.jpg)
110
+ (b)
111
+ Figure 4: (a) For structured state space learning, we force the visual state observation to be close to its language descriptions and away from others. (b) For mid-state prediction, we use the before-state descriptions and after-state descriptions as guidance to learn the presentation of mid-states.
112
+
113
+ $i$ -th positional embedding. Similar to the state decoder $f_{s}^{dec}$ , the step decoder $f_{a}^{dec}$ also takes $M = f_{d}^{enc}(D_{s})$ as the external memory. The step decoding process is denoted as:
114
+
115
+ $$
116
+ \hat {a} _ {1} ^ {d e c}, \dots , \hat {a} _ {T} ^ {d e c} = f _ {a} ^ {d e c} (Q _ {a}, M), \tag {3}
117
+ $$
118
+
119
+ where $\hat{a}_1^{dec},\dots ,\hat{a}_T^{dec}$ are the estimated action embeddings. A two-layer feed-forward network (FFN) $f_{a}^{cls}$ is built on top of $\hat{a}^{dec}$ as the step classifier to predict the logits of steps, i.e., $\hat{a} = f_a^{cls}(\hat{a}^{dec})$
120
+
121
+ In addition to capturing the task information, we establish a task classifier that takes the visual features of start and end states as input and outputs a vector to represent the task information (Wang et al., 2023b;a). The task feature is added to the queries $Q_{s}$ and $Q_{a}$ , where we omitted it for simplicity.
122
+
123
+ # 3.4 TRAINING AND INFERENCE
124
+
125
+ The training process consists of three parts: (1) state space learning that aligns visual observations with language descriptions, (2) masked state modeling for mid-state prediction, and (3) masked step modeling for step prediction. For simplicity, we define the losses with one procedure.
126
+
127
+ State Space Learning. Although vision-language models like CLIP (Radford et al., 2021) are pre-trained for vision-language alignment, they cannot be directly used for our problem as the pretraining is not designed for fine-grained state understanding. Therefore, we train two additional projections $f_{s}^{proj}$ and $f_{d}^{proj}$ on top of the visual encoder and language encoder. The added projections also allow us to align other visual features with language features. Given the start state $s_0$ (or end state $s_T$ ) and a step label $a_i$ , the similarity between $s_0$ (or $s_T$ ) and each step $A_i$ is calculated by $sim(s_0, A_i) = \sum_{j=1}^{K} < s_0^{enc}, d_{ij}^{enc,b} >$ and $sim(s_T, A_i) = \sum_{j=1}^{K} < s_T^{enc}, d_{ij}^{enc,a} >$ , where $<\cdot, \cdot>$ denotes the dot product. Figure 4 (a) illustrates the idea of structured state space via vision-language alignment. Specifically, we regard the language descriptions with the same state as positive samples, and take descriptions of the other states as negative samples. We define the contrastive loss as:
128
+
129
+ $$
130
+ L _ {s} ^ {\text {e n c}} = \underbrace {- \log \frac {\exp \left(\operatorname {s i m} \left(s _ {0} , A _ {a _ {1}}\right)\right)}{\sum_ {i = 1} ^ {C} \exp \left(\operatorname {s i m} \left(s _ {0} , A _ {i}\right)\right)}} _ {\text {s t a r t s t a t e}} - \underbrace {\log \frac {\exp \left(\operatorname {s i m} \left(s _ {T} , A _ {a _ {T}}\right)\right)}{\sum_ {i = 1} ^ {C} \exp \left(\operatorname {s i m} \left(s _ {T} , A _ {i}\right)\right)}} _ {\text {e n d s t a t e}} \tag {4}
131
+ $$
132
+
133
+ Masked State Modeling. The mid-state prediction process can be regarded as a masked state modeling problem, where the intermediate states are masked from the state sequence, and the state decoder recovers the masked states. Since the annotations of intermediate states in videos are not available, we instead use LLMs-generated state descriptions as guidance. In a procedure $(s_0, a_1, s_1, \dots, s_{T-1}, a_T, s_T)$ where the mid-state $s_t$ is the after-state for action $a_t$ and before-state for action $a_{t+1}$ , we use the before-state descriptions of $a_t$ and after-state descriptions of $a_{t+1}$ as the supervision for $s_t$ . Figure 4(b) illustrates the idea of mid-state learning. We average the description embeddings as the target embedding $\hat{s}_t^{dec}$ for $s_t$ , and calculate the mean squared error between $\hat{s}_t^{dec}$
134
+
135
+ Table 1: Comparison with other methods on CrossTask dataset.
136
+
137
+ <table><tr><td rowspan="2">Models</td><td colspan="3">T=3</td><td colspan="3">T=4</td><td>T=5</td><td>T=6</td></tr><tr><td>SR↑</td><td>mAcc↑</td><td>mIoU↑</td><td>SR↑</td><td>mAcc↑</td><td>mIoU↑</td><td>SR↑</td><td>SR↑</td></tr><tr><td>Random</td><td>&lt;0.01</td><td>0.94</td><td>1.66</td><td>&lt;0.01</td><td>0.83</td><td>1.66</td><td>&lt;0.01</td><td>&lt;0.01</td></tr><tr><td>Retrieval-Based</td><td>8.05</td><td>23.30</td><td>32.06</td><td>3.95</td><td>22.22</td><td>36.97</td><td>2.40</td><td>1.10</td></tr><tr><td>WLTDO</td><td>1.87</td><td>21.64</td><td>31.70</td><td>0.77</td><td>17.92</td><td>26.43</td><td>—</td><td>—</td></tr><tr><td>UAAA</td><td>2.15</td><td>20.21</td><td>30.87</td><td>0.98</td><td>19.86</td><td>27.09</td><td>—</td><td>—</td></tr><tr><td>UPN</td><td>2.89</td><td>24.39</td><td>31.56</td><td>1.19</td><td>21.59</td><td>27.85</td><td>—</td><td>—</td></tr><tr><td>DDN</td><td>12.18</td><td>31.29</td><td>47.48</td><td>5.97</td><td>27.10</td><td>48.46</td><td>3.10</td><td>1.20</td></tr><tr><td>PlaTe</td><td>16.00</td><td>36.17</td><td>65.91</td><td>14.00</td><td>35.29</td><td>55.36</td><td>—</td><td>—</td></tr><tr><td>Ext-MGAIL w/o Aug.</td><td>18.01</td><td>43.86</td><td>57.16</td><td>—</td><td>—</td><td>—</td><td>—</td><td>—</td></tr><tr><td>Ext-GAIL</td><td>21.27</td><td>49.46</td><td>61.70</td><td>16.41</td><td>43.05</td><td>60.93</td><td>—</td><td>—</td></tr><tr><td>P3IV w/o Adv.</td><td>22.12</td><td>45.57</td><td>67.40</td><td>—</td><td>—</td><td>—</td><td>—</td><td>—</td></tr><tr><td>P3IV</td><td>23.34</td><td>49.96</td><td>73.89</td><td>13.40</td><td>44.16</td><td>70.01</td><td>7.21</td><td>4.40</td></tr><tr><td>EGPP</td><td>26.40</td><td>53.02</td><td>74.05</td><td>16.49</td><td>48.00</td><td>70.16</td><td>8.96</td><td>5.76</td></tr><tr><td>SCHEMA (Ours)</td><td>31.83</td><td>57.31</td><td>78.33</td><td>19.71</td><td>51.85</td><td>74.46</td><td>11.41</td><td>7.68</td></tr></table>
138
+
139
+ and $s_t^{dec}$ as the mid-state prediction loss:
140
+
141
+ $$
142
+ s _ {t} ^ {d e c} = \frac {1}{2 K} \left(\sum_ {j = 1} ^ {K} d _ {a _ {t, j}} ^ {e n c, a} + d _ {a _ {t + 1, j}} ^ {e n c, b}\right), \quad L _ {s} ^ {d e c} = \sum_ {t = 1} ^ {T - 1} \left(\hat {s} _ {t} ^ {d e c} - s _ {t} ^ {d e c}\right) ^ {2}. \tag {5}
143
+ $$
144
+
145
+ Masked Step Modeling. Similar to mid-state estimation, the step prediction process can also be regarded as a masked step modeling problem, where the steps are masked from the state-action sequences. The loss is the cross-entropy between ground-truth answers $a_{t}$ and predictions $\hat{a}_{t}^{dec}$ , i.e., $L_{a}^{dec} = \sum_{t=1}^{T} -a_{t}\log\hat{a}_{t}^{dec}$ . The final loss combines the above losses, i.e., $L = L_{s}^{enc} + L_{s}^{dec} + L_{a}^{dec}$ .
146
+
147
+ Inference. The non-autoregressive Transformer model may make insufficient use of the temporal relation information among the action steps, i.e., action co-occurrence frequencies. Inspired by the success of Viterbi algorithm(Viterbi, 1967) in sequential labeling works (Koller et al., 2016; 2017; Richard et al., 2017; 2018), we follow Zhao et al. (2022) and conduct the Viterbi algorithm for post-processing during inference. For Viterbi, we obtained the emission matrix based on the probability distribution over $\left[\hat{a}_1^{dec},\dots ,\hat{a}_T^{dec}\right]$ , and estimated the transition matrix based on action co-occurrence frequencies in the training set. Different from Zhao et al. (2022) that applied Viterbi to probabilistic modeling, we applied Viterbi to deterministic modeling. Specifically, instead of sampling 1,500 generated sequences to estimate the emission matrix (Zhao et al., 2022), we run the feedforwarding only once and use the single predicted probability matrix as the emission matrix, which is simpler and more efficient.
148
+
149
+ # 4 EXPERIMENTS
150
+
151
+ # 4.1 EVALUATION PROTOCOL
152
+
153
+ Datasets. We evaluate our SCHEMA method on three benchmark instruction video datasets, CrossTask (Zhukov et al., 2019), and COIN (Tang et al., 2019), and NIV (Alayrac et al., 2016). The CrossTask dataset consists of 2,750 videos from 18 tasks depicting 133 actions, with an average of 7.6 actions per video. The COIN dataset contains 11,827 videos from 180 tasks, with an average of 3.6 actions per video. The NIV dataset contains 150 videos with an average of 9.5 actions per video. Following previous works (Chang et al., 2020; Bi et al., 2021; Sun et al., 2022), we randomly select $70\%$ of the videos in each task as the training set and take the others as the test set. We extract all the step sequences $a_{t:(t + T - 1)}$ in the videos as procedures with the time horizon $T$ as 3 or 4.
154
+
155
+ Feature Extractors. As our goal for state space learning is to align visual observation and language descriptions, we tried CLIP (Radford et al., 2021) ViT-L/14 model as visual encoder and its associated pretrained Transformer as language encoder. We also follow recent works and use the S3D network (Miech et al., 2019) pretrained on the HowTo100M dataset (Miech et al., 2020) as the visual encoder, and add two projections for vision-language alignment (Sec. 3.4). We empirically found
156
+
157
+ Table 2: Comparison with PDPP on CrossTask dataset. † denotes the results under PDPP's setting.
158
+
159
+ <table><tr><td rowspan="2">Models</td><td colspan="3">T=3</td><td colspan="3">T=4</td><td>T=5</td><td>T=6</td></tr><tr><td>SR↑</td><td>mAcc↑</td><td>mIoU↑</td><td>SR↑</td><td>mAcc↑</td><td>mIoU↑</td><td>SR↑</td><td>SR↑</td></tr><tr><td>PDPP</td><td>26.38</td><td>55.62</td><td>59.34</td><td>18.69</td><td>52.44</td><td>62.38</td><td>13.22</td><td>7.60</td></tr><tr><td>SCHEMA (Ours)</td><td>31.83</td><td>57.31</td><td>78.33</td><td>19.71</td><td>51.85</td><td>74.46</td><td>11.41</td><td>7.68</td></tr><tr><td>PDPP†</td><td>37.20</td><td>64.67</td><td>66.57</td><td>21.48</td><td>57.82</td><td>65.13</td><td>13.45</td><td>8.41</td></tr><tr><td>SCHEMA (Ours)†</td><td>38.93</td><td>63.80</td><td>79.82</td><td>24.50</td><td>58.48</td><td>76.48</td><td>14.75</td><td>10.53</td></tr></table>
160
+
161
+ Table 3: Comparisons with other methods on COIN dataset.
162
+
163
+ <table><tr><td rowspan="2">Models</td><td colspan="3">T=3</td><td colspan="3">T=4</td></tr><tr><td>SR↑</td><td>mAcc↑</td><td>mIoU↑</td><td>SR↑</td><td>mAcc↑</td><td>mIoU↑</td></tr><tr><td>Random</td><td>&lt;0.01</td><td>&lt;0.01</td><td>2.47</td><td>&lt;0.01</td><td>&lt;0.01</td><td>2.32</td></tr><tr><td>Retrieval</td><td>4.38</td><td>17.40</td><td>32.06</td><td>2.71</td><td>14.29</td><td>36.97</td></tr><tr><td>DDN</td><td>13.90</td><td>20.19</td><td>64.78</td><td>11.13</td><td>17.71</td><td>68.06</td></tr><tr><td>P3IV</td><td>15.40</td><td>21.67</td><td>76.31</td><td>11.32</td><td>18.85</td><td>70.53</td></tr><tr><td>EGPP</td><td>19.57</td><td>31.42</td><td>84.95</td><td>13.59</td><td>26.72</td><td>84.72</td></tr><tr><td>SCHEMA (Ours)</td><td>32.09</td><td>49.84</td><td>83.83</td><td>22.02</td><td>45.33</td><td>83.47</td></tr></table>
164
+
165
+ that video-based pre-trained features perform better than image-based pre-trained features. In the following, we used the pretrained S3D model as visual encoder.
166
+
167
+ Metrics. Following previous works (Chang et al., 2020; Bi et al., 2021; Sun et al., 2022; Zhao et al., 2022), we evaluate the models on three metrics. (1) Success Rate (SR) is the most strict metric that regards a procedure as a success if all the predicted action steps in the procedure match the ground-truth steps. (2) mean Accuracy (mAcc) calculates the average accuracy of the predicted actions at each step. (3) mean Intersection over Union (mIoU) is the least strict metric that calculates the overlap between the predicted procedure and ground-truth plan, obtained by $\frac{|\{a_t\} \cap \{\hat{a}_t\}|}{|\{a_t\} \cup \{\hat{a}_t\}|}$ , where $\{\hat{a}_t\}$ is the set of predicted actions and $\{a_t\}$ is the set of ground truths.
168
+
169
+ Baselines. We follow previous works and consider the following baseline methods for comparisons. The recent baselines are (1) PlaTe (Sun et al., 2022), which extends DNN and uses a Transformer-based architecture; (2) Ext-GAIL (Bi et al., 2021), which uses reinforcement learning for procedure planning; (3) $\mathrm{P}^3\mathrm{IV}$ (Zhao et al., 2022), which is the first to use weak supervision and proposed a generative adversarial framework; (4) PDPP (Wang et al., 2023b), which is a diffusion-based model for sequence distribution modeling; and (5) EGPP (Wang et al., 2023a), which extracts event information for procedure planning. Details of other earlier baselines can be found in appendix.
170
+
171
+ # 4.2 RESULTS
172
+
173
+ Comparisons with Other Methods. Tables 1 and 3 show the comparisons between our method and others on CrossTask and COIN datasets. Overall, our proposed method outperforms other methods by large margins on all the datasets and metrics. Specifically, for $T = 3$ on CrossTask, our method outperforms $\mathrm{P}^3\mathrm{IV}$ by over $8\%$ (31.83 vs. 23.34) on the sequence-level metric SR and outperforms EGPP by over $5\%$ (31.83 vs. 26.40). The improvements are consistent with longer procedures (i.e., $T = 4, 5, 6$ ), and other two step-level metrics mAcc and mIoU. We also found that both $\mathrm{P}^3\mathrm{IV}$ and EGPP didn't work well on COIN compared to their performances on CrossTask. Specifically, $\mathrm{P}^3\mathrm{IV}$ outperforms DDN by large margins on CrossTask (e.g., 23.34 vs. 12.18 for SR with $T = 3$ ). However, the improvements on COIN become marginal, especially for longer procedures (i.e., 11.32 vs. 11.13 for SR with $T = 4$ ). The similar results are observed on EGPP, As comparisons, the SR of our SEPP is consistently larger than P3IV by over $16\%$ for $T = 3$ and $10\%$ for $T = 4$ . The improvements of mACC and mIoU are also significant. These results demonstrate the better generality and effectiveness of our method on different datasets compared to P3IV and EGPP.
174
+
175
+ An exception case is the recent work PDPP (Wang et al., 2023b) which achieves higher performance on both datasets. However, we argued that they define the start state and end state differently.
176
+
177
+ Table 4: Ablation studies on state space learning and mid-state prediction on CrossTask with $T = 3$ .
178
+
179
+ <table><tr><td></td><td>State Align.</td><td>Mid-state Pred.</td><td>SR↑</td><td>mAcc↑</td><td>mIoU↑</td></tr><tr><td>(a)</td><td></td><td></td><td>28.72</td><td>54.72</td><td>76.66</td></tr><tr><td>(b)</td><td></td><td>✓</td><td>29.41</td><td>54.92</td><td>77.26</td></tr><tr><td>(c)</td><td>✓</td><td></td><td>30.15</td><td>56.32</td><td>77.68</td></tr><tr><td>(d)</td><td>✓</td><td>✓</td><td>31.83</td><td>57.31</td><td>78.33</td></tr></table>
180
+
181
+ ![](images/db2be2117fcbfcf094c77d0eecf943b8b0c43d9b407ae31822dfea64aaabc2f4.jpg)
182
+ Figure 5: Examples of state justifications from our model.
183
+
184
+ ![](images/6a02abc8d841e3ff2c53848337f2f0455beba18c3005860b914fc8221ec4616d.jpg)
185
+
186
+ Specifically, previous works define states as a 2-second window around the start/end time, while PDPP defines the window after the start time and before the end time. Such a definition is more likely to access step information especially for short-term actions, leading to unfair comparisons with other methods. We further compared our method with PDPP under both conventional setting and their setting. The results on Table 2 show that our method outperforms PDPP with $T = 3$ and $T = 4$ under both settings, and the main improvement of PDPP comes from the different setting with a small $T$ (e.g., $\sim 11\%$ increase of SR on $T = 3$ ). An interesting observation is that the benefits of different settings to PDPP become marginal with a larger $T$ , which may be credited to their diffusion model.
187
+
188
+ Ablation Studies. We first conduct ablation studies on CrossTask to validate the effect of two key components, state alignment (Eq. 4 and Figure 4(a)) and mid-state prediction (Sec. 3.3.2). As shown in Table 4, visual-language alignment improves SR by $1.4\sim 2.4\%$ ((c) vs. (a), (d) vs. (b)) for $T = 3$ on CrossTask. Also, the mid-state prediction module also improves the performance, and the improvements become larger with state alignment (i.e., $+0.69\%$ on SR w/o state alignment vs. $+1.68\%$ on SR with state alignment). The entire combination (d) achieves the best results. These results verified the impacts of state space learning and mid-state prediction. More ablation studies are in the appendix.
189
+
190
+ Qualitative Results. Figure 5 illustrates examples of state justifications, i.e., how the model aligns visual state observation with language descriptions. We retrieve top-5 similar descriptions from the corpus of state descriptions. Overall, the retrieved descriptions match the image well, and most of the top similar descriptions are aligned with the visual observations, which improved the explainable state understanding. More visualization results are in the appendix.
191
+
192
+ # 5 CONCLUSION
193
+
194
+ In this work, we pointed out that State CHangEs MAtter (SCHEMA) for procedure planning in instructional videos, and proposed to represent steps as state changes and track state changes in procedural videos. We leveraged large language models (i.e., GPT-3.5) to generate descriptions of state changes, and align the visual states with language descriptions for a more structured state space. We further decompose the procedure planning into two subproblems, mid-state prediction and step prediction. Extensive experiments further verified that our proposed state representation can promote procedure planning. In the future, potential directions are to establish a benchmark dataset to explicitly track state changes in instructional videos, and to investigate the roles of state changes tracking in other procedural learning tasks like pre-training and future step forecasting. In addition, multimodal procedural planning would be a practical and challenging problem that generates coherent textual plans and visual plans, reflecting the state changes in multiple modalities.
195
+
196
+ # ACKNOWLEDGEMENT
197
+
198
+ This work is supported by U.S. DARPA KAIROS Program No. FA8750-19-2-1004. The views and conclusions contained herein are those of the authors and should not be interpreted as necessarily representing the official policies, either expressed or implied, of DARPA, or the U.S. Government. The U.S. Government is authorized to reproduce and distribute reprints for governmental purposes notwithstanding any copyright annotation therein.
199
+
200
+ # REFERENCES
201
+
202
+ Yazan Abu Farha and Juergen Gall. Uncertainty-aware anticipation of activities. In Proceedings of the IEEE/CVF International Conference on Computer Vision Workshops, pp. 0-0, 2019.
203
+ Jean-Baptiste Alayrac, Piotr Bojanowski, Nishant Agrawal, Josef Sivic, Ivan Laptev, and Simon Lacoste-Julien. Unsupervised learning from narrated instruction videos. In Proceedings of the IEEE Conference on Computer Vision and Pattern Recognition, pp. 4575-4583, 2016.
204
+ Jean-Baptiste Alayrac, Ivan Laptev, Josef Sivic, and Simon Lacoste-Julien. Joint discovery of object states and manipulation actions. In Proceedings of the IEEE International Conference on Computer Vision, pp. 2127-2136, 2017.
205
+ Jing Bi, Jiebo Luo, and Chenliang Xu. Procedure planning in instructional videos via contextual modeling and model-based policy learning. In Proceedings of the IEEE/CVF International Conference on Computer Vision, pp. 15611-15620, 2021.
206
+ Mario Bollini, Stefanie TELlex, Tyler Thompson, Nicholas Roy, and Daniela Rus. Interpreting and executing recipes with a cooking robot. In Experimental Robotics: The 13th International Symposium on Experimental Robotics, pp. 481-495. Springer, 2013.
207
+ Anthony Brohan, Yevgen Chebotar, Chelsea Finn, Karol Hausman, Alexander Herzog, Daniel Ho, Julian Ibarz, Alex Irpan, Eric Jang, Ryan Julian, et al. Do as i can, not as i say: Grounding language in robotic affordances. In 6th Annual Conference on Robot Learning, 2022.
208
+ Tom Brown, Benjamin Mann, Nick Ryder, Melanie Subbiah, Jared D Kaplan, Prafulla Dhariwal, Arvind Neelakantan, Pranav Shyam, Girish Sastry, Amanda Askell, et al. Language models are few-shot learners. Advances in neural information processing systems, 33:1877-1901, 2020.
209
+ Chien-Yi Chang, De-An Huang, Danfei Xu, Ehsan Adeli, Li Fei-Fei, and Juan Carlos Niebles. Procedure planning in instructional videos. In Computer Vision-ECCV 2020: 16th European Conference, Glasgow, UK, August 23-28, 2020, Proceedings, Part XI, pp. 334-350. Springer, 2020.
210
+ Nikita Dvornik, Isma Hadji, Ran Zhang, Konstantinos G Derpanis, Animesh Garg, Richard P Wildes, and Allan D Jepson. Stepformer: Self-supervised step discovery and localization in instructional videos. arXiv preprint arXiv:2304.13265, 2023.
211
+ Kiana Ehsani, Hessam Bagherinezhad, Joseph Redmon, Roozbeh Mottaghi, and Ali Farhadi. Who let the dogs out? modeling dog behavior from visual data. In Proceedings of the IEEE Conference on Computer Vision and Pattern Recognition, pp. 4051-4060, 2018.
212
+ Peter Jansen. Visually-grounded planning without vision: Language models infer detailed plans from high-level instructions. In Findings of the Association for Computational Linguistics: EMNLP 2020, pp. 4412-4417, 2020.
213
+ Oscar Koller, Hermann Ney, and Richard Bowden. Deep hand: How to train a cnn on 1 million hand images when your data is continuous and weakly labelled. In Proceedings of the IEEE conference on computer vision and pattern recognition, pp. 3793-3802, 2016.
214
+ Oscar Koller, Sepehr Zargaran, and Hermann Ney. Re-sign: Re-aligned end-to-end sequence modelling with deep recurrent cnn-hmms. In Proceedings of the IEEE conference on computer vision and pattern recognition, pp. 4297-4305, 2017.
215
+
216
+ Hilde Kuehne, Ali Arslan, and Thomas Serre. The language of actions: Recovering the syntax and semantics of goal-directed human activities. In Proceedings of the IEEE conference on computer vision and pattern recognition, pp. 780-787, 2014.
217
+ Mingchen Li and Lifu Huang. Understand the dynamic world: An end-to-end knowledge informed framework for open domain entity state tracking. arXiv preprint arXiv:2304.13854, 2023.
218
+ Xudong Lin, Fabio Petroni, Gedas Bertasius, Marcus Rohrbach, Shih-Fu Chang, and Lorenzo Torresani. Learning to recognize procedural activities with distant supervision. In Proceedings of the IEEE/CVF Conference on Computer Vision and Pattern Recognition, pp. 13853-13863, 2022.
219
+ Sachit Menon and Carl Vondrick. Visual classification via description from large language models. arXiv preprint arXiv:2210.07183, 2022.
220
+ Antoine Miech, Dimitri Zhukov, Jean-Baptiste Alayrac, Makarand Tapaswi, Ivan Laptev, and Josef Sivic. Howto100m: Learning a text-video embedding by watching hundred million narrated video clips. In Proceedings of the IEEE/CVF International Conference on Computer Vision, pp. 2630-2640, 2019.
221
+ Antoine Miech, Jean-Baptiste Alayrac, Lucas Smaira, Ivan Laptev, Josef Sivic, and Andrew Zisserman. End-to-end learning of visual representations from uncurated instructional videos. In Proceedings of the IEEE/CVF Conference on Computer Vision and Pattern Recognition, pp. 9879-9889, 2020.
222
+ Bhavana Dalvi Mishra, Lifu Huang, Niket Tandon, Wen-tau Yih, and Peter Clark. Tracking state changes in procedural text: a challenge dataset and models for process paragraph comprehension. arXiv preprint arXiv:1805.06975, 2018.
223
+ Sheshera Mysore, Zach Jensen, Edward Kim, Kevin Huang, Haw-Shiuan Chang, Emma Strubell, Jeffrey Flanigan, Andrew McCallum, and Elsa Olivetti. The materials science procedural text corpus: Annotating materials synthesis procedures with shallow semantic structures. arXiv preprint arXiv:1905.06939, 2019.
224
+ Taichi Nishimura, Atsushi Hashimoto, Yoshitaka Ushiku, Hirotaka Kameko, and Shinsuke Mori. State-aware video procedural captioning. In Proceedings of the 29th ACM International Conference on Multimedia, pp. 1766-1774, 2021.
225
+ Alec Radford, Jong Wook Kim, Chris Hallacy, Aditya Ramesh, Gabriel Goh, Sandhini Agarwal, Girish Sastry, Amanda Askell, Pamela Mishkin, Jack Clark, et al. Learning transferable visual models from natural language supervision. In International conference on machine learning, pp. 8748-8763. PMLR, 2021.
226
+ Alexander Richard, Hilde Kuehne, and Juergen Gall. Weakly supervised action learning with rn based fine-to-coarse modeling. In Proceedings of the IEEE conference on Computer Vision and Pattern Recognition, pp. 754-763, 2017.
227
+ Alexander Richard, Hilde Kuehne, Ahsan Iqbal, and Juergen Gall. Neuralnetwork-viterbi: A framework for weakly supervised video learning. In Proceedings of the IEEE conference on Computer Vision and Pattern Recognition, pp. 7386-7395, 2018.
228
+ Marcus Rohrbach, Anna Rohrbach, Michaela Regneri, Sikandar Amin, Mykhaylo Andriluka, Manfred Pinkal, and Bernt Schiele. Recognizing fine-grained and composite activities using hand-centric features and script data. 2016.
229
+ Nirat Saini, Hanyu Wang, Archana Swaminathan, Vinoj Jayasundara, Bo He, Kamal Gupta, and Abhinav Shrivastava. Chop & learn: Recognizing and generating object-state compositions. In Proceedings of the IEEE/CVF International Conference on Computer Vision, pp. 20247-20258, 2023.
230
+ Keisuke Shirai, Atsushi Hashimoto, Taichi Nishimura, Hirotaka Kameko, Shuhei Kurita, Yoshitaka Ushiku, and Shinsuke Mori. Visual recipe flow: A dataset for learning visual state changes of objects with recipe flows. In Proceedings of the 29th International Conference on Computational Linguistics, pp. 3570-3577, 2022.
231
+
232
+ Tomáš Souček, Jean-Baptiste Alayrac, Antoine Miech, Ivan Laptev, and Josef Sivic. Look for the change: Learning object states and state-modifying actions from untrimmed web videos. In Proceedings of the IEEE/CVF Conference on Computer Vision and Pattern Recognition, pp. 13956-13966, 2022a.
233
+ Tomáš Souček, Jean-Baptiste Alayrac, Antoine Miech, Ivan Laptev, and Josef Sivic. Multi-task learning of object state changes from uncurated videos. arXiv preprint arXiv:2211.13500, 2022b.
234
+ Tomáš Souček, Dima Damen, Michael Wray, Ivan Laptev, and Josef Sivic. Genhowto: Learning to generate actions and state transformations from instructional videos. arXiv preprint arXiv:2312.07322, 2023.
235
+ Aravind Srinivas, Allan Jabri, Pieter Abbeel, Sergey Levine, and Chelsea Finn. Universal planning networks: Learning generalizable representations for visuomotor control. In International Conference on Machine Learning, pp. 4732-4741. PMLR, 2018.
236
+ Jiankai Sun, De-An Huang, Bo Lu, Yun-Hui Liu, Bolei Zhou, and Animesh Garg. Plate: Visually-grounded planning with transformers in procedural tasks. IEEE Robotics and Automation Letters, 7(2):4924-4930, 2022.
237
+ Niket Tandon, Bhavana Dalvi Mishra, Joel Grus, Wen-tau Yih, Antoine Bosselut, and Peter Clark. Reasoning about actions and state changes by injecting commonsense knowledge. arXiv preprint arXiv:1808.10012, 2018.
238
+ Niket Tandon, Keisuke Sakaguchi, Bhavana Dalvi Mishra, Dheeraj Rajagopal, Peter Clark, Michal Guerquin, Kyle Richardson, and Eduard Hovy. A dataset for tracking entities in open domain procedural text. arXiv preprint arXiv:2011.08092, 2020.
239
+ Yansong Tang, Dajun Ding, Yongming Rao, Yu Zheng, Danyang Zhang, Lili Zhao, Jiwen Lu, and Jie Zhou. Coin: A large-scale dataset for comprehensive instructional video analysis. In Proceedings of the IEEE/CVF Conference on Computer Vision and Pattern Recognition, pp. 1207-1216, 2019.
240
+ Stefanie Tellex, Thomas Kollar, Steven Dickerson, Matthew Walter, Ashis Banerjee, Seth Teller, and Nicholas Roy. Understanding natural language commands for robotic navigation and mobile manipulation. In Proceedings of the AAAI Conference on Artificial Intelligence, pp. 1507-1514, 2011.
241
+ Ashish Vaswani, Noam Shazeer, Niki Parmar, Jakob Uszkoreit, Llion Jones, Aidan N Gomez, Lukasz Kaiser, and Illia Polosukhin. Attention is all you need. Advances in neural information processing systems, 30, 2017.
242
+ Andrew Viterbi. Error bounds for convolutional codes and an asymptotically optimum decoding algorithm. IEEE transactions on Information Theory, 13(2):260-269, 1967.
243
+ An-Lan Wang, Kun-Yu Lin, Jia-Run Du, Jingke Meng, and Wei-Shi Zheng. Event-guided procedure planning from instructional videos with text supervision. arXiv preprint arXiv:2308.08885, 2023a.
244
+ Hanlin Wang, Yilu Wu, Sheng Guo, and Limin Wang. Pdpp: Projected diffusion for procedure planning in instructional videos. arXiv preprint arXiv:2303.14676, 2023b.
245
+ Jason Wei, Xuezhi Wang, Dale Schuurmans, Maarten Bosma, Ed Chi, Quoc Le, and Denny Zhou. Chain of thought prompting elicits reasoning in large language models. arXiv preprint arXiv:2201.11903, 2022.
246
+ Xueqing Wu, Sha Li, and Heng Ji. Openpi-c: A better benchmark and stronger baseline for open-vocabulary state tracking. arXiv preprint arXiv:2306.00887, 2023.
247
+ Zihui Xue, Kumar Ashutosh, and Kristen Grauman. Learning object state changes in videos: An open-world perspective. arXiv preprint arXiv:2312.11782, 2023.
248
+ Zi Yang and Eric Nyberg. Leveraging procedural knowledge for task-oriented search. In Proceedings of the 38th International ACM SIGIR Conference on Research and Development in Information Retrieval, pp. 513-522, 2015.
249
+
250
+ Andy Zeng, Maria Attarian, Brian Ichter, Krzysztof Choromanski, Adrian Wong, Stefan Welker, Federico Tombari, Aveek Purohit, Michael Ryoo, Vikas Sindhwani, et al. Socratic models: Composing zero-shot multimodal reasoning with language. arXiv preprint arXiv:2204.00598, 2022.
251
+ Li Zhang, Qing Lyu, and Chris Callison-Burch. Reasoning about goals, steps, and temporal ordering with wikihow. arXiv preprint arXiv:2009.07690, 2020.
252
+ Li Zhang, Hainiu Xu, Abhinav Kommula, Niket Tandon, and Chris Callison-Burch. Openpi2.0: An improved dataset for entity tracking in texts. arXiv preprint arXiv:2305.14603, 2023.
253
+ He Zhao, Isma Hadji, Nikita Dvornik, Konstantinos G Derpanis, Richard P Wildes, and Allan D Jepson. P3iv: Probabilistic procedure planning from instructional videos with weak supervision. In Proceedings of the IEEE/CVF Conference on Computer Vision and Pattern Recognition, pp. 2938-2948, 2022.
254
+ Luowei Zhou, Chenliang Xu, and Jason J Corso. Towards automatic learning of procedures from web instructional videos. In Thirty-Second AAAI Conference on Artificial Intelligence, 2018.
255
+ Dimitri Zhukov, Jean-Baptiste Alayrac, Ramazan Gokberk Cinbis, David Fouhey, Ivan Laptev, and Josef Sivic. Cross-task weakly supervised learning from instructional videos. In Proceedings of the IEEE/CVF Conference on Computer Vision and Pattern Recognition, pp. 3537-3545, 2019.
256
+
257
+ # APPENDIX
258
+
259
+ # A IMPLEMENTATION DETAILS
260
+
261
+ In Section 3.3, we introduced the architecture of our SCHEMA. In the appendix, we further introduce the implementation details of the model, including model architecture and training.
262
+
263
+ Chain-of-Thought Prompting. Recall that we use a chain-of-thought prompt with examples to trigger the language model, which encourages the language model to generate the descriptions of state changes according to the action description. For example, for the action step "cut banana" in the task "make banana ice cream", the form of our prompt is:
264
+
265
+ First, describe the details of [step] for [goal] with one verb. Second, use 3 sentences to describe the status changes of objects before and after [step], avoiding using [verb].
266
+
267
+ ```txt
268
+ [goal]: Grill steak
269
+ [step]: season steak
270
+ [verb]: season
271
+ Description:
272
+ Season steak with salt and pepper
273
+ Before:
274
+ - The steak is unseasoned.
275
+ - The steak has no salt or pepper on it.
276
+ - The steak is raw.
277
+ After:
278
+ - The steak is with salt and pepper.
279
+ - The steak has salt and pepper on it.
280
+ - The steak is ready to be grilled.
281
+ [goal]: Make Kimchi Fried Rice
282
+ [step]: add ham
283
+ [verb]: add
284
+ Description:
285
+ Incorporate diced ham into the fried rice.
286
+ Before:
287
+ - The diced ham is separate from the pan.
288
+ - The pan contains fried rice.
289
+ - The pan has no ham on it.
290
+ ```
291
+
292
+ ```txt
293
+ After:
294
+ - The diced ham is blended with the fried rice.
295
+ - The ham is on the pan.
296
+ - The pan contains ham.
297
+ [goal]:Make Banana Ice Cream [step]:cut banana
298
+ ```
299
+
300
+ Note that the examples are generated by GPT-3.5 and manually selected. An example output is
301
+
302
+ ```txt
303
+ [verb]: cut
304
+ Description:
305
+ Cut banana into small pieces
306
+ Before:
307
+ - The banana is a whole.
308
+ - The banana is uncut.
309
+ - The banana is in one piece.
310
+ After:
311
+ - The banana is in small pieces.
312
+ - The banana is cut into pieces.
313
+ - The banana is divided into multiple parts.
314
+ ```
315
+
316
+ Transformer Models for State Decoder and Step Decoder. Our state decoder and step decoder are Transformer-based models. The model consists of two blocks. Each block consists of one self-attention module, one cross-attention module, and a two-layer projection module. The input query is first processed by the self-attention module, then forwarded to the cross-attention module, and processed by the projection module. The cross-attention module takes the external memory to calculate the keys and values. Each self-attention and cross-attention module consists of 32 heads and the hidden layer size is set as 128. The step classifier is a two-layer MLP with hidden size of 128. The dropout ratio is 0.2.
317
+
318
+ Training Details. We train our model with Adam optimizer, an initial learning rate set to $5 \times 10^{-3}$ decayed by 0.65 every 40 epochs. The batch size is set as 256. The training process takes 1 hour (500 epochs) on CrossTask and 5.5 hours (400 epochs) on COIN using a single V100 GPU. We will release the code after the paper is accepted. The code will be released under Apache-2.0 license.
319
+
320
+ Viterbi Algorithm for Inference. During inference, we follow Zhao et al. (Zhao et al., 2022) and use Viterbi (Viterbi, 1967) algorithm to further incorporate the temporal prior into the model. Specifically, Viterbi algorithm is conducted based on a transition matrix and an emission matrix. The transition matrix depicts the probability of state transiting from one state to another state, which is denoted as $A \in \mathbb{R}^{N_a \times N_a}$ . We use the action co-occurrence frequencies (i.e., ground-truth procedure annotations in the training set) to obtain the transition matrix as temporal prior knowledge. The emission matrix depicts the probability of each state given observations, which is denoted as $B \in \mathbb{R}^{T \times N_a}$ and obtained by the predicted probability distribution.
321
+
322
+ # B EXPERIMENTS
323
+
324
+ Baselines. We follow previous works (Zhao et al., 2022; Bi et al., 2021; Chang et al., 2020; Sun et al., 2022) and consider the baseline methods for comparisons. In addition to the baselines in Sec 4.1, we introduce other baselines as follows:(1) Random. This baseline randomly selects actions from the candidate action set to generate the procedure. (2) Retrieval-based. The baseline retrieves the closest neighbor of the start and goal
325
+
326
+ ![](images/cdf593018c57ba14d0449fdb7f95a170b2e8cc8e14fd5d33ad145eb2c3a346ac.jpg)
327
+ Figure 6: Illustration of state-based step classification.
328
+
329
+ observations based on the visual feature similarity in the training set. (3) WLTDO (Ehsani et al., 2018). This baseline used a recurrent neural network (RNN) to predict the action sequence given the visual observations. (4) UAAA (Abu Farha & Gall, 2019). This baseline is an auto-regression model using RNN-HMM architecture. (5) UPN (Srinivas et al., 2018). This baseline is a physical-world path planning method. (6) DDN (Chang et al., 2020). This baseline is an auto-regressive model that predicts both the action and state in the same space.
330
+
331
+ Table 5: Results on the state-based zero-shot step classification task on CrossTask.
332
+
333
+ <table><tr><td>Prompts</td><td>None</td><td>“A photo of”</td><td>“A video of”</td><td>“The start/end state of”</td></tr><tr><td>Acc (%)</td><td>14.6</td><td>14.1</td><td>16.0</td><td>13.4</td></tr><tr><td>Descriptions</td><td>DCLIP</td><td>Action descriptions</td><td>State descriptions</td><td></td></tr><tr><td>Acc (%)</td><td>16.2</td><td>17.7</td><td>21.1</td><td></td></tr></table>
334
+
335
+ Table 6: Comparisons on the NIV dataset.
336
+
337
+ <table><tr><td rowspan="2">Models</td><td colspan="3">T=3</td><td colspan="3">T=4</td></tr><tr><td>SR↑</td><td>mAcc↑</td><td>mIoU↑</td><td>SR↑</td><td>mAcc↑</td><td>mIoU↑</td></tr><tr><td>Random</td><td>2.21</td><td>4.07</td><td>6.09</td><td>1.12</td><td>2.73</td><td>5.84</td></tr><tr><td>DDN</td><td>18.41</td><td>32.54</td><td>56.56</td><td>15.97</td><td>27.09</td><td>53.84</td></tr><tr><td>Ext-GAIL</td><td>22.11</td><td>42.20</td><td>65.93</td><td>19.91</td><td>36.31</td><td>53.84</td></tr><tr><td>P3IV</td><td>24.68</td><td>49.01</td><td>74.29</td><td>20.14</td><td>38.36</td><td>67.29</td></tr><tr><td>EGPP</td><td>26.05</td><td>51.24</td><td>75.81</td><td>21.37</td><td>41.96</td><td>74.90</td></tr><tr><td>SCHEMA (Ours)</td><td>27.93</td><td>41.64</td><td>76.77</td><td>23.26</td><td>39.93</td><td>76.75</td></tr></table>
338
+
339
+ State Descriptions. We establish a preliminary task called state-based step classification. As illustrated in Figure 6, given two visual state observations, the task is to predict the one action step that leads to the state changes. It can be regarded as a special form of procedure planning with $T = 1$ . We conduct evaluations under the zero-shot setting using CLIP (Radford et al., 2021) with different language descriptions, which are listed in Table 5. We evaluate both manually-designed prompted captions (first row) and GPT-3.5 generated descriptions introduced in Sec. 3.2 (second row). Detailed examples can be found in the appendix. As shown in Table 5, our state descriptions using chain-of-thought prompting achieves a relative $31.9\%$ improvement compared to manually-designed prompted captions (21.1 vs. 16.0), while the improvement of the modified baseline DCLIP (Menon & Vondrick, 2022) is marginal (16.2 vs. 16.0). These results show that our state descriptions are better state descriptors for CLIP.
340
+
341
+ Results on NIV. Table 6 shows the results on the NIV dataset. Similar to the observations on CrossTask and COIN, our SCHEMA achieves better SR and mIoU and competitive mAcc.
342
+
343
+ Uncertain Modeling. Uncertain modeling is to produce several procedures by running the model multiple times with different noise input vectors. Although we focus on deterministic modeling, our model can be easily extended to probabilistic modeling by including the noise vectors into queries of state decoder and step decoder. We follow Zhao et al. (2022) to evaluate the performance of uncertain modeling. Evaluation metrics are KL-Div, NLL, Mode Recall (ModeRec), Mode Precision (ModePre). Results are provided in Table 7. The results of SR, mAcc, and mIoU are shown in Table 8. As shown in the table, the probabilistic variant underperforms the deterministic variant on procedure planning metrics SR, mAcc, and mIoU. The possible reason is that language descriptions as the supervision of state representations would also decreases the uncertainty and variances of visual observations, which conflicts with noisy vectors in the probabilistic variant that increases the uncertainty and variances.
344
+
345
+ Ablations on two-decoder design. We used two decoders for state prediction and step prediction. An alternative is using one decoder for both the state and action steps. We used the two-decoder design because the intermediate states serving as explicit inputs work better than implicit outputs. Table 9 further compares the two designs, showing the effectiveness of the two-decoder design.
346
+
347
+ Ablations on external memory. We further conduct ablation studies to verify the impact of external memory. The baseline is to learn a memory module with the same size of state descriptions but randomly initialized. Table 10 compares different choices of external memory for the Transformer models. As shown in the table, state descriptions works better than random initialized memory, which indicates that the semantic information in state descriptions help with procedure planning.
348
+
349
+ Note that we also use state descriptions rather than setup descriptions as external memory for the step decoder. Table 11 shows the comparison between these two variants. As shown in the table, state descriptions as external memory outperforms the variant with step descriptions under all the
350
+
351
+ Table 7: The results of uncertain modeling on the CrossTask dataset.
352
+
353
+ <table><tr><td>Metric</td><td>Method</td><td>T=3</td><td>T=4</td><td>T=5</td><td>T=6</td></tr><tr><td rowspan="2">KL-Div ↓</td><td>Ours - deterministic</td><td>4.03</td><td>4.31</td><td>4.49</td><td>4.65</td></tr><tr><td>Ours - probabilistic</td><td>3.62</td><td>3.82</td><td>3.92</td><td>3.97</td></tr><tr><td rowspan="2">NLL ↓</td><td>Ours - deterministic</td><td>4.55</td><td>5.11</td><td>5.46</td><td>5.71</td></tr><tr><td>Ours - probabilistic</td><td>4.15</td><td>4.62</td><td>4.88</td><td>5.04</td></tr><tr><td rowspan="2">ModePrec ↑</td><td>Ours - deterministic</td><td>38.41</td><td>26.67</td><td>15.28</td><td>9.84</td></tr><tr><td>Ours - probabilistic</td><td>38.32</td><td>26.46</td><td>14.99</td><td>9.91</td></tr><tr><td rowspan="2">ModeRec ↑</td><td>Ours - deterministic</td><td>25.59</td><td>13.63</td><td>6.27</td><td>3.37</td></tr><tr><td>Ours - probabilistic</td><td>37.70</td><td>23.76</td><td>13.85</td><td>9.30</td></tr></table>
354
+
355
+ Table 8: The planning results of probabilistic model on CrossTask.
356
+
357
+ <table><tr><td rowspan="2">white Models</td><td colspan="3">T=3</td><td colspan="3">T=4</td><td>T=5</td><td>T=6</td></tr><tr><td>SR↑</td><td>mAcc↑</td><td>mIoU↑</td><td>SR↑</td><td>mAcc↑</td><td>mIoU↑</td><td>SR↑</td><td>SR↑</td></tr><tr><td>Ours - probabilistic</td><td>29.51</td><td>57.09</td><td>77.76</td><td>16.55</td><td>51.93</td><td>74.42</td><td>8.73</td><td>5.53</td></tr><tr><td>Ours - deterministic</td><td>31.83</td><td>57.31</td><td>78.33</td><td>19.71</td><td>51.85</td><td>74.46</td><td>11.41</td><td>7.68</td></tr></table>
358
+
359
+ Table 9: Ablation studies on decoder design.
360
+
361
+ <table><tr><td rowspan="2"></td><td colspan="3">T = 3</td><td colspan="3">T = 4</td></tr><tr><td>SR↑</td><td>mAcc↑</td><td>mIoU↑</td><td>SR↑</td><td>mAcc↑</td><td>mIoU↑</td></tr><tr><td>One-decoder</td><td>30.25</td><td>56.35</td><td>77.83</td><td>19.01</td><td>51.15</td><td>74.13</td></tr><tr><td>Two-decoder</td><td>31.83</td><td>57.31</td><td>78.33</td><td>19.71</td><td>51.85</td><td>74.46</td></tr></table>
362
+
363
+ scenarios. The possible reason is that state descriptions contain more information of object status and serve as supplement to step label supervisions. In addition, as shown in Table 5, state descriptions works better than step descriptions for the state-based step classification problem, which indicates that state descriptions are good resources for step recognition.
364
+
365
+ Ablations on Viterbi. We applied Viterbi algorithm to add temporal prior. Table 12 shows that Viterbi has a positive impact on all the metrics, which indicates that Viterbi successfully includes the temporal ordering knowledge in the training data, i.e., action co-occurrence frequencies.
366
+
367
+ Qualitative Results. Figure 7 shows more examples of state justification results outputted by our model. These examples show that our model can provide evidence about the visual state, which is more explainable and informative.
368
+
369
+ Failure Case Analysis. The examples are shown in Figure 8. We grouped them into three cases:
370
+
371
+ (1) Failed understanding of start/end state. As shown in Figure 8(a), the model predicted "season steak" as the first step because it didn't recognize that there is pepper on top of the steak, i.e., it failed to understand the start state. As shown in Figure 8(b), the model predicted "flip steak" rather than "put steak on grill" as the second step. The way to distinguish these two steps is whether the steak has its top side grilled. Although the end state shows that the top side of the steak is raw, the steak is very small to be captured. One future solution is to use high-resolution video frames or object detector to ground the object.
372
+ (2) Hallucination. As shown in Figure 8(c), the model predicts "add strawberries to cake" as the third step. However, the goal is not to make strawberry cake. This failure may be due to the training priors as there are many videos for the task of "make french strawberry cake".
373
+ (3) Reasonable but not matched with ground-truth plans. As shown in Figure 8(d), the generated plan is reasonable, although it doesn't exactly match the ground-truth annotation. This "failure" indicates that this task needs a better evaluation protocol for all the reasonable results, which is a general challenge for sequence generation tasks.
374
+
375
+ ![](images/125020c9bdbabc38cfe6d3e67611f0c7eeda6bede206fb22fac0c682f14ce074.jpg)
376
+ Figure 7: More examples of state justifications from our model.
377
+ Figure 8: Failure case analysis. For each example, the first row is the ground-truth annotation while the second is the prediction.
378
+
379
+ [goal]: Make Kimchi Fried Rice
380
+
381
+ [step]: add onion
382
+
383
+ Step Description:
384
+
385
+ - Add diced onion into the fried rice.
386
+
387
+ Before:
388
+
389
+ - The diced onion is separate from the pan.
390
+ - The pan contains fried rice.
391
+ - The pan has no onion on it.
392
+ After:
393
+ - The diced onion is mixed with the fried rice.
394
+ - The onion is on the pan.
395
+ - The pan contains onion.
396
+
397
+ [goal]: Make Pancakes
398
+ [step]: pour milk
399
+ Step Description:
400
+ - Pour milk into the pancake batter.
401
+ Before:
402
+ - The milk is in a container.
403
+ - The pancake batter contains no milk.
404
+ - The milk is a liquid.
405
+ After:
406
+ - The milk is mixed with the pancake batter.
407
+ - The milk is in the mixing bowl.
408
+ - The pancake batter contains milk.
409
+
410
+ Table 10: Ablation studies on external memory.
411
+
412
+ <table><tr><td rowspan="2">Memory</td><td colspan="3">T=3</td><td colspan="3">T=4</td></tr><tr><td>SR↑</td><td>mAcc↑</td><td>mIoU↑</td><td>SR↑</td><td>mAcc↑</td><td>mIoU↑</td></tr><tr><td>Random Initialized</td><td>29.83</td><td>56.04</td><td>77.22</td><td>19.53</td><td>50.99</td><td>73.96</td></tr><tr><td>Two-decoder</td><td>31.83</td><td>57.31</td><td>78.33</td><td>19.71</td><td>51.85</td><td>74.46</td></tr></table>
413
+
414
+ Table 11: Ablation studies on memory of step classifier.
415
+
416
+ <table><tr><td rowspan="2">Memory</td><td colspan="3">T=3</td><td colspan="3">T=4</td><td>T=5</td><td>T=6</td></tr><tr><td>SR↑</td><td>mAcc↑</td><td>mIoU↑</td><td>SR↑</td><td>mAcc↑</td><td>mIoU↑</td><td>SR↑</td><td>SR↑</td></tr><tr><td>Step Descriptions</td><td>30.00</td><td>55.89</td><td>77.61</td><td>19.30</td><td>51.43</td><td>74.13</td><td>10.99</td><td>7.60</td></tr><tr><td>State Descriptions</td><td>31.83</td><td>57.31</td><td>78.33</td><td>19.71</td><td>51.85</td><td>74.46</td><td>11.41</td><td>7.68</td></tr></table>
417
+
418
+ Table 12: Ablation studies on Viterbi.
419
+
420
+ <table><tr><td></td><td colspan="3">T=3</td><td colspan="3">T=4</td></tr><tr><td></td><td>SR↑</td><td>mAcc↑</td><td>mIoU↑</td><td>SR↑</td><td>mAcc↑</td><td>mIoU↑</td></tr><tr><td>w/o Viterbi</td><td>27.48</td><td>56.62</td><td>68.92</td><td>14.85</td><td>51.46</td><td>66.47</td></tr><tr><td>w/ Viterbi</td><td>31.83</td><td>57.31</td><td>78.33</td><td>19.71</td><td>51.85</td><td>74.46</td></tr></table>
421
+
422
+ # C FURTHER DISCUSSIONS
423
+
424
+ In this section, we provide further discussions with related works and insights that are not included in the main paper due to page limits.
425
+
426
+ Limitations. The limitations of our method are as follows. First, the model may fail to identify state changes if they are not explicitly shown in the video. This is a general challenge for procedure planning models, as the details of objects may be hard to recognize if they are far from the camera. Although we tried to tackle this challenge by associating non-visible state changes with language descriptions, which is learned from the paired vision-text training data, there is no guarantee that the non-visible state changes issue can be totally removed. A potential direction is to generalize the task by taking long-term videos as the input visual observations, so that the model can infer the state changes from video history or ASR narrations. Second, the quality of state descriptions relies on LLMs, which would be a bottleneck of state representation. We will explore more effective and reliable methods to leverage LLMs' commonsense knowledge, or utilize generative vision-language models (VLMs) for state description generation. Third, our approach is under a close-vocabulary setting. We will explore the open-vocabulary setting in the future.
427
+
428
+ Differences from other mid-state prediction methods. Differences from existing mid-state prediction methods: (1) Compared to PlaTe (Sun et al., 2022) and Ext-GAIL (Bi et al., 2021). First, PlaTe and Ext-GAIL are under the full supervision setting (i.e., visual observations of intermediate states are annotated, shown in Figure 1(b)) while ours is under the weak supervision setting (i.e., mid-state annotations are not available). Second, PlaTe formulates mid-state prediction as $P(s_{t}|s_{t - 1},a_{t - 1},s_{T})$ conditioned on last state $s_{t - 1}$ , last action $a_{t - 1}$ , and end state $s_T$ , Ext-GAIL formulates mid-state prediction as $P(s_{t}|s_{t - 1},a_{t - 1},z_{c})$ where $z_{c}$ is context information learned from $s_0$ and $s_T$ , while we formulate mid-state prediction as $P(s_{1:(T - 1)}|s_0,s_T)$ conditioned on start state $s_0$ and end state $s_T$ . Third, PlaTe represents mid-states using extremely low-dimensional (actually 4-d) features in their implementation, which is hard to learn and represent mid-state information. The role of their mid-state predictor is questionable.
429
+
430
+ (2) Compared to methods under the weak supervision settings. Recent works like P3IV (Zhao et al., 2022) consider the weak supervision where mid-states are not annotated, and they didn't predict mid-states in their pipeline. Differently, we leverage LLMs' commonsense knowledge to transform step into state change descriptions. Therefore, our work rethinks the role and representation style of mid-states, and we expect future works to further investigate the state representation.
431
+
432
+ Comparisons with related works. Some recent works explored how to extract commonsense information via text descriptions using language models. For example, Socratic Models (Zeng et al., 2022) (SMs) use language models in a zero-shot setting to solve downstream multimodal tasks. The similarity between ours and SMs is that we both leveraged LLMs and prompting to obtain commonsense knowledge for other modalities and multimodal tasks, especially video-related tasks and planning tasks. The main differences are: (1) Goal. SMs aim to embrace the heterogeneity of pretrained models through structured Socratic dialogue, while our goal is to represent steps as state changes via LLMs descriptions for procedure planning. (2) Task. SMs focus on zero-shot multimodal tasks without further training, while we focus on procedure learning in instructional videos with weak supervision and further training; (3) Framework. SMs deliver a zero-shot modular framework that composes multimodal models and LLMs and makes sample-specific API calling, while we only used LLMs once to obtain the generic language descriptions and train another planning model.
433
+
434
+ Viterbi alrogithm. We use Viterbi for post-processing during inference. We use transition matrix in Viterbi to include the temporal ordering knowledge in the training data, i.e., action co-occurrence frequencies. We empirically found that the training priors help with success rate increase. Our emission matrix estimation is a new contribution to deterministic modeling for procedure planning. Instead of sampling 1,500 generated sequences to estimate the emission matrix (Zhao et al., 2022), we run the feedforwarding only once and use the single predicted probability matrix as the emission matrix, which is simple and more time-efficient. This will be a useful tool for future deterministic modeling works.
435
+
436
+ Hallucination of LLMs. In the main paper, we observed the hallucination of LLMs using the baseline from Menon & Vondrick (2022), e.g., given the action step "add onion" and the task goal "make kimchi fried rice", the generated description of the state before adding onion is "the onion was uncut and unchopped", which is incorrect because the onion should have been cut before being added to the rice. We proposed a chain-of-thought prompting method to first describe more details of the steps and then describe the state changes based on the detailed step descriptions. According to our manual checkup, most of the descriptions are reasonable and match human knowledge. We observed a few failure cases. One common problem is that LLMs may combine two steps as one. For example, for the step "cut strawberries" and task "make French strawberry cake", one of the after-state descriptions is "The strawberries are on the cake" which is incorrect. The reason is that LLMs mix two steps "cut strawberries" and "add strawberries" to generate the after-state descriptions. A potential solution is to require the LLMs to (1) distinguish different steps by feeding other steps into the prompt as references, (2) consider the temporal relations between steps.
437
+
438
+ Generalization capabilities. Our method can handle variations in action steps, object states, and environmental conditions. For variations in action steps, we evaluated our method with variant lengths of action steps, ranging from 3 to 6. According to the experimental results, our method consistently outperforms state-of-the-art models. For object states and environmental conditions, our evaluation benchmark instructional video datasets cover various topics and domains, including different environments like cooking, housework, and car repairing, and different objects like fruits, drinks, and household items. For example, CrossTask covers 133 types of steps in 18 tasks, and COIN covers 778 types of steps in 180 tasks. The evaluation on these two datasets can reflect the models' generality on various object states and environmental conditions.
439
+
440
+ Potential benefit and drawback of mid-states. The potential benefit of mid-states is the explainability, e.g., extending language-only procedures to multi-modal procedures by adding intermediate visual states. The extension can be realized by (a) retrieving images or video clips from a predefined corpus of images or videos based on feature similarities; (b) generative images via text-to-image generation models (e.g., Stable Diffusion) based on the associated language descriptions. A potential drawback is the impact on the uncertainty modeling, i.e., generating multiple procedures given the same start and goal states. As our motivation is to reduce the high variance of visual observations, language descriptions as the supervision of mid-states would also decrease the uncertainty of sequences. The future direction is to combine mid-states and language descriptions with probabilistic modeling.
441
+
442
+ Noisy visual observations. Visual scenes of states are diverse and may have low qualities (i.e., incomplete or noisy) in instructional videos. Considering the high variance of visual observations, we proposed to represent visual states using LLMs descriptions and align the visual observations with language descriptions. We expect the discriminative language description to reduce the variance of visual states and add LLM commonsense knowledge for representation learning.
443
+
444
+ Scaling up to larger dataset. Different from existing benchmark datasets for procedure planning in instructional videos, larger datasets would have the following requirements: (1) Open-vocabulary setting. Large-scale real-word datasets are often open-vocabulary. For the state description generation process, since LLM is designed for open-vocabulary sequence generation, our generation part can be easily applied to larger datasets. For the step classifier, we can replace the fixed-vocabulary classifier (i.e., two-layer FFN) with a similarity calculation module, i.e., calculating the similarity between output embeddings of step decoder and language step descriptions. (2) Efficient training. Training on large-scale datasets often requires efficient training like distributed computing. Since our state decoder and step decoder are encoder-only Transformer architecture, it is easy to extend the training pipeline to distributed computing. (3) Long-term prediction. As shown in the comparison results with state-of-the-art methods, long-term prediction is still challenging for procedure planning model, but is an essential ability for larger datasets. One potential extension way is to treat our model as an adaptor to transform visual observations into tokens as the inputs to generative model like LLMs or VLMs for long-term sequence generation, which is a popular way to adapt LLMs or VLMs to downstream applications.
2024/SCHEMA_ State CHangEs MAtter for Procedure Planning in Instructional Videos/images.zip ADDED
@@ -0,0 +1,3 @@
 
 
 
 
1
+ version https://git-lfs.github.com/spec/v1
2
+ oid sha256:eb245bc3966cad08be41119c2d38d71552d8d039666d8b5860db9f2f03aa7cc0
3
+ size 863803
2024/SCHEMA_ State CHangEs MAtter for Procedure Planning in Instructional Videos/layout.json ADDED
The diff for this file is too large to render. See raw diff
 
2024/SEABO_ A Simple Search-Based Method for Offline Imitation Learning/430a3b73-fa5b-41bf-be8d-859b294c6e4c_content_list.json ADDED
The diff for this file is too large to render. See raw diff
 
2024/SEABO_ A Simple Search-Based Method for Offline Imitation Learning/430a3b73-fa5b-41bf-be8d-859b294c6e4c_model.json ADDED
The diff for this file is too large to render. See raw diff
 
2024/SEABO_ A Simple Search-Based Method for Offline Imitation Learning/430a3b73-fa5b-41bf-be8d-859b294c6e4c_origin.pdf ADDED
@@ -0,0 +1,3 @@
 
 
 
 
1
+ version https://git-lfs.github.com/spec/v1
2
+ oid sha256:eed520314a3b0afb33e9612947cf71079576222b18e520a7be808636add451df
3
+ size 9372508
2024/SEABO_ A Simple Search-Based Method for Offline Imitation Learning/full.md ADDED
@@ -0,0 +1,566 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ # SEABO: A SIMPLE SEARCH-BASED METHOD FOR OFFLINE IMITATION LEARNING
2
+
3
+ Jiafei Lyu $^{1}$ , *Xiaoteng Ma $^{2}$ , Le Wan $^{3}$ , Runze Liu $^{1}$ , Xiu Li $^{1,\dagger}$ , Zongqing Lu $^{4,\dagger}$
4
+
5
+ $^{1}$ Tsinghua Shenzhen International Graduate School, Tsinghua University
6
+
7
+ $^{2}$ Department of Automation, Tsinghua University, $^{3}$ IEG, Tencent
8
+
9
+ $^{4}$ School of Computer Science, Peking University
10
+
11
+ lvjf20@mails.tsinghua.edu.cn, li.xiu@sz.tsinghua.edu.cn, zongqing.lu@pku.edu.cn
12
+
13
+ # ABSTRACT
14
+
15
+ Offline reinforcement learning (RL) has attracted much attention due to its ability in learning from static offline datasets and eliminating the need of interacting with the environment. Nevertheless, the success of offline RL relies heavily on the offline transitions annotated with reward labels. In practice, we often need to hand-craft the reward function, which is sometimes difficult, labor-intensive, or inefficient. To tackle this challenge, we set our focus on the offline imitation learning (IL) setting, and aim at getting a reward function based on the expert data and unlabeled data. To that end, we propose a simple yet effective search-based offline IL method, tagged SEABO. SEABO allocates a larger reward to the transition that is close to its closest neighbor in the expert demonstration, and a smaller reward otherwise, all in an unsupervised learning manner. Experimental results on a variety of D4RL datasets indicate that SEABO can achieve competitive performance to offline RL algorithms with ground-truth rewards, given only a single expert trajectory, and can outperform prior reward learning and offline IL methods across many tasks. Moreover, we demonstrate that SEABO also works well if the expert demonstrations contain only observations. Our code is publicly available at https://github.com/dmksjfl/SEABO.
16
+
17
+ # 1 INTRODUCTION
18
+
19
+ In recent years, reinforcement learning (RL) (Sutton & Barto, 2018) has made prominent achievements in fields like video games (Mnih et al., 2015; Schrittwieser et al., 2020), robotics (Kober et al., 2013), nuclear fusion control (Degrave et al., 2022), etc. It is known that RL is a reward-oriented learning paradigm. Online RL algorithms typically require an interactive environment for data collection and improve the policy through trial-and-error. However, continual online interactions are usually expensive, time-consuming, or even dangerous in many practical applications. Offline RL (Lange et al., 2012; Levine et al., 2020), instead, resorts to learning optimal policies from previously gathered datasets, which are composed of trajectories containing observations, actions, and rewards.
20
+
21
+ A bare fact is that reward engineering is often difficult, expensive, and labor-intensive. It is also hard to specify or abstract a good reward function given some rules. To overcome this challenge in the offline setting, there are generally two methods. First, one can train the policy via the behavior cloning (BC) algorithm (Pomerleau, 1988), but its performance is heavily determined by the performance of the data-collecting policy (a.k.a., the behavior policy). Second, one can learn a reward function from some expert demonstrations and assign rewards to the unlabeled data in the dataset. Then, the policy can be optimized by leveraging the reward. This is also known as offline imitation learning (offline IL). Note that in many real-world tasks, acquiring a few expert demonstrations is easy (e.g., ask a human expert to operate the system) and affordable.
22
+
23
+ However, it turns out that, similar to offline RL, offline IL also suffers from distribution shift issue (Kim et al., 2022b; DeMoss et al., 2023), where the learned policy deviates from the data-collecting policy, leading to poor performance during evaluation. Prior works concerning on distribution cor
24
+
25
+ ![](images/751c29d9a27b0eeef9766305e38f6a2364ab646f0f06d099c7c7b5d5c4574967.jpg)
26
+ Figure 1: Left: The key idea behind SEABO. We assign larger rewards to transitions that are closer to the expert demonstration, and smaller rewards otherwise. The dotted lines connect the query samples with their nearest neighbors along the demonstration. Right: Illustration of the SEABO framework. Given an expert demonstration, we first construct a KD-tree and then feed the unlabeled samples into the tree to query their nearest neighbors. We use the resulting distance to calculate the reward label. Then one can adopt any existing offline RL algorithm to train on the labeled dataset.
27
+
28
+ rection estimation (DICE family) address this by enforcing the learned policy to be close to the behavior policy via a distribution divergence measure (e.g., $f$ -divergence (Ghasemipour et al., 2019; Ke et al., 2019)). However, such distribution matching schemes can incur training instability (Ma et al., 2022) and over-conservatism (Yu et al., 2023), and they often involve training task-specific discriminators. On the other hand, some works seek to decouple the processes of reward annotation and policy optimization (Zolna et al., 2020; Luo et al., 2023). However, they involve solving complex optimal transport problems or contrasting expert states and unlabeled trajectory states.
29
+
30
+ In this paper, we propose a simple yet effective alternative, SEArch-Based method for Offline imitation learning, namely SEABO, that leverages search algorithms to acquire reward signals in an unsupervised learning manner. As illustrated in Figure 1 (left), we hypothesize that the transition is near-optimal if it lies close to the expert trajectory, hence larger reward ought to be assigned to it, and vice versa. To that end, we propose to determine whether the sample approaches the expert trajectory via measuring the distance between the query sample and its nearest neighbor in the expert trajectory. In practice, as depicted in Figure 1 (right), SEABO first builds a KD-tree upon expert demonstrations. Then for each unlabeled sample in the dataset, we query the tree to find its nearest neighbor, and measure their distance. If the distance is small (i.e., close to expert trajectory), a large reward will be annotated, while if the distance is large (i.e., stray away from the expert trajectory), the assigned reward is low. SEABO is efficient and easy to implement. It can be combined with any existing offline RL algorithm to acquire a meaningful policy from the static offline dataset.
31
+
32
+ Empirical results on the D4RL (Fu et al., 2020) datasets show that SEABO can enable the offline RL algorithm to achieve competitive or even better performance against its performance under ground-truth rewards with only one expert trajectory. SEABO also beats recent strong reward annotation methods and imitation learning baselines on many datasets. Furthermore, we also demonstrate that SEABO can learn effectively when the expert demonstrations are composed of pure observations.
33
+
34
+ # 2 PRELIMINARY
35
+
36
+ We formulate the interaction between the environment and policy as a Markov Decision Process (MDP) specified by the tuple $\langle S, \mathcal{A}, p, r, \gamma, p_0 \rangle$ , where $S$ is the state space, $\mathcal{A}$ is the action space, $p: S \times \mathcal{A} \mapsto S$ is the transition dynamics, $r: S \times \mathcal{A} \mapsto \mathbb{R}$ is the scalar reward signal, $\gamma \in [0,1]$ is the discount factor, $p_0$ is the initial state distribution. A policy $\pi(a|s)$ outputs the action based on the state $s$ . We assume that the underlying MDP has a finite horizon. The goal of RL is to maximize the discounted future reward: $J(\pi) = \mathbb{E}_{s_0 \sim p_0} \mathbb{E}_{a \sim \pi, s_{t+1} \sim p(\cdot | s_t, a_t)} [\sum_{t=0}^{T-1} \gamma^t r(s_t, a_t)]$ . Whereas, in many scenarios, it is often hard for one to get the reward signals. It is more common that the unlabeled trajectory, $\tau = \{s_0, a_0, \dots, s_t, a_t, \dots, s_T\}$ , is collected. This poses veritable challenges for applying offline RL algorithms.
37
+
38
+ In this paper, we focus on the offline IL setting. We assume that we have access to the dataset of expert demonstrations $\mathcal{D}_e = \{\tau_e^{(i)}\}_{i=1}^M$ , and a dataset of unlabeled data $\mathcal{D}_u = \{\tau_u^{(i)}\}_{i=1}^N$ , where $M$ and $N$ are the sizes of the expert dataset and unlabeled dataset, respectively. The unlabeled trajectories are gathered by some unknown behavior policy $\mu$ . Note that we allow the expert demonstrations to either contain actions or do not contain actions. We aim at attaining the reward function by extracting information from the expert trajectories and unlabeled trajectories, and assigning rewards to the unlabeled datasets, without any interactions with the environment. Then we can train the policy using any offline RL algorithm.
39
+
40
+ # 3 RELATED WORK
41
+
42
+ Offline Reinforcement Learning. In offline RL (Lange et al., 2012; Levine et al., 2020), the agent is not permitted to interact with the environment, and can only learn policies from previously gathered dataset $\mathcal{D} = \{(s_i,a_i,r_i,s_{i + 1})\}_{i = 1}^N$ , where $N$ is the dataset size. Existing work on offline RL can be generally categorized into model-based (Yu et al., 2020; 2021; Kidambi et al., 2020; Lyu et al., 2022b; Rigter et al., 2022; Lu et al., 2022a; Chen et al., 2021; Janner et al., 2021; Uehara & Sun, 2022; Zhang et al., 2023) and model-free approaches (Fujimoto et al., 2019; Fujimoto & Gu, 2021; Kumar et al., 2020; Kostrikov et al., 2022; Lyu et al., 2022c;a; Cheng et al., 2022; Zhou et al., 2020; Ran et al., 2023; Bai et al., 2022; Yang et al., 2024). The success of these methods rely heavily on the requirement that the datasets must contain annotated reward signals.
43
+
44
+ Imitation Learning. Imitation Learning (IL) considers optimizing the behavior of the agent given some expert demonstrations, and no reward is needed. The primary goal of IL is to mimic the behavior of the expert demonstrator. Behavior cloning (BC) (Pomerleau, 1988) directly performs supervised regression or maximum-likelihood on expert demonstrations. Yet, BC can suffer from compounding error and may result in performance collapse upon unseen states (Ross et al., 2011). Another line of work, inverse reinforcement learning (IRL) (Arora & Doshi, 2021), first learns a reward function using expert demonstrations, and then utilizes this reward function to train policies with RL algorithms. Typical IRL algorithms include adversarial methods (Ho & Ermon, 2016; Jeon et al., 2018; Kostrikov et al., 2019; Baram et al., 2017), maximum-entropy approaches (Ziebart et al., 2008; Boullarias et al., 2011), normalizing flows (Freund et al., 2023), etc. However, these methods often require abundant online transitions to train a good policy. Imitation learning without online interactions, which is the focus of our work, is hence attractive and remains an active area. There are many advances in offline IL, such as applying online IRL algorithms in the offline setting (Zolna et al., 2020; Yue et al., 2023), using energy-based methods (Jarrett et al., 2020), weighting the BC loss with the output of the trained discriminator (Xu et al., 2022), etc. Among them, DICE (Nachum et al., 2019) family receives much attention. Methods like ValueDICE (Kostrikov et al., 2020), DemoDICE (Kim et al., 2022b), and LobsDICE (Kim et al., 2022a) can consistently drub BC in the offline setting. Notably, a recent work, OTR (Luo et al., 2023), acquires the reward function in the offline setting via optimal transport. OTR decouples the processes of reward learning and policy optimization. Still, OTR needs to solve complex optimal transport problems. We, instead, explore to get the reward function via a search-based method.
45
+
46
+ Search Algorithms. Search algorithms (Korf, 1999) are critical components in artificial intelligence. Typical search algorithms include brute-force search algorithms (Dijkstra, 1959; Stickel & Tyson, 1985; Korf, 1985; Taylor & Korf, 1993), heuristic search approaches (Doran & Michie, 1966; Hart et al., 1968; Pohl, 1970; Edelkamp & Schrödl, 2011), etc. In this paper, we resort to the simple search approach, KD-tree (Bentley, 1975), for capturing the nearest neighbors of the unlabeled data in the expert demonstrations.
47
+
48
+ # 4 OFFLINE IMITATION LEARNING VIA SEARCH-BASED METHOD
49
+
50
+ In this section, we formally present our novel approach for offline imitation learning, SEArch-Based Offline imitation learning (SEABO). We begin by analyzing the common formulation adopted in distribution matching IL methods (Ho & Ermon, 2016; Kim et al., 2020; Kostrikov et al., 2020), which attempt to match the state-action distribution of the agent $p_{\pi}$ and the expert $p_e$ , often by means of minimizing some $f$ -divergence measurement $D_f$ : arg $\min_{\pi} D_f(p_{\pi} \| p_e)$ . Though these methods have promising results, they usually require training task-specific discriminators and suffer
51
+
52
+ from training instability (Wang et al., 2020; Ma et al., 2022). A natural question arises, can we get the reward signals without training neural networks?
53
+
54
+ Instead of measuring the distribution of states or state-action pairs, we want to determine the optimality of a single transition. Our idea is quite straightforward, the closer the transition is to the expert trajectory, the more optimal this transition is. The agent ought to pay more attention to those optimal transitions. This motivates us to measure how close the unlabeled transition is to the expert trajectories. We propose to achieve this by finding the nearest neighbor of the query transition in the expert demonstrations, and then measuring their distance (e.g., Euclidean distance). If the distance is large, then the transition is away from the expert demonstration. While if the distance is small, it indicates that the transition is near-optimal, or even is exact expert data if the distance approaches 0. Intuitively, this distance can be interpreted as a reward signal.
55
+
56
+ To that end, we construct a function dubbed NearestNeighbor (demo, query_sample) that returns the nearest neighbor of the query sample in the expert demonstrations. Suppose the expert trajectories are made up of state-action pairs, then for the query sample $(s,a,s')$ , we have:
57
+
58
+ $$
59
+ \left(\tilde {s} _ {e}, \tilde {a} _ {e}, \tilde {s} _ {e} ^ {\prime}\right) = \text {N e a r e s t N e i g h b o r} \left(\mathcal {D} _ {e}, (s, a, s ^ {\prime})\right). \tag {1}
60
+ $$
61
+
62
+ Then we measure their deviation using some distance measurement $D$ :
63
+
64
+ $$
65
+ d = D \left(\left(\tilde {s} _ {e}, \tilde {a} _ {e}, \tilde {s} _ {e} ^ {\prime}\right), \left(s, a, s ^ {\prime}\right)\right). \tag {2}
66
+ $$
67
+
68
+ Afterward, following prior work (Cohen et al., 2022; Freund et al., 2023; Dadashi et al., 2021; Luo et al., 2023), we get the rewards via a squashing function: $r = \alpha \exp(-\beta \times d)$ , where $\alpha$ and $\beta$ are hyperparameters that control the scale of the reward and the impact of the distance, respectively.
69
+
70
+ Algorithm 1 SEArch-Based Offline Imitation Learning (SEABO)
71
+ 1: Require: expert demonstrations $\mathcal{D}_e$ , unlabeled dataset $\mathcal{D}_u$
72
+ 2: Initialize $\mathcal{D}_{\mathrm{label}} \gets \emptyset$ . Given distance measurement $D$
73
+ 3: for $(s, a, s')$ in $\mathcal{D}_u$ do
74
+ 4: Find its nearest neighbor, $(\tilde{s}_e, \tilde{a}_e, \tilde{s}_e') = \text{NearestNeighbor}(\mathcal{D}_e, (s, a, s'))$
75
+ 5: Measure the distance: $d = D((\tilde{s}_e, \tilde{a}_e, \tilde{s}_e'), (s, a, s'))$
76
+ 6: Get the reward signal via Equation 3
77
+ 7: $\mathcal{D}_{\mathrm{label}} \gets \mathcal{D}_{\mathrm{label}} \cup (s, a, r, s')$
78
+ 8: end for
79
+
80
+ We name the resulting method SEABO, and list its pseudo-code in Algorithm 1. For practical implementation of SEABO, we leverage KD-tree (Bentley, 1975) for searching the nearest neighbors, and adopt Euclidean distance (Torabi et al., 2019) as the distance measurement for simplicity (i.e., the default setting of KD-tree). We also slightly modify the aforementioned formula of the reward function to make it better adapt to different tasks with one set of hyperparameters, which gives:
81
+
82
+ $$
83
+ r = \alpha \exp \left(- \frac {\beta \times d}{| \mathcal {A} |}\right), \tag {3}
84
+ $$
85
+
86
+ where $|\mathcal{A}|$ is the dimension of the action space. Note that this technique is also adopted in Dadashi et al. (2021). We choose to use $(s, a, s')$ to query since the magnitude of states and actions may be different. One possible solution is to query the demonstrations via $(\xi \times s, a), \xi \in \mathbb{R}^{+}$ , but it introduces an additional hyperparameter that may need to be tuned per dataset. We empirically find that involving $s'$ in the query sample can ensure good performance across many tasks. The above procedure (as specified in Figure 1 (right)) also applies when the expert demonstrations contain only observations, because it is feasible that we find the nearest neighbors using only observations.
87
+
88
+ SEABO enjoys many advantages over prior reward learning methods or offline imitation learning algorithms. First, SEABO does not require any additional processing upon the offline dataset<sup>1</sup>. The unlabeled dataset can have different trajectory lengths, and the unlabeled trajectories can be fragmented, or even scattered, since SEABO computes the rewards only using the single transition instead of the entire trajectory. Second, SEABO does not require training reward models or discriminators, hence getting rid of the issues of training instability and hyperparameter tuning of the neural networks. Third, SEABO is easy to implement and can be combined with any offline RL algorithm.
89
+
90
+ ![](images/4a00ff534af7106fbe6f5d12ef35117ae45582a8e80558e9a3e4eaef5e5405b7.jpg)
91
+ Figure 2: Density plots of ground-truth rewards and rewards acquired by SEABO. Note that oracle indicates the ground-truth rewards are plotted.
92
+
93
+ ![](images/5f3f393d2bcc8ea1f3490de2d0e20c4c4860f528746b4ea54f6e155a8ed28111.jpg)
94
+
95
+ ![](images/9da0a5a87d2b60f75a35d9eb0e38caeb51594da000f67281fafe93f8de35b0fe.jpg)
96
+
97
+ ![](images/39959bfab5dd8caa385658e83fc272b9a90cfff156509738425a07d9c99d2e40.jpg)
98
+
99
+ To show the effectiveness of our method, we plot the distribution of ground-truth rewards (oracle) and rewards given by SEABO. We choose two datasets, halfcheetah-medium-expert-v2 and hopper-medium-v2 from D4RL (Fu et al., 2020) as examples, and use $\alpha = 1, \beta = 0.5$ , which is the same as our hyperparameter setup in Section 5. The results are summarized in Figure 2. We find that the reward distributions of SEABO resemble those of oracle. Notably, SEABO successfully gives two peaks in halfcheetah-medium-expert, indicating that it can distinguish samples of different qualities. These reveal that SEABO can serve as a good reward labeler, which validates its combination with off-the-shelf offline RL algorithms.
100
+
101
+ # 5 EXPERIMENTS
102
+
103
+ In this section, we empirically evaluate SEABO on D4RL datasets. We are targeted at examining, given only one single expert demonstration, whether SEABO can make different base offline RL algorithms recover or beat their performance with ground-truth rewards across varied tasks. We are also interested in exploring how SEABO competes against prior reward learning and offline imitation learning methods. We further investigate whether SEABO can work well if the expert demonstrations are composed of pure observations. Moreover, we check how different choices of search algorithms affect the performance of SEABO.
104
+
105
+ We discard reward signals in the D4RL datasets to form unlabeled datasets. For expert demonstrations, we follow Luo et al. (2023) and utilize the trajectory with the highest return in the raw dataset for ease of evaluation. One can also use a separate expert trajectory. All of the experiments in this paper are run for 1M gradient steps over five different random seeds, and the results are averaged at the final gradient step. We report the mean performance in conjunction with the corresponding standard deviation. We adopt the same squashing function for tasks under the same domain. Unless specified, we use the number of expert demonstrations $K = 1$ for evaluation. It is worth noting that SEABO is computationally efficient since there is only a single expert trajectory, and the time complexity of KD-tree gives $\mathcal{O}(d_f\log |\mathcal{D}_e|)$ , where $d_{f}$ is the feature dimension size. It takes SEABO about 1 minute to annotate 1 million unlabeled transitions using merely CPUs. Hence, we believe the overall computation overhead from SEABO is minor and tolerable. We defer the experimental details and hyperparameter setup for all of our experiments to Appendix A.
106
+
107
+ # 5.1 MAIN RESULTS
108
+
109
+ SEABO upon different base algorithms. We first explore whether SEABO can aid different offline RL algorithms. We verify this by incorporating SEABO with two popular offline RL algorithms, TD3_BC (Fujimoto & Gu, 2021) and IQL (Kostrikov et al., 2022). We conduct experiments on 9 medium-level (medium, medium-replay, medium-expert) D4RL MuJoCo locomotion "-v2" datasets (halfcheetah, hopper, walker2d) and summarize the results in Table 1. One can see that IQL+SEABO beats IQL with ground-truth rewards on 6 out of 9 datasets, and TD3_BC+SEABO outperforms TD3_BC with raw rewards on 5 out of 9 datasets. On other datasets, SEABO can achieve competitive performance against the oracle performance. The overall scores of SEABO with IQL and TD3_BC exceed those of ground-truth rewards. This evidence indicates that SEABO can generate high-quality rewards and benefit different offline RL algorithms.
110
+
111
+ SEABO competes against baselines. To better illustrate the effectiveness of SEABO, we compare IQL+SEABO against the following strong reward learning and offline IL baselines: ORIL (Zolna et al., 2020), which learns the reward function by contrasting the expert demonstrations with the
112
+
113
+ Table 1: Results of SEABO upon different base algorithms. $\mu_{\mathrm{max}}$ denotes the normalized return of the highest return trajectory in the specific dataset, IQL and TD3_BC indicate that they are trained upon the ground-truth reward labels, while $+SEABO$ indicates the algorithm is trained on the reward signals provided by SEABO. The normalized average scores at the final 10 episodes of evaluations are reported, along with standard deviations. We bold the mean score and highlight the cell if SEABO outperforms algorithms trained on ground-truth rewards.
114
+
115
+ <table><tr><td>Task Name</td><td>μmax</td><td>IQL</td><td>IQL+SEABO</td><td>TD3_BC</td><td>TD3_BC+SEABO</td></tr><tr><td>halfcheetah-medium</td><td>45.0</td><td>47.4±0.2</td><td>44.8±0.3</td><td>48.0±0.7</td><td>45.9±0.3</td></tr><tr><td>hopper-medium</td><td>99.5</td><td>66.2±5.7</td><td>80.9±3.2</td><td>60.7±12.5</td><td>76.1±4.2</td></tr><tr><td>walker2d-medium</td><td>92.0</td><td>78.3±8.7</td><td>80.9±0.6</td><td>83.7±5.3</td><td>76.6±0.4</td></tr><tr><td>halfcheetah-medium-replay</td><td>42.4</td><td>44.2±1.2</td><td>42.3±0.1</td><td>44.4±0.8</td><td>43.0±0.4</td></tr><tr><td>hopper-medium-replay</td><td>98.6</td><td>94.7±8.6</td><td>92.7±2.9</td><td>64.8±25.5</td><td>96.3±3.0</td></tr><tr><td>walker2d-medium-replay</td><td>89.9</td><td>73.8±7.1</td><td>74.0±2.7</td><td>87.4±8.4</td><td>73.1±2.2</td></tr><tr><td>halfcheetah-medium-expert</td><td>92.8</td><td>86.7±5.3</td><td>89.3±2.5</td><td>93.5±2.0</td><td>95.7±0.4</td></tr><tr><td>hopper-medium-expert</td><td>116.0</td><td>91.5±14.3</td><td>97.5±5.8</td><td>100.2±20.0</td><td>107.1±3.3</td></tr><tr><td>walker2d-medium-expert</td><td>109.0</td><td>109.6±1.0</td><td>110.9±0.2</td><td>109.5±0.5</td><td>109.7±0.2</td></tr><tr><td>Total Score</td><td>785.2</td><td>692.4</td><td>713.3</td><td>692.3</td><td>723.5</td></tr></table>
116
+
117
+ Table 2: Comparison of SEABO against some recent baselines. We report the mean normalized scores and the corresponding standard deviations. We bold and highlight the mean score cell if it is close to or beats IQL trained on the raw rewards.
118
+
119
+ <table><tr><td>Task Name</td><td>BC</td><td>10%BC</td><td>IQL</td><td>IQL+ORIL</td><td>IQL+UDS</td><td>IQL+OTR</td><td>IQL+SEABO</td></tr><tr><td>halfcheetah-medium</td><td>42.6</td><td>42.5</td><td>47.4±0.2</td><td>49.0±0.2</td><td>42.4±0.3</td><td>43.2±0.2</td><td>44.8±0.3</td></tr><tr><td>hopper-medium</td><td>52.9</td><td>56.9</td><td>66.2±5.7</td><td>47.0±4.0</td><td>54.5±3.0</td><td>74.2±5.1</td><td>80.9±3.2</td></tr><tr><td>walker2d-medium</td><td>75.3</td><td>75.0</td><td>78.3±8.7</td><td>61.9±6.6</td><td>68.9±6.2</td><td>78.7±2.2</td><td>80.9±0.6</td></tr><tr><td>halfcheetah-medium-replay</td><td>36.6</td><td>40.6</td><td>44.2±1.2</td><td>44.1±0.6</td><td>37.9±2.4</td><td>41.8±0.3</td><td>42.3±0.1</td></tr><tr><td>hopper-medium-replay</td><td>18.1</td><td>75.9</td><td>94.7±8.6</td><td>82.4±1.7</td><td>49.3±22.7</td><td>85.4±0.8</td><td>92.7±2.9</td></tr><tr><td>walker2d-medium-replay</td><td>26.0</td><td>62.5</td><td>73.8±7.1</td><td>76.3±4.9</td><td>17.7±9.6</td><td>67.2±6.0</td><td>74.0±2.7</td></tr><tr><td>halfcheetah-medium-expert</td><td>55.2</td><td>92.9</td><td>86.7±5.3</td><td>87.5±3.9</td><td>63.0±5.7</td><td>87.4±4.4</td><td>89.3±2.5</td></tr><tr><td>hopper-medium-expert</td><td>52.5</td><td>110.9</td><td>91.5±14.3</td><td>29.7±22.2</td><td>53.9±2.5</td><td>88.4±12.6</td><td>97.5±5.8</td></tr><tr><td>walker2d-medium-expert</td><td>107.5</td><td>109.0</td><td>109.6±1.0</td><td>110.6±0.6</td><td>107.5±1.7</td><td>109.5±0.3</td><td>110.9±0.2</td></tr><tr><td>Total Score</td><td>466.7</td><td>666.2</td><td>692.4</td><td>588.5</td><td>495.1</td><td>675.8</td><td>713.3</td></tr></table>
120
+
121
+ unlabeled trajectories; UDS (Yu et al., 2022), which keeps the rewards in the expert demonstrations and simply assigns minimum rewards to the unlabeled data; OTR (Luo et al., 2023), which learns a reward function via using the optimal transport to get the optimal alignment between the expert demonstrations and unlabeled trajectories. For a fair comparison, all these methods adopt IQL as the base algorithm. We additionally compare against BC, and $10\%$ BC (Chen et al., 2021). We take the results of IQL+ORIL and IQL+UDS directly from the OTR paper. As OTR computes rewards using pure observations (and SEABO uses $(s,a,s')$ to query the reward), we modify its way of solving optimal coupling by involving actions, and run IQL+OTR on these datasets with its official codebase. We summarize the comparison results in Table 2. It can be found that, though methods like ORIL and OTR can lead to competitive or better performance on some of the datasets than IQL trained with raw rewards, SEABO beats them on numerous tasks. Meanwhile, SEABO is the only method that can surpass IQL with ground-truth rewards in terms of the total score.
122
+
123
+ SEABO evaluation on wider datasets. We further evaluate IQL+SEABO on two challenging domains from D4RL, AntMaze and Adroit. We run IQL with ground-truth rewards to obtain the IQL performance. We take the results of IQL+OTR from its paper directly. Table 3 demonstrates the detailed comparison results. We find that IQL+SEABO beats IQL and IQL+OTR on 5 out of 6 datasets on AntMaze, and outperforms baselines on 6 out of 8 datasets on Adroit, often by a large margin. IQL+SEABO incurs a performance improvement of $6.0\%$ and $32.0\%$ beyond IQL with vanilla rewards on AntMaze and Adroit tasks, respectively. These indicate that SEABO with one single expert trajectory can handle datasets with diverse behavior, and work as a good and promising proxy to the hand-crafted rewards.
124
+
125
+ <table><tr><td>Task Name</td><td>IQL</td><td>IQL+OTR</td><td>IQL+SEABO</td></tr><tr><td>umaze</td><td>87.5±2.6</td><td>83.4±3.3</td><td>90.0±1.8</td></tr><tr><td>umaze-diverse</td><td>62.2±13.8</td><td>68.9±13.6</td><td>66.2±7.2</td></tr><tr><td>medium-diverse</td><td>70.0±10.9</td><td>70.4±4.8</td><td>72.2±4.1</td></tr><tr><td>medium-play</td><td>71.2±7.3</td><td>70.5±6.6</td><td>71.6±5.4</td></tr><tr><td>large-diverse</td><td>47.5±9.5</td><td>45.5±6.2</td><td>50.0±6.8</td></tr><tr><td>large-play</td><td>39.6±5.8</td><td>45.3±6.9</td><td>50.8±8.7</td></tr><tr><td>Total Score</td><td>378.0</td><td>384.0</td><td>400.8</td></tr></table>
126
+
127
+ Table 3: Experimental results on the AntMaze-v0 and Adroit-v0 domains. SEABO and OTR use IQL as the base algorithm. IQL denotes that IQL uses the ground-truth reward for policy learning. We report the mean normalized scores and the corresponding standard deviations. We bold and highlight the best mean score cell.
128
+
129
+ <table><tr><td>Task Name</td><td>IQL</td><td>IQL+OTR</td><td>IQL+SEABO</td></tr><tr><td>pen-human</td><td>70.7±8.6</td><td>66.8±21.2</td><td>94.3±12.0</td></tr><tr><td>pen-cloned</td><td>37.2±7.3</td><td>46.9±20.9</td><td>48.7±15.3</td></tr><tr><td>door-human</td><td>3.3±1.3</td><td>5.9±2.7</td><td>5.1±2.0</td></tr><tr><td>door-cloned</td><td>1.6±0.5</td><td>0.0±0.0</td><td>0.4±0.8</td></tr><tr><td>relocate-human</td><td>0.1±0.0</td><td>0.1±0.1</td><td>0.4±0.5</td></tr><tr><td>relocate-cloned</td><td>-0.2±0.0</td><td>-0.2±0.0</td><td>-0.2±0.0</td></tr><tr><td>hammer-human</td><td>1.6±0.6</td><td>1.8±1.4</td><td>2.7±1.8</td></tr><tr><td>hammer-cloned</td><td>2.1±1.0</td><td>0.9±0.3</td><td>2.2±0.8</td></tr><tr><td>Total Score</td><td>116.4</td><td>122.2</td><td>153.6</td></tr></table>
130
+
131
+ Table 4: Comparison of SEABO against imitation learning algorithms. We use IQL as the base algorithm for SEABO and PWIL. PWIL-action means that we concatenate state and action to compute rewards in PWIL. We report the mean performance at the final 10 episodes of evaluation for each algorithm, $\pm$ captures the standard deviation. We highlight the best mean score cell.
132
+
133
+ <table><tr><td>Task Name</td><td>SQIL</td><td>DemoDICE</td><td>SMODICE</td><td>PWIL-action</td><td>SEABO</td></tr><tr><td>halfcheetah-medium</td><td>31.3±1.8</td><td>42.5±1.7</td><td>41.7±1.0</td><td>44.4±0.2</td><td>44.8±0.3</td></tr><tr><td>hopper-medium</td><td>44.7±20.1</td><td>55.1±3.3</td><td>56.3±2.3</td><td>60.4±1.8</td><td>80.9±3.2</td></tr><tr><td>walker2d-medium</td><td>59.6±7.5</td><td>73.4±2.6</td><td>13.3±9.2</td><td>72.6±6.3</td><td>80.9±0.6</td></tr><tr><td>halfcheetah-medium-replay</td><td>29.3±2.2</td><td>38.1±2.7</td><td>38.7±2.4</td><td>42.6±0.5</td><td>42.3±0.1</td></tr><tr><td>hopper-medium-replay</td><td>45.2±23.1</td><td>39.0±15.4</td><td>44.3±19.7</td><td>94.0±7.0</td><td>92.7±2.9</td></tr><tr><td>walker2d-medium-replay</td><td>36.3±13.2</td><td>52.2±13.1</td><td>44.6±23.4</td><td>41.9±6.0</td><td>74.0±2.7</td></tr><tr><td>halfcheetah-medium-expert</td><td>40.1±6.4</td><td>85.8±5.7</td><td>87.9±5.8</td><td>89.5±3.6</td><td>89.3±2.5</td></tr><tr><td>hopper-medium-expert</td><td>49.8±5.8</td><td>92.3±14.2</td><td>76.0±8.6</td><td>70.9±35.1</td><td>97.5±5.8</td></tr><tr><td>walker2d-medium-expert</td><td>35.9±22.2</td><td>106.9±1.9</td><td>47.8±31.1</td><td>109.8±0.2</td><td>110.9±0.2</td></tr><tr><td>Total Score</td><td>372.2</td><td>585.3</td><td>450.6</td><td>626.1</td><td>713.3</td></tr></table>
134
+
135
+ # 5.2 COMPARISON AGAINST OFFLINE IL ALGORITHMS
136
+
137
+ To further show the advantages of SEABO, we additionally compare it against recent strong offline imitation learning approaches, including DemoDICE (Kim et al., 2022b) and SMODICE (Ma et al., 2022). We also convert two online IL algorithms into the offline setting, SQIL (Reddy et al., 2020) and PWIL (Dadashi et al., 2021), where we replace the base algorithm in SQIL with TD3_BC and utilize IQL as the base algorithm for PWIL. All algorithms are run using their official implementations under the identical experimental setting as SEABO (i.e., one single expert demonstration). For a fair comparison, we involve actions when training discriminators in SMODICE and measuring the distance in PWIL. We use IQL as the base algorithm for SEABO. The empirical results in Table 4 show that IQL+SEABO achieves the best performance on 6 out of 9 datasets, and has the highest total score (surpassing the second highest one by $13.9\%$ ). Though SEABO underperforms PWIL on some datasets, it significantly beats PWIL on tasks like hopper-medium-v2. Note that SMODICE behaves poorly on many tasks, which is also observed in Li et al. (2023).
138
+
139
+ # 5.3 STATE-ONLY REGIMES
140
+
141
+ We now examine how SEABO behaves when the expert demonstrations consist of only observations, i.e., $\mathcal{D}_e = \{\tau_e^i\}_{i=1}^M$ , where $M$ is the size of the demonstration and $\tau = \{s_0, s_1, \ldots, s_T\}$ . In principle, SEABO can also calculate rewards by querying the KD-tree with only states, $(\tilde{s}_e, \tilde{s}_e') = \text{NearestNeighbor}(\mathcal{D}_e, (s, s'))$ . The distance can then be calculated with some distance metric $D$ , $d = D((\tilde{s}_e, \tilde{s}_e'), (s, s'))$ , and the rewards can be computed accordingly, via Equation 3. For baselines, since DemoDICE and ValueDICE are inapplicable to state-only regimes (Zhu et al., 2021), we compare against LobsDICE (Kim et al., 2022a), which is a state-of-the-art offline IL algorithm that learns from expert observations. We also involve SMODICE, PWIL, and OTR for comparison, and train them using only expert observations. All baselines are run with their official implementation.
142
+
143
+ Table 5: Experimental results on the state-only regime. SEABO, PWIL, and OTR utilize IQL as the base offline RL algorithm. PWIL-state denotes that PWIL only uses observations to compute rewards. The results are averaged over the final 10 evaluations, and $\pm$ captures the standard deviation. We highlight the cell with the best mean performance.
144
+
145
+ <table><tr><td>Task Name</td><td>SMODICE</td><td>LobsDICE</td><td>PWIL-state</td><td>OTR</td><td>SEABO</td></tr><tr><td>halfcheetah-medium</td><td>41.1±2.1</td><td>41.5±1.8</td><td>0.1±0.6</td><td>43.3±0.2</td><td>45.0±0.2</td></tr><tr><td>hopper-medium</td><td>56.5±1.8</td><td>56.9±1.4</td><td>1.4±0.5</td><td>78.7±5.5</td><td>74.7±5.2</td></tr><tr><td>walker2d-medium</td><td>15.5±18.6</td><td>69.3±5.4</td><td>0.2±0.2</td><td>79.4±1.4</td><td>81.3±1.3</td></tr><tr><td>halfcheetah-medium-replay</td><td>39.2±3.1</td><td>39.9±3.1</td><td>-2.4±0.2</td><td>41.3±0.6</td><td>42.4±0.6</td></tr><tr><td>hopper-medium-replay</td><td>55.3±21.4</td><td>41.6±16.8</td><td>0.7±0.2</td><td>84.8±2.6</td><td>88.0±0.7</td></tr><tr><td>walker2d-medium-replay</td><td>37.8±10.2</td><td>33.2±7.0</td><td>-0.2±0.2</td><td>66.0±6.7</td><td>76.4±3.0</td></tr><tr><td>halfcheetah-medium-expert</td><td>88.0±4.0</td><td>89.4±3.2</td><td>0.0±1.0</td><td>89.6±3.0</td><td>91.8±1.5</td></tr><tr><td>hopper-medium-expert</td><td>75.1±11.7</td><td>53.4±3.2</td><td>2.7±2.1</td><td>93.2±20.6</td><td>97.5±6.4</td></tr><tr><td>walker2d-medium-expert</td><td>32.3±14.7</td><td>106.6±2.7</td><td>0.2±0.3</td><td>109.3±0.8</td><td>110.5±0.3</td></tr><tr><td>Total Score</td><td>440.8</td><td>531.8</td><td>2.7</td><td>685.6</td><td>707.6</td></tr></table>
146
+
147
+ Table 6: Comparison of different choices of search algorithms in SEABO. We report the mean normalized scores with standard deviations. We highlight the best mean score cell except for IQL.
148
+
149
+ <table><tr><td>Task Name</td><td>IQL</td><td>SEABO (KD-tree)</td><td>SEABO (Ball-tree)</td><td>SEABO (HNSW)</td></tr><tr><td>halfcheetah-medium</td><td>47.4±0.2</td><td>44.8±0.3</td><td>44.9±0.3</td><td>42.1±0.6</td></tr><tr><td>hopper-medium</td><td>66.2±5.7</td><td>80.9±3.2</td><td>80.7±3.7</td><td>47.2±2.9</td></tr><tr><td>walker2d-medium</td><td>78.3±8.7</td><td>80.9±0.6</td><td>80.8±0.6</td><td>30.7±19.9</td></tr><tr><td>halfcheetah-medium-replay</td><td>44.2±1.2</td><td>42.3±0.1</td><td>42.5±0.3</td><td>26.9±4.2</td></tr><tr><td>hopper-medium-replay</td><td>94.7±8.6</td><td>92.7±2.9</td><td>92.1±2.3</td><td>25.8±7.5</td></tr><tr><td>walker2d-medium-replay</td><td>73.8±7.1</td><td>74.0±2.7</td><td>74.3±2.0</td><td>29.1±10.1</td></tr><tr><td>halfcheetah-medium-expert</td><td>86.7±5.3</td><td>89.3±2.5</td><td>89.2±2.4</td><td>34.5±2.2</td></tr><tr><td>hopper-medium-expert</td><td>91.5±14.3</td><td>97.5±5.8</td><td>96.7±6.2</td><td>41.5±7.7</td></tr><tr><td>walker2d-medium-expert</td><td>109.6±1.0</td><td>110.9±0.2</td><td>110.9±0.1</td><td>108.6±0.8</td></tr><tr><td>Total Score</td><td>692.4</td><td>713.3</td><td>712.1</td><td>386.4</td></tr></table>
150
+
151
+ tions and single expert demonstration. The results in Table 5 suggest that SEABO outperforms other methods on 8 out of 9 tasks, achieving a total score of 707.6, while LobsDICE and OTR only have a total score of 531.8 and 685.6, respectively. It indicates that SEABO can work quite well regardless of whether the expert demonstrations contain actions, further demonstrating the advantages of SEABO. Note that the failure of PWIL in state-only regimes is also reported in Luo et al. (2023).
152
+
153
+ # 5.4 COMPARISON OF DIFFERENT SEARCH ALGORITHMS
154
+
155
+ The most critical component in SEABO is the nearest neighbor search algorithm. It is interesting to check how SEABO performs under different search algorithms. To that end, we build SEABO on top of Ball-tree (Omohundro, 1989; Liu et al., 2006), and HNSW (Hierarchical Navigable Small World graphs, Malkov & Yashunin (2018)). These are widely applied nearest neighbor algorithms, where Ball-tree partitions regions via hyper-spheres and HNSW is a fully graph-based search structure. We allow the single expert demonstration to involve actions (i.e., query with $(s, a, s')$ ), and run all of the variants of SEABO using the same set of hyperparameters for a fair comparison. Empirical results on 9 D4RL locomotion datasets are shown in Table 6. It is interesting to see that SEABO with Ball-tree is competitive with SEABO with KD-tree (their performance differences are minor), while SEABO with HNSW exhibits poor performance on many datasets. This means that the choice of the search algorithm counts in SEABO, and simply employing KD-tree can already guarantee good performance. Please see more discussions in Appendix C.
156
+
157
+ # 5.5 PARAMETER STUDY
158
+
159
+ It is vital to examine how sensitive SEABO is to the introduced hyperparameters. Due to the space limit, we can only report part of the experiments here and defer more experiments to Appendix B.3.
160
+
161
+ ![](images/69f51e9e1eacdfb053ee5b9d2614a20c336f83ba0aa37c0b001fb5c61f6a9d2e.jpg)
162
+ Figure 3: Parameter study on the reward scale. The shaded region denotes the standard deviation.
163
+
164
+ ![](images/a53d09a08446678c716bc877be6e8d21ae683a67da2e4b6fac987578abd3ec0a.jpg)
165
+ (a) Weighting coefficient $\beta$
166
+
167
+ ![](images/147643607141f250aa3ddce86dace34cf50a7bac32a986a7b76aa3cca27367ff.jpg)
168
+ (b) Number of neighbors $N$
169
+ Figure 4: Parameter study of (a) weighting coefficient $\beta$ , (b) number of neighbors $N$ . The shaded region captures the standard deviation.
170
+
171
+ Reward scale $\alpha$ . $\alpha$ controls the scale of the resulting rewards. To check its influence, we conduct experiments on three datasets from D4RL locomotion tasks and sweep $\alpha$ across $\{1, 5, 10\}$ . Results in Figure 3 demonstrate that the best $\alpha$ may depend on the dataset while a smaller $\alpha$ is preferred.
172
+
173
+ Weighting coefficient $\beta$ . $\beta$ is probably the most critical hyperparameter which decides the scale of the distance. In Figure 4(a), we vary $\beta$ across $\{0.1, 0.5, 1, 5\}$ , and find that the performance drops with too small or too large $\beta$ . It seems that $\beta = 0.5$ or $\beta = 1$ can achieve a good trade-off.
174
+
175
+ Number of neighbors $N$ . To see whether the number of neighbors $N$ matters, we run IQL+SEABO with $N \in \{1, 5, 10\}$ . Results in Figure 4(b) show that SEABO is robust to this hyperparameter.
176
+
177
+ Number of expert demonstrations $K$ . We investigate whether increasing the number of expert demonstrations can further boost the performance of SEABO and baselines by running experiments of these methods on 9 MuJoCo locomotion tasks. We report the aggregate performance (i.e., total score) in Table 7. One can see that all methods enjoy performance improvement when $K = 10$ , while none of them can outperform SEABO (there still exists a large performance gap).
178
+
179
+ Table 7: Comparison of SEABO against baseline algorithms under different amounts of expert demonstrations. We report the aggregate performances and bold the best one.
180
+
181
+ <table><tr><td># demo</td><td>DemoDICE</td><td>IQL+ORIL</td><td>IQL+UDS</td><td>IQL+OTR</td><td>IQL+PWIL</td><td>IQL+SEABO</td></tr><tr><td>K=1</td><td>585.3</td><td>588.5</td><td>495.1</td><td>685.6</td><td>626.1</td><td>713.3</td></tr><tr><td>K=10</td><td>589.3</td><td>618.3</td><td>575.8</td><td>694.2</td><td>638.0</td><td>716.1</td></tr></table>
182
+
183
+ # 6 CONCLUSION
184
+
185
+ In this paper, we propose a novel search-based offline imitation learning method, dubbed SEABO, that annotates the unlabeled offline trajectories in an unsupervised learning manner. SEABO builds a KD-tree using the expert demonstration(s), and searches the nearest neighbors of the query sample. We then measure their distance and output the reward signal via a squashing function. SEABO is easy to implement and can be incorporated with any offline RL algorithm. Experiments on D4RL datasets show that SEABO can incur competitive or even better offline policies than pre-defined reward functions. SEABO can also function well if the expert demonstrations are made up of only observations. For future work, it is interesting to apply SEABO in visual offline RL datasets (e.g., Lu et al. (2022b)), or adapt SEABO to cross-domain offline imitation learning tasks.
186
+
187
+ # ACKNOWLEDGEMENTS
188
+
189
+ This work was supported by the STI 2030-Major Projects under Grant 2021ZD0201404 and NSFC under Grant 62250068. The authors would like to thank the anonymous reviewers for their valuable comments and advice.
190
+
191
+ # REFERENCES
192
+
193
+ Saurabh Arora and Prashant Doshi. A Survey of Inverse Reinforcement Learning: Challenges, Methods and Progress. Artificial Intelligence, 297:103500, 2021.
194
+ Chenjia Bai, Lingxiao Wang, Zhuoran Yang, Zhi-Hong Deng, Animesh Garg, Peng Liu, and Zhaoran Wang. Pessimistic Bootstrapping for Uncertainty-Driven Offline Reinforcement Learning. In International Conference on Learning Representations, 2022. URL https://openreview.net/forum?id=Y4cs1Z3HnqL.
195
+ Nir Baram, Oron Anschel, Itai Caspi, and Shie Mannor. End-to-End Differentiable Adversarial Imitation Learning. In International Conference on Machine Learning, 2017.
196
+ Jon Louis Bentley. Multidimensional binary search trees used for associative searching. Communications of the ACM, 18(9):509-517, 1975.
197
+ Abdeslam Boullarias, Jens Kober, and Jan Peters. Relative Entropy Inverse Reinforcement Learning. In International Conference on Artificial Intelligence and Statistics, 2011.
198
+ Lili Chen, Kevin Lu, Aravind Rajeswaran, Kimin Lee, Aditya Grover, Michael Laskin, P. Abbeel, A. Srinivas, and Igor Mordatch. Decision Transformer: Reinforcement Learning via Sequence Modeling. *ArXiv*, abs/2106.01345, 2021.
199
+ Ching-An Cheng, Tengyang Xie, Nan Jiang, and Alekh Agarwal. Adversarily Trained Actor Critic for Offline Reinforcement Learning. In Proceedings of the 39th International Conference on Machine Learning, 2022. URL https://proceedings.mlr.press/v162/cheng22b.html.
200
+ Kamil Ciosek. Imitation Learning by Reinforcement Learning. In International Conference on Learning Representations, 2022. URL https://openreview.net/forum?id=1zwleytEpYx.
201
+ Samuel Cohen, Brandon Amos, Marc Peter Deisenroth, Mikael Henaff, Eugene Vinitsky, and Denis Yarats. Imitation Learning from Pixel Observations for Continuous Control, 2022. URL https://openreview.net/forum?id=JLbXkHkLCG6.
202
+ Robert Dadashi, Leonard Hussenot, Matthieu Geist, and Olivier Pietquin. Primal Wasserstein Imitation Learning. In International Conference on Learning Representations, 2021. URL https://openreview.net/forum?id=TtYSU29zgR.
203
+ Jonas Degrave, Federico Felici, Jonas Buchli, Michael Neunert, Brendan Tracey, Francesco Carpanese, Timo Ewalds, Roland Hafner, Abbas Abdelmaleki, Diego de Las Casas, et al. Magnetic control of tokamak plasmas through deep reinforcement learning. Nature, 602(7897):414-419, 2022.
204
+ Branton DeMoss, Paul Duckworth, Nick Hawes, and Ingmar Posner. DITTO: Offline Imitation Learning with World Models. ArXiv, abs/2302.03086, 2023.
205
+ Edsger W. Dijkstra. A note on two problems in connexion with graphs. Numerische Mathematik, 1: 269-271, 1959.
206
+ James E Doran and Donald Michie. Experiments with the graph traverser program. Proceedings of the Royal Society of London. Series A. Mathematical and Physical Sciences, 294(1437):235-259, 1966.
207
+ Stefan Edelkamp and Stefan Schrödl. Heuristic search: theory and applications. Elsevier, 2011.
208
+
209
+ Gideon Joseph Freund, Elad Sarafian, and Sarit Kraus. A Coupled Flow Approach to Imitation Learning. In International Conference on Machine Learning, 2023.
210
+ Justin Fu, Aviral Kumar, Ofir Nachum, G. Tucker, and Sergey Levine. D4RL: Datasets for Deep Data-Driven Reinforcement Learning. ArXiv, abs/2004.07219, 2020.
211
+ Scott Fujimoto and Shixiang Shane Gu. A Minimalist Approach to Offline Reinforcement Learning. In Advances in Neural Information Processing Systems, 2021.
212
+ Scott Fujimoto, David Meger, and Doina Precup. Off-Policy Deep Reinforcement Learning without Exploration. In International Conference on Machine Learning, 2019.
213
+ Seyed Kamyar Seyed Ghasemipour, Richard S. Zemel, and Shixiang Shane Gu. A Divergence Minimization Perspective on Imitation Learning Methods. In Conference on Robot Learning, 2019.
214
+ Abhishek Gupta, Vikash Kumar, Corey Lynch, Sergey Levine, and Karol Hausman. Relay Policy Learning: Solving Long-Horizon Tasks via Imitation and Reinforcement Learning. *ArXiv*, abs/1910.11956, 2019.
215
+ Peter E Hart, Nils J Nilsson, and Bertram Raphael. A formal basis for the heuristic determination of minimum cost paths. IEEE transactions on Systems Science and Cybernetics, 4(2):100-107, 1968.
216
+ Minho Heo, Youngwoo Lee, Doohyun Lee, and Joseph J. Lim. FurnitureBench: Reproducible Real-World Benchmark for Long-Horizon Complex Manipulation. ArXiv, abs/2305.12821, 2023.
217
+ Jonathan Ho and Stefano Ermon. Generative Adversarial Imitation Learning. In Advances in Neural Information Processing Systems, 2016.
218
+ Matthew W. Hoffman, Bobak Shahriari, John Aslanides, Gabriel Barth-Maron, Feryal M. P. Behbahani, Tamara Norman, Abbas Abdelmaleki, Albin Cassirer, Fan Yang, Kate Baumli, Sarah Henderson, Alexander Novikov, Sergio Gomez Colmenarejo, Serkan Cabi, Caglar Gulcehre, Tom Le Paine, Andrew Cowie, Ziyun Wang, Bilal Piot, and Nando de Freitas. Acme: A Research Framework for Distributed Reinforcement Learning. ArXiv, abs/2006.00979, 2020. URL https://apisemantic scholar.org/CorpusID:219176679.
219
+ Michael Janner, Qiyang Li, and Sergey Levine. Offline Reinforcement Learning as One Big Sequence Modeling Problem. In Advances in Neural Information Processing Systems, 2021.
220
+ Daniel Jarrett, Ioana Bica, and Mihaela van der Schaar. Strictly Batch Imitation Learning by Energy-based Distribution Matching. In Advances in neural information processing systems, 2020.
221
+ Wonseok Jeon, Seokin Seo, and Kee-Eung Kim. A Bayesian Approach to Generative Adversarial Imitation Learning. In Neural Information Processing Systems, 2018.
222
+ Liyiming Ke, Matt Barnes, Wen Sun, Gilwoo Lee, Sanjiban Choudhury, and Siddhartha S. Srinivasa. Imitation Learning as f-Divergence Minimization. In Workshop on the Algorithmic Foundations of Robotics, 2019.
223
+ Rahul Kidambi, Aravind Rajeswaran, Praneeth Netrapalli, and Thorsten Joachims. MOReL: Model-Based Offline Reinforcement Learning. In Advances in Neural Information Processing Systems, 2020.
224
+ Geon-Hyeong Kim, Jongmin Lee, Youngsoo Jang, Hongseok Yang, and Kee-Eung Kim. Lobs-DICE: Offline Learning from Observation via Stationary Distribution Correction Estimation. In Advances in Neural Information Processing Systems, 2022a. URL https://openreview.net/forum?id=8U5J6zK_MtV.
225
+ Geon-Hyeong Kim, Seokin Seo, Jongmin Lee, Wonseok Jeon, HyeongJoo Hwang, Hongseok Yang, and Kee-Eung Kim. DemoDICE: Offline Imitation Learning with Supplementary Imperfect Demonstrations. In International Conference on Learning Representations, 2022b. URL https://openreview.net/forum?id=BrPdX1bDZkQ.
226
+
227
+ Kuno Kim, Akshit Jindal, Yang Song, Jiaming Song, Yanan Sui, and Stefano Ermon. Imitation with Neural Density Models. In Neural Information Processing Systems, 2020.
228
+ Diederik P. Kingma and Jimmy Ba. Adam: A Method for Stochastic Optimization. In International Conference on Learning Representation, 2015.
229
+ Jens Kober, J Andrew Bagnell, and Jan Peters. Reinforcement learning in robotics: A survey. The International Journal of Robotics Research, 32(11):1238-1274, 2013.
230
+ Richard E Korf. Depth-first iterative-deepening: An optimal admissible tree search. Artificial intelligence, 27(1):97-109, 1985.
231
+ Richard E. Korf. Artificial Intelligence Search Algorithms. In Algorithms and Theory of Computation Handbook, 1999.
232
+ Ilya Kostrikov, Kumar Krishna Agrawal, Debidatta Dwibedi, Sergey Levine, and Jonathan Tompson. Discriminator-Actor-Critic: Addressing Sample Inefficiency and Reward Bias in Adversarial Imitation Learning. In International Conference on Learning Representations, 2019. URL https://openreview.net/forum?id=Hk4fpoA5Km.
233
+ Ilya Kostrikov, Ofir Nachum, and Jonathan Tompson. Imitation Learning via Off-Policy Distribution Matching. In International Conference on Learning Representations, 2020. URL https://openreview.net/forum?id=Hyg-JC4FDr.
234
+ Ilya Kostrikov, Ashvin Nair, and Sergey Levine. Offline Reinforcement Learning with Implicit Q-Learning. In International Conference on Learning Representations, 2022. URL https://openreview.net/forum?id=68n2s9ZJWF8.
235
+ Aviral Kumar, Aurick Zhou, G. Tucker, and Sergey Levine. Conservative Q-Learning for Offline Reinforcement Learning. In Advances in Neural Information Processing Systems, 2020.
236
+ Sascha Lange, Thomas Gabel, and Martin A. Riedmiller. Batch Reinforcement Learning. In Reinforcement Learning, 2012.
237
+ Youngwoon Lee, Edward S. Hu, Zhengyu Yang, Alexander Yin, and Joseph J. Lim. IKEA Furniture Assembly Environment for Long-Horizon Complex Manipulation Tasks. 2021 IEEE International Conference on Robotics and Automation (ICRA), pp. 6343-6349, 2019.
238
+ Youngwoon Lee, Joseph J. Lim, Anima Anandkumar, and Yuke Zhu. Adversarial Skill Chaining for Long-Horizon Robot Manipulation via Terminal State Regularization. In Conference on Robot Learning, 2021.
239
+ Sergey Levine, Aviral Kumar, G. Tucker, and Justin Fu. Offline Reinforcement Learning: Tutorial, Review, and Perspectives on Open Problems. ArXiv, abs/2005.01643, 2020.
240
+ Anqi Li, Byron Boots, and Ching-An Cheng. MAHALO: Unifying Offline Reinforcement Learning and Imitation Learning from Observations. In International Conference on Machine Learning, 2023.
241
+ Ting Liu, Andrew W Moore, Alexander Gray, and Claire Cardie. New Algorithms for Efficient High-Dimensional Nonparametric Classification. Journal of Machine Learning Research, 7(6), 2006.
242
+ Cong Lu, Philip Ball, Jack Parker-Holder, Michael Osborne, and Stephen J. Roberts. Revisiting Design Choices in Offline Model Based Reinforcement Learning. In International Conference on Learning Representations, 2022a. URL https://openreview.net/forum?id=zz9hXVhf40.
243
+ Cong Lu, Philip J Ball, Tim GJ Rudner, Jack Parker-Holder, Michael A Osborne, and Yee Whye Teh. Challenges and Opportunities in Offline Reinforcement Learning from Visual Observations. arXiv preprint arXiv:2206.04779, 2022b.
244
+
245
+ Yicheng Luo, zhengyao jiang, Samuel Cohen, Edward Grefenstette, and Marc Peter Deisen-roth. Optimal Transport for Offline Imitation Learning. In The Eleventh International Conference on Learning Representations, 2023. URL https://openreview.net/forum?id=MhuFzFsrfvH.
246
+ Jiafei Lyu, aicheng Gong, Le Wan, Zongqing Lu, and Xiu Li. State Advantage Weighting for Offline RL. In 3rd Offline RL Workshop: Offline RL as a "Launchpad", 2022a. URL https://openreview.net/forum?id=2rOD_UQfv1.
247
+ Jiafei Lyu, Xiu Li, and Zongqing Lu. Double Check Your State Before Trusting It: Confidence-Aware Bidirectional Offline Model-Based Imagination. In Advances in Neural Information Processing Systems, 2022b. URL https://openreview.net/forum?id=3e3IQMLDSLIP.
248
+ Jiafei Lyu, Xiaoteng Ma, Xiu Li, and Zongqing Lu. Mildly Conservative Q-Learning for Offline Reinforcement Learning. In Advances in Neural Information Processing Systems, 2022c. URL https://openreview.net/forum?id=VYYf6S67pQc.
249
+ Yecheng Jason Ma, Andrew Shen, Dinesh Jayaraman, and Osbert Bastani. Versatile Offline Imitation from Observations and Examples via Regularized State-Occupancy Matching. In International Conference on Machine Learning, 2022.
250
+ Yu A Malkov and Dmitry A Yashunin. Efficient and robust approximate nearest neighbor search using hierarchical navigable small world graphs. IEEE transactions on pattern analysis and machine intelligence, 42(4):824-836, 2018.
251
+ Volodymyr Mnih, Koray Kavukcuoglu, David Silver, Andrei A. Rusu, Joel Veness, Marc G. Bellemare, Alex Graves, Martin A. Riedmiller, Andreas Kirkeby Fidjeland, Georg Ostrovski, Stig Petersen, Charlie Beattie, Amir Sadik, Ioannis Antonoglou, Helen King, Dharshan Kumaran, Daan Wierstra, Shane Legg, and Demis Hassabis. Human-level Control through Deep Reinforcement Learning. Nature, 518:529-533, 2015. URL https://api-semanticscholar.org/CorpusID:205242740.
252
+ Ofir Nachum, Yinlam Chow, Bo Dai, and Lihong Li. DualDICE: Behavior-Agnostic Estimation of Discounted Stationary Distribution Corrections. In Advances in neural information processing systems, 2019.
253
+ Stephen M Omohundro. Five balltree construction algorithms. Technical report, International Computer Science Institute, 1989.
254
+ Jyothish Pari, Nur Muhammad (Mahi) Shafullah, Sridhar Pandian Arunachalam, and Lerrel Pinto. The surprising effectiveness of representation learning for visual imitation. *ArXiv*, abs/2112.01511, 2021.
255
+ Adam Paszke, Sam Gross, Francisco Massa, Adam Lerer, James Bradbury, Gregory Chanan, Trevor Killeen, Zeming Lin, Natalia Gimelshein, Luca Antiga, Alban Desmaison, Andreas Köpf, Edward Yang, Zach DeVito, Martin Raison, Alykhan Tejani, Sasank Chilamkurthy, Benoit Steiner, Lu Fang, Junjie Bai, and Soumith Chintala. PyTorch: An Imperative Style, High-Performance Deep Learning Library. In Neural Information Processing Systems, 2019.
256
+ F. Pedregosa, G. Varoquaux, A. Gramfort, V. Michel, B. Thirion, O. Grisel, M. Blondel, P. Prettenhofer, R. Weiss, V. Dubourg, J. Vanderplas, A. Passos, D. Cournapeau, M. Brucher, M. Perrot, and E. Duchesnay. Scikit-learn: Machine learning in Python. Journal of Machine Learning Research, 12:2825–2830, 2011.
257
+ Ira Pohl. Heuristic search viewed as path finding in a graph. Artificial intelligence, 1(3-4):193-204, 1970.
258
+ Dean A Pomerleau. Alvinn: An autonomous land vehicle in a neural network. In Advances in Neural Information Processing Systems, 1988.
259
+ Yuhang Ran, Yichen Li, Fuxiang Zhang, Zongzhang Zhang, and Yang Yu. Policy Regularization with Dataset Constraint for Offline Reinforcement Learning. In International Conference on Machine Learning, 2023.
260
+
261
+ Siddharth Reddy, Anca D. Dragan, and Sergey Levine. {SQIL}: Imitation Learning via Reinforcement Learning with Sparse Rewards. In International Conference on Learning Representations, 2020. URL https://openreview.net/forum?id=S1xKd24twB.
262
+ Marc Rigter, Bruno Lacerda, and Nick Hawes. RAMBO-RL: Robust Adversarial Model-Based Offline Reinforcement Learning. In Advances in Neural Information Processing Systems, 2022. URL https://openreview.net/forum?id=nrksGSRT7kX.
263
+ Stéphane Ross, Geoffrey J. Gordon, and J. Andrew Bagnell. A Reduction of Imitation Learning and Structured Prediction to No-Regret Online Learning. In International Conference on Artificial Intelligence and Statistics, 2011.
264
+ Julian Schrittwieser, Ioannis Antonoglou, Thomas Hubert, Karen Simonyan, Laurent Sifre, Simon Schmitt, Arthur Guez, Edward Lockhart, Demis Hassabis, Thore Graepel, et al. Mastering atari, go, chess and shogi by planning with a learned model. Nature, 588(7839):604-609, 2020.
265
+ Mark E Stickel and Mabry Tyson. An analysis of consecutively bounded depth-first search with applications in automated deduction. In *IJCAI*, pp. 1073-1075, 1985.
266
+ Richard S Sutton and Andrew G Barto. Reinforcement learning: An introduction. MIT press, 2018.
267
+ Larry A. Taylor and Richard E. Korf. Pruning Duplicate Nodes in Depth-First Search. In AAAI Conference on Artificial Intelligence, 1993.
268
+ Emanuel Todorov, Tom Erez, and Yuval Tassa. MuJoCo: A Physics Engine for Model-based Control. IEEE/RSJ International Conference on Intelligent Robots and Systems, 2012.
269
+ Faraz Torabi, Garrett Warnell, and Peter Stone. Recent Advances in Imitation Learning from Observation. In International Joint Conference on Artificial Intelligence, 2019.
270
+ Masatoshi Uehara and Wen Sun. Pessimistic Model-based Offline Reinforcement Learning under Partial Coverage. In International Conference on Learning Representations, 2022. URL https://openreview.net/forum?id=tyrJsbKAe6.
271
+ Pauli Virtanen, Ralf Gommers, Travis E. Oliphant, Matt Haberland, Tyler Reddy, David Cournapeau, Evgeni Burovski, PEARU Peterson, Warren Weckesser, Jonathan Bright, Stéfan J. van der Walt, Matthew Brett, Joshua Wilson, K. Jarrod Millman, Nikolay Mayorov, Andrew R. J. Nelson, Eric Jones, Robert Kern, Eric Larson, C J Carey, Ilhan Polat, Yu Feng, Eric W. Moore, Jake VanderPlas, Denis Laxalde, Josef Perktold, Robert Cirmrnan, Ian Henriksen, E. A. Quintero, Charles R. Harris, Anne M. Archibald, Antonio H. Ribeiro, Fabian Pedregosa, Paul van Mulbregt, and SciPy 1.0 Contributors. SciPy 1.0: Fundamental Algorithms for Scientific Computing in Python. Nature Methods, 17:261-272, 2020.
272
+ Ruohan Wang, Carlo Ciliberto, Pierluigi Vito Amadori, and Y. Demiris. Support-weighted Adversarial Imitation Learning. ArXiv, abs/2002.08803, 2020.
273
+ Haoran Xu, Xianyuan Zhan, Honglei Yin, and Huiling Qin. Discriminator-Weighted Offline Imitation Learning from Suboptimal Demonstrations. In International Conference on Machine Learning, 2022.
274
+ Kai Yang, Jian Tao, Jiafei Lyu, and Xiu Li. Exploration and anti-exploration with distributional random network distillation. ArXiv, abs/2401.09750, 2024.
275
+ Lantao Yu, Tianhe Yu, Jiaming Song, Willie Neiswanger, and Stefano Ermon. Offline Imitation Learning with Suboptimal Demonstrations via Relaxed Distribution Matching. In AAAI Conference on Artificial Intelligence, 2023.
276
+ Tianhe Yu, Garrett Thomas, Lantao Yu, Stefano Ermon, James Y. Zou, Sergey Levine, Chelsea Finn, and Tengyu Ma. MOPO: Model-based Offline Policy Optimization. In Advances in Neural Information Processing Systems, 2020.
277
+ Tianhe Yu, Aviral Kumar, Rafael Rafailov, Aravind Rajeswaran, Sergey Levine, and Chelsea Finn. COMBO: Conservative Offline Model-Based Policy Optimization. In Advances in Neural Information Processing Systems, 2021.
278
+
279
+ Tianhe Yu, Aviral Kumar, Yevgen Chebotar, Karol Hausman, Chelsea Finn, and Sergey Levine. How to Leverage Unlabeled Data in Offline Reinforcement Learning. In International Conference on Machine Learning, 2022.
280
+ Sheng Yue, Guanbo Wang, Wei Shao, Zhaofeng Zhang, Sen Lin, Ju Ren, and Junshan Zhang. CLARE: Conservative Model-Based Reward Learning for Offline Inverse Reinforcement Learning. In The Eleventh International Conference on Learning Representations, 2023. URL https://openreview.net/forum?id=5aT4ganOd98.
281
+ Junjie Zhang, Jiafei Lyu, Xiaoteng Ma, Jiangpeng Yan, Jun Yang, Le Wan, and Xiu Li. Uncertainty-driven Trajectory Truncation for Model-based Offline Reinforcement Learning. ArXiv, abs/2304.04660, 2023.
282
+ Wenxuan Zhou, Sujay Bajracharya, and David Held. PLAS: Latent Action Space for Offline Reinforcement Learning. In Conference on Robot Learning, 2020.
283
+ Zhuangdi Zhu, Kaixiang Lin, Bo Dai, and Jiayu Zhou. Off-Policy Imitation Learning from Observations. In Neural Information Processing Systems, 2021.
284
+ Brian D. Ziebart, Andrew L. Maas, J. Andrew Bagnell, and Anind K. Dey. Maximum Entropy Inverse Reinforcement Learning. In AAAI Conference on Artificial Intelligence, 2008.
285
+ Konrad Zolna, Alexander Novikov, Ksenia Konyushkova, Caglar Gulcehre, Ziyun Wang, Yusuf Aytar, Misha Denil, Nando de Freitas, and Scott E. Reed. Offline Learning from Demonstrations and Unlabeled Experience. ArXiv, abs/2011.13885, 2020.
286
+
287
+ # A HYPERPARAMETER SETUP
288
+
289
+ In this section, we detail the hyperparameter setup utilized in our experiments. We conduct experiments on 9 MuJoCo locomotion “-v2” medium-level datasets, 6 AntMaze “-v0” datasets, and 8 Adroit “-v0” datasets, yielding a total of 23 tasks. We list the hyperparameter setup for IQL and TD3_BC on MuJoCo locomotion tasks in Table 8. We keep the hyperparameter setup of the base offline RL algorithms unchanged for both IQL and TD3_BC. For IQL, we do not rescale the rewards in the datasets by $1000 / \max_{\mathrm{return - min\_return}}$ , as we have an additional hyperparameter $\alpha$ to control the reward scale. In practice, we find minor performance differences if we rescale the rewards. We generally utilize the same formula of squashing function for most of the datasets, except that we set $\beta = 1$ in hopper-medium-replay-v2, and $\alpha = 10, \beta = 0.1$ in hopper-medium-expert-v2 for better performance. Note that using $\alpha = 1, \beta = 0.5$ on these tasks can also produce a good performance (e.g., setting $\alpha = 1, \beta = 0.5$ on hopper-medium-replay-v2 leads to an average performance of 87.2, still outperforming strong baselines like OTR), while slightly modifying the hyperparameter setup can result in better performance. We divide the scaled distance by the action dimension of the task to strike a balance between different tasks (as we use one set of hyperparameters). This is also adopted in PWIL paper (Dadashi et al., 2021). For TD3_BC, we use the same type of squashing function as IQL on the locomotion tasks, with $\alpha = 1, \beta = 0.5$ , except that we use $\alpha = 10$ for walker2d-medium-v2 and walker2d-medium-replay-v2 for slightly better performance. We use the official implementation of TD3_BC (https://github.com/sfujim/TD3_BC) and adopt the PyTorch (Paszke et al. (2019)) version of IQL for evaluation.
290
+
291
+ Table 8: Hyperparameter setup of SEABO on locomotion tasks, with IQL and TD3_BC as the base offline RL algorithms.
292
+
293
+ <table><tr><td></td><td>Hyperparameter</td><td>Value</td></tr><tr><td rowspan="8">Shared Configurations</td><td>Hidden layers</td><td>(256, 256)</td></tr><tr><td>Discount factor</td><td>0.99</td></tr><tr><td>Actor learning rate</td><td>3 × 10-4</td></tr><tr><td>Critic learning rate</td><td>3 × 10-4</td></tr><tr><td>Batch size</td><td>256</td></tr><tr><td>Optimizer</td><td>Adam (Kingma &amp; Ba, 2015)</td></tr><tr><td>Target update rate</td><td>5 × 10-3</td></tr><tr><td>Activation function</td><td>ReLU</td></tr><tr><td rowspan="3">IQL</td><td>Value learning rate</td><td>3 × 10-4</td></tr><tr><td>Temperature</td><td>3.0</td></tr><tr><td>Expectile</td><td>0.7</td></tr><tr><td rowspan="4">TD3_BC</td><td>Policy noise</td><td>0.2</td></tr><tr><td>Policy noise clipping</td><td>(-0.5, 0.5)</td></tr><tr><td>Policy update frequency</td><td>2</td></tr><tr><td>Normalization weight</td><td>2.5</td></tr><tr><td rowspan="4">SEABO</td><td>Squashing function</td><td>r = exp(-0.5 × d/|A|)</td></tr><tr><td>Distance measurement</td><td>Euclidean distance</td></tr><tr><td>Number of neighbors</td><td>1</td></tr><tr><td>Number of expert demonstrations</td><td>1</td></tr></table>
294
+
295
+ We summarize the hyperparameter setup of SEABO (using IQL as the underlying algorithm) on the AntMaze domain and Adroit domain in Table 9 and Table 10, respectively. We only list the different hyperparameters in these tables and the other hyperparameters follow those presented in Table 8. Note that we filter the highest return trajectory as the expert demonstration in the Adroit domain, while selecting the goal-reached trajectory as the expert demonstration in the AntMaze domain, which is also adopted in OTR paper (Luo et al., 2023). We adopt a comparatively large $\beta = 5$ on AntMaze tasks. We also follow the IQL paper (Kostrikov et al., 2022) to subtract 1 from the rewards, which we find can result in better performance. For Adroit tasks, we remove the action dimension in the squashing function, since these tasks have large action space dimensions. If one insists on involving $|\mathcal{A}|$ , a much larger $\beta$ than 0.5 is then necessary to mitigate its influence. We find
296
+
297
+ Table 9: Hyperparameter setup of SEABO on AntMaze tasks, with IQL as the base offline RL algorithm.
298
+
299
+ <table><tr><td></td><td>Hyperparameter</td><td>Value</td></tr><tr><td rowspan="2">IQL</td><td>Temperature</td><td>10.0</td></tr><tr><td>Expectile</td><td>0.9</td></tr><tr><td>SEABO</td><td>Squashing function</td><td>r = exp(−5×d/|A|) - 1</td></tr></table>
300
+
301
+ Table 10: Hyperparameter setup of SEABO on Adroit tasks, with IQL as the base offline RL algorithm.
302
+
303
+ <table><tr><td></td><td>Hyperparameter</td><td>Value</td></tr><tr><td rowspan="3">IQL</td><td>Temperature</td><td>0.5</td></tr><tr><td>Expectile</td><td>0.7</td></tr><tr><td>Actor dropout rate</td><td>0.1</td></tr><tr><td>SEABO</td><td>Squashing function</td><td>r = exp(-0.5 × d)</td></tr></table>
304
+
305
+ that simply removing $|\mathcal{A}|$ can ensure quite good performance on all of the evaluated Adroit datasets. Note that OTR (Luo et al., 2023) also adopts different forms of squashing functions for different domains. We query with $(s, s')$ for Adroit tasks and $(s, a, s')$ for other domains.
306
+
307
+ To acquire expert demonstrations, we use the trajectory with the highest return as expert demonstrations on MuJoCo locomotion tasks and Adroit tasks, and filter the goal-reached trajectory in AntMaze tasks. For all of the baseline reward learning and offline imitation learning algorithms, we follow this setting and run them with their official codebases over five different random seeds. We use the PWIL implementation from Acme (Hoffman et al., 2020) $^3$ .
308
+
309
+ In SEABO, we use the KD-tree implementation from the scipy library (Virtanen et al., 2020), i.e., scipyiard. KDTree. We set the number of nearest neighbors $N = 1$ , and keep other default hyperparameters in KD-tree. Note that we can directly get the desired distance by querying the KD-tree. For Ball-tree, we use its implementation in the scikit-learn package (Pedregosa et al., 2011), i.e., sklearn.neighbors.BallTree. We also keep its original hyperparameters unchanged. For HNSW, we use its implementation in hnswlib. We use the suggested hyperparameter setting in its GitHub page and set ef建设和 $= 200$ (which defines a construction time/accuracy trade-off) and $M = 16$ (which defines the maximum number of outgoing connections in the graph). All these search algorithms adopt the Euclidean distance as the distance measurement.
310
+
311
+ In our experiments, we use MuJoCo 2.0 (Todorov et al., 2012) with Gym version 0.18.3, PyTorch (Paszke et al., 2019) version 1.8. We use the normalized score metric recommended in the D4RL paper (Fu et al., 2020), where 0 corresponds to a random policy, and 100 corresponds to an expert policy. Formally, suppose we get the average return $J$ by deploying the learned policy in the test environment, the normalized score gives:
312
+
313
+ $$
314
+ \text {N o r m a l i z e d} = \frac {J - J _ {r}}{J _ {e} - J _ {r}} \times 1 0 0, \tag {4}
315
+ $$
316
+
317
+ where $J_{r}$ is the return of a random policy, and $J_{e}$ is the return of an expert policy.
318
+
319
+ # B MISSING EXPERIMENTAL RESULTS
320
+
321
+ In this section, we present the missing experimental results from the main text due to the space limit.
322
+
323
+ Table 11: Comparison of SEABO against baseline algorithms under 10 expert demonstrations. We use IQL as the base algorithm for SEABO, PWIL, and OTR. We report the mean performance at the final 10 evaluations for each algorithm, and $\pm$ captures the standard deviation.
324
+
325
+ <table><tr><td>Task Name</td><td>IQL</td><td>PWIL-state</td><td>PWIL-action</td><td>OTR-state</td><td>OTR-action</td><td>SEABO</td></tr><tr><td>halfcheetah-medium</td><td>47.4±0.2</td><td>1.6±1.2</td><td>47.5±0.2</td><td>43.1±0.3</td><td>43.4±0.3</td><td>44.4±0.2</td></tr><tr><td>hopper-medium</td><td>66.2±5.7</td><td>2.1±1.3</td><td>70.4±4.2</td><td>80.0±5.2</td><td>75.4±4.6</td><td>81.4±3.5</td></tr><tr><td>walker2d-medium</td><td>78.3±8.7</td><td>0.9±1.3</td><td>81.9±1.0</td><td>79.2±1.3</td><td>79.7±1.2</td><td>81.1±0.7</td></tr><tr><td>halfcheetah-medium-replay</td><td>44.2±1.2</td><td>-2.3±0.5</td><td>44.6±1.1</td><td>41.6±0.3</td><td>41.9±0.3</td><td>43.9±0.2</td></tr><tr><td>hopper-medium-replay</td><td>94.7±8.6</td><td>1.4±1.2</td><td>89.7±4.9</td><td>84.4±1.8</td><td>85.3±1.1</td><td>86.4±1.4</td></tr><tr><td>walker2d-medium-replay</td><td>73.8±7.1</td><td>-0.1±0.2</td><td>72.2±10.6</td><td>71.8±3.8</td><td>69.1±4.6</td><td>78.0±0.7</td></tr><tr><td>halfcheetah-medium-expert</td><td>86.7±5.3</td><td>-0.3±1.5</td><td>88.6±4.3</td><td>87.9±3.4</td><td>88.3±5.1</td><td>90.5±2.5</td></tr><tr><td>hopper-medium-expert</td><td>91.5±14.3</td><td>1.5±0.6</td><td>32.9±25.0</td><td>96.6±21.5</td><td>86.6±22.9</td><td>100.0±7.0</td></tr><tr><td>walker2d-medium-expert</td><td>109.6±1.0</td><td>1.0±1.9</td><td>110.2±0.2</td><td>109.6±0.5</td><td>109.2±0.5</td><td>110.4±0.6</td></tr><tr><td>Total Score</td><td>692.4</td><td>5.8</td><td>638.0</td><td>694.2</td><td>678.9</td><td>716.1</td></tr></table>
326
+
327
+ # B.1 NUMERICAL COMPARISON UNDER TEN EXPERT DEMONSTRATIONS
328
+
329
+ In Section 5.5, we present the comparison results of SEABO and baseline reward learning and offline IL algorithms under different numbers of expert demonstrations $K \in \{1, 10\}$ . However, we only report the aggregate performance (i.e., the total score) on the 9 MuJoCo locomotion medium-level tasks (medium, medium-replay, medium-expert) in Table 7. To make the comparison clearer, we present the detailed normalized scores of these methods under $K = 10$ on different datasets in Table 11, where we mainly compare SEABO against different variants of PWIL and OTR. SEABO computes the rewards with actions involved in the single expert demonstration here.
330
+
331
+ The results reveal that SEABO outperforms baseline methods on 5 out of 9 datasets and is competitive with baselines on the rest of the datasets. SEABO achieves a total score of 716.1, surpassing the second best method (OTR-state) by $3.2\%$ . Though we observe that PWIL-action beats SEABO on datasets like halffcheetah-medium-v2, it can perform poorly on datasets like hopper-medium-expert-v2. We also note that the performance of PWIL deteriorates in the state-only regimes, i.e., learning from pure expert observations. This phenomenon is also reported in Dadashi et al. (2021); Luo et al. (2023). SEABO, instead, is flexible and can be applied regardless of whether the expert demonstrations contain actions.
332
+
333
+ Furthermore, we show in Table 12 the results of IQL+SEABO on AntMaze and Adroit datasets when 10 expert demonstrations are provided. We compare IQL+SEABO against IQL+OTR and IQL with raw rewards (denoted as IQL). The results demonstrate that SEABO can recover the performance of the offline RL algorithm with ground-truth rewards and sometimes yield better performance. This advantage is agnostic to the number of expert demonstrations $K$ .
334
+
335
+ IQL+SEABO matches the performance of IQL+OTR on many AntMaze tasks and outperforms IQL+OTR on 6 out of 8 datasets from the Adroit domain. On both the AntMaze domain and Adroit domain, OTR underperforms SEABO in terms of the total score. One may notice that the performance of IQL+SEABO decreases with more expert demonstrations, mainly on the Adroit datasets. This is caused by the performance drop on pen-human-v0, which dominate the total score (the magnitude of its score is much larger than those of other datasets). One can also observe that the performance of IQL+OTR declines on many Adroit tasks, given 10 expert demonstrations (see Table 7 in Luo et al. (2023)). Still, IQL+SEABO exhibits strong performance across numerous datasets.
336
+
337
+ # B.2 COMPARISON OF TD3_BC+OTR AND TD3_BC+SEABO
338
+
339
+ Since the majority of the experiments in the main text are conducted using IQL as the base offline RL algorithm, it is interesting to see how SEABO competes against baseline methods with another offline RL algorithm as the base method. To that end, we choose TD3_BC and incorporate it with the strong baseline method, OTR. We follow the experimental setting utilized in the main text, filter a single expert demonstration with the highest return in the offline dataset, and deem it as the expert demonstration. We run TD3_BC+SEABO and TD3_BC+OTR on 9 D4RL MuJoCo locomotion datasets. We follow our experimental setup specified in Appendix A, and use the default hyperpa
340
+
341
+ <table><tr><td>Task Name</td><td>IQL</td><td>IQL+OTR</td><td>IQL+SEABO</td></tr><tr><td>umaze</td><td>87.5±2.6</td><td>88.7±3.5</td><td>87.6±2.0</td></tr><tr><td>umaze-diverse</td><td>62.2±13.8</td><td>64.4±18.2</td><td>70.0±9.5</td></tr><tr><td>medium-diverse</td><td>70.0±10.9</td><td>70.5±6.9</td><td>70.2±5.4</td></tr><tr><td>medium-play</td><td>71.2±7.3</td><td>72.7±6.2</td><td>72.8±1.6</td></tr><tr><td>large-diverse</td><td>47.5±9.5</td><td>50.7±6.9</td><td>50.0±7.9</td></tr><tr><td>large-play</td><td>39.6±5.8</td><td>51.2±7.1</td><td>48.6±9.8</td></tr><tr><td>Total Score</td><td>378.0</td><td>398.2</td><td>399.2</td></tr></table>
342
+
343
+ Table 12: Experimental results of SEABO on the AntMaze-v0 and Adroit-v0 domains with 10 expert demonstrations. SEABO and OTR use IQL as the base algorithm. The average normalized scores along with the corresponding standard deviations are reported. We bold and highlight the best mean score cell.
344
+
345
+ <table><tr><td>Task Name</td><td>IQL</td><td>IQL+OTR</td><td>IQL+SEABO</td></tr><tr><td>pen-human</td><td>70.7±8.6</td><td>69.4±21.5</td><td>85.8±16.1</td></tr><tr><td>pen-cloned</td><td>37.2±7.3</td><td>42.7±25.0</td><td>49.2±12.2</td></tr><tr><td>door-human</td><td>3.3±1.3</td><td>4.2±2.1</td><td>6.8±5.6</td></tr><tr><td>door-cloned</td><td>1.6±0.5</td><td>0.0±0.0</td><td>0.1±0.1</td></tr><tr><td>relocate-human</td><td>0.1±0.0</td><td>0.1±0.1</td><td>0.1±0.1</td></tr><tr><td>relocate-cloned</td><td>-0.2±0.0</td><td>-0.2±0.0</td><td>-0.2±0.0</td></tr><tr><td>hammer-human</td><td>1.6±0.6</td><td>1.4±0.2</td><td>1.7±0.3</td></tr><tr><td>hammer-cloned</td><td>2.1±1.0</td><td>1.3±0.7</td><td>1.7±0.5</td></tr><tr><td>Total Score</td><td>116.4</td><td>118.9</td><td>145.2</td></tr></table>
346
+
347
+ Table 13: Comparison of SEABO against OTR using TD3_BC as the base algorithm. We report the average normalized scores and their standard deviations. We bold and highlight the mean score cell except for TD3_BC. We adopt one single expert demonstration for OTR and SEABO.
348
+
349
+ <table><tr><td>Task Name</td><td>BC</td><td>10%BC</td><td>TD3_BC</td><td>TD3_BC+OTR</td><td>TD3_BC+SEABO</td></tr><tr><td>halfcheetah-medium</td><td>42.6</td><td>42.5</td><td>48.0±0.7</td><td>42.6±1.0</td><td>45.9±0.3</td></tr><tr><td>hopper-medium</td><td>52.9</td><td>56.9</td><td>60.7±12.5</td><td>66.4±10.3</td><td>76.1±4.2</td></tr><tr><td>walker2d-medium</td><td>75.3</td><td>75.0</td><td>83.7±5.3</td><td>76.9±5.4</td><td>76.6±0.4</td></tr><tr><td>halfcheetah-medium-replay</td><td>36.6</td><td>40.6</td><td>44.4±0.8</td><td>39.4±1.3</td><td>43.0±0.4</td></tr><tr><td>hopper-medium-replay</td><td>18.1</td><td>75.9</td><td>64.8±25.5</td><td>74.9±28.8</td><td>96.3±3.0</td></tr><tr><td>walker2d-medium-replay</td><td>26.0</td><td>62.5</td><td>87.4±8.4</td><td>69.7±16.4</td><td>73.1±2.2</td></tr><tr><td>halfcheetah-medium-expert</td><td>55.2</td><td>92.9</td><td>93.5±2.0</td><td>74.8±20.1</td><td>95.7±0.4</td></tr><tr><td>hopper-medium-expert</td><td>52.5</td><td>110.9</td><td>100.2±20.0</td><td>103.2±13.9</td><td>107.1±3.3</td></tr><tr><td>walker2d-medium-expert</td><td>107.5</td><td>109.0</td><td>109.5±0.5</td><td>109.0±0.6</td><td>109.7±0.2</td></tr><tr><td>Total Score</td><td>466.7</td><td>666.2</td><td>692.3</td><td>656.9</td><td>723.5</td></tr></table>
350
+
351
+ rameter setup of OTR suggested by the authors. We summarize the comparison results in Table 13. It turns out that TD3_BC+SEABO outperforms TD3_BC+OTR on 8 out of 9 datasets, often by a large margin, surpassing it by $10.1\%$ in terms of the total score. TD3_BC+SEABO is the only algorithm that even beats TD3_BC learned with raw rewards in total score. We observe that the standard deviation of TD3_BC+OTR is large on datasets like halffcheetah-medium-expert-v2, while the standard deviation of TD3_BC+SEABO is much smaller. This evidence indicates that SEABO is superior to OTR when acting as the reward labeler, and can consistently aid different base offline RL algorithms recover its performance under ground-truth rewards or achieve better performance.
352
+
353
+ # B.3 HYPERPARAMETER SENSITIVITY
354
+
355
+ In Section 5.5, we are only able to attach the results on a small proportion of datasets from D4RL, e.g., halfcheetah-medium-replay-v2 due to the space limit. In this part, we include wider experimental results in terms of the reward scale $\alpha$ , weighting coefficient $\beta$ , and number of neighbors $N$ . Again, we use IQL as the base offline RL algorithm for SEABO. The expert demonstrations utilized here contain actions. We follow the hyperparameter setup specified in Section A.
356
+
357
+ Reward scale $\alpha$ . The reward scale $\alpha$ controls the magnitude of the computed rewards. In Figure 3 of the main text, we find that a smaller $\alpha$ seems to be better (especially on hopper-medium-v2). We further conduct experiments on three additional tasks, halfcheetah-medium-expert-v2, hopper-medium-replay-v2, and walker2d-medium-v2 by varying $\alpha \in \{1,5,10\}$ . The results are shown in Figure 5, where we actually do not find much performance difference of $\alpha$ on these three tasks. That indicates that IQL+SEABO is robust to $\alpha$ on most of the datasets. In practice, one can simply set $\alpha = 1$ , which we find can already yield very good performance on MuJoCo tasks, AntMaze tasks, and Adroit tasks.
358
+
359
+ Weighting coefficient $\beta$ . As commented in the main text, the weighting coefficient $\beta$ is perhaps the most important hyperparameter in SEABO, since it controls the weights of the measured distance and this may have a significant influence on the final rewards. For a specific domain,
360
+
361
+ ![](images/b248665633aeef8e897deaeb2105411d9117ff9b3b93b3f3eb03bb092f368363.jpg)
362
+ Figure 5: Additional experiments on the influence of $\alpha$ . The shaded region captures the standard deviation. All other hyperparameters are kept unchanged except $\alpha$ .
363
+
364
+ ![](images/15dda1d6b4318f0a3a4560a54fa74c561be0f56ee2d9994bf1217abc172d7ae1.jpg)
365
+ Figure 6: Additional experiments on the effect of $\beta$ . We choose three additional datasets from D4RL, and plot their mean normalized score curve. The shaded area denotes the standard deviation.
366
+
367
+ we mostly adopt a fixed $\beta$ as we do not want to bother tuning this hyperparameter. However, we believe it is vital to examine how $\beta$ influences the performance of SEABO in wider experiments. We additionally conduct several experiments on halfcheetah-medium-expert-v2, hopper-medium-replay-v2, walker2d-medium-replay-v2 from D4RL locomotion tasks. We sweep $\beta$ across $\{0.1, 0.5, 1, 5\}$ , and summarize the results in Figure 6. It can be clearly seen that a large $\beta$ results in poor performance on halfcheetah-medium-expert-v2 and walker2d-medium-replay-v2, while setting $\beta = 5$ results in the best performance on hopper-medium-replay-v2. In the hyperparameter setup part, we state that we set $\beta = 1$ on hopper-medium-replay-v2 due to the fact that SEABO is comparatively stable with $\beta \{0.5, 1\}$ . We do not doubt that the best $\beta$ is task-dependent, and one can get higher performance by carefully tuning this hyperparameter. However, we empirically show that using a fixed $\beta$ is also feasible, and we believe this is appealing since the users can get rid of the work of tedious hyperparameter search.
368
+
369
+ Number of neighbors $N$ . The number of neighbors $N$ is a hyperparameter introduced in the nearest neighbor algorithms. For all of our main experiments, we simply adopt $N = 1$ , i.e., searching for the nearest neighbor. In Figure 4(b), we see that SEABO is robust to this hyperparameter. To examine whether this conclusion applies to a wider range of datasets, we conduct experiments on three additional datasets, halfcheetah-medium-v2, halfcheetah-medium-expert-v2, and walker2d-medium-replay-v2. The results are summarized in Figure 7, where we also observe that SEABO is robust to this hyperparameter, indicating the effectiveness and generality of SEABO.
370
+
371
+ # B.4 PERFORMANCE OF SEABO UNDER LONG-HORIZON MANIPULATION TASKS
372
+
373
+ In this part, we investigate how SEABO behaves under long-horizon manipulation tasks. To that end, we evaluate SEABO in Kitchen datasets (Fu et al., 2020). The kitchen environment (Gupta et al., 2019) consists of a 9 DoF Franka robot interacting with a kitchen scene that includes an openable microwave, four turnable oven burners, an oven light switch, a freely movable kettle, two hinged cabinets, and a sliding cabinet door. In kitchen, the robot may need to manipulate different components, e.g., it may need to open the microwave, move the kettle, turn on the light, and slide open the cabinet (precision is required). We run IQL+SEABO on three kitchen datasets using the author-recommended hyperparameters of IQL on the kitchen environment. We set reward
374
+
375
+ ![](images/209103ede67def6e1884a201aaa6f97a793954b8a06d93b2e0f853edde6f3797.jpg)
376
+ Figure 7: Additional experiments on examining the influence of the number of neighbors in KD-tree. The shaded region represents the standard deviation.
377
+
378
+ Table 14: Comparison of SEABO against baselines in the Kitchen tasks. We report the average normalized scores and the corresponding standard deviations. We bold and highlight the best mean score cell.
379
+
380
+ <table><tr><td>Task Name</td><td>BC</td><td>CQL</td><td>IQL</td><td>IQL+SEABO</td></tr><tr><td>kitchen-complete-v0</td><td>65.0</td><td>43.8</td><td>62.5</td><td>67.5±4.2</td></tr><tr><td>kitchen-partial-v0</td><td>38.0</td><td>49.8</td><td>46.3</td><td>71.0±4.1</td></tr><tr><td>kitchen-mixed-v0</td><td>51.5</td><td>51.0</td><td>51.0</td><td>55.0±3.5</td></tr><tr><td>Average Score</td><td>51.5</td><td>48.2</td><td>53.3</td><td>64.5</td></tr></table>
381
+
382
+ scale $\alpha = 1$ , coefficient $\beta = 0.5$ for SEABO. We compare IQL+SEABO against some baselines taken from the IQL paper and summarize the results in Table 14. We find that SEABO exhibits superior performance, surpassing IQL with raw rewards by $21.0\%$ . We believe these results show that SEABO can aid some long-horizon manipulation tasks.
383
+
384
+ However, we experimentally find that SEABO does not exhibit strong performance for some tasks that require high precision, e.g., the IKEA Furniture assembly benchmark (Lee et al., 2019; 2021; Heo et al., 2023). We leave the open problem of how to enable SEABO to successfully address such benchmarks a future work.
385
+
386
+ # B.5 LEARNING CURVES
387
+
388
+ In this section, we provide the detailed training curves of IQL+SEABO on the locomotion tasks, AntMaze tasks, and Adroit tasks. We also provide learning curves of TD3_BC+SEABO on locomotion tasks. We summarize the results of IQL+SEABO on D4RL MuJoCo locomotion tasks in Figure 8, the performance of IQL+SEABO on AntMaze tasks in Figure 9, and the curves of IQL+SEABO on Adroit tasks in Figure 10. The results of TD3_BC+SEABO are depicted in Figure 11.
389
+
390
+ From all these results, we find that both IQL+SEABO and TD3_BC+SEABO have stable and strong performance on the evaluated tasks, indicating the advantages of our method.
391
+
392
+ # C DISCUSSIONS ON DIFFERENT SEARCH ALGORITHMS
393
+
394
+ The success of SEABO can be largely attributed to the adopted search algorithm (i.e., KD-tree). In Section 5.4 of the main text, we compare different design choices for the underlying search algorithm. It is not surprising to find that Ball-tree results in a similar performance as KD-tree, as Ball-tree shares many similarities with KD-tree. However, we find that HNSW incurs quite poor performance on many datasets using its default hyperparameter setup (see Appendix A). HNSW builds a multi-layer structure made up of a hierarchical set of proximity graphs for nested subsets of the stored elements while employing a heuristic for selecting proximity graph neighbors. HNSW is a graph-based search algorithm. Based on the empirical results in Table 6 in the main text, we find that HNSW leads to quite poor performance for the base offline RL algorithm, only achieving competitive performance against KD-tree on halffcheetah-medium-v2 and walker2d-medium-expert-v2.
395
+
396
+ ![](images/1d7e326ad8f8677a16663aafac31c634596ab97841107f1b3e173e5dcbf37d61.jpg)
397
+
398
+ ![](images/5d8b0f44c667843557c0e4ebd46fa954545099c0392c81606403217bcf88ab44.jpg)
399
+
400
+ ![](images/8b0ba86aa1aea48b5c3998356227d1d197945a9191838fcc0dbd0b97ae14528d.jpg)
401
+
402
+ ![](images/18710706eb8db5dbf633723abed5e9361a89828975e7fcb17b1353bc62d65a27.jpg)
403
+
404
+ ![](images/d7183834d20c9a4e8680488a3950f84a0636178d6faa3dd586a514aaf67079a1.jpg)
405
+
406
+ ![](images/dc5aca5cbde1f5014e4fcbbc6d8b6f10e8c9dfc5f35b1cd74910d53fcea6e8a1.jpg)
407
+
408
+ ![](images/15085841095be33b15c8247d05c6da112822199be6a02ff806d8c0cc3cd65353.jpg)
409
+ Figure 8: Full learning curves of IQL+SEABO on D4RL MuJoCo datasets. We plot the average performance and the shaded region captures the standard deviation.
410
+
411
+ ![](images/23b37da41702d8727ea2968211dff300363e9ea9898861ec647033ea2afc5067.jpg)
412
+
413
+ ![](images/69d5b89c4e81a5429f09b5ebc6aa3f9156b9baa92f448d03316047692b14daff.jpg)
414
+
415
+ ![](images/2e1e43103ea621ce30ac0c0679ba1d3ecbcd71058f3e0e36e6b955fbf8108298.jpg)
416
+
417
+ ![](images/d743e59d2429fd7c6e5e9ade5005b2d187d3aea56b1c18d501c24e0c740da5fc.jpg)
418
+
419
+ ![](images/7a82103971e556c3a42590967180f9c9d53b88438e8edb7910ddc707c737d646.jpg)
420
+
421
+ ![](images/6fb8d973721e4c5a84d9e2cf7ec3c672285abf0210d341764f415ab5e4d51df4.jpg)
422
+ Figure 9: Full learning curves of IQL+SEABO on AntMaze tasks. The mean performance in conjunction with the standard deviations are plotted.
423
+
424
+ ![](images/a2f0162b0a8876e92ea3add5db64e0df6a07ac61dbf4a08af036dda8a16c96e6.jpg)
425
+
426
+ ![](images/22b456f97c17aee076eb84fab2fb4905ea3eac476cdbb4476325befc1d44df82.jpg)
427
+
428
+ ![](images/285b16c2e1b7ca29f6c35e3f2032fc78f55257050a69784b328099c0e333025b.jpg)
429
+
430
+ ![](images/43b5a8a6fd0782e99b700ab13adb930e47199056fd933b8183a913a08a4d30f0.jpg)
431
+
432
+ ![](images/bee20b5b128aefa1fe378f0208d3474e098fae9f5f4765d29be8326dad6b3d44.jpg)
433
+
434
+ ![](images/5ab2a80a9dbcd1d30a9fbe8e643028a14ac689480d737f04eeb2e050154df4c6.jpg)
435
+
436
+ ![](images/dbc3295badfd36914d636aba0f429d0c17a233b636fde9da74e7a59947a2f056.jpg)
437
+ Figure 10: Full learning curves of IQL+SEABO on Adroit datasets. We report the mean performance along with its standard deviation.
438
+
439
+ ![](images/22f9cf3fa4adf5001f3f6e3f0eadbc90f4c127825f009e3e4c78970c31e13f38.jpg)
440
+
441
+ ![](images/cc1eba186cdf28d8c77999c511767d68c43efbde7f289112d2fdac427f54d005.jpg)
442
+
443
+ ![](images/59e2e64c579d46aedccc3fbad6ed4e3480968e54d44321165b4baccfa435b71e.jpg)
444
+
445
+ ![](images/a7ccfd572b9508a0b0241854605c0958291aba5fbe9ce5436390e86d10d44949.jpg)
446
+
447
+ ![](images/008a9a25e3eefb270f29b4311300580e49f37eed758602ba4424f1600c39c0d7.jpg)
448
+
449
+ ![](images/b02d62f978bd5c49b186775cc61c84967bd94a65b72b43280b59702a65df3b31.jpg)
450
+
451
+ ![](images/977c40d162a3c52aff18243b6416f76869ab728418ae22423a59d5a0829d1040.jpg)
452
+
453
+ ![](images/b521f73354534d7381abf91dfae3848d70ccc718af52bf1c794696e94a9cd776.jpg)
454
+
455
+ ![](images/f4f3a422e3cecce7844a303242cf19a7306c456de6ff43861b636fcacbec5b80.jpg)
456
+
457
+ ![](images/18d786e41877915858967ada1b2094842f8cee4d4a71573a6beb3fe798d6faf5.jpg)
458
+ Figure 11: Full learning curves of TD3_BC+SEABO on D4RL MuJoCo datasets. The average performance as well as its statistical significance is depicted.
459
+
460
+ ![](images/02369c918701b48de73682ee62e19f2e14a77ef5fcbce2d335ff97176bf5ad1f.jpg)
461
+
462
+ ![](images/14179411e7302fa34490cf0b30fb0e613845ac15cc19bb49846141712bd80832.jpg)
463
+
464
+ In this subsection, we try to understand why HNSW fails through some empirical evidence. We choose some subsets, halfcheetah-medium-v2, halfcheetah-medium-expert-v2, hopper-medium-replay-v2, hopper-medium-expert-v2, walker2d-medium-v2, and walker2d-medium-replay-v2, from D4RL MuJoCo datasets and plot the reward density of ground-truth rewards, rewards computed using KD-tree, and rewards acquired via HNSW. We summarize the results in Figure 12. It is clear that SEABO with KD-tree can produce a similar reward structure as the ground-truth reward distribution, while SEABO with HNSW tends to assign large rewards to only a small proportion of samples and small rewards to the majority of transitions. We believe this explains the unsatisfying performance of IQL+SEABO with HNSW as the base search algorithm, indicating that a graph-based search mechanism may not be suitable for D4RL datasets. Another possible explanation is that the hyperparameters of HNSW need to be tuned to adapt to different tasks. We do not doubt that a careful tuning of hyperparameters (e.g., the maximum number of outgoing connections in the graph, the number of neighbors, etc.) has the potential of making SEABO with HNSW work in D4RL datasets. However, we do not think it is necessary to do that considering the fact that adopting KD-tree with its default hyperparameters can already result in quite good performance across different datasets. Hence, it is recommended that one uses KD-tree (or Ball-tree) as the base search algorithm.
465
+
466
+ # D COMPUTE INFRASTRUCTURE
467
+
468
+ In Table 15, we list the compute infrastructure that we use to run all of the algorithms.
469
+
470
+ Table 15: Compute infrastructure.
471
+
472
+ <table><tr><td>CPU</td><td>GPU</td><td>Memory</td></tr><tr><td>AMD EPYC 7452</td><td>RTX3090×8</td><td>288GB</td></tr></table>
473
+
474
+ # E LIMITATIONS
475
+
476
+ Despite the simplicity and effectiveness of our proposed algorithm, SEABO, we have to admit honestly that there may exist some potential limitations. First, SEABO is slightly sensitive to the weighting coefficient $\beta$ on some datasets (not all datasets), and one may need to manually tune it so as to find the best-suited hyperparameter setup for a specific task. While based on our empirical results, one can find the best $\beta \in \{0.5, 1, 5\}$ using grid search, It is not difficult to conduct experiments since SEABO is computationally efficient (and can be applied with only CPUs). Second, it may take more time for SEABO to annotate the unlabeled trajectories with visual input, as images are hard to process. Whereas, we can preprocess the visual images using some pre-trained image encoder (e.g., ImageNet pretrain models) to obtain low-dimensional representations of the high-dimensional image. Note that we build KD-tree upon expert demonstrations which usually contain a small amount of expert transitions. Thus, it should not be time-consuming to annotate the visual trajectories.
477
+
478
+ We hope this work can provide some new insights to the community and inspire future work on offline imitation learning.
479
+
480
+ # F ADDITIONAL REWARD PLOTS ON ADROIT AND ANTMAZE TASKS
481
+
482
+ In this section, we provide reward distribution plots of the ground truth rewards, rewards obtained by SEABO, and rewards output from HNSW on some Adroit-v0 and AntMaze-v0 tasks, hammer-human-v0, hammer-cloned-v0, door-human-v0, door-cloned-v0, antimaze-uamze-v0, and antimaze-medium-diverse-v0. Note that we provide the histogram plot of rewards in antimaze-medium-diverse-v0 as most of the samples in this datasets have quite similar reward signals, making it difficult to draw the density plot. We summarize the results in Figure 13. It can be seen that with KD-tree, SEABO outputs similar reward density as vanilla rewards (e.g., SEABO successfully gives three peaks in hammer-human-v0 and door-human-v0).
483
+
484
+ ![](images/edf021ef7458c7cd936cc186fd5bdf036a26277b268ed9b276c899def949cfe0.jpg)
485
+
486
+ ![](images/30700e61ea1285c08d45f02b22bcd7707dabd8a381019a458260e1f999de0a66.jpg)
487
+
488
+ ![](images/5d7dd9f6b4090f7aa4654fcf7139207bd4b05e4a66cde56eb93cb1d23a346ff2.jpg)
489
+
490
+ ![](images/eda9578e58a2d345d55d39e8a930c2510b57ae2c811421bba251d3376b960f10.jpg)
491
+
492
+ ![](images/c949b56f823ecdccc2ce29ced5347ea63689434aaa2de5b4ec4181cbbd936944.jpg)
493
+
494
+ ![](images/0dbe32e6cba37623037db0c3c6bebb9f49b28749773a89cd967d094cc0877ea8.jpg)
495
+
496
+ ![](images/4e3a38db8a918f9788ef263a791dd3aeb2263dcfce71fe7f3cd9d4fe36c0d3cd.jpg)
497
+
498
+ ![](images/57544567a05620b4945331ea59197d8864f60be1f02b45f183ec98bd232a656f.jpg)
499
+
500
+ ![](images/a91625b37628ebbf6d87765e825395a56b0f32b2e544fe8ced4aa139b5ec2b21.jpg)
501
+
502
+ ![](images/4d12cb5825ba8facb5a6debaed0ab8d4b3c04c8500eed5e6e1185dfa2d1dc9fe.jpg)
503
+
504
+ ![](images/8997551e02fde6a3f597abfaba47dc15b7171655cd285eb292d456c3da2b26d3.jpg)
505
+
506
+ ![](images/118df2ab134ffb8af0b8661cafcfe7952cea62343f92b70881f4cb436b8dd1a1.jpg)
507
+
508
+ ![](images/771551ea9918d970e36c3b9f2d80525d3cd5d27e5e8b8541841867c61a59038b.jpg)
509
+
510
+ ![](images/d6e12f50fd2fd54f232d50a97bab40f558dd29f03efbc4cadbd6155e1553a9c8.jpg)
511
+
512
+ ![](images/9f132412e7ab4116d8ab437315f8bc3bfe4c20722c5db8205de2449f80af2175.jpg)
513
+
514
+ ![](images/b0c21a2a90d96f5db3eaba5e7df32a068153509daff1050c1d5ed40fe2285fbf.jpg)
515
+ Figure 12: Density plot comparison of ground-truth rewards and rewards acquired by different search algorithms. The right two columns show reward distributions of two SEABO variants.
516
+
517
+ ![](images/721ab501d7da4a8cd18a8cfe2eb7a30467b5d2ebaa3480965eabfced552f5482.jpg)
518
+
519
+ ![](images/0b3aeddacf253bcc0752f8df6d572daab7f2df7ecb5c934cdf3bc4c09718b73b.jpg)
520
+
521
+ ![](images/2a77c1b3990444cc411140153401ed8096627e1394c716c2b863a87cdaa1efd7.jpg)
522
+
523
+ ![](images/a85fac6e1a17f1f734cdcd56d08055e8c40e67715a957c3dac1dd3c3853bf4c3.jpg)
524
+
525
+ ![](images/e5145a4678ab841381a5a8ef9ee22f29ffe0eaf8ced3ace0ac3f25ecd1e6b71a.jpg)
526
+
527
+ ![](images/bae6261b0bca6e4c867397fcb3f67094c73dddb0eb422f837f1f7c486911f2f4.jpg)
528
+
529
+ ![](images/10bd1ed3b33b68c8e97bd593cf23f8287b6898f1faf857f6f0fee2d27b163005.jpg)
530
+
531
+ ![](images/6e5a99be657ed13d3e5a5749a6074d2ea382f2dcb4a9c86f550e8b569ee9489d.jpg)
532
+
533
+ ![](images/9364bb0915ad82901e802b26a6c1632ba9e7e1ffc7618084fc86315265df6b61.jpg)
534
+
535
+ ![](images/9078d80640f9c35c47c3dcb4aa6c073f04a6fc6226053216e4ab16fc1b5870a2.jpg)
536
+
537
+ ![](images/f734dc0b612c37098ec8357b3180230b4e8ce2afccb24b732854ecadcfc7347f.jpg)
538
+
539
+ ![](images/8fea74767eebebf715f23a4746495294ce6b33903d9bc638b9ce9285f960a5bf.jpg)
540
+
541
+ ![](images/218ad258db0360661af9ac7a7f689bae5d375cc2aa917079ff464358269d6916.jpg)
542
+
543
+ ![](images/05cad37d605ee3bb8d3ff15203ac165e559f6fbbd7db1f5c7942db4ec72fbb47.jpg)
544
+
545
+ ![](images/57edd1f8bd688f7eb97e4b7175e357238b2db44d52d367f6be6e7d3f6ab8304f.jpg)
546
+
547
+ ![](images/0b051c047dc99af6dd9bd884e00865b566d098d02a0ada25a6dbf571fafea837.jpg)
548
+
549
+ ![](images/b4dba5e56ab2741354c200c46d5e86c4661e55710cf84eff39e24fd7ac8c463c.jpg)
550
+
551
+ ![](images/cee15ec8a2562767055958560071cfaa8b68a5ee85863b8f691e8f097d3512d1.jpg)
552
+ Figure 13: Density plot comparison of ground-truth rewards and rewards acquired by different search algorithms. The results are on selected datasets from Adroit and AntMaze tasks.
553
+
554
+ ![](images/51eca0f3ea161b9f6a81bc2255a01e087b978e6cc717cbd609db573ce75f4d14.jpg)
555
+
556
+ ![](images/7653ad15b8c412b44b7ed28dd6c688a477235cce0d70e523e947eb7172fd3e17.jpg)
557
+
558
+ # G DISCUSSIONS ON SEABO AND ILR
559
+
560
+ There are some previous studies that use nearest neighbor-based methods for imitation learning, e.g., Pari et al. (2021). Among them, the most relevant to our work is Ciosek (2022). In this section, we discuss the connections and differences between our method and prior work, ILR (Ciosek, 2022), which can be summarized below:
561
+
562
+ - The motivations are varied. The practical reward formula in ILR is given by $r = 1 - \min_{(s', a') \in D} d_{l_2}((s, a), (s', a'))^2$ , which is a relaxation of its theoretical version. There exists a gap between the theory and the resulting reward formula. The authors claim that the relaxation is an upper bound on the scaled theoretical reward and interpret $L = \min_{(s', a') \in D} d_{l_2}((s, a), (s', a'))^2$ as the $l_2$ -diameter of the state-action space. The primary goal of doing so is to reduce imitation learning to RL with a stationary reward for deterministic experts. However, the motivation of SEABO is that we would like to determine the optimality of the single transition (instead of examining whether the transition comes from the expert trajectory or performing relaxation to the rewards). We assume that the transition is near-optimal if it lies close to the expert trajectory. Hence, we assign a larger reward to the transition if it is close to the expert trajectory and a smaller reward otherwise. Meanwhile, SEABO does not require that the expert is deterministic (and also does not require that the environment is deterministic). We aim to adopt SEABO to annotate unlabeled samples in the dataset and train off-the-shelf offline RL algorithms.
563
+
564
+ - The methods are different but connected. The reward formula adopted in ILR is a special case of SEABO with Euclidean distance. SEABO does not interpret $L$ as the diameter of the state-action space. SEABO can adopt $N$ nearest neighbors and use their average distance to compute the reward (ILR simply finds the smallest Euclidean distance between sample $(s, a)$ and the expert trajectory). Meanwhile, SEABO is not restricted to Euclidean distance. Our procedure is, that we first find the nearest neighbor of the query sample, and then utilize some distance measurements (different distance measurements can be used here) to decide the distance between the query sample and its nearest neighbor, and finally get the reward by adopting a squashing function. Furthermore, SEABO strongly relies on the nearest neighbor methods (e.g., KD-Tree), and one can use different types of nearest neighbor algorithms in SEABO, while ILR does not emphasize search algorithms. Note that different search algorithms with different hyperparameter setups can result in different final rewards. For example, in scipyiardal.KDTree(query, setting eps larger than 0 enables approximate nearest neighbors search and ensures that the $k$ -th returned value is no further than $(1 + \mathrm{eps})$ times the distance to the real $k$ -th nearest neighbor. This may incur different results from ILR even under Euclidean distance. Moreover, SEABO can also work in state-only regimes, which is both a more general and challenging setting, while ILR strongly relies on the assumption that state-action pairs are present in the expert trajectory in its theory and practical implementation. Finally, one can query with $(s, a, s')$ , $(s, a)$ or $(s, s')$ in SEABO (ILR is limited to $(s, a)$ ), and SEABO adopts a different choice of squashing function.
565
+
566
+ - The settings are varied. SEABO is targeted at the offline imitation learning setting while ILR addresses the online setting. It also turns out that the experiment setup (e.g., number of expert trajectories) is different between SEABO and ILR.
2024/SEABO_ A Simple Search-Based Method for Offline Imitation Learning/images.zip ADDED
@@ -0,0 +1,3 @@
 
 
 
 
1
+ version https://git-lfs.github.com/spec/v1
2
+ oid sha256:e00652deda9b735e487c3108e2a80e29c00cba20dc4cc5b1be4ed93d8e8b918f
3
+ size 1827817
2024/SEABO_ A Simple Search-Based Method for Offline Imitation Learning/layout.json ADDED
The diff for this file is too large to render. See raw diff
 
2024/SEA_ Sparse Linear Attention with Estimated Attention Mask/677e089e-2f24-4b16-920d-bdef731c9804_content_list.json ADDED
The diff for this file is too large to render. See raw diff
 
2024/SEA_ Sparse Linear Attention with Estimated Attention Mask/677e089e-2f24-4b16-920d-bdef731c9804_model.json ADDED
The diff for this file is too large to render. See raw diff
 
2024/SEA_ Sparse Linear Attention with Estimated Attention Mask/677e089e-2f24-4b16-920d-bdef731c9804_origin.pdf ADDED
@@ -0,0 +1,3 @@
 
 
 
 
1
+ version https://git-lfs.github.com/spec/v1
2
+ oid sha256:ccbb5b144cf04d51d2419d220a800d749bf0a922adcd174e66f4fae7a5cb4f6d
3
+ size 16193453
2024/SEA_ Sparse Linear Attention with Estimated Attention Mask/full.md ADDED
@@ -0,0 +1,408 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ # SEA: SPARSE LINEAR ATTENTION WITH ESTIMATED ATTENTION MASK
2
+
3
+ Heejun Lee $^{1}$ , Jina Kim $^{1}$ , Jeffrey Willette $^{2}$ , Sung Ju Hwang $^{2,3}$
4
+
5
+ School of Computing<sup>1</sup>, Graduate School of AI<sup>2</sup>
6
+
7
+ Korea Advanced Institute of Science and Technology $^{1,2}$ , DeepAuto.ai $^{3}$
8
+
9
+ Daejeon, South Korea
10
+
11
+ {ainl,jinakim,jwillette,sjhwang}@kaist.ac.kr
12
+
13
+ # ABSTRACT
14
+
15
+ The transformer architecture has driven breakthroughs in recent years on tasks which require modeling pairwise relationships between sequential elements, as is the case in natural language understanding. However, long sequences pose a problem due to the quadratic complexity of the attention operation. Previous research has aimed to lower the complexity by sparsifying or linearly approximating the attention matrix. Yet, these approaches cannot straightforwardly distill knowledge from a teacher's attention matrix, and often require complete retraining from scratch. Furthermore, previous sparse and linear approaches lose interpretability if they cannot produce full attention matrices. To address these challenges, we propose SEA: Sparse linear attention with an Estimated Attention mask. SEA estimates the attention matrix with linear complexity via kernel-based linear attention, then subsequently creates a sparse attention matrix with a top- $\hat{k}$ selection to perform a sparse attention operation. For language modeling tasks (Wikitext2), previous linear and sparse attention methods show roughly two-fold worse perplexity scores over the quadratic OPT-1.3B baseline, while SEA achieves better perplexity than OPT-1.3B, using roughly half the memory of OPT-1.3B. Moreover, SEA maintains an interpretable attention matrix and can utilize knowledge distillation to lower the complexity of existing pretrained transformers. We believe that our work will have a large practical impact, as it opens the possibility of running large transformers on resource-limited devices with less memory.
16
+
17
+ # 1 INTRODUCTION
18
+
19
+ The transformer (Vaswani et al., 2017) architecture has revolutionized various fields of artificial intelligence, such as natural language understanding (Touvron et al., 2023; Wang et al., 2022) and computer vision (Dosovitskiy et al., 2021) due to its ability to learn pairwise relationships between all $T$ tokens in a given sequence $(\mathcal{O}(T^2))$ . This has ushered in the era of large transformer-based foundation models with impressive generalization abilities (Brown et al., 2020; Chiang et al., 2023). However, since the transformer's attention mechanism comes with a quadratic space and time complexity, it becomes untenable for handling long sequences which are essential for tasks such as dialogue generation (Chen et al., 2023). To overcome this limitation, previous works have suggested approaches with linear complexity by using static or dynamic sparse attention patterns (Beltagy et al., 2020; Zaheer et al., 2020; Tay et al., 2020a; Kitaev et al., 2020; Tay et al., 2020b; Liu et al., 2021), or by replacing quadratic attention with kernel or low-rank approximations (Choromanski et al., 2021; Chen et al., 2021; Qin et al., 2022).
20
+
21
+ However, despite their promising aspects, previous linear attention methods have yet to be widely used in research and production for several reasons. Firstly, these attention mechanisms cannot be easily swapped into existing finetuned models. After radically replacing the quadratic attention mechanism, they require training new attention relations to attempt to recover the performance of the quadratic attention module and cannot directly learn the full range of attention relations during knowledge distillation. Therefore, they suffer from unpredictable accuracy degradation on downstream tasks. For example, as shown in Table A.8, Reformer (Kitaev et al., 2020) outperforms many
22
+
23
+ ![](images/4ee399a15df034df3e77215df369021ad3b6ac2e254aa89ad6914847ac114348.jpg)
24
+ Figure 1: Concept. We estimate the attention matrix in a compressed size $(\hat{A})$ , then perform a grouped top-k selection, and subsequently perform sparse attention with our novel FlatCSR operation using an estimated attention mask on the full attention matrix. SEA has linear complexity in all steps at test-time, and requires direct attention matrix distillation from the quadratic teacher at train-time.
25
+
26
+ other baselines on MNLI (Williams et al., 2018); however, it shows the worst performance in Table 2 on Wikitext2 (Merit et al., 2017). Secondly, previous linear attention methods may hinder the ability to interpret the attention matrix or merge/prune tokens (Kim et al., 2022; Lee et al., 2023; Bolya et al., 2023) of the transformer model, as they do not produce the full attention matrix which is usually required for analyzing the importance of a given token.
27
+
28
+ In contrast to previous works, our proposed linear attention method, SEA: Sparse linear attention with Estimated Attention mask, focuses on estimating the attention matrix from a pretrained teacher transformer model with $\mathcal{O}(T)$ complexity at inference rather than $\mathcal{O}(T^2)$ . In order to do so, our novel estimator, distills knowledge (Hinton et al., 2015) from the teacher and estimates the attention matrix with $\mathcal{O}(T)$ complexity by fixing the second dimension to a constant value $K$ where $K \ll T$ . This results in a compressed attention matrix which can be decompressed via interpolation into an approximation of the full attention matrix when performing the distillation step as opposed to previous works which prescribe retraining attention relationships during distillation due to incompatible changes in the attention operation (Choromanski et al., 2021; Qin et al., 2022). By distilling from the full attention matrix into our compressed matrix, SEA can use the complex and dynamic attention information from the pretrained model and preserve task performance.
29
+
30
+ Furthermore, as SEA distills knowledge from a full attention matrix, the resulting compressed attention matrix and sparse attention matrix can still provide interpretable attention by allowing for interpreting the relationships and importance of tokens (e.g. analysis of attention patterns in images (Dosovitskiy et al., 2021) and token pruning (Kim et al., 2022; Lee et al., 2023; Bolya et al., 2023)). Lastly, SEA reduces the space and time complexity of attention from $\mathcal{O}(T^2)$ into $\mathcal{O}(T)$ at test-time, with significantly reduced memory and computational cost while maintaining similar performance to the original pretrained transformer model, as shown in Fig. 5 and Tables 2 and A.8.
31
+
32
+ In Fig. 1, we provide a overview of our proposed method's inference stage. The main idea is to first estimate a compressed attention matrix $\hat{\mathbf{A}}$ with $\mathcal{O}(T)$ complexity, and subsequently perform sparse attention after choosing only $\mathcal{O}(T)$ important relationships inferred from $\hat{\mathbf{A}}$ . Specifically, we decode the output features of the kernel-based linear attention method Performer (Choromanski et al., 2021) to form $\hat{\mathbf{A}}$ . Next, we perform a top- $\hat{k}$ selection on $\hat{\mathbf{A}}$ to form a compressed attention mask which can be used to generate a sparse attention mask for the final sparse attention operation. By utilizing both kernel-based and sparse attention, we can take advantage of their diverse token embedding spaces, as shown in previous work (Chen et al., 2021). The compressed estimated attention matrix $\hat{\mathbf{A}}$ is trained via knowledge distillation (Hinton et al., 2015; Jiao et al., 2020) from a pretrained quadratic teacher model to distill complex and dynamic attention patterns. We achieve linear complexity in this process by controlling sparsity and compression ratio in the compressed attention mask.
33
+
34
+ We validate SEA by applying it to BERT for text classification (Devlin et al., 2019; Wang et al., 2019) and to OPT for causal language modeling (Zhang et al., 2022; Merity et al., 2017). Our empirical findings demonstrate that SEA adequately retains the performance of the quadratic teacher model in both tasks (Tables 2 and A.8), while previous methods do not. SEA significantly outperforms the best linear attention baselines, such as Performer, in language modeling with $47.7\%$ lower (better) perplexity while consuming $54.2\%$ less memory than quadratic attention (Table 2). This opens up the possibility of running long context language models on lower-grade computing devices that have smaller VRAMs because SEA can run on a smaller memory budget as shown in Section 5 and Fig. 8. To summarize:
35
+
36
+ - We propose a novel, test-time linear attention mechanism (SEA) that distills knowledge from a pretrained quadratic transformer into a compressed estimated attention matrix which is then used to create a sparse attention mask for the final attention operation. As demonstrated in Fig. 8, SEA is $\mathcal{O}(T)$ at test time, where there is no distillation step.
37
+ - We demonstrate the efficiency and effectiveness of our method through empirical evaluations on natural language processing tasks such as text classification on GLUE and language modeling on Wikitext-2, where we maintain competitive performance with the vanilla transformer baseline, as shown in Figs. 5a and 7a.
38
+ - We propose and provide code for a novel CSR tensor operation, called FlatCSR, which is capable of handling non-contiguous flatten tasks within a GPU kernel.
39
+ - We showcase the interpretability of our method by visualizing the estimated sparse attention matrix and comparing it to the teacher's attention matrix. Our estimator can estimate both self-attention and causal attention.
40
+
41
+ # 2 RELATED WORK
42
+
43
+ Sparse Attention for Efficient Transformers. Sparse attention can be categorized into methods using static and dynamic attention masks. For static attention masks, Longformer (Beltagy et al., 2020) and BigBird (Zaheer et al., 2020) introduce heuristic patterns, but since token relationships may not fit to those heuristics, it can be challenging to achieve state-of-the-art performance for every task. Hence, some recent methods focus on learning to sort or cluster the tokens to better fit static masks (Tay et al., 2020a; Kitaev et al., 2020; Tay et al., 2020b). However, as these works still operate based on static patterns, a more flexible and learnable setting is necessary since patterns in attention are unavoidably dynamic and data-dependent, as shown in TDSA (Liu et al., 2021), which learns to estimate an attention mask. However, TDSA still performs quadratic attention when generating dynamic sparse attention masks.
44
+
45
+ Kernel and Low-rank Methods for Efficient Transformers. Recent works either focus on using kernel-based methods (Choromanski et al., 2021; Qin et al., 2022) or combining kernel and sparse methods (Chen et al., 2021). For example, Performer (Choromanski et al., 2021) uses a positive-definite kernel approximation to approximate the softmax attention mechanism but comes with nonnegligible approximation errors and therefore is not generalizable on every task. To handle this problem, Cosformer (Qin et al., 2022) replaces the non-linear approximate softmax operation of Performer with a linear operation that contains a non-linear cosine-based re-weighting mechanism. But again, the cosine weighting scheme is a heuristic which limits it to approximating attention with a specific pattern, which may be a downside for attention matrices which do not follow the fixed heuristic pattern, as shown in Fig. 9 (subfigure a, bottom-left). Another work, Scatterbrain (Chen et al., 2021) proposes combining sparse and low-rank methods to approximate attention, by separately applying both and then summing the result together. While this is a promising approach, it still cannot straightforwardly benefit from direct attention matrix distillation.
46
+
47
+ # 3 SEA: SPARSE LINEAR ATTENTION WITH ESTIMATED ATTENTION MASK
48
+
49
+ Preliminaries. We first define notations used for the attention mechanisms. We define the following real matrices: $Q, K, V \in \mathbb{R}^{T \times d}$ . The attention matrix $A$ is defined as $A = \text{softmax}(QK^\top) \in \mathbb{R}^{T \times T}$ . Let $C = AV \in \mathbb{R}^{T \times d}$ be the context feature of the attention lookup, and $T$ be the length of the input sequence, and $d$ be the size of the head embedding dimension. We use $\odot$ to denote elementwise multiplication which may be applied between similar sizes matrices or on the last dimension and repeated over prior dimensions as is the case when applied to a matrix and vector. We define $K$ as the width of the compressed matrix, $k$ as a value which controls the sparsity of an attention matrix. The matrix superscript $*$ (e.g. $A^*$ ) indicates a sparse matrix, and a superscript $^*$ (e.g. $\hat{A}$ ) refers to the compressed $T \times K$ space. Let $\mathbb{KL}(p,q)$ and $\text{MSE}(x,y)$ be the standard KL divergence and mean-squared error, respectively. All matrices may also contain a batch ( $B$ ) and head ( $H$ ) dimension, but we omit this for simplicity unless otherwise specified.
50
+
51
+ **Performer (FAVOR+).** We define the simplified notation of FAVOR+ (Choromanski et al., 2021). We omit details, such as the kernel projection matrix, for the convenience of reading. The output of FAVOR+ is defined as FAVOR+(Q, K, V) = φ(Q) × (φ(K)^\top φ(V)) ∈ R^T \times d. As there is no need to construct the full T × T attention matrix, the FAVOR+ mechanism scales linearly.
52
+
53
+ # 3.1 SEA ATTENTION
54
+
55
+ SEA consists of two main phases that are depicted in Fig. 2: (1) Attention Estimation (kernel-based), and (2) Sparse Attention Mask Generation and Subsequent Sparse Attention. In step
56
+
57
+ ![](images/85f68f2f07a26887dea0632223fd1ba872c88a9f8b3c93e6c08eb1dd143cda23.jpg)
58
+ Figure 2: Model diagram of our proposed linear attention method, SEA. SEA replaces the multi-head attention (MHA) mechanism from the teacher transformer model while preserving the attention matrix using knowledge distillation with only a small finetuning dataset. The deployed SEA model shows linear complexity at test time.
59
+
60
+ (1), we estimate a compressed attention matrix $\hat{A}$ by fixing the size of one dimension to be $K$ , where $K \ll T$ using the kernel-based method Performer and a simple decoder. In step (2), we build an attention mask from the values in $\hat{A}$ using one of our novel grouped top- $\hat{k}$ selection methods depicted in Fig. 4. We then interpolate the mask to form a sparse mask on the full attention matrix $\mathbf{A}$ , resulting in a sparse attention matrix $\mathbf{A}^*$ . Then, we perform the sparse $\mathbf{A}^*\mathbf{V}$ multiplication to complete the procedure. By using a kernel-based estimator, as well as a sparse attention matrix, we take advantage of the complementary aspects of their representation spaces, as shown in previous work (Chen et al., 2021). Detailed model structure is shown in Fig. A.6.
61
+
62
+ Attention Matrix Estimation. The intuition for $\hat{A}$ is to compress one dimension of the matrix in a way analogous to compressing one dimension of an image. We ultimately want the values within the compressed attention matrix to be similar to the full attention matrix in the same way that compressing one dimension of an image creates a distorted image which is semantically similar to the full image. For this task, we use the Performer (Choromanski et al., 2021) and a decoder, and treat the output as our estimated attention matrix. Once this attention matrix 'image' is obtained, it can be interpolated to decompress it into an approximation of the full attention matrix for distillation during training, or likewise, we may also perform top- $\hat{k}$ selection on the compressed matrix in order to construct a mask for sparse attention. Our attention matrix estimation starts by passing $Q$ , $K$ , $V_{\mathrm{cat}}$ to the kernel-based linear attention method, Performer (Choromanski et al., 2021), where $V_{\mathrm{cat}} = [V_I; V] \in \mathbb{R}^{T \times 2d}$ and $V_I$ is obtained by performing nearest neighbor interpolation on the identity matrix $I \in \mathbb{R}^{d \times d}$ to modify the first dimension resulting in a matrix $V_I \in \mathbb{R}^{T \times d}$ . We include $V_I$ in $V_{\mathrm{cat}}$ because the output of Performer can be considered as the attention matrix when $V = I \in \mathbb{R}^{T \times T}$ , (e.g. $Q(K^\top I) = QK^\top$ ), as shown by Choromanski et al. (2021). Therefore, passing $V_I$ together with $V$ may enable a more accurate estimation of the attention matrix by the decoder described in the next section. This results in the context encoding $C_{\mathrm{perf}} = \mathrm{FAVOR} + (Q, K, V_{\mathrm{cat}}) \in \mathbb{R}^{T \times 2d}$ .
63
+
64
+ CNN Decoder. We further transform Performer's estimated output $C_{\mathrm{perf}}$ with an MLP and CNN. We found the CNN to be a necessary part of SEA due to the fact that convolutions provide fine-grained detail among local features, which is crucial for dynamically representing complex patterns present in the attention matrix as shown in Figs. 3 and 9. As we may consider the attention matrix as a kind of compressed 'image,' a CNN is a natural choice for the decoder. For the decoder, we begin by concatenating the local Performer encoding $C_{\mathrm{perf}}$ and the previous context $V$ as
65
+
66
+ $\pmb{V}_{\mathrm{cat}}^{\prime} = [\pmb{C}_{\mathrm{perf}}; \pmb{V}] \in \mathbb{R}^{T \times 3d}$ . We then apply an MLP $\mu: \mathbb{R}^{3d} \mapsto \mathbb{R}^{d'}$ to obtain an intermediate representation $\pmb{Z} = \mu(\pmb{V}_{\mathrm{cat}}^{\prime}) \in \mathbb{R}^{T \times d'}$ , where $d'$ is a hyperparameter which decides the shared hidden state size. The resulting $\pmb{Z}$ is used for estimating the attention matrix and also for the scalars $(S_{\mathrm{mix}}$ and $S_{\mathrm{prob}})$ described in Section 3.1.1. Then, before applying the CNN on $\pmb{Z}$ , we apply MLP $\nu: \mathbb{R}^{d'} \mapsto \mathbb{R}^{Kc_h / c_s}$ , where $c_s$ and $c_h$ are respective width reduction and channel expansion factors. We transpose and reshape to make the output $\hat{\pmb{Z}} = \nu(\pmb{Z})$ into $\mathbb{R}^{Hc_h \times T \times K / c_s}$ . Finally, we apply a 2D CNN $f_{\mathrm{dec}}$ which treats the extra head dimension $H$ as a channel dimension, resulting in the compressed attention matrix $\hat{\pmb{A}} = f_{\mathrm{dec}}(\hat{\pmb{Z}}) \in \mathbb{R}^{T \times K}$ (for further details, see Appendix A.5.1). As the decoder $f_{\mathrm{dec}}$ results in a fixed width $\hat{\pmb{A}}$ , we can successfully generate dynamic patterns with linear time and space complexity. The CNN $f_{\mathrm{dec}}$ plays a significant role due to its ability to capture
67
+
68
+ ![](images/2507172139def0b62398d6f128f4f9a335f3a83dc324ab9eda76c8879c7d564f.jpg)
69
+ Figure 3: Visualization of Input and Output of CNN Decoder
70
+
71
+ local patterns of the estimated compressed attention matrix. The depth of the CNN can be adjusted depending on the task, but we use a fixed 3-layer CNN in our experiments.
72
+
73
+ Grouped Top- $\hat{k}$ Selection. Once we have the compressed attention matrix $\hat{A}$ , we must select $k$ critical values which will be used in the final $T\times T$ sparse attention. However, since our top- $\hat{k}$ selection is held in the compressed $\hat{A}$ , we transform $k$ to $\hat{k}$ , which refers to the number of selected values in the compressed $T\times K$ attention space. For this, we propose four novel methods for top- $\hat{k}$ selection: per-query, per-head, per-batch, and causal-per-batch, where each method performs the top- $\hat{k}$ selection along different dimensions, as shown in Fig. 4. As noted in Section 3.1 (preliminaries), we have previously omitted the head dimension $H$ from all matrices. However in this paragraph, for clarity, we include the head dimension $H$ so that $\hat{A} \in \mathbb{R}^{H\times T\times K}$ . For per-query, per-head, and per-batch, we gradually extend the dimension of the group, starting from the last dimension of $\hat{A}$ , so that top- $\hat{k}$ selection is held in $\mathbb{R}^K$ , $\mathbb{R}^{T\times K}$ , and $\mathbb{R}^{H\times T\times K}$ space for each grouping method, respectively. Consequently, $\hat{k}$ is also adjusted to $\hat{k}_{\mathrm{per - query}} = \hat{k}$ , $\hat{k}_{\mathrm{per - head}} = T\times \hat{k}$ , and $\hat{k}_{\mathrm{per - batch}} = H\times T\times \hat{k}$ . Finally, we propose causal-per-batch for causal attention, which performs top- $\hat{k}$ in $\mathbb{R}^{H\times K}$ space, with $\hat{k}_{\mathrm{causal - per - batch}} = H\times \hat{k}$ . For this, we transpose $\hat{A}$ to $\mathbb{R}^{T\times H\times K}$ and group the last two dimensions without the $T$ dimension, to avoid temporal information exchange across the time dimension. In our experiments, we use causal-per-batch which shows strong performance in our ablation study on GLUE-MNLI ( $K = 128$ , 5 epochs), as shown in Table 1.
74
+
75
+ Linear Sparse Attention Mask Generation. With the obtained $\hat{A}$ , we generate a sparse formatted binary mask $M^{*} \in \{0,1\}^{T \times T}$ . For this, we take the following two steps: 1) Performing our proposed grouped top- $\hat{k}$ selection from the compressed $\hat{A}$ to generate a binary mask $\hat{M} \in \{0,1\}^{T \times K}$ , and 2) interpolating $\hat{M}$ to the sparse formatted $M^{*} \in \{0,1\}^{T \times T}$ . For the grouped top- $\hat{k}$ selection, we set $k$ as a hyperparameter, which will determine the number of selected indices in each block of the binary mask $M^{*}$ depending on the top- $\hat{k}$ strategy and the attention matrix size. Note that each selection strategy has a different block (group) shape as depicted in Fig. 4. However, since we perform top- $\hat{k}$ on the smaller $\hat{A} \in \mathbb{R}^{T \times K}$ , we must convert $k$ to a compressed $\hat{k}$ with $\hat{k} = \max(1, \text{round}(k * K / T))$ . Once we obtain the compressed mask $\hat{M} \in \{0,1\}^{T \times K}$ , we interpolate it into the sparse formatted $M^{*} \in \{0,1\}^{T \times T}$ . In the case of a very long sequence, it is possible that $\max(1, \text{round}(k * K / T))$ evaluates to 1, and the subsequent in-
76
+
77
+ terpolation (pixel duplications) to create $M^{*}$ will become a function of $T$ and no longer have linear complexity, as this results in a block larger than $k$ being computed for $M^{*}$ . Therefore, in order to avoid this, we enforce the number of pixel duplications in the block of $M^{*}$ to be $\min(k, \lceil T / K \rceil)$ , and uniformly space the resulting pixels within the larger block. Since we only need to check the indices where the values are 1 in the compressed $\hat{M}$ and put 1 in the corresponding indices in $M^{*}$ , the interpolation has linear complexity. For further details, please refer to Appendix A.5.3.
78
+
79
+ Table 1: Ablation study on grouped top- $\hat{k}$ modes
80
+
81
+ <table><tr><td>Grouping Method</td><td>k=7</td><td>k=13</td><td>k=25</td></tr><tr><td>per-query</td><td>77.68</td><td>81.45</td><td>83.55</td></tr><tr><td>per-head</td><td>79.03</td><td>82.71</td><td>83.71</td></tr><tr><td>per-batch</td><td>80.03</td><td>82.94</td><td>84.14</td></tr><tr><td>causal per-batch</td><td>80.55</td><td>83.49</td><td>84.19</td></tr></table>
82
+
83
+ ![](images/bf90e838dde26f32c517db27c1c32b0383fcc74a360e2be8993efa18345bc32d.jpg)
84
+ (a) Per-query
85
+
86
+ ![](images/feda17fd9af76355f2a0e746604a1e58f419f0dfd3f223677dd98b6ce4443efd.jpg)
87
+ (b) Per-head
88
+
89
+ ![](images/402f1049c417e588fc84fa6a54dfb36caf5837bc359ac7499405a65917457eff.jpg)
90
+ (c) Per-batch
91
+ Figure 4: Visualization of the Group of each top- $\hat{k}$ method.
92
+
93
+ ![](images/6c8431eab09f8327a558c951fec647edd9377b416e489700002fbae028738255.jpg)
94
+ (d) Causal Per-batch
95
+
96
+ # 3.1.1 SPARSE ATTENTION AND FINAL OUTPUT CALCULATION WITHIN LINEAR COST
97
+
98
+ Sparse Attention Mechanism. We calculate a re-weighted sparse attention probability $A^{*}$ by first applying a sparse masked matrix multiplication $\rho$ , where $\rho(Q, K^{\top}, M^{*}) = QK^{\top} \odot M^{*}$ followed by a softmax operation $\sigma$ . Note that the $Q$ and $K$ matrices which are inputs to $\rho$ are the same $Q$ and $K$ which were inputs to the Performer. We then re-scale the weights using $s_{\mathrm{prob}} \in \mathbb{R}^{T}$ (defined later in this paragraph), so that $A^{*} = s_{\mathrm{prob}} \odot \sigma(\rho(Q, K^{\top}, M^{*})) \in \mathbb{R}^{T \times T}$ . Note that $\rho$ is a sparse operation and $M^{*} \in \{0, 1\}^{T \times T}$ is the previously obtained sparse binary mask using FlatCSR. The output of $\rho$ only needs to store the non-zero values and indices, which are the indices where $M^{*}$ has value 1. The softmax $\sigma(\rho(Q, K^{\top}, M^{*}))$ calculates the softmax probability of non-zero values in the sparse input. After applying $\sigma$ , each row of the sparse attention matrix $A^{*}$ will sum to 1, therefore, due to the high sparsity of $M^{*}$ , the resulting non-zero values after $\sigma$ will be higher than the ground truth attention matrix from the teacher. To account for this effect, we scale the attention probability using a learned weight $s_{\mathrm{prob}} \in \mathbb{R}^{T}$ , where $s_{\mathrm{prob}} = f_{\mathrm{prob}}(Z)$ ( $Z$ was previously defined
99
+
100
+ ![](images/4a70782625c65fed5736cac5f7797f8b23402705d1eb29ab72defd6b06d7d14e.jpg)
101
+ (a) Computational costs vs. perplexity $\downarrow$ on Wikitext2 with OPT-125m.
102
+
103
+ ![](images/3fefe01105074c0ae19cf121da390a407194a3ea05bd2529719306c2e501ff06.jpg)
104
+ (b) OPT-125M validation curves
105
+
106
+ ![](images/a2b823ee239b4022ba10b510931726995d59761f5497904586eb0de53a06055c.jpg)
107
+
108
+ Table 2: Comparison of perplexity score on Wikitext2 with various scales of OPT model. We trained the same number of steps (10k) for each method. We used $k = 64$ ; $K = 64$ for SEA on OPT-125M, 350M and 1.3B.
109
+
110
+ <table><tr><td rowspan="2">Method</td><td colspan="3">OPT-125M</td><td colspan="3">OPT-350M</td><td colspan="3">OPT-1.3B</td></tr><tr><td>PPL. ↓</td><td>Mem. ↓</td><td>Lat. ↓</td><td>PPL. ↓</td><td>Mem. ↓</td><td>Lat. ↓</td><td>PPL. ↓</td><td>Mem. ↓</td><td>Lat. ↓</td></tr><tr><td>Vanilla</td><td>29.2</td><td>408</td><td>4.88</td><td>19.3</td><td>536</td><td>6.71</td><td>13.9</td><td>1120</td><td>16.49</td></tr><tr><td>Reformer</td><td>63.9 (+34.7)</td><td>902</td><td>10.90</td><td>58.2 (+38.9)</td><td>1195</td><td>14.76</td><td>49.02 (+35.12)</td><td>2406</td><td>31.37</td></tr><tr><td>Performer</td><td>49.8 (+20.6)</td><td>51</td><td>1.21</td><td>36.6 (+17.3)</td><td>60.5</td><td>1.82</td><td>30.6 (+16.7)</td><td>137</td><td>5.71</td></tr><tr><td>SEA (Ours)</td><td>26.0 (-3.2)</td><td>187</td><td>6.76</td><td>19.5 (+0.2)</td><td>241</td><td>9.43</td><td>13.5 (-0.4)</td><td>499</td><td>21.57</td></tr></table>
111
+
112
+ ![](images/d46b263c32c756c231203ba19783f7c1011a0966a2b7d08f32d32bfd8adda801.jpg)
113
+ Figure 5: Fig. 5a shows how 9 variants of our model perform when comparing perplexity vs. computation. Baseline model marker sizes correspond to increasing numbers of buckets (Reformer) or random projections (Performer). In all cases, SEA produces the best perplexity score. Fig. 5b Validation curves for SEA and baseline efficient attention methods. SEA converges much faster compared to Performer and Reformer.
114
+ Figure 6: Dynamically adjusting $k$ after training.
115
+
116
+ in Section 3.1 CNN Decoder) and $f_{\mathrm{prob}}$ is a linear projection from $\mathbb{R}^{d'} \mapsto \mathbb{R}$ followed by a sigmoid activation function. Since the sparse calculation of $\rho$ is only performed in the indices where $M^*$ has 1, the complexity follows that of $M^*$ , which is $\mathcal{O}(T)$ . The resulting $A^*$ matrix remains in a sparse matrix format. Afterward, we calculate the context feature as $C = A^* V \in \mathbb{R}^{T \times d}$ which has linear complexity due to the linear complexity of $A^*$ and $V$ . The output $C$ is now stored in a dense matrix format.
117
+
118
+ FlatCSR: A Modified Compressed Sparse Row (CSR) Format. We introduce our novel sparse operation, FlatCSR, which is an efficient implementation of the previously described sparse attention mask generation and attention operations utilizing grouped top- $\hat{k}$ selection. Our initial attempt for the sparse operations in our model utilized the Coordinate List (COO) sparse format. However, COO is not ideal because it stores every coordinate of each non-zero point and it does not take advantage of the structure provided by our grouped top- $\hat{k}$ selection, as shown in Table 3. Therefore, we eventually adopted the CSR sparse format instead of COO, as it uses less memory and schedules the per-row computations wisely using pre-constructed rows from our grouped top- $\hat{k}$ selection. We present a detailed explanation of FlatCSR and further discussions in Appendix A.5.2.
119
+
120
+ Output Calculation. For the final output, instead of relying solely on the sparse attention operation previously described, we combine the output of the Performer, and the sparse attention operation to improve the ability of the highly sparse attention matrix to look up global information.
121
+
122
+ Table 3: Comparison of different sparse matrix formats on random inputs
123
+
124
+ <table><tr><td>Method</td><td>Latency (ms)</td><td>Memory (MB)</td></tr><tr><td>COO</td><td>75.66 (100%)</td><td>1194 (100%)</td></tr><tr><td>FlatCSR (Ours)</td><td>11.4 (15.06%)</td><td>817.5 (68.46%)</td></tr></table>
125
+
126
+ The final output $C_{\mathrm{sea}}$ is computed as a summation of two terms $C$ and $C_{\mathrm{avg}}$ , each obtained from $A^{*}$ and $\hat{A}$ respectively. First, we calculate the importance score of each token by averaging every row of $\hat{A}$ , resulting in $\hat{\pmb{i}} = \frac{1}{T}\sum_{t=0}^{T}\hat{A}_{t,:} \in \mathbb{R}^{K}$ . We then interpolate $\hat{\pmb{i}}$ to $\pmb{i} \in \mathbb{R}^T$ and subsequently perform weighted average pooling of $C_{\mathrm{avg}} = \pmb{i}^\top V \in \mathbb{R}^d$ . In causal attention, this global pooled context feature $C_{\mathrm{avg}}$ is replaced with an accumulated average of the tokens in $V$ such that $V_j = \frac{1}{j}\sum_{i=1}^{j}V_i$ . We mix $C_{\mathrm{avg}}$ and $C$ using learned weight $s_{\mathrm{mix}} = f_{\mathrm{pool}}(Z) \in \mathbb{R}^T$ , with $f_{\mathrm{pool}}$ composed of a linear transformation and sigmoid activation $f_{\mathrm{pool}}: \mathbb{R}^{d'} \mapsto \mathbb{R}$ . $C_{\mathrm{sea}}$ is calculated as $C_{\mathrm{sea}} = s_{\mathrm{mix}} \odot C + (1 - s_{\mathrm{mix}}) \odot C_{\mathrm{avg}}^\top$ .
127
+
128
+ # 3.2 TRAINING SEA ATTENTION
129
+
130
+ For training SEA, we first replace the attention mechanism of a pretrained teacher transformer model with our SEA attention mechanism. Then, we use knowledge distillation (KD) (Hinton et al., 2015) to train the newly added SEA attention parameters while adapting the original weights to SEA attention. Our training scheme is similar to previous transformer KD work (Jiao et al., 2020) since we approximate the context features and attention matrices. However, we further add an objective
131
+
132
+ ![](images/fde932bb4c532236e64dd12334f65aaf3573a968ede5bc9c6e7785a388d544bb.jpg)
133
+
134
+ ![](images/504895c72107dd3ddfb927f12612c15eca64196f2f142b381306e386d7bf32c0.jpg)
135
+
136
+ ![](images/3ccd2a002e3fab218010171a6082bfd25ed5231fc4819f3fb6617ab971b510b6.jpg)
137
+
138
+ ![](images/1e76d1fe48076dbf89b2782dda714c9205aa48922a57eb8e5b4d5c6320576b8f.jpg)
139
+
140
+ ![](images/b481fe233b4e23c4df3750475d6f846fcb43fd016cd1071e929c97ef9017c962.jpg)
141
+ (b) Dynamically adjusting $k$ after training.
142
+
143
+ ![](images/c2ca14a12f5832879339fb53d44799e726b14686c62568b7fcb7adb3d4936798.jpg)
144
+ (a) Comparison of the trade-off on GLUE.
145
+
146
+ ![](images/5fc07125cc7e95aa685bb9f45ac1de62c3dfb6194ec153ea58cdeda4cc746b85.jpg)
147
+ Figure 7: Fig. 7a shows the comparison of the trade-off between computational cost (latency and memory usage) and accuracy on each GLUE subset with BERT-base. 7a (column 1): Overall performance trade-off over three subsets. We average metrics weighted with dataset size. 7a (column 2-4): Performance trade-off per each GLUE subset. Baseline model marker sizes correspond to increasing numbers of buckets or random projections. Fig. 7b shows the accuracy trade-off of dynamically adjusting $k$ after training.
148
+
149
+ ![](images/db94c4810f5703192c5ff0e9d8f403e8402ebd6a65a181d158906f94eb0c5905.jpg)
150
+
151
+ ![](images/9bf6a5bb234ecf0d8f23a59517d877e11e09afa783962810a3a21d5571db07e6.jpg)
152
+
153
+ ![](images/5d0b5cf4ece4e26b0b5f54c562544c56ea74fdec1193822fbed067063cf2f403.jpg)
154
+ Accuracy After Adjusting $k$
155
+
156
+ for the compressed estimated attention matrix $\hat{A}$ to match the teacher attention matrix. With $\mathcal{L}^{(i)}$ signifying a loss for layer $i$ , our overall training loss $\mathcal{L}_{\mathrm{sea}}$ is given as the following, with each term described in the following paragraph:
157
+
158
+ $$
159
+ \mathcal {L} _ {\text {s e a}} = \frac {1}{L} \left(\sum_ {i = 1} ^ {L} \mathcal {L} _ {\text {a p p r o x}} ^ {(i)} + \mathcal {L} _ {\text {p r o b}} ^ {(i)} + \mathcal {L} _ {\text {c o n t e x t}} ^ {(i)} + \mathcal {L} _ {\mathrm {k d}} ^ {(i)}\right) + \mathcal {L} _ {\mathrm {k d} \_ \text {t a s k}} + \mathcal {L} _ {\text {t a s k}} \tag {1}
160
+ $$
161
+
162
+ To calculate $\mathcal{L}_{\mathrm{approx}}$ , we perform nearest neighbor interpolation to the estimated attention matrix $\tilde{\boldsymbol{A}}_i$ , and get $\boldsymbol{A}_i' \in \mathbb{R}^{T \times T}$ in order to match the shape of the teacher attention matrix $\tilde{\boldsymbol{A}}_i \in \mathbb{R}^{T \times T}$ . Then we apply both KL divergence and an MSE loss between $\boldsymbol{A}_i'$ and $\tilde{\boldsymbol{A}}_i$ , $\mathcal{L}_{\mathrm{approx}}^{(i)} = \mathbb{KL}(\boldsymbol{A}_i', \tilde{\boldsymbol{A}}_i) + \mathsf{MSE}(\boldsymbol{A}_i', \tilde{\boldsymbol{A}}_i)$ . Next, we calculate $\mathcal{L}_{\mathrm{prob}}^{(i)} = \mathbb{KL}(\boldsymbol{A}_i, \tilde{\boldsymbol{A}}_i) + \mathsf{MSE}(\boldsymbol{A}_i, \tilde{\boldsymbol{A}}_i)$ which minimizes the error between the student's $\boldsymbol{A}_i$ and teacher's $\tilde{\boldsymbol{A}}_i$ attention matrices. For $\mathcal{L}_{\mathrm{prob}}^{(i)}$ , we calculate the dense student attention $\boldsymbol{A}_i = \sigma(\boldsymbol{Q}_i \boldsymbol{K}_i^\top)$ during training. We then add $\mathcal{L}_{\mathrm{context}}^{(i)} = \mathsf{MSE}(\boldsymbol{C}_{\mathrm{sea}}^{(i)}, \tilde{\boldsymbol{C}}^{(i)})$ to minimize the error between the attention context feature $\boldsymbol{C}_{\mathrm{sea}}^{(i)}$ and teacher context feature $\tilde{\boldsymbol{C}}^{(i)} \in \mathbb{R}^{T \times d}$ . Next, to minimize the error of each transformer layer (after the attention layer and MLP), we gather the outputs of each layer $O_{\mathrm{sea}}^{(i)}$ , $\tilde{\boldsymbol{O}}^{(i)} \in \mathbb{R}^{N \times T \times H * d}$ for SEA and the teacher, respectively, and calculate $\mathcal{L}_{\mathrm{kd}}^{(i)} = \mathsf{MSE}(O_{\mathrm{sea}}^{(i)}, \tilde{\boldsymbol{O}}^{(i)})$ . The loss for training the $i$ -th layer is $\mathcal{L}_{\mathrm{sea}}^{(i)}$ and is a weighted sum of each layerwise loss such that $\mathcal{L}_{\mathrm{sea}}^{(i)} = \mathcal{L}_{\mathrm{approx}}^{(i)} + \mathcal{L}_{\mathrm{prob}}^{(i)} + \mathcal{L}_{\mathrm{context}}^{(i)} + \mathcal{L}_{\mathrm{kd}}^{(i)}$ . We omit the weight term on each sub-task loss for simplicity; details are in Appendix A.4.1. We then calculate knowledge distillation loss from the model output logits $\mathcal{L}_{\mathrm{kd\_task}} = \mathbb{KL}(\boldsymbol{P}, \tilde{\boldsymbol{P}})$ , where $\boldsymbol{P} \in \mathbb{R}^z$ is model output logit. Finally, we sum together the average layer-wise loss and the downstream task loss $\mathcal{L}_{\mathrm{task}}$ into the SEA training loss given in Eq. (1).
163
+
164
+ # 4 EXPERIMENTS
165
+
166
+ # 4.1 CAUSAL LANGUAGE MODELING
167
+
168
+ We further evaluated SEA on the language modeling task on Wikitext2 (Merit et al., 2017) with various OPT (Zhang et al., 2022) variants, which involves causal attention. We selected two representative baselines, Reformer (Kitaev et al., 2020) and Performer (Choromanski et al., 2021), which represent the sparse attention and kernel-based linear attention methods, respectively. In Tables 2 and A.8, Reformer shows unpredictable performance between the tasks, exhibiting strong performance in text classification (Table A.8), and the worst result in causal language modeling (Table 2). In contrast, our proposed method, SEA attention, performs the best in both cases with the closest perplexity score to the vanilla OPT and even surpasses the quadratic attention model on OPT-125M in Table 2. In Fig. 5a, we show a trade-off between computational cost and perplexity. Our method exhibits more latency, since we utilize both kernel-based and sparse attention within our model (detailed latency breakdown in Fig. 8). Therefore, we discuss the latency and memory trade-off of our method in Section 5. We note, however, that even though SEA uses both Performer and sparse attention modules, the convergence rate is much faster than both solo baselines, as depicted in Fig. 5b due to the direct attention distillation from the quadratic teacher.
169
+
170
+ # 4.2 TEXT CLASSIFICATION
171
+
172
+ We perform text classification evaluation of SEA on the GLUE (Wang et al., 2019) benchmark with BERT (Devlin et al., 2019). We train SEA attention by adapting to the fine-tuned model, as
173
+
174
+ ![](images/63bd84e6dcca0075184c5fa6794d598090a1f06eaea49ede74ff1152aa9eac18.jpg)
175
+ Figure 8: (top) Space and time complexity comparison between our SEA attention and baselines. Lower values are better in both figures. SEA exhibits complexity in line with other linear attention models. We show a trendline for the quadratic attention because it runs out of memory on sequence lengths larger than $2^{13}$ . (bottom) Latency (ms) breakdown of our SEA attention ( $T = 2^{13}$ , causal-per-batch). Each orange and green box shows that the operation is computed in our novel FlatCSR format and in dense tensor format, respectively.
176
+
177
+ ![](images/01ccd3e202bce14742bfb70be09f76fbfbbea482e10f4e3163650636031135da.jpg)
178
+
179
+ ![](images/bf17b7922026efdb3c2b1bb9ccb6824ab2975b983020586933115deb383f4dd2.jpg)
180
+
181
+ <table><tr><td rowspan="2">Performer (10.06%)</td><td rowspan="2">Predictor (27.93%)</td><td>top-k</td><td>scatter</td><td>setup</td><td>----</td><td>mbmm</td><td>softmax</td><td>e multinul</td><td>sdbmm</td></tr><tr><td colspan="2">Mask (9.46%)</td><td colspan="2">Interp (9.26%)</td><td colspan="4">Sparse Attention (37.02%)</td></tr><tr><td colspan="10">SEQ=8192, k=64, K=256, 24.62ms</td></tr></table>
182
+
183
+ described in Section 3.2. In Fig. 7a, we show a trade-off between computational costs and various performance scores. We test the following baseline methods: Reformer, Sinkhorn (Tay et al., 2020b), Performer, Cosformer (Qin et al., 2022), and Synthesizer (Tay et al., 2020a) (see Appendix A.4.2 for further experiment details). In all tested subsets, SEA achieves the top performance and maintains competitive latency and memory costs. In Table A.8, we show results of the tested baselines within the same constraints by limiting all the baselines and our method to have the same bucket size in sparse attentions and the same number of random projection feature sizes in kernel-based attentions. To summarize, our method achieves higher accuracy than all linear baselines while maintaining competitive performance in terms of latency and memory usage. SEA comes within $0.1\%$ accuracy of quadratic attention on MNLI in Table A.8, and in Section 4.3 and Figs. 6 and 7b we show we can dynamically adjust $k$ after training to outperform quadratic attention.
184
+
185
+ # 4.3 DYNAMICALLY ADJUSTING $k$
186
+
187
+ In Figs. 6 and 7b, we experiment with dynamically adjusting $k$ after training with a fixed value of $k$ on the Wikitext2 and MNLI dataset. We find that increasing $k$ also increases the accuracy without the need for any further training. This means even after fine-tuning the SEA, our model still preserves pretrained knowledge and increases accuracy when the constraint on $k$ is relaxed. Therefore, this characteristic helps users to design flexible and dynamic models that can adapt to real-time service demands and cost constraints by dynamically adjusting $k$ . For example, considering that lower $k$ leads to a lower computational cost as shown in Fig. 5a and Fig. 7a, if a given situation calls for lower computational cost, $k$ can be minimized, while if accuracy is more important, $k$ can be set to a higher in real-time. In addition, surprisingly, increasing $k$ after training makes the model perform better than the vanilla quadratic model. In Fig. 6, the vanilla baseline shows a perplexity score of 29.2, however, all SEA models ( $k = 32, 64, 128$ ) surpass this when we increase $k$ after training.
188
+
189
+ # 5 EFFICIENCY OF SEA ATTENTION COMPUTATION
190
+
191
+ In this section, we provide the memory usage and latency experiment results of our method with different sequence lengths $T$ . In Fig. 8, we show that our resource usage tendency is $\mathcal{O}(T)$ . We test SEA attention with the causal per-batch top-k grouping mode with our FlatCSR implementation.
192
+
193
+ Peak Memory Usage. In Table A.1 and Fig. 8 (top-left), we compare peak memory usage in mega-bytes for each attention method. Compared to baselines, SEA attention shows competitive peak memory usage. Our method shows an $81.05\%$ reduction in peak memory usage compared to quadratic attention at sequence length $2^{13}$ . Our method consumes memory only about $78.81\%$ compared to Reformer, while consistently maintaining higher accuracy as shown in Figs. 5a and 7a and Tables 2 and A.8. Moreover, our methods successfully operate with a competitive memory budget with other linear attention methods on all sequence lengths (shown in Table A.1 and Fig. 8), while quadratic attention exceeds memory capacity above $2^{13}$ . In summary, our method reduces memory complexity to $\mathcal{O}(T)$ , and exhibits less memory usage than Reformer.
194
+
195
+ Latency. In Fig. 8 (top-right), we compare the latency between SEA and our linear attention baselines, showing that SEA scales linearly. Our model only incurs $32.72\%$ of the latency cost of quadratic attention in Fig. 8 for a sequence length of $2^{13}$ where quadratic attention runs out of
196
+
197
+ ![](images/99da4a38ce77927fa28abf50273265b0dbaec8b34b757a0840b73a359194f34b.jpg)
198
+ Figure 9: (left) Intermediate attention examples. (right) The first row is the attention probability of the teacher model, and the second row is the compressed attention interpolated to full size. Interpolation to the full size attention matrix is for visualizing our estimated attention $\hat{A}$ and is not part of the regular linear inference procedure. (a) MNLI with BERT-base ( $K = 128$ ) (b) Wikitext2 with OPT-125m ( $K = 256$ ).
199
+
200
+ memory. SEA also shows better performance with a similar latency to Reformer, as shown in Fig. 7a (bottom-left). However, our method also shows a latency-accuracy trade-off in Fig. 7a, where some baselines such as Sinkhorn, Cosformer, and Performer show better latency but worse accuracy than our SEA. We break down the latency of each component of our proposed method in Fig. 8 (bottom). The dense operations use $47.45\%$ , FlatCSR sparse operations use $46.28\%$ , and the other operations, mainly permute and reshape, comprise $6.27\%$ of latency. However, in the COO sparse format, the dense operations use $13.31\%$ , and COO sparse operations comprise $86.68\%$ of the latency cost. As a result, the COO format is $6.63 \times$ slower than our novel FlatCSR format as shown in Table 3.
201
+
202
+ # 6 VISUALIZATION OF ESTIMATED ATTENTION FROM SEA ATTENTION
203
+
204
+ In Fig. 9 (right-a), using BERT and the MNLI dataset, we visualize the interpolated estimated attention matrix $\hat{A}$ from SEA and compare it with the attention matrix of the teacher model $\tilde{A}$ . The learned estimator of SEA attention shows the ability to predict various attention shapes from the original finetuned BERT model. As can be seen, our estimator learns well-known fixed patterns, such as the diag-
205
+
206
+ onal but also dynamic patterns that require contextual interpretation. In Fig. 9 (right-b), we show the visualization of causal attention commonly used in generative models. In the causal-attention setting, we observe a diagonal attention probability with wavy or chunked diagonal lines, patterns that cannot be handled by previous heuristic linear attention mask patterns. However, our estimator still shows great predictions on such highly variant patterns. In addition, in Fig. 10, we show our compressed attention $\hat{A}$ , top- $k$ compressed mask $\hat{M}$ , sparse mask $M^{*}$ , and sparse attention $A^{*}$ .
207
+
208
+ Moreover, our model can perform well even if the estimated attention is slightly different from the teacher's, thanks to grouped top- $k$ , which drops all values that are not selected in the top- $k$ procedure. For example, in Fig. 9 (left-bottom), we show a sparse attention matrix after masking the estimated matrix with our grouped top- $k$ selection masks. Although the estimated attention matrix seems somewhat different from the teacher's Fig. 9 (left-middle), the resulting sparse attention pattern Fig. 9 (bottom-left) seems quite similar to the teacher's after applying the top- $k$ mask. Further visualization results can be found in Appendix A.2.
209
+
210
+ ![](images/a0dcd33cebabab26e8f3b9f450c97709da4cc9816aba4595e602497f39628870.jpg)
211
+ Figure 10: Visualization of intermediate buffers during masking and sparse attention.
212
+
213
+ # 7 CONCLUSION AND DISCUSSION
214
+
215
+ Our proposed method, SEA attention, shows state-of-the-art performance for integrating linear attention with pretrained transformers, as we show empirically in Section 4. The critical change over existing works is that we estimate the attention matrix in a compressed size using kernel-based linear attention to form a compressed sparse attention mask which can be decompressed into a full sparse attention mask to overcome the quadratic cost. By doing so, we can preserve the dynamic and complex attention patterns of the pretrained teacher transformer model through direct attention matrix distillation. Furthermore, SEA also provides interpretable attention patterns. SEA performs similarly to vanilla attention while existing works could not. We look forward to seeing future research that; may apply a learnable masking method instead of a top- $\hat{k}$ selection, such as concrete masking (Lee et al., 2023), or improve our uniform interpolation by some non-uniform or learnable interpolation which may provide further performance increases.
216
+
217
+ # ACKNOWLEDGEMENTS
218
+
219
+ We extend our heartfelt appreciation to Seanie Lee and Minki Kang for their insightful reviews, which greatly enriched the quality of our work. This work was supported by the National Research Foundation of Korea(NRF) grant funded by the Korea government(MSIT) (No. RS-2023-00256259).
220
+
221
+ # REPRODUCIBILITY STATEMENT
222
+
223
+ We will introduce code construction and data collection in this section for reproducibility.
224
+
225
+ SEA Attention Module Implementation First of all, we use perlin as our code name of SEA attention on supplementary source code. We implement SEA attention modules, including self-attention and causal attention for the transformer encoder and decoder. Users can import src.models.perlin_attention module to construct a custom transformer model. We implemented sample transformer models for experiment SEA attention in this paper: BERT and OPT. Users can check SEA-BERT implementation in src.models.perlin_bert, and SEA-OPT implementation in src.models.perlin_opt.
226
+
227
+ FlatCSR Triton Implementations We implemented our customized FlatCSR datatype operations in src.models.perlin attentio.n ops. Each kernel definition file has its own benchmark logic and verification logic.
228
+
229
+ Training Please check README.md in the root directory of the supplementary source code archive. We provide detailed guides and Python and Anaconda environment files to reproduce our results. Users can easily test various configurations of SEA attention on OPT with scripts/opt.py script. Users can easily test various configurations of SEA attention on BERT with src.trainer.perlin.trainer program entry. To train a custom SEA attention module, users must supply teacher attention scores and the context layer of attention layers to calculate the SEA attention loss. We implemented examples of those pipeline in src.trainer.*, src.models.hf_opt, and src.models.hf_bert.
230
+
231
+ Testing Please check README.md and src.main-tests.*. We implement several test codes to validate our implementation. For example, verifying the causality of causal attention.
232
+
233
+ # REFERENCES
234
+
235
+ Iz Beltagy, Matthew E. Peters, and Arman Cohan. Longformer: The long-document transformer. CoRR, abs/2004.05150, 2020. URL https://arxiv.org/abs/2004.05150.1,3
236
+ Daniel Bolya, Cheng-Yang Fu, Xiaoliang Dai, Peizhao Zhang, Christoph Feichtenhofer, and Judy Hoffman. Token merging: Your vit but faster. In *The Eleventh International Conference on Learning Representations*, ICLR 2023, Kigali, Rwanda, May 1-5, 2023. OpenReview.net, 2023. URL https://openreview.net/pdf?id=JroZRaRw7Eu.2
237
+ Tom B. Brown, Benjamin Mann, Nick Ryder, Melanie Subbiah, Jared Kaplan, Prafulla Dhariwal, Arvind Neelakantan, Pranav Shyam, Girish Sastry, Amanda Askell, Sandhini Agarwal, Ariel Herbert-Voss, Gretchen Krueger, Tom Henighan, Rewon Child, Aditya Ramesh, Daniel M. Ziegler, Jeffrey Wu, Clemens Winter, Christopher Hesse, Mark Chen, Eric Sigler, Mateusz Litwin, Scott Gray, Benjamin Chess, Jack Clark, Christopher Berner, Sam McCandlish, Alec Radford, Ilya Sutskever, and Dario Amodei. Language models are few-shot learners. In Hugo Larochelle, Marc'Aurelio Ranzato, Raia Hadsell, Maria-Florina Balcan, and Hsuan-Tien Lin (eds.), Advances in Neural Information Processing Systems 33: Annual Conference on Neural Information Processing Systems 2020, NeurIPS 2020, December 6-12, 2020, virtual, 2020. URL https://proceedings.neurips.cc/paper/2020/bit/1457c0d6bcbd4967418bf8ac142f64a-AAbstract.html.1
238
+ Beidi Chen, Tri Dao, Eric Winsor, Zhao Song, Atri Rudra, and Christopher Ré. Scatter-brain: Unifying sparse and low-rank attention. In Marc'Aurelio Ranzato, Alina Beygelzimer, Yann N. Dauphin, Percy Liang, and Jennifer Wortman Vaughan (eds.), Advances
239
+
240
+ in Neural Information Processing Systems 34: Annual Conference on Neural Information Processing Systems 2021, NeurIPS 2021, December 6-14, 2021, virtual, pp. 17413-17426, 2021. URL https://proceedings.neurips.cc/paper/2021/bitnet/9185f3ec501c674c7c788464a36e7fb3-Abstract.html.1,2,3,4
241
+ Ruijun Chen, Jin Wang, Liang-Chih Yu, and Xuejie Zhang. Learning to memorize entailment and discourse relations for persona-consistent dialogues. In Brian Williams, Yiling Chen, and Jennifer Neville (eds.), Thirty-Seventh AAAI Conference on Artificial Intelligence, AAAI 2023, Thirty-Fifth Conference on Innovative Applications of Artificial Intelligence, IAAI 2023, Thirteenth Symposium on Educational Advances in Artificial Intelligence, EAAI 2023, Washington, DC, USA, February 7-14, 2023, pp. 12653-12661. AAAI Press, 2023. doi: 10.1609/aaai.v37i11.26489. URL https://doi.org/10.1609/aaai.v37i11.26489.1
242
+ Wei-Lin Chiang, Zhuohan Li, Zi Lin, Ying Sheng, Zhanghao Wu, Hao Zhang, Lianmin Zheng, Siyuan Zhuang, Yonghao Zhuang, Joseph E. Gonzalez, Ion Stoica, and Eric P. Xing. Vicuna: An open-source chatbot impressing gpt-4 with $90\%$ chatgpt quality, March 2023. URL https://lmsys.org/blog/2023-03-30-vicuna/.1
243
+ Krzysztof Marcin Choromanski, Valerii Likhosherstov, David Dohan, Xingyou Song, Andreea Gane, Tamás Sarlós, Peter Hawkins, Jared Quincy Davis, Afroz Mohiuddin, Lukasz Kaiser, David Benjamin Belanger, Lucy J. Colwell, and Adrian Weller. Rethinking attention with performers. In 9th International Conference on Learning Representations, ICLR 2021, Virtual Event, Austria, May 3-7, 2021. OpenReview.net, 2021. URL https://openreview.net/forum?id=Ua6zuk0WRH.1,2,3,4,7,14
244
+ Tri Dao, Dan Fu, Stefano Ermon, Atri Rudra, and Christopher Ré. Flashattention: Fast and memory-efficient exact attention with io-awareness. Advances in Neural Information Processing Systems, 35:16344-16359, 2022. 14, 20, 22
245
+ Jacob Devlin, Ming-Wei Chang, Kenton Lee, and Kristina Toutanova. BERT: pre-training of deep bidirectional transformers for language understanding. In Jill Burstein, Christy Doran, and Thamar Solorio (eds.), Proceedings of the 2019 Conference of the North American Chapter of the Association for Computational Linguistics: Human Language Technologies, NAACL-HLT 2019, Minneapolis, MN, USA, June 2-7, 2019, Volume 1 (Long and Short Papers), pp. 4171-4186. Association for Computational Linguistics, 2019. doi: 10.18653/v1/n19-1423. URL https://doi.org/10.18653/v1/n19-1423.2, 7, 14, 15
246
+ Alexey Dosovitskiy, Lucas Beyer, Alexander Kolesnikov, Dirk Weissenborn, Xiaohua Zhai, Thomas Unterthiner, Mostafa Dehghani, Matthias Minderer, Georg Heigold, Sylvain Gelly, Jakob Uszkoreit, and Neil Houlsby. An image is worth 16x16 words: Transformers for image recognition at scale. In 9th International Conference on Learning Representations, ICLR 2021, Virtual Event, Austria, May 3-7, 2021. OpenReview.net, 2021. URL https://openreview.net/forum?id=YicbFdNTTy.1, 2, 20
247
+ Aaron Gokaslan, Vanya Cohen, Ellie Pavlick, and Stefanie Tellex. Openwebtext corpus, 2019. URL http://Skylion007.github.io/OpenWebTextCorpus.21
248
+ Geoffrey E. Hinton, Oriol Vinyals, and Jeffrey Dean. Distilling the knowledge in a neural network. CoRR, abs/1503.02531, 2015. URL http://arxiv.org/abs/1503.02531.2,6
249
+ Xiaoqi Jiao, Yichun Yin, Lifeng Shang, Xin Jiang, Xiao Chen, Linlin Li, Fang Wang, and Qun Liu. Tinybert: Distilling BERT for natural language understanding. In Trevor Cohn, Yulan He, and Yang Liu (eds.), Findings of the Association for Computational Linguistics: EMNLP 2020, Online Event, 16-20 November 2020, volume EMNLP 2020 of Findings of ACL, pp. 4163-4174. Association for Computational Linguistics, 2020. doi: 10.18653/v1/2020.findings-emnlp.372. URL https://doi.org/10.18653/v1/2020 findings-emnlp.372.2, 6
250
+ Sehoon Kim, Sheng Shen, David Thorsley, Amir Gholami, Woosuk Kwon, Joseph Hassoun, and Kurt Keutzer. Learned token pruning for transformers. In Aidong Zhang and Huzefa Rangwala (eds.), KDD '22: The 28th ACM SIGKDD Conference on Knowledge Discovery and Data Mining, Washington, DC, USA, August 14 - 18, 2022, pp. 784-794. ACM, 2022. doi: 10.1145/3534678.3539260. URL https://doi.org/10.1145/3534678.3539260. 2
251
+
252
+ Nikita Kitaev, Lukasz Kaiser, and Anselm Levskaya. Reformer: The efficient transformer. In 8th International Conference on Learning Representations, ICLR 2020, Addis Ababa, Ethiopia, April 26-30, 2020. OpenReview.net, 2020. URL https://openreview.net/forum?id= rkgNKkHtvB.1,3,7,14
253
+ Heejun Lee, Minki Kang, Youngwan Lee, and Sung Ju Hwang. Sparse token transformer with attention back tracking. In International Conference on Learning Representations, 2023. URL https://openreview.net/forum?id=VV0hSE8AxCw.2,9
254
+ Liu Liu, Zheng Qu, Zhaodong Chen, Yufei Ding, and Yuan Xie. Transformer acceleration with dynamic sparse attention. CoRR, abs/2110.11299, 2021. URL https://arxiv.org/abs/2110.11299.1,3
255
+ Stephen Merity, Caiming Xiong, James Bradbury, and Richard Socher. Pointer sentinel mixture models. In 5th International Conference on Learning Representations, ICLR 2017, Toulon, France, April 24-26, 2017, Conference Track Proceedings. OpenReview.net, 2017. URL https://openreview.net/forum?id=Byj72udxe.2,7,16
256
+ Zhen Qin, Weixuan Sun, Hui Deng, Dongxu Li, Yunshen Wei, Baohong Lv, Junjie Yan, Lingpeng Kong, and Yiran Zhong. cosformer: Rethinking softmax in attention. In The Tenth International Conference on Learning Representations, ICLR 2022, Virtual Event, April 25-29, 2022. OpenReview.net, 2022. URL https://openreview.net/forum?id=B18CQrx2Up4.1, 2, 3, 8, 14
257
+ Yi Tay, Dara Bahri, Donald Metzler, Da-Cheng Juan, Zhe Zhao, and Che Zheng. Synthesizer: Rethinking self-attention in transformer models. CoRR, abs/2005.00743, 2020a. URL https://arxiv.org/abs/2005.00743.1,3,8,14
258
+ Yi Tay, Dara Bahri, Liu Yang, Donald Metzler, and Da-Cheng Juan. Sparse sinkhorn attention. In Proceedings of the 37th International Conference on Machine Learning, ICML 2020, 13-18 July 2020, Virtual Event, volume 119 of Proceedings of Machine Learning Research, pp. 9438-9447. PMLR, 2020b. URL http://proceedings.mlr.press/v119/tay20a.html. 1, 3, 8, 14
259
+ Philippe Tillet, Hsiang-Tsung Kung, and David D. Cox. Triton: an intermediate language and compiler for tiled neural network computations. In Tim Mattson, Abdullah Muzahid, and Armando Solar-Lezama (eds.), Proceedings of the 3rd ACM SIGPLAN International Workshop on Machine Learning and Programming Languages, MAPL@PLDI 2019, Phoenix, AZ, USA, June 22, 2019, pp. 10-19. ACM, 2019. doi: 10.1145/3315508.3329973. URL https://doi.org/10.1145/3315508.3329973.18
260
+ Hugo Touvron, Louis Martin, Kevin Stone, Peter Albert, Amjad Almahairi, Yasmine Babaei, Nikolay Bashlykov, Soumya Batra, Prajjwal Bhargava, Shruti Bhosale, Dan Bikel, Lukas Blecher, Cristian Canton-Ferrer, Moya Chen, Guillem Cucurull, David Esiobu, Jude Fernandes, Jeremy Fu, Wenyin Fu, Brian Fuller, Cynthia Gao, Vedanuj Goswami, Naman Goyal, Anthony Hartshorn, Saghar Hosseini, Rui Hou, Hakan Inan, Marcin Kardas, Viktor Kerkez, Madian Khabsa, Isabel Kloumann, Artem Korenev, Punit Singh Koura, Marie-Anne Lachaux, Thibaut Lavril, Jenya Lee, Diana Liskovich, Yinghai Lu, Yuning Mao, Xavier Martinet, Todor Mihaylov, Pushkar Mishra, Igor Molybog, Yixin Nie, Andrew Poulton, Jeremy Reizenstein, Rashi Rungta, Kalyan Saladi, Alan Schelten, Ruan Silva, Eric Michael Smith, Ranjan Subramanian, Xiaqing Ellen Tan, Binh Tang, Ross Taylor, Adina Williams, Jian Xiang Kuan, Puxin Xu, Zheng Yan, Iliyan Zarov, Yuchen Zhang, Angela Fan, Melanie Kambadur, Sharan Narang, Aurélien Rodriguez, Robert Stojnic, Sergey Edunov, and Thomas Scialom. Llama 2: Open foundation and fin-tuned chat models. CoRR, abs/2307.09288, 2023. doi: 10.48550/arXiv.2307.09288. URL https://doi.org/10.48550/arXiv.2307.09288.1
261
+ Aäron van den Oord, Sander Dieleman, Heiga Zen, Karen Simonyan, Oriol Vinyals, Alex Graves, Nal Kalchbrenner, Andrew W. Senior, and Koray Kavukcuoglu. Wavenet: A generative model for raw audio. In The 9th ISCA Speech Synthesis Workshop, Sunnyvale, CA, USA, 13-15 September 2016, pp. 125. ISCA, 2016. URL http://www.isca-speech.org/archive/SSW_2016/abstracts/ssw9_DS-4_van_den_Oord.html.18
262
+
263
+ Ashish Vaswani, Noam Shazeer, Niki Parmar, Jakob Uszkoreit, Llion Jones, Aidan N. Gomez, Lukasz Kaiser, and Illia Polosukhin. Attention is all you need. In Isabelle Guyon, Ulrike von Luxburg, Samy Bengio, Hanna M. Wallach, Rob Fergus, S. V. N. Vishwanathan, and Roman Garnett (eds.), Advances in Neural Information Processing Systems 30: Annual Conference on Neural Information Processing Systems 2017, December 4-9, 2017, Long Beach, CA, USA, pp. 5998-6008, 2017. URL https://proceedings.neurips.cc/paper/2017/bit/3f5ee243547dee91fbd053c1c4a845aa-Abstract.html.1
264
+ Alex Wang, Amanpreet Singh, Julian Michael, Felix Hill, Omer Levy, and Samuel R. Bowman. GLUE: A multi-task benchmark and analysis platform for natural language understanding. In 7th International Conference on Learning Representations, ICLR 2019, New Orleans, LA, USA, May 6-9, 2019. OpenReview.net, 2019. URL https://openreview.net/forum?id=rJ4km2R5t7.2,7,22
265
+ Yizhong Wang, Swaroop Mishra, Pegah Alipoormolabashi, Yeganeh Kordi, Amirreza Mirzaei, Atharva Naik, Arjun Ashok, Arut Selvan Dhanasekaran, Anjana Arunkumar, David Stap, Eshaan Pathak, Giannis Karamanolakis, Haizhi Gary Lai, Ishan Purohit, Ishani Mondal, Jacob Anderson, Kirby Kuznia, Krima Doshi, Kuntal Kumar Pal, Maitreya Patel, Mehrad Moradshahi, Mihir Parmar, Mirali Purohit, Neeraj Varshney, Phani Rohitha Kaza, Pulkit Verma, Ravsehaj Singh Puri, Rushang Karia, Savan Doshi, Shailaja Keyur Sampat, Siddhartha Mishra, Sujan Reddy A, Sumanta Patro, Tanay Dixit, and Xudong Shen. Super-natural instructions: Generalization via declarative instructions on $1600+$ NLP tasks. In Yoav Goldberg, Zornitsa Kozareva, and Yue Zhang (eds.), Proceedings of the 2022 Conference on Empirical Methods in Natural Language Processing, EMNLP 2022, Abu Dhabi, United Arab Emirates, December 7-11, 2022, pp. 5085-5109. Association for Computational Linguistics, 2022. doi: 10.18653/v1/2022.emnlp-main.340. URL https://doi.org/10.18653/v1/2022.emnlp-main.340.1
266
+ Adina Williams, Nikita Nangia, and Samuel R. Bowman. A broad-coverage challenge corpus for sentence understanding through inference. In Marilyn A. Walker, Heng Ji, and Amanda Stent (eds.), Proceedings of the 2018 Conference of the North American Chapter of the Association for Computational Linguistics: Human Language Technologies, NAACL-HLT 2018, New Orleans, Louisiana, USA, June 1-6, 2018, Volume 1 (Long Papers), pp. 1112-1122. Association for Computational Linguistics, 2018. doi: 10.18653/v1/n18-1101. URL https://doi.org/10.18653/v1/n18-1101.2, 15
267
+ Manzil Zaheer, Guru Guruganesh, Kumar Avinava Dubey, Joshua Ainslie, Chris Alberti, Santiago Ontañón, Philip Pham, Anirudh Ravula, Qifan Wang, Li Yang, and Amr Ahmed. Big bird: Transformers for longer sequences. In Hugo Larochelle, Marc'Aurelio Ranzato, Raia Hadsell, MariaFlorina Balcan, and Hsuan-Tien Lin (eds.), Advances in Neural Information Processing Systems 33: Annual Conference on Neural Information Processing Systems 2020, NeurIPS 2020, December 6-12, 2020, virtual, 2020. URL https://proceedings.neurips.cc/paper/ 2020/biticalc/c8512d142a2d849725f31a9a7a361ab9-Abstract.html.1,3
268
+ Peiyuan Zhang, Guangtao Zeng, Tianduo Wang, and Wei Lu. Tinyllama, Sep 2023. URL https://github.com/jzhang38/TinyLlama.21
269
+ Susan Zhang, Stephen Roller, Naman Goyal, Mikel Artetxe, Moya Chen, Shuohui Chen, Christopher Dewan, Mona T. Diab, Xian Li, Xi Victoria Lin, Todor Mihaylov, Myle Ott, Sam Shleifer, Kurt Shuster, Daniel Simig, Punit Singh Koura, Anjali Sridhar, Tianlu Wang, and Luke Zettlemoyer. OPT: open pre-trained transformer language models. CoRR, abs/2205.01068, 2022. doi: 10.48550/arXiv.2205.01068. URL https://doi.org/10.48550/arXiv.2205.01068. 2, 7, 14, 16, 18
270
+
271
+ # A APPENDIX
272
+
273
+ # A.1 EFFICIENCY MEASURES OF SEA ATTENTION
274
+
275
+ Table A.1: VRAM usage comparison between baseline and SEA attention. The unit is MB, lower is better. Each column represents a different token length setting on random inputs.
276
+
277
+ <table><tr><td></td><td>4,096</td><td>8,192</td><td>16,384</td><td>32,768</td><td>65,536</td><td>131,072</td><td>Avg.</td></tr><tr><td>Vanilla</td><td>134.00</td><td>524.00</td><td>2072.00</td><td>OOM</td><td>OOM</td><td>OOM</td><td>OOM</td></tr><tr><td>FlashAttention</td><td>6.00</td><td>12.00</td><td>24.00</td><td>48.00</td><td>96.00</td><td>192.00</td><td>63.00</td></tr><tr><td>Performer</td><td>11.66</td><td>23.29</td><td>46.54</td><td>93.04</td><td>186.04</td><td>372.04</td><td>122.10</td></tr><tr><td>Sinkhorn</td><td>20.03</td><td>40.09</td><td>80.32</td><td>161.15</td><td>324.26</td><td>656.50</td><td>213.73</td></tr><tr><td>Cosformer</td><td>28.14</td><td>56.16</td><td>112.19</td><td>224.25</td><td>448.47</td><td>897.12</td><td>294.39</td></tr><tr><td>Reformer</td><td>218.65</td><td>469.26</td><td>1066.72</td><td>2645.03</td><td>7338.06</td><td>OOM</td><td>OOM</td></tr><tr><td>Synthesizer</td><td>134.02</td><td>524.04</td><td>2072.08</td><td>OOM</td><td>OOM</td><td>OOM</td><td>OOM</td></tr><tr><td>Ours (k=32)</td><td>48.64</td><td>97.35</td><td>195.00</td><td>391.19</td><td>786.86</td><td>1684.79</td><td>533.97</td></tr><tr><td>Ours (k=64)</td><td>49.75</td><td>99.39</td><td>198.76</td><td>397.55</td><td>795.14</td><td>1684.79</td><td>537.56</td></tr><tr><td>Ours (k=128)</td><td>54.84</td><td>109.47</td><td>218.77</td><td>437.55</td><td>875.08</td><td>1751.71</td><td>574.57</td></tr></table>
278
+
279
+ Table A.2: Latency comparison between baseline and SEA attention. The unit is milliseconds per iteration, lower is better. Each column represents a different token length setting on random inputs.
280
+
281
+ <table><tr><td></td><td>4,096</td><td>8,192</td><td>16,384</td><td>32,768</td><td>65,536</td><td>131,072</td><td>Avg.</td></tr><tr><td>Vanilla</td><td>1.66</td><td>8.61</td><td>35.66</td><td>OOM</td><td>OOM</td><td>OOM</td><td>OOM</td></tr><tr><td>Performer</td><td>0.25</td><td>0.49</td><td>0.90</td><td>2.00</td><td>4.25</td><td>10.94</td><td>3.14</td></tr><tr><td>Cosformer</td><td>0.36</td><td>0.73</td><td>1.49</td><td>2.94</td><td>6.28</td><td>12.82</td><td>4.10</td></tr><tr><td>Sinkhorn</td><td>0.21</td><td>0.44</td><td>1.00</td><td>2.41</td><td>6.42</td><td>18.68</td><td>4.86</td></tr><tr><td>FlashAttention</td><td>1.30</td><td>5.17</td><td>20.57</td><td>81.73</td><td>330.19</td><td>1348.04</td><td>297.83</td></tr><tr><td>Reformer</td><td>2.33</td><td>5.26</td><td>12.24</td><td>29.94</td><td>83.41</td><td>OOM</td><td>OOM</td></tr><tr><td>Synthesizer</td><td>1.53</td><td>8.04</td><td>32.42</td><td>OOM</td><td>OOM</td><td>OOM</td><td>OOM</td></tr><tr><td>Ours (k=32)</td><td>1.45</td><td>3.07</td><td>6.21</td><td>12.00</td><td>25.74</td><td>50.89</td><td>16.56</td></tr><tr><td>Ours (k=64)</td><td>1.77</td><td>3.69</td><td>7.40</td><td>13.46</td><td>28.74</td><td>56.46</td><td>18.59</td></tr><tr><td>Ours (k=128)</td><td>2.39</td><td>4.89</td><td>9.81</td><td>16.49</td><td>37.94</td><td>72.59</td><td>24.02</td></tr></table>
282
+
283
+ In this section, we show detailed results of efficiency measurements from SEA attention. We tested various sequence lengths with various attention methods: none (Vanilla), Sinkhorn (Tay et al., 2020b), Cosformer (Qin et al., 2022), Performer (Choromanski et al., 2021), Reformer(Kitaev et al., 2020), FlashAttention (Dao et al., 2022) and Synthesizer (Tay et al., 2020a). The test is performed in the bidirectional self-attention setting. We use $K = 128$ for SEA attention. We show memory usages in Table A.1, and we show latencies in Table A.2. We execute all benchmarks on the same machine with the same resources. Our test environment is built with Ryzen 3950x, RTX 2080ti on 8x PCIe 3.0, DDR4-2400 64GB, and Ubuntu 22.04. The versions of third-party libraries including PyTorch and Triton are described in the supplementary file, requirements.txt. Also, we provide the docker environment of our experiment environment for reproducing results, done with the supplementary file, DockerFile.
284
+
285
+ # A.2 ESTIMATED ATTENTION VISUALIZATION OF SEA ATTENTION
286
+
287
+ We show a more detailed attention estimation visualization in Figs. A.1 and A.2. We visualize teacher ground truth attention, estimated attention, student attention before masking, and student sparse attention after masking for each layer and head of BERT-base (Devlin et al., 2019) and OPT-125m (Zhang et al., 2022).
288
+
289
+ ![](images/a7bf889e3dff075df52ee91f47f89cf132d2e75c6121de5516c22dff58ace03b.jpg)
290
+ (a) Attention matrices of the first 6 layers
291
+ (b) Attention matrices of the last 6 layers
292
+ Figure A.1: Visualization of intermediate attention matrix buffers in SEA attention of BERT-base (Devlin et al., 2019) on MNLI (Williams et al., 2018). We visualize teacher ground truth attention, estimated attention, student attention before masking, and sparse student attention for each layer and head, with $k = 13$ . Each group of rows shows attention matrices from one layer. We stack the visualization layer by layer vertically, from top to bottom, while showing all heads in each particular layer horizontally, from left to right. We show the first 6 layers in Fig. A.1a and last 6 layers in Fig. A.1b. Best viewed with high zoom.
293
+
294
+ ![](images/a12d315ab9f617add5afc2d2e3ab368b8533d94bed08a26cd61f680578b80920.jpg)
295
+ (a) Attention matrices of the first 6 layers
296
+ Figure A.2: Visualization of intermediate attention matrix buffers in SEA attention of OPT-125 (Zhang et al., 2022) on Wikitext2 (Merit et al., 2017). We visualize intermediate buffer samples from attention matrices here, the same way as Fig. A.1. We show the first 6 layers in Fig. A.2a and last 6 layers in Fig. A.2b. Best viewed with high zoom.
297
+
298
+ ![](images/65db3971116c4704464bfb30f5dccc6e226e16eb73ab9aadf179f15353b184d1.jpg)
299
+ (b) Attention matrices of the last 6 layers
300
+
301
+ # A.3 VISUALIZATION OF THE MASKING PROCESS
302
+
303
+ ![](images/a7ac458897b38619298a3a7da254f5693dde566751a0b8d3cffc88a6e54031c5.jpg)
304
+ Figure A.3: Visualization of masking process intermediate buffers during attention estimation in compressed size and sparse interpolation for performing sparse attention.
305
+
306
+ In Fig. A.3, we visualize the intermediate buffers for masking sparse attention using $M^{*}$ for better understanding. The example is sampled from OPT-125M, which uses causal attention. We show the process to perform sparse attention using the mask $M^{*}$ estimated with compressed attention matrix estimation $\hat{A}$ . In the visualization, we differentiate binary masks and real buffers by using black-and-white and red-and-black color schemes. For note, the sparse matrices $M^{*}$ and $A^{*}$ are converted into dense matrices format in order to render the image. Black represents zero-valued pixels, which are not stored in memory. Since the visualized attention mechanism is causal attention, each row of the compressed estimation $\hat{A}$ and $\hat{M}$ is resized with different target widths according to the token index in $M^{*}$ and $A^{*}$ .
307
+
308
+ # A.4 EXPERIMENT DETAILS
309
+
310
+ # A.4.1 TRAINING HYPERPARAMETERS
311
+
312
+ <table><tr><td>Dataset</td><td>MNLI</td><td>COLA</td><td>MRPC</td><td>Wikitext2</td></tr><tr><td>Batch Size</td><td>16</td><td>64</td><td>32</td><td>32</td></tr></table>
313
+
314
+ Table A.3: Batch sizes for various datasets in our experiments shown in Section 4
315
+
316
+ <table><tr><td>Loss Name</td><td>KL of Lapprox</td><td>MSE of Lapprox</td><td>KL of Lprob</td><td>MSE of Lprob</td><td>Lcontext</td><td>Lkd</td><td>Lsea(i)</td><td>Lkd_task</td><td>Ltask</td></tr><tr><td>Weight</td><td>0.1</td><td>1.0</td><td>0.1</td><td>1.0</td><td>1.0</td><td>5.0</td><td>1.0</td><td>0.2</td><td>0.1</td></tr></table>
317
+
318
+ Table A.4: Loss weights for different loss terms defined in Section 3.2
319
+
320
+ Batch sizes for our experiments outlined in Section 4, can be seen in Table A.3, We define different learning rate values for original parameters and SEA attention parameters. We use learning rate $10^{-5}$ for original parameter, and $10^{-4}$ for SEA attention parameters. For OPT models, we use a learning rate $2 * 10^{-6}$ for the original parameter and $10^{-4}$ for SEA attention parameters. Weights for loss scaling outlined in Section 3.2 can be seen in Table A.4.
321
+
322
+ # A.4.2 GLUE
323
+
324
+ We test SEA attention with settings $k \in \{7, 13, 25\}$ and $K \in \{32, 64, 128\}$ . We changed the bucket size to match the sparsity constraint in Reformer and Sinkhorn and the number of base projection feature sizes in Performer. We test attention methods within the fixed sequence length (256) to
325
+
326
+ measure latency and memory usage. We train all methods, 20 epochs in MNLI and 50 epochs in COLA and MRPC.
327
+
328
+ # A.5 IMPLEMENTATION DETAILS
329
+
330
+ # A.5.1 ATTENTION ESTIMATOR CNN
331
+
332
+ Before arriving at the attention estimator CNN, there are two MLP's $\mu : \mathbb{R}^{3d} \mapsto \mathbb{R}^{d'}$ and $\nu : \mathbb{R}^{d'} \mapsto \mathbb{R}^{d'} \mapsto \mathbb{R}^{Kc_h / c_s}$ which projects the kernel-based attention output such that $\hat{\pmb{Z}} = \nu(\mu(\pmb{V}_{\mathrm{cat}}')) \in \mathbb{R}^{H \times T \times Kc_h / c_s}$ . This is then transposed and resized to be $\in \mathbb{R}^{Hc_h \times T \times K / c_s}$ as explained in Section 3.1. $\nu$ expands the channel dimension to and reduces the width hidden state Empirically, we found that the channel expansion helps the CNN learn a better encoding, and the size reduction reduces the overall computation cost of the CNN. In our experiments, we set $c_s = 2$ and $c_h = 4$ . After obtaining $\hat{\pmb{Z}}$ , we decode it using the 3-layer CNN. The first convolution layer reduces height by $c_s$ using kernel size 3; $f_{\mathrm{dec}}^{(1)} : \mathbb{R}^{H*c_h \times T \times K / c_s} \mapsto \mathbb{R}^{H*c_h \times T / c_s \times K / c_s}$ . The second layer performs another convolution using a kernel size of 3; $f_{\mathrm{dec}}^{(2)} : \mathbb{R}^{H*c_h \times T / c_s \times K / c_s} \mapsto \mathbb{R}^{H*c_h \times T / c_s \times K / c_s}$ . Then we resize the hidden state using the nearest neighbor interpolation to make the output $\mathbb{R}^{H*c_h \times T \times K}$ . The last layer changes the channel into the number of heads; $f_{\mathrm{dec}}^{(3)} : \mathbb{R}^{H*c_h \times T \times K} \mapsto \mathbb{R}^{H \times T \times K}$ . Lastly, we perform a softmax operation, finally obtaining $\hat{\pmb{A}}$ . In causal attention, we do not reduce the height. We only reduce the width to reduce computation. If one needs a deeper CNN, then the second layer can be duplicated multiple times. Additionally, when applying SEA on large scale pretrained language models such as OPT (Zhang et al., 2022), $\mu$ accepts a token embedding $\mathbb{R}^{H*3d}$ instead of the single head embedding $\mathbb{R}^{3d}$ so that it may learn information across the large group of attention heads. For causal attention, we change $\pmb{V}_I$ into a learnable positional embedding and use a causal CNN (van den Oord et al., 2016) to satisfy to the causality condition, see Appendix A.5.1 for details. The implementation of the CNN can be found in the supplementary file at: src.models.perlinattention.attention.PerlinAttention.
333
+
334
+ # A.5.2 FLATCSR: MODIFIED CSR FORMAT TO HANDLE GROUPED MASK
335
+
336
+ Here, we provide a detailed explanation of our novel sparse operation, FlatCSR. Our initial attempt for the sparse operations in our model utilized the Coordinate List (COO) sparse format. However, COO is not ideal, as storing full coordinates for every point in a sparse matrix makes the per-row computations difficult since each row must be identified and constructed from raw coordinates, as shown in Table 3. Therefore, we eventually adopted the CSR sparse format instead of COO, as it uses less memory and schedules the per-row computations wisely using pre-constructed rows. However, when it comes to causal-per-batch, which is our recommended setting in most cases, there exists a challenge with the non-contiguous top- $k$ grouping in the attention matrix since it requires flattening the head and query dimensions. Therefore, we propose a specialized CSR tensor operation, called FlatCSR, utilizing the Triton compiler which compiles Python code into low-level CUDA kernel binary (Tillet et al., 2019). FlatCSR is capable of handling non-contiguous flattened tasks within the GPU kernel. In this paper, we implement FlatCSR only for causal per-batch. We note, however, that we expect the same number of non-zero entries in each of the top- $k$ strategies depicted in Fig. 4, and therefore all strategies should show the same memory usage and latency.
337
+
338
+ We implement the interpolation and attention operations for the causal-per-batch grouping described in Section 3.1 in a sparse CSR tensor by transposing the head and query dimensions and flattening the interpolated attention matrix's last two dimensions (the head and key dimension). Ideally, we can store our attention mask with the CSR tensor because we have a similar number of non-zero entries per row (query) and the same number of non-zero entries per batch. We name this CSR tensor of transposed and flattened attention mask the FlatCSR tensor in this paper. However, to use this FlatCSR tensor in linear algebra operations, we must reshape and transpose the CSR tensor. Therefore, we implement a new GPU kernel that internally performs reshape and transposes from the FlatCSR using Triton (Tillet et al., 2019). We heavily utilize the property that every row (query) has a similar number of non-zero entries (approximated as $k$ ) during memory allocation and thread scheduling. Therefore, we can be more efficient in terms of memory and computation than the COO tensor type, which is generally used in sparse tensor computation.
339
+
340
+ # A.5.3 SPARSE INTERPOLATION
341
+
342
+ In this section, we describe the details of sparse interpolation from $\hat{M}$ to $M^{*}$ . We interpolate $\hat{M} \in \{0,1\}^{T \times K}$ into $M^{*} \in \{0,1\}^{T \times T}$ as described in Section 3.1. We claimed that the complexity of this interpolation is $\mathcal{O}(T)$ . However, if we perform the interpolation of the $\hat{M}$ in a dense matrix format, the complexity should be $\mathcal{O}(T^2)$ . Since we perform the interpolation in a sparse matrix format, we only need to calculate the interpolation of non-zero entries in $\hat{M}$ . This is possible because we interpolate binary masks using nearest-neighbor as there is no requirement for linear or non-linear interpolation between pixels. The nearest neighbor interpolation is independent of other nearby pixel values and only depends on pixel indices, which are stored in the sparse matrix format. This allows us to perform interpolation within $\mathcal{O}$ (number of non-zero entries after interpolation to $M^{*}$ ) complexity. We adjust the sparsity of $\hat{M}$ (which is determined by $\hat{k}$ ) to make $M^{*}$ have a constant number of non-zero entries ( $T * k$ ). As a result, we always know how many pixels are in $M^{*}$ and that the number of pixels is $\mathcal{O}(T)$ . In summary, the only thing we need to do interpolation is iterate every non-zero pixel in $\hat{M}$ and duplicate or reduce the number of pixels which are output to $M^{*}$ depending on the pixel location in $\hat{M}$ and the ratio between $T$ , $K$ .
343
+
344
+ However, to keep the linear complexity of sparse interpolation we need to deal with the case that $kK < T$ or in other words $kK / T < 1$ . This case is important because if this occurs, then $\hat{k} = \max(1, \text{round}(k*K / T))$ will be evaluated to 1 since we always must select at least one pixel from $\hat{A}$ . If we interpolate the $\hat{M}$ in that case, then each pixel replication of the non-zero entries in $\hat{M}$ should be limited to $k$ . The reason is that we set the lower bound of $\hat{k}$ into 1 to avoid an empty attention mask when $\hat{k}$ is zero after rounding because $T$ is much larger than $K$ . However, in that case, a single pixel in $\hat{M}$ will be $\lceil T / K \rceil$ after replication, and the total number of non-zero entries in $M^*$ will be quadratic. We can solve the problem by limiting the upper bound of pixel replications to $k^* = \min(k, \lceil T / K \rceil)$ because the $\hat{k}$ is always 1. However in this case we will encounter how we select $k^*$ pixels among $\lceil T / K \rceil$ pixels because the originally selected pixel in $\hat{M}$ covers $\lceil T / K \rceil$ pixels in $M^*$ . In this paper, we decided to sample uniformly.
345
+
346
+ However, we think uniformly sampling the attention relations among block regions is not ideal because there is a high chance of not selecting higher probability attention relations because a uniform sample does not consider the distribution of attention probability. We would be interested in seeing future research that deals with this case, which is what we expect to happen more often in the future as LLMs keep increasing their context length (OPT (2022)'s context length: 2048, LLaMA2 (2023)'s context length: 4096).
347
+
348
+ # A.6 FLOPS COMPARISON
349
+
350
+ ![](images/9331974ceddef93d11a7c326fcda93d9f4cfda69500d2840df4649dc46aeec8e.jpg)
351
+ Figure A.4: FLOPs comparison with SEA and quadratic attention.
352
+
353
+ We compute the FLOPs of our SEA attention and quadratic attention with different hyperparameters ( $k = 32, 64, 128, K = 128$ ) in Fig. A.4. SEA shows clear linear computational complexity. However, the original attention mechanism shows a drastic increase in computational cost on longer context length due to quadratic complexity. The figure shows only FLOPs and arithmetic operations.
354
+
355
+ Therefore, this tendency is the ideal latency complexity of our method and means that there is plenty of room for improvement in implementation.
356
+
357
+ # A.7 DISCUSSION ABOUT DIFFERENCE BETWEEN SEA AND FLASHATTENTION
358
+
359
+ In Fig. 8, we show two quadratic attention baselines, vanilla, and FlashAttention (Dao et al., 2022). While FlashAttention consumes memory linearly, it scales quadratically in terms of computation complexity. FlashAttention is an efficient implementation of original quadratic attention that eliminates most of the memory space and bandwidth requirement of the attention mechanism by fusing attention probability calculation and context vector calculation. FlashAttention has linear memory complexity and quadratic time complexity because it does not require space for storing attention score matrix to compute softmax probability. The lack of attention probability storage is an advantage in terms of memory bandwidth consumption. However, this characteristic may be a downside when attention probability is required in usage scenarios where we are concerned, such as token importance analysis for token compression. Therefore, FlashAttention has some of the same limitations as previous linear attention methods. However, our SEA attention does not have such limitations by providing an estimated attention matrix, while showing linear complexity in both memory and computation.
360
+
361
+ # A.8 EVALUATION OF SEA ON LONGER CONTEXT MODEL
362
+
363
+ Table A.5: Evaluation result of context length extension from 2048 to 4096 on WikiText2. The reformer was not included in this experiment due to the already poor performance seen in Table 2
364
+
365
+ <table><tr><td rowspan="2">Method</td><td colspan="4">OPT-125M</td></tr><tr><td>PPL. (after interp.) ↓</td><td>PPL. (trained) ↓</td><td>Memory (MB) ↓</td><td>Latency (ms) ↓</td></tr><tr><td>Vanilla</td><td>52.96</td><td>18.96</td><td>1584</td><td>17.86</td></tr><tr><td>Performer</td><td>68.29 (+15.33)</td><td>62.40 (+43.44)</td><td>102.75 (6.48%)</td><td>2.38 (13.32%)</td></tr><tr><td>SEA (Ours)</td><td>43.96 (-9.00)</td><td>23.43 (+4.47)</td><td>448 (28.28%)</td><td>14.31 (80.12%)</td></tr></table>
366
+
367
+ We evaluate our method with a longer context on Wikitext2. However, OPT only supports context lengths up to 2048, therefore we used positional embedding interpolation that was introduced in previous work (Dosovitskiy et al., 2021), using bilinear interpolation. After interpolating the positional embedding, we perform a few optimization steps (750 steps, 1.5M tokens) on the model with the causal language modeling task loss. In longer context length, 4096, our method outperforms quadratic attention in both latency and memory cost. Also, the experiment result shows our model is much stronger than baselines after positional embedding interpolation. This result is interesting, as we think this shows that sparse attention masking helps to preserve the important attention relations by masking out non-important attention relations. We picked the SEA-OPT result from Table A.5, and details are following.
368
+
369
+ Table A.6: The trade off on long context ( $T = 4096$ ) experiment on Wikitext2 using post training compression techniques: Query skipping and dynamic k control. Each entry of table shows PPL (ms/MB). Each values are colored with green and red. Better values are more green, and worse values are more red.
370
+
371
+ <table><tr><td>Dynamic-k
372
+ Query Skips</td><td>96</td><td>104</td><td>112</td><td>120</td><td>128</td></tr><tr><td>16</td><td>23.43 (14.31 / 448.37)</td><td>23.00 (14.70 / 455.65)</td><td>22.63 (15.40 / 463.06)</td><td>22.34 (16.06 / 470.28)</td><td>22.11 (16.65 / 477.59)</td></tr><tr><td>8</td><td>23.26 (14.61 / 448.37)</td><td>22.82 (15.28 / 455.65)</td><td>22.48 (15.74 / 463.06)</td><td>22.20 (16.35 / 470.28)</td><td>21.98 (16.97 / 477.59)</td></tr><tr><td>4</td><td>23.02 (15.33 / 448.37)</td><td>22.60 (15.85 / 455.65)</td><td>22.29 (16.46 / 463.06)</td><td>22.02 (17.03 / 470.28)</td><td>21.83 (17.59 / 477.59)</td></tr><tr><td>2</td><td>22.73 (16.35 / 448.37)</td><td>22.33 (16.86 / 455.65)</td><td>22.02 (17.50 / 463.06)</td><td>21.78 (18.08 / 470.28)</td><td>21.58 (18.64 / 477.58)</td></tr><tr><td>1</td><td>22.38 (18.12 / 448.35)</td><td>22.04 (18.68 / 455.65)</td><td>21.76 (19.31 / 462.98)</td><td>21.55 (19.92 / 470.19)</td><td>21.38 (20.47 / 477.54)</td></tr></table>
373
+
374
+ In Table A.5, we show the performance trade of the longer context model using our post-training compression techniques: query skipping and dynamic k control. We newly introduce the query skipping in this section. Query skipping is skipping rows before CNN inputs, and replicating rows after CNN, reducing the cost of the CNN decoder. We trained the OPT-125m with self distillation setting because we do not have a properly trained 4k OPT model, therefore we use itself as a KD
375
+
376
+ teacher. Also in this experiment we use $k = 128$ , $K = 96$ to train efficiently on longer sequence length. On each transformer layer, we use input $Q$ , $K$ as a source of the teacher attention matrix. For computing self teacher attention matrix, we cut the gradient of each $Q$ , $K$ to prevent training from oscillating and exploding due to self feedback loop of the gradient. In Table A.5, the model shows better latency and less memory consumption toward top-left, and gets closer to original model performance toward bottom-right.
377
+
378
+ # A.9 EVALUATION OF SEA ON LARGER DATASET
379
+
380
+ Table A.7: Evaluation result on OpenWebText.
381
+
382
+ <table><tr><td rowspan="2">Method</td><td colspan="3">OPT-125M</td></tr><tr><td>PPL. ↓</td><td>Mem. ↓</td><td>Lat. ↓</td></tr><tr><td>Vanilla</td><td>19.82</td><td>408</td><td>4.88</td></tr><tr><td>Performer</td><td>61.20 (+41.38)</td><td>51</td><td>1.21</td></tr><tr><td>SEA (Ours)</td><td>22.64 (+2.82)</td><td>187</td><td>6.76</td></tr></table>
383
+
384
+ ![](images/360f76ed457e2d24bad6ce707c89afb119927962bcd2d178ed0e2cc7e6b05916.jpg)
385
+ Figure A.5: Validation curves for SEA and Performer, when trained with OpenWebtext dataset. SEA converges much faster compared to Performer.
386
+
387
+ In Table A.7, we evaluate our method with the larger OpenWebText (Gokaslan et al., 2019) dataset. With a given training budget our method still outperforms the baseline, Performer. In this large-scale dataset, Performer shows much poorer approximation performance than our method. We train the models only 10k optimizer step, which is equivalent to 640M tokens. Considering the fact that LLMs are often trained with over 1T tokens (Zhang et al., 2023), we preserve most of the teacher performance with only $0.064\%$ training cost of the teacher's pretraining, while also reducing computational complexity from quadratic to linear. Moreover, as shown in Fig. A.5, SEA converges much faster compared to Performer, and the difference is even larger than Fig. 5b, where Wikitext2 dataset was used for training.
388
+
389
+ # A.10 DETAILED DIAGRAM OF MODEL STRUCTURE
390
+
391
+ ![](images/89bf78ad0818e5ede95487bbaf83f80008acf19e2c5fb2cbf1f59872e579c8c9.jpg)
392
+ Figure A.6: Model diagram of our proposed linear attention method, SEA, during inference.
393
+
394
+ In Fig. 2, we provide high-level overview of our method structure. And in this section, we provide a much more detailed model diagram with more notations in Fig. A.6. In the figure, (1) SEA estimates
395
+
396
+ the attention matrix in a compressed size $(\hat{A} \in \mathbb{R}^{T \times K})$ . (2a) We then perform a top- $k$ selection procedure from the compressed attention matrix resulting in a compressed attention mask, and (2b) interpolate the compressed attention mask to a sparse formatted mask for the full attention matrix. (2c) Finally, we perform sparse attention.
397
+
398
+ # A.11 DETAILED RESULT OF SEA ON MNLI
399
+
400
+ Table A.8: Comparison with MNLI dataset of GLUE benchmark (Wang et al., 2019) among linear attention methods. Vanilla quadratic attention is included for reference. SEA (Ours) is trained with $K = 32$ and $k = 25$ .
401
+
402
+ <table><tr><td>Metric</td><td>Vanilla</td><td>SEA (Ours)</td><td>Cosformer</td><td>Reformer</td><td>Sinkhorn</td><td>Synthesizer</td><td>Performer</td></tr><tr><td>Accuracy</td><td>84.1</td><td>84.0</td><td>82.7</td><td>82.5</td><td>81.9</td><td>75.5</td><td>74.7</td></tr><tr><td>Memory (MB)</td><td>9.00</td><td>17.17</td><td>10.88</td><td>88.36</td><td>9.39</td><td>8.25</td><td>14.76</td></tr><tr><td>Latency (μs)</td><td>238</td><td>701</td><td>242</td><td>900</td><td>152</td><td>181</td><td>320</td></tr></table>
403
+
404
+ In Table A.8, we provide the detailed result of SEA on MNLI which is the subset of the GLUE benchmark.
405
+
406
+ # A.12 DISCUSSION ABOUT THE LATENCY OF OUR FLATCSR IMPLEMENTATION
407
+
408
+ We think there is room for further optimization of FlatCSR in order to further reduce latencies. Theoretically, dense operations cost 43.96 GMACs, and sparse FlatCSR operation costs 1.25 GMACs, as shown in Fig. A.4; this means our kernel implementation does not fully utilize MACs and is therefore bottle-necked on memory computation and thread scheduling. Furthermore, we need to utilize block aligns in the sparse interpolation of the mask from $\hat{M}$ to $M^{*}$ . Since we are using the nearest neighborhood interpolation and we mostly interpolate the attention estimation from a relatively smaller size, $K$ , to a larger size $T$ , a single non-zero pixel in the compressed mask will be multiple pixels in resized one. We may utilize this fact to schedule threads with blocks like other famous block-sparse attention implementations including FlashAttention Dao et al. (2022). Therefore, further research could look to investigating and optimizing thread scheduling and cache hit ratios of the proposed FlatCSR. However, we think the implementation with Triton is sufficient to show the efficiency of the proposed SEA attention.
2024/SEA_ Sparse Linear Attention with Estimated Attention Mask/images.zip ADDED
@@ -0,0 +1,3 @@
 
 
 
 
1
+ version https://git-lfs.github.com/spec/v1
2
+ oid sha256:0764cbdbf8850890acd30de9eaf0d03d7501897414d78dcd9daff2bebbc75184
3
+ size 1409760
2024/SEA_ Sparse Linear Attention with Estimated Attention Mask/layout.json ADDED
The diff for this file is too large to render. See raw diff
 
2024/SEINE_ Short-to-Long Video Diffusion Model for Generative Transition and Prediction/4e0669d7-b95d-4ff4-97bd-d87bb4ad89af_content_list.json ADDED
@@ -0,0 +1,1706 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ [
2
+ {
3
+ "type": "text",
4
+ "text": "SEINE: SHORT-TO-LONG VIDEO DIFFUSION MODEL FOR GENERATIVE TRANSITION AND PREDICTION",
5
+ "text_level": 1,
6
+ "bbox": [
7
+ 171,
8
+ 98,
9
+ 823,
10
+ 148
11
+ ],
12
+ "page_idx": 0
13
+ },
14
+ {
15
+ "type": "text",
16
+ "text": "Xinyuan Chen $^{1*}$ Yaohui Wang $^{1*}$ Lingjun Zhang $^{2,1‡}$ Shaobin Zhuang $^{1,3}$",
17
+ "bbox": [
18
+ 184,
19
+ 167,
20
+ 709,
21
+ 184
22
+ ],
23
+ "page_idx": 0
24
+ },
25
+ {
26
+ "type": "text",
27
+ "text": "Xin Ma $^{4,1\\ddagger}$ Jiashuo Yu $^{1}$ Yali Wang $^{5,1}$ Dahua Lin $^{1\\dagger}$ Yu Qiao $^{1\\dagger}$ Ziwei Liu $^{6\\dagger}$",
28
+ "bbox": [
29
+ 184,
30
+ 184,
31
+ 733,
32
+ 199
33
+ ],
34
+ "page_idx": 0
35
+ },
36
+ {
37
+ "type": "list",
38
+ "sub_type": "text",
39
+ "list_items": [
40
+ "<sup>1</sup> Shanghai Artificial Intelligence Laboratory, <sup>2</sup> East China Normal University",
41
+ "$^{3}$ Shanghai Jiao Tong University, $^{4}$ Dept of Data Science & AI, Monash University",
42
+ "5 Shenzhen Institute of Advanced Technology, Chinese Academy of Sciences",
43
+ "$^{6}$ S-Lab, Nanyang Technological University"
44
+ ],
45
+ "bbox": [
46
+ 181,
47
+ 199,
48
+ 723,
49
+ 258
50
+ ],
51
+ "page_idx": 0
52
+ },
53
+ {
54
+ "type": "text",
55
+ "text": "ABSTRACT",
56
+ "text_level": 1,
57
+ "bbox": [
58
+ 450,
59
+ 295,
60
+ 545,
61
+ 309
62
+ ],
63
+ "page_idx": 0
64
+ },
65
+ {
66
+ "type": "text",
67
+ "text": "Recently video generation has achieved substantial progress with realistic results. Nevertheless, existing AI-generated videos are usually very short clips (\"shot-level\") depicting a single scene. To deliver a coherent long video (\"story-level\"), it is desirable to have creative transition and prediction effects across different clips. This paper presents a short-to-long (S2L) video diffusion model, SEINE, that focuses on generative transition and prediction. The goal is to generate high-quality long videos with smooth and creative transitions between scenes and varying lengths of shot-level videos. Specifically, we propose a random-mask video diffusion model to automatically generate transitions based on textual descriptions. By providing the images of different scenes as inputs, combined with text-based control, our model generates transition videos that ensure coherence and visual quality. Furthermore, the model can be readily extended to various tasks such as image-to-video animation and auto-regressive video prediction. To conduct a comprehensive evaluation of this new generative task, we propose three assessing criteria for smooth and creative transition: temporal consistency, semantic similarity, and video-text semantic alignment. Extensive experiments validate the effectiveness of our approach over existing methods for generative transition and prediction, enabling the creation of story-level long videos. Project page: https://vchitec.github.io/SEINE-project/.",
68
+ "bbox": [
69
+ 228,
70
+ 325,
71
+ 767,
72
+ 592
73
+ ],
74
+ "page_idx": 0
75
+ },
76
+ {
77
+ "type": "text",
78
+ "text": "Animation: a dog in spacesuit.",
79
+ "bbox": [
80
+ 620,
81
+ 705,
82
+ 810,
83
+ 719
84
+ ],
85
+ "page_idx": 0
86
+ },
87
+ {
88
+ "type": "image",
89
+ "img_path": "images/5c8068ba2d161bb81800b6191a16cbdcabed2c53676d2909492f27aec693c8c0.jpg",
90
+ "image_caption": [
91
+ "Transition: The panda is working in the office and reading a paper",
92
+ "Figure 1: Generated samples. Our S2L model is able to synthesize high-definition transition (shown in the left two columns) and prediction videos (shown in the right column) by giving textual descriptions. Best view with Acrobat Reader. Click the images to play the videos."
93
+ ],
94
+ "image_footnote": [],
95
+ "bbox": [
96
+ 173,
97
+ 744,
98
+ 308,
99
+ 811
100
+ ],
101
+ "page_idx": 0
102
+ },
103
+ {
104
+ "type": "image",
105
+ "img_path": "images/ffefc3edcf9863ec81e9429db19026b0ab569934f8447e130bc62935b49d0bd2.jpg",
106
+ "image_caption": [],
107
+ "image_footnote": [],
108
+ "bbox": [
109
+ 310,
110
+ 744,
111
+ 446,
112
+ 811
113
+ ],
114
+ "page_idx": 0
115
+ },
116
+ {
117
+ "type": "image",
118
+ "img_path": "images/ac38c6c6e4165f273e967657c0842bf8891b2cf8df770bc338d5a1c1dc86fced.jpg",
119
+ "image_caption": [
120
+ "Transition: Spider-man becomes a sand sculpture."
121
+ ],
122
+ "image_footnote": [],
123
+ "bbox": [
124
+ 450,
125
+ 744,
126
+ 534,
127
+ 811
128
+ ],
129
+ "page_idx": 0
130
+ },
131
+ {
132
+ "type": "image",
133
+ "img_path": "images/44baffd3873004fdee343a6400b1048ba300a3afac511b78b535105ea506b1dc.jpg",
134
+ "image_caption": [
135
+ "Prediction: Iron Man flying in the sky."
136
+ ],
137
+ "image_footnote": [],
138
+ "bbox": [
139
+ 535,
140
+ 744,
141
+ 620,
142
+ 811
143
+ ],
144
+ "page_idx": 0
145
+ },
146
+ {
147
+ "type": "header",
148
+ "text": "Published as a conference paper at ICLR 2024",
149
+ "bbox": [
150
+ 171,
151
+ 32,
152
+ 478,
153
+ 47
154
+ ],
155
+ "page_idx": 0
156
+ },
157
+ {
158
+ "type": "page_footnote",
159
+ "text": "*Equal contribution. † Correspondence. ‡ Work done as interns at Shanghai AI Laboratory.",
160
+ "bbox": [
161
+ 194,
162
+ 909,
163
+ 732,
164
+ 924
165
+ ],
166
+ "page_idx": 0
167
+ },
168
+ {
169
+ "type": "page_number",
170
+ "text": "1",
171
+ "bbox": [
172
+ 493,
173
+ 948,
174
+ 503,
175
+ 959
176
+ ],
177
+ "page_idx": 0
178
+ },
179
+ {
180
+ "type": "image",
181
+ "img_path": "images/12072b2ded7397f74e858bb16f7ec32beef38a1ca5ebb0e5e5cdac26635c49e1.jpg",
182
+ "image_caption": [
183
+ "Figure 2: Short-to-long (S2L) pipeline. Our S2L video generation model enables the seamless connection of shots from different scenes with transitions and generates videos of varying lengths through autoregressive prediction, facilitating the creation of story-level videos. The red box represents the transition video, while the blue box represents a long video generated through prediction."
184
+ ],
185
+ "image_footnote": [],
186
+ "bbox": [
187
+ 174,
188
+ 99,
189
+ 826,
190
+ 297
191
+ ],
192
+ "page_idx": 1
193
+ },
194
+ {
195
+ "type": "text",
196
+ "text": "1 INTRODUCTION",
197
+ "text_level": 1,
198
+ "bbox": [
199
+ 173,
200
+ 398,
201
+ 336,
202
+ 414
203
+ ],
204
+ "page_idx": 1
205
+ },
206
+ {
207
+ "type": "text",
208
+ "text": "Currently, with the success of diffusion model-based (Ho et al., 2020; Song et al., 2021a;b) text-to-image generation models (Ramesh et al., 2021; 2022; Sahara et al., 2022; Balaji et al., 2022; Rombach et al., 2022), a series of video generation works (Singer et al., 2023; Ho et al., 2022; Blattmann et al., 2023; Zhou et al., 2022; He et al., 2022; Wang et al., 2023b) have emerged and demonstrated impressive results. However, current video generation methods typically only yield \"shot-level\" video generation, which only consists of around a few seconds and depicts a single scene. Such shot-level short videos fall short of the demands for cinematic and film productions.",
209
+ "bbox": [
210
+ 169,
211
+ 436,
212
+ 823,
213
+ 536
214
+ ],
215
+ "page_idx": 1
216
+ },
217
+ {
218
+ "type": "text",
219
+ "text": "In cinematic or industrial-level video productions, \"story-level\" long video is typically characterized by the creation of distinct shots with different scenes. These individual shots of various lengths are interconnected through techniques like transitions and editing, providing a way for longer video and more intricate visual storytelling. The process of combining scenes or shots in film and video editing, known as transition, plays a crucial role in post-production. Traditional transition methods, including dissolves, fades, and wipes, rely on predefined algorithms or established interfaces. However, these methods lack flexibility and are often limited in their capabilities. An alternative approach to achieve seamless and smooth transitions involves the use of diverse and imaginative shots to smoothly connect between scenes. This technique, commonly employed in films, cannot be directly generated using predefined programs. In this work, we present our model to address the less common problem of generating seamless and smooth transitions by focusing on generating intermediate frames between two different scenes. We establish three criteria that the generated transition frames should meet: 1) semantic relevance to the given scene image; 2) coherence and smoothness within frames; and 3) consistency with the provided text.",
220
+ "bbox": [
221
+ 169,
222
+ 541,
223
+ 826,
224
+ 737
225
+ ],
226
+ "page_idx": 1
227
+ },
228
+ {
229
+ "type": "text",
230
+ "text": "In this work, we present a short-to-long (S2L) video diffusion model, SEINE, for generative transition and prediction. The goal is to generate high-quality long videos with smooth and creative transitions between scenes and varying lengths of shot-level videos. The pipeline is shown in Fig. 2. We delve into the study of a new task, \"generative transition\", which aims at producing diverse and creative transition video segments to connect two different scenes. Alongside, we propose an approach to tackle this task and establish criteria for evaluating the efficacy of methods. We approach the problem of transitions as a conditional video generation task. By providing the initial and final frames of a given scene as inputs, we employ a text-based and video conditioning method to generate a smooth transition video in between. This approach allows us to effectively control the transition process and ensure the coherence and visual quality of the generated videos. To this end, we design a flexible random-mask diffusion model. The model is of capable generating transition shots by giving the first frame of one scene and the last frame of another scene, the scene transition is generated by a given textual description. Our model can be extended to image-to-video animation",
231
+ "bbox": [
232
+ 169,
233
+ 743,
234
+ 826,
235
+ 924
236
+ ],
237
+ "page_idx": 1
238
+ },
239
+ {
240
+ "type": "header",
241
+ "text": "Published as a conference paper at ICLR 2024",
242
+ "bbox": [
243
+ 173,
244
+ 32,
245
+ 478,
246
+ 47
247
+ ],
248
+ "page_idx": 1
249
+ },
250
+ {
251
+ "type": "page_number",
252
+ "text": "2",
253
+ "bbox": [
254
+ 493,
255
+ 948,
256
+ 503,
257
+ 959
258
+ ],
259
+ "page_idx": 1
260
+ },
261
+ {
262
+ "type": "text",
263
+ "text": "and autoregressive video prediction, enabling the generation of long-shot videos and dynamic video creation in film production.",
264
+ "bbox": [
265
+ 169,
266
+ 103,
267
+ 823,
268
+ 132
269
+ ],
270
+ "page_idx": 2
271
+ },
272
+ {
273
+ "type": "text",
274
+ "text": "We summarize our contributions as follows: 1) We propose a new problem of generative transition and prediction, aiming at coherent \"story-level\" long video generation with smooth and creative scene transition and varying lengths of videos; 2) We present a short-to-long video diffusion model, SEINE, focusing on generative transition and prediction; 3) we propose three assessing criteria for transition and extensive experiments demonstrate our method the superior performance on the metrics, as well as its ability to be applied across versatile applications.",
275
+ "bbox": [
276
+ 169,
277
+ 138,
278
+ 826,
279
+ 224
280
+ ],
281
+ "page_idx": 2
282
+ },
283
+ {
284
+ "type": "text",
285
+ "text": "2 RELATED WORKS",
286
+ "text_level": 1,
287
+ "bbox": [
288
+ 171,
289
+ 258,
290
+ 354,
291
+ 273
292
+ ],
293
+ "page_idx": 2
294
+ },
295
+ {
296
+ "type": "text",
297
+ "text": "Text-to-Video Generation. In recent years, diffusion models (Ho et al., 2020; Song et al., 2021a;b) have significantly advanced the field of text-to-image (T2I) generation. Existing methods (Ramesh et al., 2021; He et al., 2022; Ramesh et al., 2022; Sahara et al., 2022) have made remarkable progress in generating realistic images that are closely related to textual prompts. Recent advancements in T2I generation have led to the expansion of diffusion models to develop video generation from domain-specific models (Tulyakov et al., 2018; Wang et al., 2020a;b; Tian et al., 2021; Skorokhodov et al., 2022) to general text-to-video (T2V) models. This extension involves adapting the conventional 2D UNet architecture into a spatial-temporal 3D network to establish temporal correlations between video frames. Make-A-Video (Singer et al., 2023) and Imagen Video Ho et al. (2022) leverage text-to-image diffusion models of DALL-E2 (Ramesh et al., 2022) and Imagen (Saharia et al., 2022) respectively for large-scale T2V generation. PYoCo (Ge et al., 2023) presented a noise prior approach and utilized a pre-trained eDiff-I (Balaji et al., 2022) as initialization. An alternative approach involves constructing a T2V model based on pre-trained Stable Diffusion and subsequently fine-tuning the model either entirely (Zhou et al., 2022; He et al., 2022) or partially (Blattmann et al., 2023) on video data. In addition, LaVie (Wang et al., 2023b) fine-tuned the entire T2V model on both image and video datasets. While these methods demonstrate the potential of text-to-video synthesis, they are mostly limited to generating short videos.",
298
+ "bbox": [
299
+ 169,
300
+ 297,
301
+ 826,
302
+ 536
303
+ ],
304
+ "page_idx": 2
305
+ },
306
+ {
307
+ "type": "text",
308
+ "text": "Transition Generation. Scene transition is a less common problem but is crucial in storytelling, serving as the bridge that connects different narrative moments. They facilitate the smooth progression of a story through shifts in time, place, or perspective. Several techniques are employed to achieve effective scene transitions, such as \"fade\", \"dissolves\", \"wipes\", \"IRIS\" or simply cut where a scene abruptly transitions to another. These transitions can be achieved using pre-defined algorithms with fixed patterns. Morphing (Wolberg, 1998; Shechtman et al., 2010) enables smooth transitions involving finding pixel-level similarities and estimating their transitional offsets. Existing generative models (Van Den Oord et al., 2017) can leverage linear interpolation at the latent code level to capture semantic similarities. This approach has been widely explored in various works, e.g., style transfer (Chen et al., 2018), object transfiguration (Sauer et al., 2022; Kang et al., 2023).",
309
+ "bbox": [
310
+ 169,
311
+ 541,
312
+ 823,
313
+ 681
314
+ ],
315
+ "page_idx": 2
316
+ },
317
+ {
318
+ "type": "text",
319
+ "text": "Long Video Generation. Long video generation is a long-standing challenge in the field. Earlier works (Skorokhodov et al., 2022; Yu et al., 2022; Chen et al., 2020) employing generative adversarial networks (GANs) or variational auto-encoder (VAE) to model video distributions. VideoGPT (Yan et al., 2021) employs a combination of VQVAE (Van Den Oord et al., 2017) and transformer architecture to sequentially produce tokens within a discrete latent space. TATS (Ge et al., 2022) trains a time-agnostic VQGAN and subsequently learns a time-sensitive transformer based on the latent features. Phenaki (Villegas et al., 2023) uses a transformer-based model to compress videos into discrete tokens and generate longer continuous videos based on a sequence of text prompts. Recently, Diffusion Models (DMs) (Ho et al., 2020; Song et al., 2021a; Nichol & Dhariwal, 2021) have made significant advancements in video generation. LEO (Wang et al., 2023c) proposed to produce long human videos in latent motion space. LVDM (He et al., 2022) focuses on generating shot-level long videos by employing a hierarchical latent diffusion model. NUWA-XL (Yin et al., 2023) employs a hierarchical diffusion model to generate long videos, but it has only been trained on the cartoon FlintstonesHD dataset due to the lack of datasets on natural videos. On the other hand, Gen-L-Video (Wang et al., 2023a) generates long videos by utilizing existing short text-to-video generation models and treating them as overlapping short video clips. In contrast, our approach views long videos as compositions of various scenes and shot-level videos of different lengths. Our",
320
+ "bbox": [
321
+ 169,
322
+ 686,
323
+ 826,
324
+ 924
325
+ ],
326
+ "page_idx": 2
327
+ },
328
+ {
329
+ "type": "header",
330
+ "text": "Published as a conference paper at ICLR 2024",
331
+ "bbox": [
332
+ 171,
333
+ 32,
334
+ 478,
335
+ 47
336
+ ],
337
+ "page_idx": 2
338
+ },
339
+ {
340
+ "type": "page_number",
341
+ "text": "3",
342
+ "bbox": [
343
+ 493,
344
+ 948,
345
+ 504,
346
+ 959
347
+ ],
348
+ "page_idx": 2
349
+ },
350
+ {
351
+ "type": "image",
352
+ "img_path": "images/2a7fbcfdde3e7d98f3b8a754193dddf02ac6898d1187be3c7087f2493be4b240.jpg",
353
+ "image_caption": [
354
+ "Figure 3: Notations and schematic representation of generative transition objective. Generative transition exhibits semantic similarity between each frame $x^n$ with the two scene images; each frame $x^n$ and its neighboring frames $x^{n-1}$ and $x^{n+1}$ should be temporal coherence; the semantics of generated frames should be alignment to the provided textual description."
355
+ ],
356
+ "image_footnote": [],
357
+ "bbox": [
358
+ 173,
359
+ 103,
360
+ 823,
361
+ 236
362
+ ],
363
+ "page_idx": 3
364
+ },
365
+ {
366
+ "type": "text",
367
+ "text": "short-to-long model aims to generate \"story-level\" videos containing continuous multi-scene videos with varying shot lengths.",
368
+ "bbox": [
369
+ 169,
370
+ 333,
371
+ 823,
372
+ 363
373
+ ],
374
+ "page_idx": 3
375
+ },
376
+ {
377
+ "type": "text",
378
+ "text": "3 METHODOLOGY",
379
+ "text_level": 1,
380
+ "bbox": [
381
+ 171,
382
+ 382,
383
+ 341,
384
+ 397
385
+ ],
386
+ "page_idx": 3
387
+ },
388
+ {
389
+ "type": "text",
390
+ "text": "3.1 PRELIMINARIES",
391
+ "text_level": 1,
392
+ "bbox": [
393
+ 171,
394
+ 414,
395
+ 326,
396
+ 426
397
+ ],
398
+ "page_idx": 3
399
+ },
400
+ {
401
+ "type": "text",
402
+ "text": "Text-to-Image Diffusion Model. Stable Diffusion (Rombach et al., 2022) performs image diffusion in a compressed latent space of an autoencoder (i.e., VQ-GAN and VQ-VAE). During training, a given image sample $x_0$ is encoded into the latent code $z = \\mathcal{E}(x_0)$ and corrupted by Gaussian noise from a pre-defined Markov chain:",
403
+ "bbox": [
404
+ 169,
405
+ 439,
406
+ 823,
407
+ 494
408
+ ],
409
+ "page_idx": 3
410
+ },
411
+ {
412
+ "type": "equation",
413
+ "text": "\n$$\nq \\left(z _ {t} \\mid z _ {t - 1}\\right) = \\mathcal {N} \\left(z _ {t}; \\sqrt {1 - \\beta_ {t}} z _ {t - 1}, \\beta_ {t} I\\right) \\tag {1}\n$$\n",
414
+ "text_format": "latex",
415
+ "bbox": [
416
+ 364,
417
+ 503,
418
+ 823,
419
+ 523
420
+ ],
421
+ "page_idx": 3
422
+ },
423
+ {
424
+ "type": "text",
425
+ "text": "for $t = 1, \\dots, T$ , with $T$ being the number of steps in the forward diffusion process. The sequence of hyperparameters $\\beta_{t}$ determines the noise strength at each step. The above iterative process can be reformulated in a closed-form manner as follows:",
426
+ "bbox": [
427
+ 169,
428
+ 527,
429
+ 823,
430
+ 571
431
+ ],
432
+ "page_idx": 3
433
+ },
434
+ {
435
+ "type": "equation",
436
+ "text": "\n$$\nz _ {t} = \\sqrt {\\bar {\\alpha} _ {t}} z _ {0} + \\sqrt {1 - \\bar {\\alpha} _ {t}} \\epsilon , \\epsilon \\sim \\mathcal {N} (0, I) \\tag {2}\n$$\n",
437
+ "text_format": "latex",
438
+ "bbox": [
439
+ 366,
440
+ 578,
441
+ 823,
442
+ 595
443
+ ],
444
+ "page_idx": 3
445
+ },
446
+ {
447
+ "type": "text",
448
+ "text": "where $\\bar{\\alpha}_t = \\prod_{i=1}^t \\alpha_t, \\alpha_t = 1 - \\beta_t$ . The model adopts $\\epsilon$ -prediction and DDPM to learn a function $\\epsilon_\\theta$ is minimized by:",
449
+ "bbox": [
450
+ 169,
451
+ 603,
452
+ 823,
453
+ 632
454
+ ],
455
+ "page_idx": 3
456
+ },
457
+ {
458
+ "type": "equation",
459
+ "text": "\n$$\n\\mathcal {L} = \\mathbf {E} _ {z _ {0}, c, \\epsilon \\sim \\mathcal {N} (0, I), t} [ \\| \\epsilon - \\epsilon_ {\\theta} (z _ {t}, t, c) \\| _ {2} ^ {2} ] \\tag {3}\n$$\n",
460
+ "text_format": "latex",
461
+ "bbox": [
462
+ 362,
463
+ 631,
464
+ 823,
465
+ 648
466
+ ],
467
+ "page_idx": 3
468
+ },
469
+ {
470
+ "type": "text",
471
+ "text": "where $c$ indicates the condition of the textual description, $\\epsilon$ is drawn from a diagonal Gaussian distribution. The $\\epsilon_{\\theta}$ is commonly implemented by a Unet, where $\\theta$ is a parameterized neural network.",
472
+ "bbox": [
473
+ 169,
474
+ 650,
475
+ 823,
476
+ 679
477
+ ],
478
+ "page_idx": 3
479
+ },
480
+ {
481
+ "type": "text",
482
+ "text": "Text-to-Video Diffusion Model. Our framework is constructed upon a pre-trained diffusion-based T2V model, LaVie (Wang et al., 2023b), which is a cascaded framework that includes a base T2V model, a temporal interpolation model, and a video super-resolution model. LaVie-base, which is part of the LaVie framework, is developed using Stable Diffusion pre-trained model and incorporates a temporal attention module and image-video joint fine-tuning. To benefit from its ability to generate visually and temporally consistent videos with diverse content, we utilize the pre-trained LaVie-base model as the initialization for our framework.",
483
+ "bbox": [
484
+ 169,
485
+ 686,
486
+ 825,
487
+ 782
488
+ ],
489
+ "page_idx": 3
490
+ },
491
+ {
492
+ "type": "text",
493
+ "text": "3.2 GENERATIVE TRANSITION",
494
+ "text_level": 1,
495
+ "bbox": [
496
+ 171,
497
+ 800,
498
+ 398,
499
+ 814
500
+ ],
501
+ "page_idx": 3
502
+ },
503
+ {
504
+ "type": "text",
505
+ "text": "The objective of the transition task is to generate a sequence of intermediate frames, denoted as $x^n$ , between two given images $S_1$ and $S_2$ , using a transition description caption $c$ . We define $x^0$ as $S_1$ and $x^N$ as $S_2$ , so the sequence consists of $N - 2$ target (in-between) frames. The generated sequence should satisfy the following three properties, as shown in Fig. 3: 1) Temporal Coherence: The changes in visual content across the sequence should be smooth and coherent over time. This property ensures that the generated video appears natural and visually consistent. 2) Semantic Similarity: The semantic content of each generated intermediate frame should resemble either of",
506
+ "bbox": [
507
+ 169,
508
+ 825,
509
+ 826,
510
+ 925
511
+ ],
512
+ "page_idx": 3
513
+ },
514
+ {
515
+ "type": "header",
516
+ "text": "Published as a conference paper at ICLR 2024",
517
+ "bbox": [
518
+ 171,
519
+ 32,
520
+ 478,
521
+ 47
522
+ ],
523
+ "page_idx": 3
524
+ },
525
+ {
526
+ "type": "page_number",
527
+ "text": "4",
528
+ "bbox": [
529
+ 493,
530
+ 948,
531
+ 503,
532
+ 959
533
+ ],
534
+ "page_idx": 3
535
+ },
536
+ {
537
+ "type": "image",
538
+ "img_path": "images/55e7683d6a054b44a9711519375a79083bf691e1e13204b236a3107cd2e1ea64.jpg",
539
+ "image_caption": [
540
+ "Figure 4: Overview of our proposed method. We present our S2L generation model for generating transition video and long video prediction. Our model supports text as input, which is processed through a clip encoder and injected into the model (blue part). For brevity, we omit the details of the text injection, which is identical to the stable diffusion model."
541
+ ],
542
+ "image_footnote": [],
543
+ "bbox": [
544
+ 171,
545
+ 73,
546
+ 812,
547
+ 256
548
+ ],
549
+ "page_idx": 4
550
+ },
551
+ {
552
+ "type": "text",
553
+ "text": "the source images to some extent. This prevents the appearance of the sequence from deviating too much from the source scene images. Additionally, the similarity should gradually change from one source image to the other. 3) Video-text Alignment: The generated frames should align with the provided text description. This alignment allows us to control the transition between the two source images using the text description.",
554
+ "bbox": [
555
+ 169,
556
+ 348,
557
+ 823,
558
+ 417
559
+ ],
560
+ "page_idx": 4
561
+ },
562
+ {
563
+ "type": "text",
564
+ "text": "3.3 SHORT-TO-LONGVIDEODIFFUSIONMODEL",
565
+ "text_level": 1,
566
+ "bbox": [
567
+ 171,
568
+ 435,
569
+ 524,
570
+ 450
571
+ ],
572
+ "page_idx": 4
573
+ },
574
+ {
575
+ "type": "text",
576
+ "text": "We develop a diffusion-based model for S2L videos via transition generation and video prediction. In order to generate unseen frames of transition and prediction, based on visible conditional images or videos, our S2L video diffusion model incorporates a random mask module, as shown in Fig. 4. Given the video dataset $p_{\\mathrm{video}}$ , we take a $N$ -frame original video denoted as $x_0 \\in \\mathbb{R}^{N \\times 3 \\times H \\times W}$ where $x_0$ follows the distribution $p_{\\mathrm{video}}$ . The frames of video $x_0$ are first encoded by the pre-trained variational auto-encoder simultaneously as $z_0 \\in \\mathbb{R}^{n \\times c \\times h \\times w}$ , where $c, h$ and $w$ indicate the channel, height, and width of the latent code, $n$ represents the frame number. To achieve more controllable transition videos and leverage the capability of short text-to-video generation, our model also takes a textual description $c$ as an input. The goal of our model is to learn a dual condition diffusion model: $p_{\\theta}(z_0 | c, \\tilde{z}_0)$ . In the training stage, the latent code of video is corrupted as Eq. 3: $z_t = \\sqrt{\\alpha_t} z_0 + \\sqrt{1 - \\bar{\\alpha}_t \\epsilon}$ , where the initial noise $\\epsilon \\sim \\mathcal{N}(0, I)$ whose size is same as $z_0$ : $\\epsilon \\in \\mathbb{R}^{n \\times c \\times h \\times w}$ . To capture an intermediate representation of the motion between frames, we introduce a random-mask condition layer at the input stage. This layer applies a binary mask $m \\in \\mathbb{R}^n$ broadcasting to $\\tilde{m} \\in \\mathbb{R}^{n \\times c \\times h \\times w}$ as the size of the latent code, resulting in a masked latent code:",
577
+ "bbox": [
578
+ 169,
579
+ 460,
580
+ 823,
581
+ 656
582
+ ],
583
+ "page_idx": 4
584
+ },
585
+ {
586
+ "type": "equation",
587
+ "text": "\n$$\n\\tilde {z} _ {0} = z _ {0} \\odot m, \\tilde {z} _ {0} \\in \\mathbb {R} ^ {n \\times c \\times h \\times w}. \\tag {4}\n$$\n",
588
+ "text_format": "latex",
589
+ "bbox": [
590
+ 390,
591
+ 664,
592
+ 823,
593
+ 681
594
+ ],
595
+ "page_idx": 4
596
+ },
597
+ {
598
+ "type": "text",
599
+ "text": "The binary masks, represented by $m$ , serve as a mechanism to selectively preserve or suppress information from the original latent code. In order to identify which frames are masked and which ones are visible conditional images, our model takes the masked latent code $\\tilde{z}_0$ concatenated with the mask $m$ as a conditional input:",
600
+ "bbox": [
601
+ 169,
602
+ 689,
603
+ 823,
604
+ 744
605
+ ],
606
+ "page_idx": 4
607
+ },
608
+ {
609
+ "type": "equation",
610
+ "text": "\n$$\n\\tilde {z} _ {t} = \\left[ z _ {t}; m; \\tilde {z} _ {0} \\right], \\tilde {z} _ {t} \\in \\mathbb {R} ^ {n \\times (3 \\times c) \\times h \\times w}, \\tag {5}\n$$\n",
611
+ "text_format": "latex",
612
+ "bbox": [
613
+ 370,
614
+ 753,
615
+ 823,
616
+ 772
617
+ ],
618
+ "page_idx": 4
619
+ },
620
+ {
621
+ "type": "text",
622
+ "text": "where $\\tilde{z}_t$ represents the final input to the U-Net. The model is trained to predict the noise of the entire corrupted latent code:",
623
+ "bbox": [
624
+ 169,
625
+ 777,
626
+ 823,
627
+ 806
628
+ ],
629
+ "page_idx": 4
630
+ },
631
+ {
632
+ "type": "equation",
633
+ "text": "\n$$\n\\mathcal {L} = \\mathcal {E} [ \\| \\epsilon - \\epsilon_ {\\theta} (\\tilde {z} _ {t}, t, c) \\| ]. \\tag {6}\n$$\n",
634
+ "text_format": "latex",
635
+ "bbox": [
636
+ 410,
637
+ 806,
638
+ 823,
639
+ 823
640
+ ],
641
+ "page_idx": 4
642
+ },
643
+ {
644
+ "type": "text",
645
+ "text": "This involves learning the underlying distribution of the noise that affects the unmasked frames and textual description. By modeling and predicting the noise, the model aims to generate realistic and visually coherent transition frames that seamlessly blend the visible frames with the unmasked frames. The mask has $n$ elements indicating the index of frames, each of which can take on the values 0 or 1. The probability of the element taking the value 1 is denoted as $p$ : $\\mathrm{m} \\sim \\mathrm{Bernoulli}(p)$ . Given that our model primarily focuses on transitions and predictions, where typically less than 3 frames are involved. In our model, we set $p = 0.15$ considering the probability $\\frac{2}{n} < p < \\frac{3}{n}$ . This",
646
+ "bbox": [
647
+ 169,
648
+ 825,
649
+ 825,
650
+ 926
651
+ ],
652
+ "page_idx": 4
653
+ },
654
+ {
655
+ "type": "header",
656
+ "text": "Published as a conference paper at ICLR 2024",
657
+ "bbox": [
658
+ 171,
659
+ 32,
660
+ 478,
661
+ 47
662
+ ],
663
+ "page_idx": 4
664
+ },
665
+ {
666
+ "type": "page_number",
667
+ "text": "5",
668
+ "bbox": [
669
+ 493,
670
+ 948,
671
+ 503,
672
+ 959
673
+ ],
674
+ "page_idx": 4
675
+ },
676
+ {
677
+ "type": "image",
678
+ "img_path": "images/9b18b5d28e2f9682c235d8d5eb48269ca9a294cc07bf6e8972ad98a55ed009b6.jpg",
679
+ "image_caption": [
680
+ "Figure 5: Qualitative comparisons with existing methods. Left: Spiderman becomes into a sand sculpture. Right: A cat from sitting on the coach transfer to lying on the sand."
681
+ ],
682
+ "image_footnote": [],
683
+ "bbox": [
684
+ 174,
685
+ 99,
686
+ 823,
687
+ 431
688
+ ],
689
+ "page_idx": 5
690
+ },
691
+ {
692
+ "type": "text",
693
+ "text": "choice of probability ensures that, on average, approximately two or three out of every $n$ frames will be visible. It aligns with the assumption that the mask is primarily used for capturing transitions between frames, where adjacent frames are more likely to be influenced by the mask. Our random-mask based model is capable of generating frames for any given frames at arbitrary positions within the sequence. Transition can be obtained by providing the first and last frames of a sequence and utilizing prompts to control the transition style and content, resulting in intermediate transition frames that depict the transition or progression within the video sequence. Long video involves recursive using the last few frames of the generated video as input and utilizing masks to predict the subsequent frames. By recursively iterating this process, the model can generate longer video sequences. Image-to-video animation can be achieved by treating the reference image as the first frame. The first binary mask is set as ones and the remaining is set as zeros. The animated video can be obtained through a denoising process and subsequently decoded from the encoder.",
694
+ "bbox": [
695
+ 169,
696
+ 508,
697
+ 823,
698
+ 676
699
+ ],
700
+ "page_idx": 5
701
+ },
702
+ {
703
+ "type": "text",
704
+ "text": "4 EXPERIMENTS",
705
+ "text_level": 1,
706
+ "bbox": [
707
+ 171,
708
+ 714,
709
+ 326,
710
+ 729
711
+ ],
712
+ "page_idx": 5
713
+ },
714
+ {
715
+ "type": "text",
716
+ "text": "Implementation Details. SEINE is initialized from LaVie-base (Wang et al., 2023b), with the addition of a random mask layer being randomly initialized. We first utilize the WebVid10M dataset (Bain et al., 2021) as the main training set, and during the later stages of training, we use a few internal watermark-free datasets to mitigate the presence of watermarks in the generated output. Our model is trained on videos of $320 \\times 512$ resolution with 16 frames. During inference, SEINE is able to generate videos of arbitrary aspect ratios. Comparison Methods. Transition video generation is a relatively understudied and novel problem within the field. While traditional methods have explored smooth transitions through image morphing techniques, there is a lack of specific approaches addressing generative transition in the context of video generation. In this part, we conduct analyses between our proposed approach and existing methods that can achieve similar effects: diffusion model-based method (i.e., Stable Diffusion), VQGAN-based model (Esser et al., 2021). Details description and implementation for the compared methods are described in App. A.1.",
717
+ "bbox": [
718
+ 169,
719
+ 757,
720
+ 823,
721
+ 925
722
+ ],
723
+ "page_idx": 5
724
+ },
725
+ {
726
+ "type": "header",
727
+ "text": "Published as a conference paper at ICLR 2024",
728
+ "bbox": [
729
+ 173,
730
+ 32,
731
+ 478,
732
+ 47
733
+ ],
734
+ "page_idx": 5
735
+ },
736
+ {
737
+ "type": "page_number",
738
+ "text": "6",
739
+ "bbox": [
740
+ 493,
741
+ 948,
742
+ 503,
743
+ 959
744
+ ],
745
+ "page_idx": 5
746
+ },
747
+ {
748
+ "type": "text",
749
+ "text": "4.1 QUALITATIVE COMPARISON",
750
+ "text_level": 1,
751
+ "bbox": [
752
+ 171,
753
+ 104,
754
+ 410,
755
+ 119
756
+ ],
757
+ "page_idx": 6
758
+ },
759
+ {
760
+ "type": "text",
761
+ "text": "Fig. 5 shows the visual comparison with the existing methods. We observe that using interpolation methods for VQVAE to generate intermediate transition scenes often results in a transparent blending of two images. Morphing techniques, on the other hand, can achieve object deformation by matching key points (such as changes in a cat's pose), ensuring that objects do not undergo transparent blending. However, for scenes without significant object deformation, such as transitioning from a cityscape to the sky in a Spiderman scene, simple blending may still occur. Stable Diffusion-based methods do not suffer from simple blending issues, but their lack of sufficient continuity in hidden codes leads to a lack of consistency in the generated intermediate images. In contrast, our method ensures smooth object motion while incorporating plausible phenomena during transitions.",
762
+ "bbox": [
763
+ 169,
764
+ 130,
765
+ 826,
766
+ 256
767
+ ],
768
+ "page_idx": 6
769
+ },
770
+ {
771
+ "type": "text",
772
+ "text": "4.2 QUANTITATIVE COMPARISON",
773
+ "text_level": 1,
774
+ "bbox": [
775
+ 171,
776
+ 273,
777
+ 419,
778
+ 287
779
+ ],
780
+ "page_idx": 6
781
+ },
782
+ {
783
+ "type": "text",
784
+ "text": "We assess the generative transition from three aspects: temporal coherence, semantic similarity, and video-text alignment. To evaluate the semantic similarity between generated frames and given scene images, we use the clip similarity (CLIPSIM) metric. To compute \"CLIPSIM-scenes\", abbr. \"CLIPSIM-s\", we calculate the clip image similarity for each frame and the given scene images. To compute \"CLIPSIM-frames\", abbr. \"CLIPSIM-f\", we calculate the clip score in between generated frames. Likewise, we utilize the clip text-image similarity as \"CLIPSIM-text\", abbr. \"CLIPSIM-t\", to quantify the semantic correlation between the generated videos and their corresponding descriptive text. In our experiments, we employ the MSR-VTT dataset due to its open-domain nature with textual annotations. We randomly selected one caption per video from the official test set (a total of 2,990 videos). In order to evaluate the quality of the generative transition, we considered the given scene images as two frames of a video with a larger interval timestep. This allows us to analyze and compare the smoothness and coherence of the transition between the two images. Specifically, we utilize the first and 64th frames as the reference scene images in our evaluation. Tab. 1 presents the comparative results of our analysis. The results demonstrate that our method outperforms the comparison algorithms. It is worth noting that our method does not achieve significantly higher scores than CLIPSIM-Scene and CLIPSIM-Frames. To further scrutinize the quality of our video transitions, we calculate FVD and frame-wise FID score. The outcomes reveal that our model consistently delivers superior video quality compared to other methods examined in our study.",
785
+ "bbox": [
786
+ 169,
787
+ 300,
788
+ 826,
789
+ 551
790
+ ],
791
+ "page_idx": 6
792
+ },
793
+ {
794
+ "type": "table",
795
+ "img_path": "images/90cfb3744f9611a2a70dbaab5efd2a34298c42146492070a1451ceae6886d342.jpg",
796
+ "table_caption": [
797
+ "Table 1: Comparison with methods w.r.t. CLIPSIM- $t$ ,CLIPSIM- $s$ ,CLIPSIM- $f$ ,FVD and FID."
798
+ ],
799
+ "table_footnote": [],
800
+ "table_body": "<table><tr><td>Methods</td><td>CLIPSIM-t(↑)</td><td>CLIPSIM-s(↑)</td><td>CLIPSIM-f(↑)</td><td>FVD(↓)</td><td>FID(↓)</td></tr><tr><td>Morphing</td><td>0.2535</td><td>0.7707</td><td>0.9569</td><td>573.9</td><td>35.3</td></tr><tr><td>VQGAN-based Transition</td><td>0.2528</td><td>0.7389</td><td>0.9542</td><td>445.6</td><td>36.7</td></tr><tr><td>SD-based Transition</td><td>0.2665</td><td>0.6080</td><td>0.8809</td><td>502.0</td><td>62.0</td></tr><tr><td>Ours</td><td>0.2726</td><td>0.7740</td><td>0.9675</td><td>181.6</td><td>13.4</td></tr></table>",
801
+ "bbox": [
802
+ 189,
803
+ 589,
804
+ 808,
805
+ 670
806
+ ],
807
+ "page_idx": 6
808
+ },
809
+ {
810
+ "type": "text",
811
+ "text": "4.3 DIVERSE AND CONTROLLABLE TRANSITION GENERATION",
812
+ "text_level": 1,
813
+ "bbox": [
814
+ 171,
815
+ 703,
816
+ 620,
817
+ 717
818
+ ],
819
+ "page_idx": 6
820
+ },
821
+ {
822
+ "type": "text",
823
+ "text": "We showcase the advantages of our method in handling generative transitions: 1) diverse results by sampling multiple times; and 2) controllable results of our method by employing textural descriptions such as camera movement control. Diverse Transition Generation. We present visual results demonstrating the variety of transitions generated under identical prompts within two equivalent scenes, as depicted in Fig. 6. We can observe that as the raccoon transitions from being in the sea to the stage scene, the first two outcomes depict a form of similarity transition. However, the sequence of transitioning between the objects and backgrounds varies. The final transition, indeed, resembles the unfurling of a curtain, akin to a wave sweeping in from the right side. Controllable Transition Generation. Our method can achieve transitions by controlling the prompt with camera movements. For instance, by employing camera zoom-in and zoom-out control, we create visual occlusions, and during the zoom-out phase, we generate the subsequent scene to achieve a seamless scene transition. This occlusion technique is a widely employed transition method in filmmaking. Fig. 7 illustrates our example of this technique through the prompt, transitioning a scene from an office to a library with the presence of a panda.",
824
+ "bbox": [
825
+ 169,
826
+ 729,
827
+ 826,
828
+ 925
829
+ ],
830
+ "page_idx": 6
831
+ },
832
+ {
833
+ "type": "header",
834
+ "text": "Published as a conference paper at ICLR 2024",
835
+ "bbox": [
836
+ 171,
837
+ 32,
838
+ 478,
839
+ 47
840
+ ],
841
+ "page_idx": 6
842
+ },
843
+ {
844
+ "type": "page_number",
845
+ "text": "7",
846
+ "bbox": [
847
+ 493,
848
+ 948,
849
+ 504,
850
+ 959
851
+ ],
852
+ "page_idx": 6
853
+ },
854
+ {
855
+ "type": "image",
856
+ "img_path": "images/b87e0e2df43d2dc37931a32197c7504b7471f93ad607028b72b16978f07eb646.jpg",
857
+ "image_caption": [
858
+ "Figure 6: Diverse transition results. Each row illustrates frames of our transition results by \"the scene transition from the sea into a playing trumpet raccoon\"."
859
+ ],
860
+ "image_footnote": [],
861
+ "bbox": [
862
+ 174,
863
+ 101,
864
+ 823,
865
+ 297
866
+ ],
867
+ "page_idx": 7
868
+ },
869
+ {
870
+ "type": "text",
871
+ "text": "$I^{st}$ prompt: A panda working in the office, camera zoom-in.",
872
+ "bbox": [
873
+ 181,
874
+ 357,
875
+ 511,
876
+ 369
877
+ ],
878
+ "page_idx": 7
879
+ },
880
+ {
881
+ "type": "image",
882
+ "img_path": "images/90963e0552b7cddef5bfe31a6bd9c91dcba3e524fdc82f3f1169f4ba580f85ec.jpg",
883
+ "image_caption": [],
884
+ "image_footnote": [],
885
+ "bbox": [
886
+ 178,
887
+ 371,
888
+ 823,
889
+ 450
890
+ ],
891
+ "page_idx": 7
892
+ },
893
+ {
894
+ "type": "text",
895
+ "text": "$2^{st}$ prompt: A panda working in the library, camera zoom-out.",
896
+ "bbox": [
897
+ 181,
898
+ 460,
899
+ 524,
900
+ 472
901
+ ],
902
+ "page_idx": 7
903
+ },
904
+ {
905
+ "type": "image",
906
+ "img_path": "images/ab26af63341749c15b6ad2a89b203dd39cf497a5354e2aceffb4c82771cf7686.jpg",
907
+ "image_caption": [
908
+ "Figure 7: Text-controllable transition. Examples of our scene transition are achieved by controlling them through textual descriptions, i.e., camera-motion control."
909
+ ],
910
+ "image_footnote": [],
911
+ "bbox": [
912
+ 178,
913
+ 472,
914
+ 823,
915
+ 551
916
+ ],
917
+ "page_idx": 7
918
+ },
919
+ {
920
+ "type": "text",
921
+ "text": "4.4 COMPARISON WITH STATE-OF-THE-ART METHOD FOR VIDEO PREDICTION",
922
+ "text_level": 1,
923
+ "bbox": [
924
+ 169,
925
+ 618,
926
+ 728,
927
+ 631
928
+ ],
929
+ "page_idx": 7
930
+ },
931
+ {
932
+ "type": "text",
933
+ "text": "We conducted a comprehensive comparative analysis between our proposed method and the state-of-the-art method TATS for the task of generating long videos consisting of 1024 frames, on the UCF-101 dataset (Soomro et al., 2012). Qualitative and quantitative comparisons are illustrated in Fig. 8. Fig. 8 (a) visually presents the comparative results, showing that TATS tends to degrade over time, leading to the emergence of grid-like artifacts and visual collapse. In contrast, our approach avoids such collapsing phenomena, maintaining stable and visually coherent video generation throughout the sequence. Fig. 8 (b) depicts the quantitative evaluation by FVD. In our study, we compared TATS with the outcomes obtained from our model's zero-shot generation and the results achieved after fine-tuning our model on the UCF-101 dataset. All models were evaluated under the auto-regressive setting. Our results are generated by the DDIM sampling of 100 steps. Our approach demonstrates a slower degradation of video quality over time compared to TATS. In the first few frames, due to the disparity of data distribution between the training set and UCF-101, our model's scores are higher than TATS. However, as TATS degrades over time, our model's FVD score becomes lower than that of TATS. Moreover, by performing fine-tuning on the UCF-101 dataset, our method consistently outperforms TATS.",
934
+ "bbox": [
935
+ 169,
936
+ 643,
937
+ 826,
938
+ 852
939
+ ],
940
+ "page_idx": 7
941
+ },
942
+ {
943
+ "type": "text",
944
+ "text": "4.5 MORE APPLICATIONS",
945
+ "text_level": 1,
946
+ "bbox": [
947
+ 171,
948
+ 869,
949
+ 367,
950
+ 883
951
+ ],
952
+ "page_idx": 7
953
+ },
954
+ {
955
+ "type": "text",
956
+ "text": "Long Video Generation. Fig. 9 demonstrates the generation of long videos through auto-regressive prediction. Each video consists of tens of frames by auto-regressive prediction for 4 times. Notably,",
957
+ "bbox": [
958
+ 169,
959
+ 895,
960
+ 823,
961
+ 925
962
+ ],
963
+ "page_idx": 7
964
+ },
965
+ {
966
+ "type": "header",
967
+ "text": "Published as a conference paper at ICLR 2024",
968
+ "bbox": [
969
+ 173,
970
+ 32,
971
+ 478,
972
+ 47
973
+ ],
974
+ "page_idx": 7
975
+ },
976
+ {
977
+ "type": "page_number",
978
+ "text": "8",
979
+ "bbox": [
980
+ 493,
981
+ 948,
982
+ 503,
983
+ 959
984
+ ],
985
+ "page_idx": 7
986
+ },
987
+ {
988
+ "type": "image",
989
+ "img_path": "images/15f6f3824064c10f40b6b9d2c48e55bf24d2294429b466f8af3e1ec0ca14cd33.jpg",
990
+ "image_caption": [
991
+ "Figure 8: Comparison for auto-regressive long video prediction. a) Qualitative Results. Each frame is selected with a frame step 128 from the 256th frame; b) Qualitative results. The lower value indicates better quality.",
992
+ "Figure 9: Long video results via auto-regressive prediction. Best view with Acrobat Reader. Click the images to play the videos.",
993
+ "Figure 10: Image animation results. In each case, our result is on the left and the result of Gen-2 is on the right. Best view with Acrobat Reader. Click the images to play the videos."
994
+ ],
995
+ "image_footnote": [],
996
+ "bbox": [
997
+ 173,
998
+ 104,
999
+ 823,
1000
+ 220
1001
+ ],
1002
+ "page_idx": 8
1003
+ },
1004
+ {
1005
+ "type": "text",
1006
+ "text": "A raccoon dressed in a suit playing A teddy bear washing the dishes. Two pandas discussing an aca- the trumpet, stage background. demic paper.",
1007
+ "bbox": [
1008
+ 174,
1009
+ 398,
1010
+ 821,
1011
+ 426
1012
+ ],
1013
+ "page_idx": 8
1014
+ },
1015
+ {
1016
+ "type": "text",
1017
+ "text": "Ours",
1018
+ "bbox": [
1019
+ 235,
1020
+ 556,
1021
+ 269,
1022
+ 568
1023
+ ],
1024
+ "page_idx": 8
1025
+ },
1026
+ {
1027
+ "type": "text",
1028
+ "text": "Gen-2",
1029
+ "bbox": [
1030
+ 390,
1031
+ 556,
1032
+ 433,
1033
+ 568
1034
+ ],
1035
+ "page_idx": 8
1036
+ },
1037
+ {
1038
+ "type": "text",
1039
+ "text": "Ours",
1040
+ "bbox": [
1041
+ 555,
1042
+ 556,
1043
+ 586,
1044
+ 568
1045
+ ],
1046
+ "page_idx": 8
1047
+ },
1048
+ {
1049
+ "type": "text",
1050
+ "text": "Gen-2",
1051
+ "bbox": [
1052
+ 710,
1053
+ 556,
1054
+ 751,
1055
+ 568
1056
+ ],
1057
+ "page_idx": 8
1058
+ },
1059
+ {
1060
+ "type": "text",
1061
+ "text": "our method ensures that the visual quality of the generated content remains pristine while preserving consistent semantic coherence throughout the synthesized results. Image-to-Video Animation. We demonstrate the outcomes of video generation by utilizing an image as the initial frame. This approach can be seamlessly integrated with other T2I models, such as Midjourney*. Here, we compare our results with those obtained from the online API image-to-video generation model, Gen-2 (Esser et al., 2023). From the comparison, it can be observed that despite not specifically training our model for this task, our model still achieves comparable results.",
1062
+ "bbox": [
1063
+ 169,
1064
+ 637,
1065
+ 826,
1066
+ 736
1067
+ ],
1068
+ "page_idx": 8
1069
+ },
1070
+ {
1071
+ "type": "text",
1072
+ "text": "5 CONCLUSION",
1073
+ "text_level": 1,
1074
+ "bbox": [
1075
+ 171,
1076
+ 756,
1077
+ 320,
1078
+ 771
1079
+ ],
1080
+ "page_idx": 8
1081
+ },
1082
+ {
1083
+ "type": "text",
1084
+ "text": "In this paper, we introduce SEINE, a S2L video diffusion model that focuses on smooth and creative transitions and auto-regressive predictions. SEINE utilizes a random-mask video diffusion model to automatically generate transitions based on textual descriptions, ensuring coherence and visual quality. The model can also be extended to image-to-video animation and auto-regressive video prediction tasks, allowing for the creation of coherent \"story-level\" long videos. The evaluation of transitions is conducted based on temporal consistency, semantic similarity, and video-text semantic alignment. The experimental results demonstrate the superiority of our approach over existing methods in terms of transition and prediction.",
1085
+ "bbox": [
1086
+ 169,
1087
+ 787,
1088
+ 826,
1089
+ 902
1090
+ ],
1091
+ "page_idx": 8
1092
+ },
1093
+ {
1094
+ "type": "header",
1095
+ "text": "Published as a conference paper at ICLR 2024",
1096
+ "bbox": [
1097
+ 171,
1098
+ 32,
1099
+ 478,
1100
+ 47
1101
+ ],
1102
+ "page_idx": 8
1103
+ },
1104
+ {
1105
+ "type": "page_footnote",
1106
+ "text": "\\*https://www.midjourney.com",
1107
+ "bbox": [
1108
+ 194,
1109
+ 910,
1110
+ 434,
1111
+ 924
1112
+ ],
1113
+ "page_idx": 8
1114
+ },
1115
+ {
1116
+ "type": "page_number",
1117
+ "text": "9",
1118
+ "bbox": [
1119
+ 493,
1120
+ 948,
1121
+ 504,
1122
+ 959
1123
+ ],
1124
+ "page_idx": 8
1125
+ },
1126
+ {
1127
+ "type": "text",
1128
+ "text": "6 ETHICS STATEMENT",
1129
+ "text_level": 1,
1130
+ "bbox": [
1131
+ 171,
1132
+ 102,
1133
+ 377,
1134
+ 118
1135
+ ],
1136
+ "page_idx": 9
1137
+ },
1138
+ {
1139
+ "type": "text",
1140
+ "text": "We acknowledge the ethical concerns that are shared with other text-to-image and text-to-video diffusion models (Ramesh et al., 2021; 2022; Rombach et al., 2022; Sahara et al., 2022; Ho et al., 2022; He et al., 2022; Wang et al., 2023b). Furthermore, our optimization is based on diffusion model (Ho et al., 2020; Song et al., 2021b), which has the potential to introduce unintended bias as a result of the training data. On the other hand, our approach presents a short-to-long video diffusion model that aims to create a coherent story-level long video, which may have implications for various domains including filmmaking, video games, and artistic creation.",
1141
+ "bbox": [
1142
+ 169,
1143
+ 133,
1144
+ 826,
1145
+ 232
1146
+ ],
1147
+ "page_idx": 9
1148
+ },
1149
+ {
1150
+ "type": "text",
1151
+ "text": "ACKNOWLEDGEMENTS",
1152
+ "text_level": 1,
1153
+ "bbox": [
1154
+ 171,
1155
+ 252,
1156
+ 369,
1157
+ 266
1158
+ ],
1159
+ "page_idx": 9
1160
+ },
1161
+ {
1162
+ "type": "text",
1163
+ "text": "This work is supported by the National Key R&D Program of China under Grand NO.2022ZD0160100, the National Natural Science Foundation of China under Grant No. 62102150, the Ministry of Education Singapore under its MOE AcRF Tier 2 (MOE-T2EP20221-0012) and NTU NAP, and the Science and Technology Commission of Shanghai Municipality under Grant No. 23QD1400800, No. 22511105800, and the RIE2020 Industry Alignment Fund - Industry Collaboration Projects (IAF-ICP) Funding Initiative, as well as cash and in-kind contribution from the industry partner(s).",
1164
+ "bbox": [
1165
+ 169,
1166
+ 282,
1167
+ 826,
1168
+ 380
1169
+ ],
1170
+ "page_idx": 9
1171
+ },
1172
+ {
1173
+ "type": "text",
1174
+ "text": "REFERENCES",
1175
+ "text_level": 1,
1176
+ "bbox": [
1177
+ 173,
1178
+ 400,
1179
+ 287,
1180
+ 415
1181
+ ],
1182
+ "page_idx": 9
1183
+ },
1184
+ {
1185
+ "type": "list",
1186
+ "sub_type": "ref_text",
1187
+ "list_items": [
1188
+ "Max Bain, Arsha Nagrani, Gül Varol, and Andrew Zisserman. Frozen in time: A joint video and image encoder for end-to-end retrieval. In ICCV, 2021.",
1189
+ "Yogesh Balaji, Seungjun Nah, Xun Huang, Arash Vahdat, Jiaming Song, Karsten Kreis, Miika Aittala, Timo Aila, Samuli Laine, Bryan Catanzaro, et al. edifi: Text-to-image diffusion models with an ensemble of expert denoisers. arXiv preprint arXiv:2211.01324, 2022.",
1190
+ "Andreas Blattmann, Robin Rombach, Huan Ling, Tim Dockhorn, Seung Wook Kim, Sanja Fidler, and Karsten Kreis. Align your latents: High-resolution video synthesis with latent diffusion models. In CVPR, 2023.",
1191
+ "Mingdeng Cao, Xintao Wang, Zhongang Qi, Ying Shan, Xiaohu Qie, and Yinqiang Zheng. Mas-actr: Tuning-free mutual self-attention control for consistent image synthesis and editing. arXiv preprint arXiv:2304.08465, 2023.",
1192
+ "Xinyuan Chen, Chang Xu, Xiaokang Yang, Li Song, and Dacheng Tao. Gated-gan: Adversarial gated networks for multi-collection style transfer. IEEE Transactions on Image Processing, 28 (2):546-560, 2018.",
1193
+ "Xinyuan Chen, Chang Xu, Xiaokang Yang, and Dacheng Tao. Long-term video prediction via criticization and retrospection. IEEE Transactions on Image Processing, 29:7090-7103, 2020.",
1194
+ "Patrick Esser, Robin Rombach, and Bjorn Ommer. Taming transformers for high-resolution image synthesis. In CVPR, 2021.",
1195
+ "Patrick Esser, Johnathan Chiu, Parmida Atighehchian, Jonathan Granskog, and Anastasis Germanidis. Structure and content-guided video synthesis with diffusion models. arXiv preprint arXiv:2302.03011, 2023.",
1196
+ "Songwei Ge, Thomas Hayes, Harry Yang, Xi Yin, Guan Pang, David Jacobs, Jia-Bin Huang, and Devi Parikh. Long video generation with time-agnostic vqgan and time-sensitive transformer. In ECCV, 2022.",
1197
+ "Songwei Ge, Seungjun Nah, Guilin Liu, Tyler Poon, Andrew Tao, Bryan Catanzaro, David Jacobs, Jia-Bin Huang, Ming-Yu Liu, and Yogesh Balaji. Preserve your own correlation: A noise prior for video diffusion models. arXiv preprint arXiv:2305.10474, 2023.",
1198
+ "Yingqing He, Tianyu Yang, Yong Zhang, Ying Shan, and Qifeng Chen. Latent video diffusion models for high-fidelity long video generation. 2022."
1199
+ ],
1200
+ "bbox": [
1201
+ 173,
1202
+ 422,
1203
+ 825,
1204
+ 924
1205
+ ],
1206
+ "page_idx": 9
1207
+ },
1208
+ {
1209
+ "type": "header",
1210
+ "text": "Published as a conference paper at ICLR 2024",
1211
+ "bbox": [
1212
+ 171,
1213
+ 32,
1214
+ 478,
1215
+ 47
1216
+ ],
1217
+ "page_idx": 9
1218
+ },
1219
+ {
1220
+ "type": "page_number",
1221
+ "text": "10",
1222
+ "bbox": [
1223
+ 490,
1224
+ 946,
1225
+ 509,
1226
+ 960
1227
+ ],
1228
+ "page_idx": 9
1229
+ },
1230
+ {
1231
+ "type": "list",
1232
+ "sub_type": "ref_text",
1233
+ "list_items": [
1234
+ "Jonathan Ho, Ajay Jain, and Pieter Abbeel. Denoising diffusion probabilistic models. Advances in Neural Information Processing Systems, 33:6840-6851, 2020.",
1235
+ "Jonathan Ho, William Chan, Chitwan Sahara, Jay Whang, Ruiqi Gao, Alexey Gritsenko, Diederik P Kingma, Ben Poole, Mohammad Norouzi, David J Fleet, et al. Imagen video: High definition video generation with diffusion models. arXiv preprint arXiv:2210.02303, 2022.",
1236
+ "MinGuk Kang, Joonghyuk Shin, and Jaesik Park. StudioGAN: A Taxonomy and Benchmark of GANs for Image Synthesis. IEEE Transactions on Pattern Analysis and Machine Intelligence (TPAMI), 2023.",
1237
+ "Alexander Quinn Nichol and Prafulla Dhariwal. Improved denoising diffusion probabilistic models. In ICML, 2021.",
1238
+ "Aditya Ramesh, Mikhail Pavlov, Gabriel Goh, Scott Gray, Chelsea Voss, Alec Radford, Mark Chen, and Ilya Sutskever. Zero-shot text-to-image generation. In ICML, 2021.",
1239
+ "Aditya Ramesh, Prafulla Dhariwal, Alex Nichol, Casey Chu, and Mark Chen. Hierarchical text-conditional image generation with clip latents. arXiv preprint arXiv:2204.06125, 2022.",
1240
+ "Robin Rombach, Andreas Blattmann, Dominik Lorenz, Patrick Esser, and Björn Ommer. High-resolution image synthesis with latent diffusion models. In Proceedings of the IEEE/CVF conference on computer vision and pattern recognition, pp. 10684-10695, 2022.",
1241
+ "Chitwan Sahara, William Chan, Saurabh Saxena, Lala Li, Jay Whang, Emily L Denton, Kamyar Ghasemipour, Raphael Gontijo Lopes, Burcu Karagol Ayan, Tim Salimans, et al. Photorealistic text-to-image diffusion models with deep language understanding. Advances in Neural Information Processing Systems, 35:36479-36494, 2022.",
1242
+ "Axel Sauer, Katja Schwarz, and Andreas Geiger. Stylegan-xl: Scaling stylegan to large diverse datasets. In Munkhtsetseg Nandigjav, Niloy J. Mitra, and Aaron Hertzmann (eds.), SIGGRAPH '22: Special Interest Group on Computer Graphics and Interactive Techniques Conference, Vancouver, BC, Canada, August 7 - 11, 2022, pp. 49:1-49:10. ACM, 2022. doi: 10.1145/3528233.3530738. URL https://doi.org/10.1145/3528233.3530738.",
1243
+ "Eli Shechtman, Alex Rav-Acha, Michal Irani, and Steve Seitz. Regenerative morphing. In IEEE Conference on Computer Vision and Pattern Recognition (CVPR), San-Francisco, CA, June 2010.",
1244
+ "Uriel Singer, Adam Polyak, Thomas Hayes, Xi Yin, Jie An, Songyang Zhang, Qiyuan Hu, Harry Yang, Oron Ashual, Oran Gafni, Devi Parikh, Sonal Gupta, and Yaniv Taigman. Make-a-video: Text-to-video generation without text-video data. In ICLR, 2023.",
1245
+ "Ivan Skorokhodov, Sergey Tulyakov, and Mohamed Elhoseiny. Stylegan-v: A continuous video generator with the price, image quality and perks of stylegan2. In CVPR, 2022.",
1246
+ "Jiaming Song, Chenlin Meng, and Stefano Ermon. Denoising diffusion implicit models. In International Conference on Learning Representations, 2021a. URL https://openreview.net/forum?id=StlgiarCHLP.",
1247
+ "Yang Song, Jascha Sohl-Dickstein, Diederik P Kingma, Abhishek Kumar, Stefano Ermon, and Ben Poole. Score-based generative modeling through stochastic differential equations. In ICLRs, 2021b.",
1248
+ "Khurram Soomro, Amir Roshan Zamir, and Mubarak Shah. UCF101: A Dataset of 101 Human Action Classes From Videos in The Wild. Technical report, CRCV-TR-12-01, November 2012.",
1249
+ "Yu Tian, Jian Ren, Mengei Chai, Kyle Olszewski, Xi Peng, Dimitris N. Metaxas, and Sergey Tulyakov. A good image generator is what you need for high-resolution video synthesis. In ICLR, 2021.",
1250
+ "Sergey Tulyakov, Ming-Yu Liu, Xiaodong Yang, and Jan Kautz. MoCoGAN: Decomposing motion and content for video generation. In CVPR, 2018."
1251
+ ],
1252
+ "bbox": [
1253
+ 171,
1254
+ 102,
1255
+ 825,
1256
+ 924
1257
+ ],
1258
+ "page_idx": 10
1259
+ },
1260
+ {
1261
+ "type": "header",
1262
+ "text": "Published as a conference paper at ICLR 2024",
1263
+ "bbox": [
1264
+ 171,
1265
+ 32,
1266
+ 478,
1267
+ 47
1268
+ ],
1269
+ "page_idx": 10
1270
+ },
1271
+ {
1272
+ "type": "page_number",
1273
+ "text": "11",
1274
+ "bbox": [
1275
+ 490,
1276
+ 948,
1277
+ 506,
1278
+ 959
1279
+ ],
1280
+ "page_idx": 10
1281
+ },
1282
+ {
1283
+ "type": "list",
1284
+ "sub_type": "ref_text",
1285
+ "list_items": [
1286
+ "Narek Tumanyan, Michal Geyer, Shai Bagon, and Tali Dekel. Plug-and-play diffusion features for text-driven image-to-image translation. In Proceedings of the IEEE/CVF Conference on Computer Vision and Pattern Recognition, pp. 1921-1930, 2023.",
1287
+ "Aaron Van Den Oord, Oriol Vinyals, et al. Neural discrete representation learning. NeurIPS, 2017.",
1288
+ "Ruben Villegas, Mohammad Babaeizadeh, Pieter-Jan Kindermans, Hernan Moraldo, Han Zhang, Mohammad Taghi Saffar, Santiago Castro, Julius Kunze, and Dumitru Erhan. Phenaki: Variable length video generation from open domain textual descriptions. In ICLR, 2023.",
1289
+ "Fu-Yun Wang, Wenshuo Chen, Guanglu Song, Han-Jia Ye, Yu Liu, and Hongsheng Li. Gen-l-video: Multi-text to long video generation via temporal co-denoising. arXiv preprint arXiv:2305.18264, 2023a.",
1290
+ "Yaohui Wang, Piotr Bilinski, Francois Bremond, and Antitza Dantcheva. G3AN: Disentangling appearance and motion for video generation. In CVPR, 2020a.",
1291
+ "Yaohui Wang, Piotr Bilinski, Francois Bremond, and Antitza Dantcheva. Imaginator: Conditional spatio-temporal gan for video generation. In WACV, 2020b.",
1292
+ "Yaohui Wang, Xinyuan Chen, Xin Ma, Shangchen Zhou, Ziqi Huang, Yi Wang, Ceyuan Yang, Yinan He, Yu Jiashuo, Yang Peiqing, Yuwei Guo, Tianxing Wu, Chenyang Si, Yuming Jiang, Cunjian Chen, Change Loy Chen, Bo Dai, Dahua Lin, Yu Qiao, and Ziwei Liu. Lavie: High-quality video generation with cascaded latent diffusion models. arXiv preprint arXiv:2309.5135377, 2023b.",
1293
+ "Yaohui Wang, Xin Ma, Xinyuan Chen, Antitza Dantcheva, Bo Dai, and Yu Qiao. Leo: Generative latent image animator for human video synthesis. arXiv preprint arXiv:2305.03989, 2023c.",
1294
+ "George Wolberg. Image morphing: a survey. The visual computer, 14(8-9):360-372, 1998.",
1295
+ "Wilson Yan, Yunzhi Zhang, Pieter Abbeel, and Aravind Srinivas. Videogpt: Video generation using vq-vae and transformers. arXiv preprint arXiv:2104.10157, 2021.",
1296
+ "Shengming Yin, Chenfei Wu, Huan Yang, Jianfeng Wang, Xiaodong Wang, Minheng Ni, Zhengyuan Yang, Linjie Li, Shuguang Liu, Fan Yang, et al. Nuwa-xl: Diffusion over diffusion for extremely long video generation. arXiv preprint arXiv:2303.12346, 2023.",
1297
+ "Sihyun Yu, Jihoon Tack, Sangwoo Mo, Hyunsu Kim, Junho Kim, Jung-Woo Ha, and Jinwoo Shin. Generating videos with dynamics-aware implicit generative adversarial networks. In ICLR, 2022.",
1298
+ "Lvmin Zhang and Maneesh Agrawala. Adding conditional control to text-to-image diffusion models, 2023.",
1299
+ "Daquan Zhou, Weimin Wang, Hanshu Yan, Weiwei Lv, Yizhe Zhu, and Jiashi Feng. Magicvideo: Efficient video generation with latent diffusion models. arXiv preprint arXiv:2211.11018, 2022."
1300
+ ],
1301
+ "bbox": [
1302
+ 171,
1303
+ 102,
1304
+ 825,
1305
+ 679
1306
+ ],
1307
+ "page_idx": 11
1308
+ },
1309
+ {
1310
+ "type": "header",
1311
+ "text": "Published as a conference paper at ICLR 2024",
1312
+ "bbox": [
1313
+ 171,
1314
+ 32,
1315
+ 478,
1316
+ 47
1317
+ ],
1318
+ "page_idx": 11
1319
+ },
1320
+ {
1321
+ "type": "page_number",
1322
+ "text": "12",
1323
+ "bbox": [
1324
+ 490,
1325
+ 946,
1326
+ 508,
1327
+ 959
1328
+ ],
1329
+ "page_idx": 11
1330
+ },
1331
+ {
1332
+ "type": "text",
1333
+ "text": "A APPENDIX",
1334
+ "text_level": 1,
1335
+ "bbox": [
1336
+ 171,
1337
+ 102,
1338
+ 299,
1339
+ 117
1340
+ ],
1341
+ "page_idx": 12
1342
+ },
1343
+ {
1344
+ "type": "text",
1345
+ "text": "A.1 COMPARED METHODS FOR TRANSITION.",
1346
+ "text_level": 1,
1347
+ "bbox": [
1348
+ 171,
1349
+ 133,
1350
+ 501,
1351
+ 148
1352
+ ],
1353
+ "page_idx": 12
1354
+ },
1355
+ {
1356
+ "type": "text",
1357
+ "text": "Here we describe the details and implementation details for the compared methods achieving transition.",
1358
+ "bbox": [
1359
+ 169,
1360
+ 159,
1361
+ 823,
1362
+ 188
1363
+ ],
1364
+ "page_idx": 12
1365
+ },
1366
+ {
1367
+ "type": "list",
1368
+ "sub_type": "text",
1369
+ "list_items": [
1370
+ "- Morphing. Morphing is a special effect in motion pictures and animations that changes (or morphs) one image or shape into another through a seamless transition. Traditionally such a depiction would be achieved through dissolving techniques on film. The transition is achieved by using the first and the last frames and generating the intermediate frames.",
1371
+ "- SD-based Method. We adopt the SD as our baseline model. Since SD cannot directly generate intermediate frames, we first compute the latent code of the given two images by reverse diffusion process (i.e., DDIM inversion (Song et al., 2021a)), then we use the interpolation of Euclidean distance of the latent codes to denoising and obtain the intermediate frames.",
1372
+ "- VQGAN-based Method. VQGAN serves as the latent code layer for SD. We employ the interpolated representation of the codes from the encoder of VQGAN output (prior to quantization) as a reference method."
1373
+ ],
1374
+ "bbox": [
1375
+ 171,
1376
+ 200,
1377
+ 826,
1378
+ 364
1379
+ ],
1380
+ "page_idx": 12
1381
+ },
1382
+ {
1383
+ "type": "text",
1384
+ "text": "A.2 FAILURE CASES",
1385
+ "text_level": 1,
1386
+ "bbox": [
1387
+ 171,
1388
+ 382,
1389
+ 331,
1390
+ 396
1391
+ ],
1392
+ "page_idx": 12
1393
+ },
1394
+ {
1395
+ "type": "text",
1396
+ "text": "Watermarks. Since part of our training data (WebVid10M) contains watermarks, there is a chance that generated videos may also exhibit such signals (see Fig. 11 and 12). In the prediction task, we observed that in the autoregressive process, watermarks gradually emerge. Once they appear, they persist throughout the entire video. In the transition task, if the watermarks are present in the given images, the generated intermediate frames will also be affected. However, if no watermarks appear in the given images, watermarks are less likely to appear, and even if they do, they are usually faint.",
1397
+ "bbox": [
1398
+ 169,
1399
+ 407,
1400
+ 823,
1401
+ 494
1402
+ ],
1403
+ "page_idx": 12
1404
+ },
1405
+ {
1406
+ "type": "text",
1407
+ "text": "There is a table by a window with sunlight streaming through illuminating a pile of books.",
1408
+ "bbox": [
1409
+ 174,
1410
+ 613,
1411
+ 388,
1412
+ 652
1413
+ ],
1414
+ "page_idx": 12
1415
+ },
1416
+ {
1417
+ "type": "text",
1418
+ "text": "A view of lake in autumn.",
1419
+ "bbox": [
1420
+ 421,
1421
+ 613,
1422
+ 573,
1423
+ 626
1424
+ ],
1425
+ "page_idx": 12
1426
+ },
1427
+ {
1428
+ "type": "text",
1429
+ "text": "A panda playing on a swing set.",
1430
+ "bbox": [
1431
+ 617,
1432
+ 613,
1433
+ 808,
1434
+ 627
1435
+ ],
1436
+ "page_idx": 12
1437
+ },
1438
+ {
1439
+ "type": "text",
1440
+ "text": "Figure 11: Failure cases for prediction with watermarks. Best view with Acrobat Reader. Click the images to play the videos.",
1441
+ "bbox": [
1442
+ 169,
1443
+ 662,
1444
+ 823,
1445
+ 693
1446
+ ],
1447
+ "page_idx": 12
1448
+ },
1449
+ {
1450
+ "type": "text",
1451
+ "text": "Abrupt Transition. While our method excels in transition generation, it does have limitations regarding the requirement for the similarity of the source and target scenes. A natural and smooth transition relies on finding meaningful correspondences between the two scenes. If the scenes are too dissimilar or lack common elements, the transition may appear abrupt or visually inconsistent. An alternative solution to address this limitation is through a multi-step approach. We utilize image editing methods (Tumanyan et al., 2023; Cao et al., 2023; Zhang & Agrawala, 2023) to transform the source image in the scenes and actions into the target image. This method is particularly beneficial in scene generation as it operates at the image level, naturally preserving similarities such as the structure, background, and objects of the image. As a result, the transition effects produced using this approach often appear highly natural.",
1452
+ "bbox": [
1453
+ 169,
1454
+ 708,
1455
+ 826,
1456
+ 848
1457
+ ],
1458
+ "page_idx": 12
1459
+ },
1460
+ {
1461
+ "type": "text",
1462
+ "text": "Text-video Unalignment. In our S2L model, we aim to optimize $p_{\\theta}(z_0|c,\\tilde{z}_0)$ which $\\tilde{z}_0$ represents the latent code of the unmasked condition image. However, in our training dataset, videos $z_0$ , unmasked frames $\\tilde{z}_0$ , and captions/prompts $(c)$ are not completely independent and exhibit strong correlations. Consequently, when there is no inherent connection between the given unmasked image and caption, it can lead to discontinuities or difficulties in aligning with video-text alignment.",
1463
+ "bbox": [
1464
+ 169,
1465
+ 854,
1466
+ 823,
1467
+ 925
1468
+ ],
1469
+ "page_idx": 12
1470
+ },
1471
+ {
1472
+ "type": "header",
1473
+ "text": "Published as a conference paper at ICLR 2024",
1474
+ "bbox": [
1475
+ 171,
1476
+ 32,
1477
+ 478,
1478
+ 47
1479
+ ],
1480
+ "page_idx": 12
1481
+ },
1482
+ {
1483
+ "type": "page_number",
1484
+ "text": "13",
1485
+ "bbox": [
1486
+ 490,
1487
+ 946,
1488
+ 508,
1489
+ 959
1490
+ ],
1491
+ "page_idx": 12
1492
+ },
1493
+ {
1494
+ "type": "image",
1495
+ "img_path": "images/43c293381ab9bb0c2488eb7e22fec6878660490a4613c3691faf21be9b9960eb.jpg",
1496
+ "image_caption": [
1497
+ "Figure 12: Failure cases for transition with watermarks. Best view with Acrobat Reader. Click the images to play the videos."
1498
+ ],
1499
+ "image_footnote": [
1500
+ "A panda is in a bamboo forest, The scene has changed from the sea The scene has changed from the shifting from sketch-like to realistic into a playing trumpet raccoon. panda watching television to the style."
1501
+ ],
1502
+ "bbox": [
1503
+ 181,
1504
+ 200,
1505
+ 282,
1506
+ 252
1507
+ ],
1508
+ "page_idx": 13
1509
+ },
1510
+ {
1511
+ "type": "image",
1512
+ "img_path": "images/79a16785fe4f8002117f63f08f29f951836be36a28d4732d7d2e7022895b2308.jpg",
1513
+ "image_caption": [],
1514
+ "image_footnote": [],
1515
+ "bbox": [
1516
+ 287,
1517
+ 202,
1518
+ 393,
1519
+ 252
1520
+ ],
1521
+ "page_idx": 13
1522
+ },
1523
+ {
1524
+ "type": "image",
1525
+ "img_path": "images/fd791af1aea05f540c04c289cd82bc5045957844e84f741e111f444b1be94d79.jpg",
1526
+ "image_caption": [],
1527
+ "image_footnote": [],
1528
+ "bbox": [
1529
+ 393,
1530
+ 202,
1531
+ 500,
1532
+ 252
1533
+ ],
1534
+ "page_idx": 13
1535
+ },
1536
+ {
1537
+ "type": "image",
1538
+ "img_path": "images/5da44f6b73aaadcf2d9056622bc32d72921da7c7ba7b79ac0239359ec5dbe32e.jpg",
1539
+ "image_caption": [],
1540
+ "image_footnote": [],
1541
+ "bbox": [
1542
+ 500,
1543
+ 202,
1544
+ 602,
1545
+ 252
1546
+ ],
1547
+ "page_idx": 13
1548
+ },
1549
+ {
1550
+ "type": "image",
1551
+ "img_path": "images/38336a06fe54cda5fafdae16f4cb3e2a5855fb7b92e291d16c257345e5bf7cec.jpg",
1552
+ "image_caption": [
1553
+ "Transition Video 3"
1554
+ ],
1555
+ "image_footnote": [],
1556
+ "bbox": [
1557
+ 604,
1558
+ 202,
1559
+ 707,
1560
+ 252
1561
+ ],
1562
+ "page_idx": 13
1563
+ },
1564
+ {
1565
+ "type": "image",
1566
+ "img_path": "images/bdc188068c6d1fdc0cbf39d69e899281098eecffacab0fb92720f3311d76c992.jpg",
1567
+ "image_caption": [],
1568
+ "image_footnote": [],
1569
+ "bbox": [
1570
+ 709,
1571
+ 202,
1572
+ 813,
1573
+ 252
1574
+ ],
1575
+ "page_idx": 13
1576
+ },
1577
+ {
1578
+ "type": "text",
1579
+ "text": "Additionally, we have observed that the quality of generated videos would be influenced to some extent by the given prompt. Providing prompts that align well with the realistic scenario and have a resemblance to unmasked videos can yield better results. Ensuring the provision of more suitable prompts in the context of generating long videos is a topic we will explore in our subsequent research.",
1580
+ "bbox": [
1581
+ 169,
1582
+ 359,
1583
+ 823,
1584
+ 429
1585
+ ],
1586
+ "page_idx": 13
1587
+ },
1588
+ {
1589
+ "type": "image",
1590
+ "img_path": "images/bcc7b01d9ab3806737aae2078f271af05dbb20584900446e61bcdfff7a1d4ee4.jpg",
1591
+ "image_caption": [
1592
+ "Scenes",
1593
+ "Transition Video 1",
1594
+ "Transition Video 2",
1595
+ "Figure 13: Transition samples. In each case, transitions are generated by the same prompt with different random seeds. Best view with Acrobat Reader. Click the images to play videos."
1596
+ ],
1597
+ "image_footnote": [],
1598
+ "bbox": [
1599
+ 173,
1600
+ 441,
1601
+ 267,
1602
+ 867
1603
+ ],
1604
+ "page_idx": 13
1605
+ },
1606
+ {
1607
+ "type": "header",
1608
+ "text": "Published as a conference paper at ICLR 2024",
1609
+ "bbox": [
1610
+ 171,
1611
+ 32,
1612
+ 478,
1613
+ 47
1614
+ ],
1615
+ "page_idx": 13
1616
+ },
1617
+ {
1618
+ "type": "page_number",
1619
+ "text": "14",
1620
+ "bbox": [
1621
+ 490,
1622
+ 946,
1623
+ 508,
1624
+ 959
1625
+ ],
1626
+ "page_idx": 13
1627
+ },
1628
+ {
1629
+ "type": "text",
1630
+ "text": "A.2.1 IMAGE-TO-VIDEO ANIMATION",
1631
+ "text_level": 1,
1632
+ "bbox": [
1633
+ 171,
1634
+ 103,
1635
+ 446,
1636
+ 118
1637
+ ],
1638
+ "page_idx": 14
1639
+ },
1640
+ {
1641
+ "type": "text",
1642
+ "text": "We present additional outcomes of image-to-video animation, as depicted in Fig. 14. For each instance, the reference image is displayed on the left, while the corresponding animation video is showcased on the right. Notably, our model demonstrates the ability to accommodate images of various sizes. The figure showcases the animation results obtained from both square and rectangular images. The reference images in the first three rows are generated from Midjourney. The reference images in the last two rows are generated from Stable Diffusion XL.",
1643
+ "bbox": [
1644
+ 169,
1645
+ 127,
1646
+ 826,
1647
+ 213
1648
+ ],
1649
+ "page_idx": 14
1650
+ },
1651
+ {
1652
+ "type": "text",
1653
+ "text": "(a) First Frame is generated from Midjourney",
1654
+ "bbox": [
1655
+ 361,
1656
+ 549,
1657
+ 635,
1658
+ 564
1659
+ ],
1660
+ "page_idx": 14
1661
+ },
1662
+ {
1663
+ "type": "text",
1664
+ "text": "(b) First Frame is generated from Stable Diffusion XL",
1665
+ "bbox": [
1666
+ 336,
1667
+ 729,
1668
+ 658,
1669
+ 743
1670
+ ],
1671
+ "page_idx": 14
1672
+ },
1673
+ {
1674
+ "type": "text",
1675
+ "text": "Figure 14: Image-to-video animation results. Best view with Acrobat Reader. Click the images to play the transition videos.",
1676
+ "bbox": [
1677
+ 169,
1678
+ 744,
1679
+ 823,
1680
+ 773
1681
+ ],
1682
+ "page_idx": 14
1683
+ },
1684
+ {
1685
+ "type": "header",
1686
+ "text": "Published as a conference paper at ICLR 2024",
1687
+ "bbox": [
1688
+ 171,
1689
+ 32,
1690
+ 478,
1691
+ 47
1692
+ ],
1693
+ "page_idx": 14
1694
+ },
1695
+ {
1696
+ "type": "page_number",
1697
+ "text": "15",
1698
+ "bbox": [
1699
+ 490,
1700
+ 946,
1701
+ 508,
1702
+ 960
1703
+ ],
1704
+ "page_idx": 14
1705
+ }
1706
+ ]
2024/SEINE_ Short-to-Long Video Diffusion Model for Generative Transition and Prediction/4e0669d7-b95d-4ff4-97bd-d87bb4ad89af_model.json ADDED
@@ -0,0 +1,2342 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ [
2
+ [
3
+ {
4
+ "type": "header",
5
+ "bbox": [
6
+ 0.173,
7
+ 0.033,
8
+ 0.48,
9
+ 0.049
10
+ ],
11
+ "angle": 0,
12
+ "content": "Published as a conference paper at ICLR 2024"
13
+ },
14
+ {
15
+ "type": "title",
16
+ "bbox": [
17
+ 0.172,
18
+ 0.099,
19
+ 0.825,
20
+ 0.149
21
+ ],
22
+ "angle": 0,
23
+ "content": "SEINE: SHORT-TO-LONG VIDEO DIFFUSION MODEL FOR GENERATIVE TRANSITION AND PREDICTION"
24
+ },
25
+ {
26
+ "type": "text",
27
+ "bbox": [
28
+ 0.185,
29
+ 0.169,
30
+ 0.71,
31
+ 0.185
32
+ ],
33
+ "angle": 0,
34
+ "content": "Xinyuan Chen\\(^{1*}\\) Yaohui Wang\\(^{1*}\\) Lingjun Zhang\\(^{2,1‡}\\) Shaobin Zhuang\\(^{1,3}\\)"
35
+ },
36
+ {
37
+ "type": "text",
38
+ "bbox": [
39
+ 0.185,
40
+ 0.185,
41
+ 0.735,
42
+ 0.2
43
+ ],
44
+ "angle": 0,
45
+ "content": "Xin Ma\\(^{4,1\\ddagger}\\) Jiashuo Yu\\(^{1}\\) Yali Wang\\(^{5,1}\\) Dahua Lin\\(^{1\\dagger}\\) Yu Qiao\\(^{1\\dagger}\\) Ziwei Liu\\(^{6\\dagger}\\)"
46
+ },
47
+ {
48
+ "type": "text",
49
+ "bbox": [
50
+ 0.184,
51
+ 0.2,
52
+ 0.695,
53
+ 0.216
54
+ ],
55
+ "angle": 0,
56
+ "content": "<sup>1</sup> Shanghai Artificial Intelligence Laboratory, <sup>2</sup> East China Normal University"
57
+ },
58
+ {
59
+ "type": "text",
60
+ "bbox": [
61
+ 0.183,
62
+ 0.215,
63
+ 0.725,
64
+ 0.23
65
+ ],
66
+ "angle": 0,
67
+ "content": "\\(^{3}\\) Shanghai Jiao Tong University, \\(^{4}\\) Dept of Data Science & AI, Monash University"
68
+ },
69
+ {
70
+ "type": "text",
71
+ "bbox": [
72
+ 0.183,
73
+ 0.23,
74
+ 0.691,
75
+ 0.245
76
+ ],
77
+ "angle": 0,
78
+ "content": "5 Shenzhen Institute of Advanced Technology, Chinese Academy of Sciences"
79
+ },
80
+ {
81
+ "type": "text",
82
+ "bbox": [
83
+ 0.183,
84
+ 0.245,
85
+ 0.473,
86
+ 0.26
87
+ ],
88
+ "angle": 0,
89
+ "content": "\\(^{6}\\) S-Lab, Nanyang Technological University"
90
+ },
91
+ {
92
+ "type": "list",
93
+ "bbox": [
94
+ 0.183,
95
+ 0.2,
96
+ 0.725,
97
+ 0.26
98
+ ],
99
+ "angle": 0,
100
+ "content": null
101
+ },
102
+ {
103
+ "type": "title",
104
+ "bbox": [
105
+ 0.451,
106
+ 0.296,
107
+ 0.547,
108
+ 0.31
109
+ ],
110
+ "angle": 0,
111
+ "content": "ABSTRACT"
112
+ },
113
+ {
114
+ "type": "text",
115
+ "bbox": [
116
+ 0.23,
117
+ 0.327,
118
+ 0.769,
119
+ 0.593
120
+ ],
121
+ "angle": 0,
122
+ "content": "Recently video generation has achieved substantial progress with realistic results. Nevertheless, existing AI-generated videos are usually very short clips (\"shot-level\") depicting a single scene. To deliver a coherent long video (\"story-level\"), it is desirable to have creative transition and prediction effects across different clips. This paper presents a short-to-long (S2L) video diffusion model, SEINE, that focuses on generative transition and prediction. The goal is to generate high-quality long videos with smooth and creative transitions between scenes and varying lengths of shot-level videos. Specifically, we propose a random-mask video diffusion model to automatically generate transitions based on textual descriptions. By providing the images of different scenes as inputs, combined with text-based control, our model generates transition videos that ensure coherence and visual quality. Furthermore, the model can be readily extended to various tasks such as image-to-video animation and auto-regressive video prediction. To conduct a comprehensive evaluation of this new generative task, we propose three assessing criteria for smooth and creative transition: temporal consistency, semantic similarity, and video-text semantic alignment. Extensive experiments validate the effectiveness of our approach over existing methods for generative transition and prediction, enabling the creation of story-level long videos. Project page: https://vchitec.github.io/SEINE-project/."
123
+ },
124
+ {
125
+ "type": "text",
126
+ "bbox": [
127
+ 0.622,
128
+ 0.707,
129
+ 0.812,
130
+ 0.72
131
+ ],
132
+ "angle": 0,
133
+ "content": "Animation: a dog in spacesuit."
134
+ },
135
+ {
136
+ "type": "image",
137
+ "bbox": [
138
+ 0.174,
139
+ 0.746,
140
+ 0.309,
141
+ 0.813
142
+ ],
143
+ "angle": 0,
144
+ "content": null
145
+ },
146
+ {
147
+ "type": "image_caption",
148
+ "bbox": [
149
+ 0.172,
150
+ 0.813,
151
+ 0.449,
152
+ 0.838
153
+ ],
154
+ "angle": 0,
155
+ "content": "Transition: The panda is working in the office and reading a paper"
156
+ },
157
+ {
158
+ "type": "image",
159
+ "bbox": [
160
+ 0.312,
161
+ 0.746,
162
+ 0.447,
163
+ 0.813
164
+ ],
165
+ "angle": 0,
166
+ "content": null
167
+ },
168
+ {
169
+ "type": "image",
170
+ "bbox": [
171
+ 0.451,
172
+ 0.745,
173
+ 0.535,
174
+ 0.813
175
+ ],
176
+ "angle": 0,
177
+ "content": null
178
+ },
179
+ {
180
+ "type": "image",
181
+ "bbox": [
182
+ 0.537,
183
+ 0.746,
184
+ 0.621,
185
+ 0.812
186
+ ],
187
+ "angle": 0,
188
+ "content": null
189
+ },
190
+ {
191
+ "type": "image_caption",
192
+ "bbox": [
193
+ 0.451,
194
+ 0.812,
195
+ 0.62,
196
+ 0.836
197
+ ],
198
+ "angle": 0,
199
+ "content": "Transition: Spider-man becomes a sand sculpture."
200
+ },
201
+ {
202
+ "type": "image_caption",
203
+ "bbox": [
204
+ 0.621,
205
+ 0.812,
206
+ 0.813,
207
+ 0.837
208
+ ],
209
+ "angle": 0,
210
+ "content": "Prediction: Iron Man flying in the sky."
211
+ },
212
+ {
213
+ "type": "image_caption",
214
+ "bbox": [
215
+ 0.171,
216
+ 0.849,
217
+ 0.825,
218
+ 0.893
219
+ ],
220
+ "angle": 0,
221
+ "content": "Figure 1: Generated samples. Our S2L model is able to synthesize high-definition transition (shown in the left two columns) and prediction videos (shown in the right column) by giving textual descriptions. Best view with Acrobat Reader. Click the images to play the videos."
222
+ },
223
+ {
224
+ "type": "page_footnote",
225
+ "bbox": [
226
+ 0.195,
227
+ 0.91,
228
+ 0.733,
229
+ 0.925
230
+ ],
231
+ "angle": 0,
232
+ "content": "*Equal contribution. † Correspondence. ‡ Work done as interns at Shanghai AI Laboratory."
233
+ },
234
+ {
235
+ "type": "page_number",
236
+ "bbox": [
237
+ 0.494,
238
+ 0.949,
239
+ 0.504,
240
+ 0.96
241
+ ],
242
+ "angle": 0,
243
+ "content": "1"
244
+ }
245
+ ],
246
+ [
247
+ {
248
+ "type": "header",
249
+ "bbox": [
250
+ 0.174,
251
+ 0.033,
252
+ 0.48,
253
+ 0.049
254
+ ],
255
+ "angle": 0,
256
+ "content": "Published as a conference paper at ICLR 2024"
257
+ },
258
+ {
259
+ "type": "image",
260
+ "bbox": [
261
+ 0.175,
262
+ 0.101,
263
+ 0.827,
264
+ 0.299
265
+ ],
266
+ "angle": 0,
267
+ "content": null
268
+ },
269
+ {
270
+ "type": "image_caption",
271
+ "bbox": [
272
+ 0.171,
273
+ 0.308,
274
+ 0.825,
275
+ 0.366
276
+ ],
277
+ "angle": 0,
278
+ "content": "Figure 2: Short-to-long (S2L) pipeline. Our S2L video generation model enables the seamless connection of shots from different scenes with transitions and generates videos of varying lengths through autoregressive prediction, facilitating the creation of story-level videos. The red box represents the transition video, while the blue box represents a long video generated through prediction."
279
+ },
280
+ {
281
+ "type": "title",
282
+ "bbox": [
283
+ 0.174,
284
+ 0.4,
285
+ 0.338,
286
+ 0.415
287
+ ],
288
+ "angle": 0,
289
+ "content": "1 INTRODUCTION"
290
+ },
291
+ {
292
+ "type": "text",
293
+ "bbox": [
294
+ 0.171,
295
+ 0.438,
296
+ 0.825,
297
+ 0.537
298
+ ],
299
+ "angle": 0,
300
+ "content": "Currently, with the success of diffusion model-based (Ho et al., 2020; Song et al., 2021a;b) text-to-image generation models (Ramesh et al., 2021; 2022; Sahara et al., 2022; Balaji et al., 2022; Rombach et al., 2022), a series of video generation works (Singer et al., 2023; Ho et al., 2022; Blattmann et al., 2023; Zhou et al., 2022; He et al., 2022; Wang et al., 2023b) have emerged and demonstrated impressive results. However, current video generation methods typically only yield \"shot-level\" video generation, which only consists of around a few seconds and depicts a single scene. Such shot-level short videos fall short of the demands for cinematic and film productions."
301
+ },
302
+ {
303
+ "type": "text",
304
+ "bbox": [
305
+ 0.171,
306
+ 0.542,
307
+ 0.827,
308
+ 0.738
309
+ ],
310
+ "angle": 0,
311
+ "content": "In cinematic or industrial-level video productions, \"story-level\" long video is typically characterized by the creation of distinct shots with different scenes. These individual shots of various lengths are interconnected through techniques like transitions and editing, providing a way for longer video and more intricate visual storytelling. The process of combining scenes or shots in film and video editing, known as transition, plays a crucial role in post-production. Traditional transition methods, including dissolves, fades, and wipes, rely on predefined algorithms or established interfaces. However, these methods lack flexibility and are often limited in their capabilities. An alternative approach to achieve seamless and smooth transitions involves the use of diverse and imaginative shots to smoothly connect between scenes. This technique, commonly employed in films, cannot be directly generated using predefined programs. In this work, we present our model to address the less common problem of generating seamless and smooth transitions by focusing on generating intermediate frames between two different scenes. We establish three criteria that the generated transition frames should meet: 1) semantic relevance to the given scene image; 2) coherence and smoothness within frames; and 3) consistency with the provided text."
312
+ },
313
+ {
314
+ "type": "text",
315
+ "bbox": [
316
+ 0.171,
317
+ 0.744,
318
+ 0.827,
319
+ 0.925
320
+ ],
321
+ "angle": 0,
322
+ "content": "In this work, we present a short-to-long (S2L) video diffusion model, SEINE, for generative transition and prediction. The goal is to generate high-quality long videos with smooth and creative transitions between scenes and varying lengths of shot-level videos. The pipeline is shown in Fig. 2. We delve into the study of a new task, \"generative transition\", which aims at producing diverse and creative transition video segments to connect two different scenes. Alongside, we propose an approach to tackle this task and establish criteria for evaluating the efficacy of methods. We approach the problem of transitions as a conditional video generation task. By providing the initial and final frames of a given scene as inputs, we employ a text-based and video conditioning method to generate a smooth transition video in between. This approach allows us to effectively control the transition process and ensure the coherence and visual quality of the generated videos. To this end, we design a flexible random-mask diffusion model. The model is of capable generating transition shots by giving the first frame of one scene and the last frame of another scene, the scene transition is generated by a given textual description. Our model can be extended to image-to-video animation"
323
+ },
324
+ {
325
+ "type": "page_number",
326
+ "bbox": [
327
+ 0.494,
328
+ 0.949,
329
+ 0.504,
330
+ 0.96
331
+ ],
332
+ "angle": 0,
333
+ "content": "2"
334
+ }
335
+ ],
336
+ [
337
+ {
338
+ "type": "header",
339
+ "bbox": [
340
+ 0.173,
341
+ 0.033,
342
+ 0.48,
343
+ 0.049
344
+ ],
345
+ "angle": 0,
346
+ "content": "Published as a conference paper at ICLR 2024"
347
+ },
348
+ {
349
+ "type": "text",
350
+ "bbox": [
351
+ 0.171,
352
+ 0.104,
353
+ 0.825,
354
+ 0.133
355
+ ],
356
+ "angle": 0,
357
+ "content": "and autoregressive video prediction, enabling the generation of long-shot videos and dynamic video creation in film production."
358
+ },
359
+ {
360
+ "type": "text",
361
+ "bbox": [
362
+ 0.171,
363
+ 0.14,
364
+ 0.827,
365
+ 0.225
366
+ ],
367
+ "angle": 0,
368
+ "content": "We summarize our contributions as follows: 1) We propose a new problem of generative transition and prediction, aiming at coherent \"story-level\" long video generation with smooth and creative scene transition and varying lengths of videos; 2) We present a short-to-long video diffusion model, SEINE, focusing on generative transition and prediction; 3) we propose three assessing criteria for transition and extensive experiments demonstrate our method the superior performance on the metrics, as well as its ability to be applied across versatile applications."
369
+ },
370
+ {
371
+ "type": "title",
372
+ "bbox": [
373
+ 0.173,
374
+ 0.259,
375
+ 0.356,
376
+ 0.274
377
+ ],
378
+ "angle": 0,
379
+ "content": "2 RELATED WORKS"
380
+ },
381
+ {
382
+ "type": "text",
383
+ "bbox": [
384
+ 0.171,
385
+ 0.299,
386
+ 0.827,
387
+ 0.537
388
+ ],
389
+ "angle": 0,
390
+ "content": "Text-to-Video Generation. In recent years, diffusion models (Ho et al., 2020; Song et al., 2021a;b) have significantly advanced the field of text-to-image (T2I) generation. Existing methods (Ramesh et al., 2021; He et al., 2022; Ramesh et al., 2022; Sahara et al., 2022) have made remarkable progress in generating realistic images that are closely related to textual prompts. Recent advancements in T2I generation have led to the expansion of diffusion models to develop video generation from domain-specific models (Tulyakov et al., 2018; Wang et al., 2020a;b; Tian et al., 2021; Skorokhodov et al., 2022) to general text-to-video (T2V) models. This extension involves adapting the conventional 2D UNet architecture into a spatial-temporal 3D network to establish temporal correlations between video frames. Make-A-Video (Singer et al., 2023) and Imagen Video Ho et al. (2022) leverage text-to-image diffusion models of DALL-E2 (Ramesh et al., 2022) and Imagen (Saharia et al., 2022) respectively for large-scale T2V generation. PYoCo (Ge et al., 2023) presented a noise prior approach and utilized a pre-trained eDiff-I (Balaji et al., 2022) as initialization. An alternative approach involves constructing a T2V model based on pre-trained Stable Diffusion and subsequently fine-tuning the model either entirely (Zhou et al., 2022; He et al., 2022) or partially (Blattmann et al., 2023) on video data. In addition, LaVie (Wang et al., 2023b) fine-tuned the entire T2V model on both image and video datasets. While these methods demonstrate the potential of text-to-video synthesis, they are mostly limited to generating short videos."
391
+ },
392
+ {
393
+ "type": "text",
394
+ "bbox": [
395
+ 0.171,
396
+ 0.542,
397
+ 0.825,
398
+ 0.683
399
+ ],
400
+ "angle": 0,
401
+ "content": "Transition Generation. Scene transition is a less common problem but is crucial in storytelling, serving as the bridge that connects different narrative moments. They facilitate the smooth progression of a story through shifts in time, place, or perspective. Several techniques are employed to achieve effective scene transitions, such as \"fade\", \"dissolves\", \"wipes\", \"IRIS\" or simply cut where a scene abruptly transitions to another. These transitions can be achieved using pre-defined algorithms with fixed patterns. Morphing (Wolberg, 1998; Shechtman et al., 2010) enables smooth transitions involving finding pixel-level similarities and estimating their transitional offsets. Existing generative models (Van Den Oord et al., 2017) can leverage linear interpolation at the latent code level to capture semantic similarities. This approach has been widely explored in various works, e.g., style transfer (Chen et al., 2018), object transfiguration (Sauer et al., 2022; Kang et al., 2023)."
402
+ },
403
+ {
404
+ "type": "text",
405
+ "bbox": [
406
+ 0.171,
407
+ 0.688,
408
+ 0.827,
409
+ 0.925
410
+ ],
411
+ "angle": 0,
412
+ "content": "Long Video Generation. Long video generation is a long-standing challenge in the field. Earlier works (Skorokhodov et al., 2022; Yu et al., 2022; Chen et al., 2020) employing generative adversarial networks (GANs) or variational auto-encoder (VAE) to model video distributions. VideoGPT (Yan et al., 2021) employs a combination of VQVAE (Van Den Oord et al., 2017) and transformer architecture to sequentially produce tokens within a discrete latent space. TATS (Ge et al., 2022) trains a time-agnostic VQGAN and subsequently learns a time-sensitive transformer based on the latent features. Phenaki (Villegas et al., 2023) uses a transformer-based model to compress videos into discrete tokens and generate longer continuous videos based on a sequence of text prompts. Recently, Diffusion Models (DMs) (Ho et al., 2020; Song et al., 2021a; Nichol & Dhariwal, 2021) have made significant advancements in video generation. LEO (Wang et al., 2023c) proposed to produce long human videos in latent motion space. LVDM (He et al., 2022) focuses on generating shot-level long videos by employing a hierarchical latent diffusion model. NUWA-XL (Yin et al., 2023) employs a hierarchical diffusion model to generate long videos, but it has only been trained on the cartoon FlintstonesHD dataset due to the lack of datasets on natural videos. On the other hand, Gen-L-Video (Wang et al., 2023a) generates long videos by utilizing existing short text-to-video generation models and treating them as overlapping short video clips. In contrast, our approach views long videos as compositions of various scenes and shot-level videos of different lengths. Our"
413
+ },
414
+ {
415
+ "type": "page_number",
416
+ "bbox": [
417
+ 0.494,
418
+ 0.949,
419
+ 0.506,
420
+ 0.96
421
+ ],
422
+ "angle": 0,
423
+ "content": "3"
424
+ }
425
+ ],
426
+ [
427
+ {
428
+ "type": "header",
429
+ "bbox": [
430
+ 0.173,
431
+ 0.033,
432
+ 0.48,
433
+ 0.049
434
+ ],
435
+ "angle": 0,
436
+ "content": "Published as a conference paper at ICLR 2024"
437
+ },
438
+ {
439
+ "type": "image",
440
+ "bbox": [
441
+ 0.174,
442
+ 0.104,
443
+ 0.825,
444
+ 0.237
445
+ ],
446
+ "angle": 0,
447
+ "content": null
448
+ },
449
+ {
450
+ "type": "image_caption",
451
+ "bbox": [
452
+ 0.17,
453
+ 0.251,
454
+ 0.825,
455
+ 0.308
456
+ ],
457
+ "angle": 0,
458
+ "content": "Figure 3: Notations and schematic representation of generative transition objective. Generative transition exhibits semantic similarity between each frame \\( x^n \\) with the two scene images; each frame \\( x^n \\) and its neighboring frames \\( x^{n-1} \\) and \\( x^{n+1} \\) should be temporal coherence; the semantics of generated frames should be alignment to the provided textual description."
459
+ },
460
+ {
461
+ "type": "text",
462
+ "bbox": [
463
+ 0.171,
464
+ 0.334,
465
+ 0.825,
466
+ 0.364
467
+ ],
468
+ "angle": 0,
469
+ "content": "short-to-long model aims to generate \"story-level\" videos containing continuous multi-scene videos with varying shot lengths."
470
+ },
471
+ {
472
+ "type": "title",
473
+ "bbox": [
474
+ 0.173,
475
+ 0.383,
476
+ 0.343,
477
+ 0.398
478
+ ],
479
+ "angle": 0,
480
+ "content": "3 METHODOLOGY"
481
+ },
482
+ {
483
+ "type": "title",
484
+ "bbox": [
485
+ 0.173,
486
+ 0.415,
487
+ 0.327,
488
+ 0.428
489
+ ],
490
+ "angle": 0,
491
+ "content": "3.1 PRELIMINARIES"
492
+ },
493
+ {
494
+ "type": "text",
495
+ "bbox": [
496
+ 0.171,
497
+ 0.44,
498
+ 0.825,
499
+ 0.496
500
+ ],
501
+ "angle": 0,
502
+ "content": "Text-to-Image Diffusion Model. Stable Diffusion (Rombach et al., 2022) performs image diffusion in a compressed latent space of an autoencoder (i.e., VQ-GAN and VQ-VAE). During training, a given image sample \\( x_0 \\) is encoded into the latent code \\( z = \\mathcal{E}(x_0) \\) and corrupted by Gaussian noise from a pre-defined Markov chain:"
503
+ },
504
+ {
505
+ "type": "equation",
506
+ "bbox": [
507
+ 0.365,
508
+ 0.505,
509
+ 0.825,
510
+ 0.524
511
+ ],
512
+ "angle": 0,
513
+ "content": "\\[\nq \\left(z _ {t} \\mid z _ {t - 1}\\right) = \\mathcal {N} \\left(z _ {t}; \\sqrt {1 - \\beta_ {t}} z _ {t - 1}, \\beta_ {t} I\\right) \\tag {1}\n\\]"
514
+ },
515
+ {
516
+ "type": "text",
517
+ "bbox": [
518
+ 0.171,
519
+ 0.529,
520
+ 0.825,
521
+ 0.572
522
+ ],
523
+ "angle": 0,
524
+ "content": "for \\( t = 1, \\dots, T \\), with \\( T \\) being the number of steps in the forward diffusion process. The sequence of hyperparameters \\( \\beta_{t} \\) determines the noise strength at each step. The above iterative process can be reformulated in a closed-form manner as follows:"
525
+ },
526
+ {
527
+ "type": "equation",
528
+ "bbox": [
529
+ 0.367,
530
+ 0.579,
531
+ 0.825,
532
+ 0.596
533
+ ],
534
+ "angle": 0,
535
+ "content": "\\[\nz _ {t} = \\sqrt {\\bar {\\alpha} _ {t}} z _ {0} + \\sqrt {1 - \\bar {\\alpha} _ {t}} \\epsilon , \\epsilon \\sim \\mathcal {N} (0, I) \\tag {2}\n\\]"
536
+ },
537
+ {
538
+ "type": "text",
539
+ "bbox": [
540
+ 0.171,
541
+ 0.604,
542
+ 0.825,
543
+ 0.633
544
+ ],
545
+ "angle": 0,
546
+ "content": "where \\(\\bar{\\alpha}_t = \\prod_{i=1}^t \\alpha_t, \\alpha_t = 1 - \\beta_t\\). The model adopts \\(\\epsilon\\)-prediction and DDPM to learn a function \\(\\epsilon_\\theta\\) is minimized by:"
547
+ },
548
+ {
549
+ "type": "equation",
550
+ "bbox": [
551
+ 0.364,
552
+ 0.632,
553
+ 0.825,
554
+ 0.649
555
+ ],
556
+ "angle": 0,
557
+ "content": "\\[\n\\mathcal {L} = \\mathbf {E} _ {z _ {0}, c, \\epsilon \\sim \\mathcal {N} (0, I), t} [ \\| \\epsilon - \\epsilon_ {\\theta} (z _ {t}, t, c) \\| _ {2} ^ {2} ] \\tag {3}\n\\]"
558
+ },
559
+ {
560
+ "type": "text",
561
+ "bbox": [
562
+ 0.171,
563
+ 0.651,
564
+ 0.825,
565
+ 0.68
566
+ ],
567
+ "angle": 0,
568
+ "content": "where \\(c\\) indicates the condition of the textual description, \\(\\epsilon\\) is drawn from a diagonal Gaussian distribution. The \\(\\epsilon_{\\theta}\\) is commonly implemented by a Unet, where \\(\\theta\\) is a parameterized neural network."
569
+ },
570
+ {
571
+ "type": "text",
572
+ "bbox": [
573
+ 0.171,
574
+ 0.687,
575
+ 0.826,
576
+ 0.784
577
+ ],
578
+ "angle": 0,
579
+ "content": "Text-to-Video Diffusion Model. Our framework is constructed upon a pre-trained diffusion-based T2V model, LaVie (Wang et al., 2023b), which is a cascaded framework that includes a base T2V model, a temporal interpolation model, and a video super-resolution model. LaVie-base, which is part of the LaVie framework, is developed using Stable Diffusion pre-trained model and incorporates a temporal attention module and image-video joint fine-tuning. To benefit from its ability to generate visually and temporally consistent videos with diverse content, we utilize the pre-trained LaVie-base model as the initialization for our framework."
580
+ },
581
+ {
582
+ "type": "title",
583
+ "bbox": [
584
+ 0.173,
585
+ 0.801,
586
+ 0.4,
587
+ 0.815
588
+ ],
589
+ "angle": 0,
590
+ "content": "3.2 GENERATIVE TRANSITION"
591
+ },
592
+ {
593
+ "type": "text",
594
+ "bbox": [
595
+ 0.171,
596
+ 0.827,
597
+ 0.827,
598
+ 0.926
599
+ ],
600
+ "angle": 0,
601
+ "content": "The objective of the transition task is to generate a sequence of intermediate frames, denoted as \\( x^n \\), between two given images \\( S_1 \\) and \\( S_2 \\), using a transition description caption \\( c \\). We define \\( x^0 \\) as \\( S_1 \\) and \\( x^N \\) as \\( S_2 \\), so the sequence consists of \\( N - 2 \\) target (in-between) frames. The generated sequence should satisfy the following three properties, as shown in Fig. 3: 1) Temporal Coherence: The changes in visual content across the sequence should be smooth and coherent over time. This property ensures that the generated video appears natural and visually consistent. 2) Semantic Similarity: The semantic content of each generated intermediate frame should resemble either of"
602
+ },
603
+ {
604
+ "type": "page_number",
605
+ "bbox": [
606
+ 0.494,
607
+ 0.949,
608
+ 0.504,
609
+ 0.96
610
+ ],
611
+ "angle": 0,
612
+ "content": "4"
613
+ }
614
+ ],
615
+ [
616
+ {
617
+ "type": "header",
618
+ "bbox": [
619
+ 0.173,
620
+ 0.033,
621
+ 0.48,
622
+ 0.049
623
+ ],
624
+ "angle": 0,
625
+ "content": "Published as a conference paper at ICLR 2024"
626
+ },
627
+ {
628
+ "type": "image",
629
+ "bbox": [
630
+ 0.173,
631
+ 0.074,
632
+ 0.813,
633
+ 0.257
634
+ ],
635
+ "angle": 0,
636
+ "content": null
637
+ },
638
+ {
639
+ "type": "image_caption",
640
+ "bbox": [
641
+ 0.17,
642
+ 0.265,
643
+ 0.825,
644
+ 0.322
645
+ ],
646
+ "angle": 0,
647
+ "content": "Figure 4: Overview of our proposed method. We present our S2L generation model for generating transition video and long video prediction. Our model supports text as input, which is processed through a clip encoder and injected into the model (blue part). For brevity, we omit the details of the text injection, which is identical to the stable diffusion model."
648
+ },
649
+ {
650
+ "type": "text",
651
+ "bbox": [
652
+ 0.17,
653
+ 0.349,
654
+ 0.825,
655
+ 0.419
656
+ ],
657
+ "angle": 0,
658
+ "content": "the source images to some extent. This prevents the appearance of the sequence from deviating too much from the source scene images. Additionally, the similarity should gradually change from one source image to the other. 3) Video-text Alignment: The generated frames should align with the provided text description. This alignment allows us to control the transition between the two source images using the text description."
659
+ },
660
+ {
661
+ "type": "title",
662
+ "bbox": [
663
+ 0.172,
664
+ 0.436,
665
+ 0.525,
666
+ 0.451
667
+ ],
668
+ "angle": 0,
669
+ "content": "3.3 SHORT-TO-LONGVIDEODIFFUSIONMODEL"
670
+ },
671
+ {
672
+ "type": "text",
673
+ "bbox": [
674
+ 0.17,
675
+ 0.462,
676
+ 0.825,
677
+ 0.657
678
+ ],
679
+ "angle": 0,
680
+ "content": "We develop a diffusion-based model for S2L videos via transition generation and video prediction. In order to generate unseen frames of transition and prediction, based on visible conditional images or videos, our S2L video diffusion model incorporates a random mask module, as shown in Fig. 4. Given the video dataset \\( p_{\\mathrm{video}} \\), we take a \\( N \\)-frame original video denoted as \\( x_0 \\in \\mathbb{R}^{N \\times 3 \\times H \\times W} \\) where \\( x_0 \\) follows the distribution \\( p_{\\mathrm{video}} \\). The frames of video \\( x_0 \\) are first encoded by the pre-trained variational auto-encoder simultaneously as \\( z_0 \\in \\mathbb{R}^{n \\times c \\times h \\times w} \\), where \\( c, h \\) and \\( w \\) indicate the channel, height, and width of the latent code, \\( n \\) represents the frame number. To achieve more controllable transition videos and leverage the capability of short text-to-video generation, our model also takes a textual description \\( c \\) as an input. The goal of our model is to learn a dual condition diffusion model: \\( p_{\\theta}(z_0 | c, \\tilde{z}_0) \\). In the training stage, the latent code of video is corrupted as Eq. 3: \\( z_t = \\sqrt{\\alpha_t} z_0 + \\sqrt{1 - \\bar{\\alpha}_t \\epsilon} \\), where the initial noise \\( \\epsilon \\sim \\mathcal{N}(0, I) \\) whose size is same as \\( z_0 \\): \\( \\epsilon \\in \\mathbb{R}^{n \\times c \\times h \\times w} \\). To capture an intermediate representation of the motion between frames, we introduce a random-mask condition layer at the input stage. This layer applies a binary mask \\( m \\in \\mathbb{R}^n \\) broadcasting to \\( \\tilde{m} \\in \\mathbb{R}^{n \\times c \\times h \\times w} \\) as the size of the latent code, resulting in a masked latent code:"
681
+ },
682
+ {
683
+ "type": "equation",
684
+ "bbox": [
685
+ 0.392,
686
+ 0.665,
687
+ 0.825,
688
+ 0.683
689
+ ],
690
+ "angle": 0,
691
+ "content": "\\[\n\\tilde {z} _ {0} = z _ {0} \\odot m, \\tilde {z} _ {0} \\in \\mathbb {R} ^ {n \\times c \\times h \\times w}. \\tag {4}\n\\]"
692
+ },
693
+ {
694
+ "type": "text",
695
+ "bbox": [
696
+ 0.17,
697
+ 0.69,
698
+ 0.825,
699
+ 0.746
700
+ ],
701
+ "angle": 0,
702
+ "content": "The binary masks, represented by \\( m \\), serve as a mechanism to selectively preserve or suppress information from the original latent code. In order to identify which frames are masked and which ones are visible conditional images, our model takes the masked latent code \\( \\tilde{z}_0 \\) concatenated with the mask \\( m \\) as a conditional input:"
703
+ },
704
+ {
705
+ "type": "equation",
706
+ "bbox": [
707
+ 0.371,
708
+ 0.754,
709
+ 0.825,
710
+ 0.773
711
+ ],
712
+ "angle": 0,
713
+ "content": "\\[\n\\tilde {z} _ {t} = \\left[ z _ {t}; m; \\tilde {z} _ {0} \\right], \\tilde {z} _ {t} \\in \\mathbb {R} ^ {n \\times (3 \\times c) \\times h \\times w}, \\tag {5}\n\\]"
714
+ },
715
+ {
716
+ "type": "text",
717
+ "bbox": [
718
+ 0.17,
719
+ 0.779,
720
+ 0.825,
721
+ 0.807
722
+ ],
723
+ "angle": 0,
724
+ "content": "where \\(\\tilde{z}_t\\) represents the final input to the U-Net. The model is trained to predict the noise of the entire corrupted latent code:"
725
+ },
726
+ {
727
+ "type": "equation",
728
+ "bbox": [
729
+ 0.411,
730
+ 0.807,
731
+ 0.825,
732
+ 0.824
733
+ ],
734
+ "angle": 0,
735
+ "content": "\\[\n\\mathcal {L} = \\mathcal {E} [ \\| \\epsilon - \\epsilon_ {\\theta} (\\tilde {z} _ {t}, t, c) \\| ]. \\tag {6}\n\\]"
736
+ },
737
+ {
738
+ "type": "text",
739
+ "bbox": [
740
+ 0.17,
741
+ 0.827,
742
+ 0.826,
743
+ 0.928
744
+ ],
745
+ "angle": 0,
746
+ "content": "This involves learning the underlying distribution of the noise that affects the unmasked frames and textual description. By modeling and predicting the noise, the model aims to generate realistic and visually coherent transition frames that seamlessly blend the visible frames with the unmasked frames. The mask has \\( n \\) elements indicating the index of frames, each of which can take on the values 0 or 1. The probability of the element taking the value 1 is denoted as \\( p \\): \\( \\mathrm{m} \\sim \\mathrm{Bernoulli}(p) \\). Given that our model primarily focuses on transitions and predictions, where typically less than 3 frames are involved. In our model, we set \\( p = 0.15 \\) considering the probability \\( \\frac{2}{n} < p < \\frac{3}{n} \\). This"
747
+ },
748
+ {
749
+ "type": "page_number",
750
+ "bbox": [
751
+ 0.494,
752
+ 0.949,
753
+ 0.504,
754
+ 0.96
755
+ ],
756
+ "angle": 0,
757
+ "content": "5"
758
+ }
759
+ ],
760
+ [
761
+ {
762
+ "type": "header",
763
+ "bbox": [
764
+ 0.174,
765
+ 0.033,
766
+ 0.48,
767
+ 0.049
768
+ ],
769
+ "angle": 0,
770
+ "content": "Published as a conference paper at ICLR 2024"
771
+ },
772
+ {
773
+ "type": "image",
774
+ "bbox": [
775
+ 0.175,
776
+ 0.101,
777
+ 0.825,
778
+ 0.433
779
+ ],
780
+ "angle": 0,
781
+ "content": null
782
+ },
783
+ {
784
+ "type": "image_caption",
785
+ "bbox": [
786
+ 0.171,
787
+ 0.436,
788
+ 0.825,
789
+ 0.465
790
+ ],
791
+ "angle": 0,
792
+ "content": "Figure 5: Qualitative comparisons with existing methods. Left: Spiderman becomes into a sand sculpture. Right: A cat from sitting on the coach transfer to lying on the sand."
793
+ },
794
+ {
795
+ "type": "text",
796
+ "bbox": [
797
+ 0.17,
798
+ 0.509,
799
+ 0.825,
800
+ 0.678
801
+ ],
802
+ "angle": 0,
803
+ "content": "choice of probability ensures that, on average, approximately two or three out of every \\( n \\) frames will be visible. It aligns with the assumption that the mask is primarily used for capturing transitions between frames, where adjacent frames are more likely to be influenced by the mask. Our random-mask based model is capable of generating frames for any given frames at arbitrary positions within the sequence. Transition can be obtained by providing the first and last frames of a sequence and utilizing prompts to control the transition style and content, resulting in intermediate transition frames that depict the transition or progression within the video sequence. Long video involves recursive using the last few frames of the generated video as input and utilizing masks to predict the subsequent frames. By recursively iterating this process, the model can generate longer video sequences. Image-to-video animation can be achieved by treating the reference image as the first frame. The first binary mask is set as ones and the remaining is set as zeros. The animated video can be obtained through a denoising process and subsequently decoded from the encoder."
804
+ },
805
+ {
806
+ "type": "title",
807
+ "bbox": [
808
+ 0.172,
809
+ 0.715,
810
+ 0.328,
811
+ 0.73
812
+ ],
813
+ "angle": 0,
814
+ "content": "4 EXPERIMENTS"
815
+ },
816
+ {
817
+ "type": "text",
818
+ "bbox": [
819
+ 0.17,
820
+ 0.758,
821
+ 0.825,
822
+ 0.926
823
+ ],
824
+ "angle": 0,
825
+ "content": "Implementation Details. SEINE is initialized from LaVie-base (Wang et al., 2023b), with the addition of a random mask layer being randomly initialized. We first utilize the WebVid10M dataset (Bain et al., 2021) as the main training set, and during the later stages of training, we use a few internal watermark-free datasets to mitigate the presence of watermarks in the generated output. Our model is trained on videos of \\(320 \\times 512\\) resolution with 16 frames. During inference, SEINE is able to generate videos of arbitrary aspect ratios. Comparison Methods. Transition video generation is a relatively understudied and novel problem within the field. While traditional methods have explored smooth transitions through image morphing techniques, there is a lack of specific approaches addressing generative transition in the context of video generation. In this part, we conduct analyses between our proposed approach and existing methods that can achieve similar effects: diffusion model-based method (i.e., Stable Diffusion), VQGAN-based model (Esser et al., 2021). Details description and implementation for the compared methods are described in App. A.1."
826
+ },
827
+ {
828
+ "type": "page_number",
829
+ "bbox": [
830
+ 0.494,
831
+ 0.949,
832
+ 0.504,
833
+ 0.96
834
+ ],
835
+ "angle": 0,
836
+ "content": "6"
837
+ }
838
+ ],
839
+ [
840
+ {
841
+ "type": "header",
842
+ "bbox": [
843
+ 0.173,
844
+ 0.033,
845
+ 0.48,
846
+ 0.049
847
+ ],
848
+ "angle": 0,
849
+ "content": "Published as a conference paper at ICLR 2024"
850
+ },
851
+ {
852
+ "type": "title",
853
+ "bbox": [
854
+ 0.172,
855
+ 0.105,
856
+ 0.411,
857
+ 0.12
858
+ ],
859
+ "angle": 0,
860
+ "content": "4.1 QUALITATIVE COMPARISON"
861
+ },
862
+ {
863
+ "type": "text",
864
+ "bbox": [
865
+ 0.171,
866
+ 0.131,
867
+ 0.827,
868
+ 0.257
869
+ ],
870
+ "angle": 0,
871
+ "content": "Fig. 5 shows the visual comparison with the existing methods. We observe that using interpolation methods for VQVAE to generate intermediate transition scenes often results in a transparent blending of two images. Morphing techniques, on the other hand, can achieve object deformation by matching key points (such as changes in a cat's pose), ensuring that objects do not undergo transparent blending. However, for scenes without significant object deformation, such as transitioning from a cityscape to the sky in a Spiderman scene, simple blending may still occur. Stable Diffusion-based methods do not suffer from simple blending issues, but their lack of sufficient continuity in hidden codes leads to a lack of consistency in the generated intermediate images. In contrast, our method ensures smooth object motion while incorporating plausible phenomena during transitions."
872
+ },
873
+ {
874
+ "type": "title",
875
+ "bbox": [
876
+ 0.172,
877
+ 0.275,
878
+ 0.421,
879
+ 0.289
880
+ ],
881
+ "angle": 0,
882
+ "content": "4.2 QUANTITATIVE COMPARISON"
883
+ },
884
+ {
885
+ "type": "text",
886
+ "bbox": [
887
+ 0.171,
888
+ 0.301,
889
+ 0.828,
890
+ 0.552
891
+ ],
892
+ "angle": 0,
893
+ "content": "We assess the generative transition from three aspects: temporal coherence, semantic similarity, and video-text alignment. To evaluate the semantic similarity between generated frames and given scene images, we use the clip similarity (CLIPSIM) metric. To compute \"CLIPSIM-scenes\", abbr. \"CLIPSIM-s\", we calculate the clip image similarity for each frame and the given scene images. To compute \"CLIPSIM-frames\", abbr. \"CLIPSIM-f\", we calculate the clip score in between generated frames. Likewise, we utilize the clip text-image similarity as \"CLIPSIM-text\", abbr. \"CLIPSIM-t\", to quantify the semantic correlation between the generated videos and their corresponding descriptive text. In our experiments, we employ the MSR-VTT dataset due to its open-domain nature with textual annotations. We randomly selected one caption per video from the official test set (a total of 2,990 videos). In order to evaluate the quality of the generative transition, we considered the given scene images as two frames of a video with a larger interval timestep. This allows us to analyze and compare the smoothness and coherence of the transition between the two images. Specifically, we utilize the first and 64th frames as the reference scene images in our evaluation. Tab. 1 presents the comparative results of our analysis. The results demonstrate that our method outperforms the comparison algorithms. It is worth noting that our method does not achieve significantly higher scores than CLIPSIM-Scene and CLIPSIM-Frames. To further scrutinize the quality of our video transitions, we calculate FVD and frame-wise FID score. The outcomes reveal that our model consistently delivers superior video quality compared to other methods examined in our study."
894
+ },
895
+ {
896
+ "type": "table_caption",
897
+ "bbox": [
898
+ 0.189,
899
+ 0.564,
900
+ 0.807,
901
+ 0.58
902
+ ],
903
+ "angle": 0,
904
+ "content": "Table 1: Comparison with methods w.r.t. CLIPSIM- \\( t \\) ,CLIPSIM- \\( s \\) ,CLIPSIM- \\( f \\) ,FVD and FID."
905
+ },
906
+ {
907
+ "type": "table",
908
+ "bbox": [
909
+ 0.19,
910
+ 0.59,
911
+ 0.809,
912
+ 0.671
913
+ ],
914
+ "angle": 0,
915
+ "content": "<table><tr><td>Methods</td><td>CLIPSIM-t(↑)</td><td>CLIPSIM-s(↑)</td><td>CLIPSIM-f(↑)</td><td>FVD(↓)</td><td>FID(↓)</td></tr><tr><td>Morphing</td><td>0.2535</td><td>0.7707</td><td>0.9569</td><td>573.9</td><td>35.3</td></tr><tr><td>VQGAN-based Transition</td><td>0.2528</td><td>0.7389</td><td>0.9542</td><td>445.6</td><td>36.7</td></tr><tr><td>SD-based Transition</td><td>0.2665</td><td>0.6080</td><td>0.8809</td><td>502.0</td><td>62.0</td></tr><tr><td>Ours</td><td>0.2726</td><td>0.7740</td><td>0.9675</td><td>181.6</td><td>13.4</td></tr></table>"
916
+ },
917
+ {
918
+ "type": "title",
919
+ "bbox": [
920
+ 0.172,
921
+ 0.704,
922
+ 0.622,
923
+ 0.718
924
+ ],
925
+ "angle": 0,
926
+ "content": "4.3 DIVERSE AND CONTROLLABLE TRANSITION GENERATION"
927
+ },
928
+ {
929
+ "type": "text",
930
+ "bbox": [
931
+ 0.171,
932
+ 0.73,
933
+ 0.827,
934
+ 0.926
935
+ ],
936
+ "angle": 0,
937
+ "content": "We showcase the advantages of our method in handling generative transitions: 1) diverse results by sampling multiple times; and 2) controllable results of our method by employing textural descriptions such as camera movement control. Diverse Transition Generation. We present visual results demonstrating the variety of transitions generated under identical prompts within two equivalent scenes, as depicted in Fig. 6. We can observe that as the raccoon transitions from being in the sea to the stage scene, the first two outcomes depict a form of similarity transition. However, the sequence of transitioning between the objects and backgrounds varies. The final transition, indeed, resembles the unfurling of a curtain, akin to a wave sweeping in from the right side. Controllable Transition Generation. Our method can achieve transitions by controlling the prompt with camera movements. For instance, by employing camera zoom-in and zoom-out control, we create visual occlusions, and during the zoom-out phase, we generate the subsequent scene to achieve a seamless scene transition. This occlusion technique is a widely employed transition method in filmmaking. Fig. 7 illustrates our example of this technique through the prompt, transitioning a scene from an office to a library with the presence of a panda."
938
+ },
939
+ {
940
+ "type": "page_number",
941
+ "bbox": [
942
+ 0.494,
943
+ 0.949,
944
+ 0.506,
945
+ 0.96
946
+ ],
947
+ "angle": 0,
948
+ "content": "7"
949
+ }
950
+ ],
951
+ [
952
+ {
953
+ "type": "header",
954
+ "bbox": [
955
+ 0.174,
956
+ 0.033,
957
+ 0.48,
958
+ 0.048
959
+ ],
960
+ "angle": 0,
961
+ "content": "Published as a conference paper at ICLR 2024"
962
+ },
963
+ {
964
+ "type": "image",
965
+ "bbox": [
966
+ 0.175,
967
+ 0.102,
968
+ 0.825,
969
+ 0.299
970
+ ],
971
+ "angle": 0,
972
+ "content": null
973
+ },
974
+ {
975
+ "type": "image_caption",
976
+ "bbox": [
977
+ 0.171,
978
+ 0.309,
979
+ 0.825,
980
+ 0.339
981
+ ],
982
+ "angle": 0,
983
+ "content": "Figure 6: Diverse transition results. Each row illustrates frames of our transition results by \"the scene transition from the sea into a playing trumpet raccoon\"."
984
+ },
985
+ {
986
+ "type": "text",
987
+ "bbox": [
988
+ 0.182,
989
+ 0.358,
990
+ 0.512,
991
+ 0.371
992
+ ],
993
+ "angle": 0,
994
+ "content": "\\(I^{st}\\) prompt: A panda working in the office, camera zoom-in."
995
+ },
996
+ {
997
+ "type": "image",
998
+ "bbox": [
999
+ 0.179,
1000
+ 0.372,
1001
+ 0.825,
1002
+ 0.452
1003
+ ],
1004
+ "angle": 0,
1005
+ "content": null
1006
+ },
1007
+ {
1008
+ "type": "text",
1009
+ "bbox": [
1010
+ 0.182,
1011
+ 0.461,
1012
+ 0.526,
1013
+ 0.473
1014
+ ],
1015
+ "angle": 0,
1016
+ "content": "\\(2^{st}\\) prompt: A panda working in the library, camera zoom-out."
1017
+ },
1018
+ {
1019
+ "type": "image",
1020
+ "bbox": [
1021
+ 0.179,
1022
+ 0.473,
1023
+ 0.825,
1024
+ 0.553
1025
+ ],
1026
+ "angle": 0,
1027
+ "content": null
1028
+ },
1029
+ {
1030
+ "type": "image_caption",
1031
+ "bbox": [
1032
+ 0.171,
1033
+ 0.562,
1034
+ 0.825,
1035
+ 0.592
1036
+ ],
1037
+ "angle": 0,
1038
+ "content": "Figure 7: Text-controllable transition. Examples of our scene transition are achieved by controlling them through textual descriptions, i.e., camera-motion control."
1039
+ },
1040
+ {
1041
+ "type": "title",
1042
+ "bbox": [
1043
+ 0.171,
1044
+ 0.619,
1045
+ 0.729,
1046
+ 0.632
1047
+ ],
1048
+ "angle": 0,
1049
+ "content": "4.4 COMPARISON WITH STATE-OF-THE-ART METHOD FOR VIDEO PREDICTION"
1050
+ },
1051
+ {
1052
+ "type": "text",
1053
+ "bbox": [
1054
+ 0.17,
1055
+ 0.644,
1056
+ 0.827,
1057
+ 0.853
1058
+ ],
1059
+ "angle": 0,
1060
+ "content": "We conducted a comprehensive comparative analysis between our proposed method and the state-of-the-art method TATS for the task of generating long videos consisting of 1024 frames, on the UCF-101 dataset (Soomro et al., 2012). Qualitative and quantitative comparisons are illustrated in Fig. 8. Fig. 8 (a) visually presents the comparative results, showing that TATS tends to degrade over time, leading to the emergence of grid-like artifacts and visual collapse. In contrast, our approach avoids such collapsing phenomena, maintaining stable and visually coherent video generation throughout the sequence. Fig. 8 (b) depicts the quantitative evaluation by FVD. In our study, we compared TATS with the outcomes obtained from our model's zero-shot generation and the results achieved after fine-tuning our model on the UCF-101 dataset. All models were evaluated under the auto-regressive setting. Our results are generated by the DDIM sampling of 100 steps. Our approach demonstrates a slower degradation of video quality over time compared to TATS. In the first few frames, due to the disparity of data distribution between the training set and UCF-101, our model's scores are higher than TATS. However, as TATS degrades over time, our model's FVD score becomes lower than that of TATS. Moreover, by performing fine-tuning on the UCF-101 dataset, our method consistently outperforms TATS."
1061
+ },
1062
+ {
1063
+ "type": "title",
1064
+ "bbox": [
1065
+ 0.172,
1066
+ 0.87,
1067
+ 0.368,
1068
+ 0.884
1069
+ ],
1070
+ "angle": 0,
1071
+ "content": "4.5 MORE APPLICATIONS"
1072
+ },
1073
+ {
1074
+ "type": "text",
1075
+ "bbox": [
1076
+ 0.171,
1077
+ 0.896,
1078
+ 0.825,
1079
+ 0.926
1080
+ ],
1081
+ "angle": 0,
1082
+ "content": "Long Video Generation. Fig. 9 demonstrates the generation of long videos through auto-regressive prediction. Each video consists of tens of frames by auto-regressive prediction for 4 times. Notably,"
1083
+ },
1084
+ {
1085
+ "type": "page_number",
1086
+ "bbox": [
1087
+ 0.494,
1088
+ 0.949,
1089
+ 0.504,
1090
+ 0.96
1091
+ ],
1092
+ "angle": 0,
1093
+ "content": "8"
1094
+ }
1095
+ ],
1096
+ [
1097
+ {
1098
+ "type": "header",
1099
+ "bbox": [
1100
+ 0.173,
1101
+ 0.033,
1102
+ 0.48,
1103
+ 0.049
1104
+ ],
1105
+ "angle": 0,
1106
+ "content": "Published as a conference paper at ICLR 2024"
1107
+ },
1108
+ {
1109
+ "type": "image",
1110
+ "bbox": [
1111
+ 0.174,
1112
+ 0.106,
1113
+ 0.825,
1114
+ 0.222
1115
+ ],
1116
+ "angle": 0,
1117
+ "content": null
1118
+ },
1119
+ {
1120
+ "type": "image_caption",
1121
+ "bbox": [
1122
+ 0.171,
1123
+ 0.234,
1124
+ 0.828,
1125
+ 0.279
1126
+ ],
1127
+ "angle": 0,
1128
+ "content": "Figure 8: Comparison for auto-regressive long video prediction. a) Qualitative Results. Each frame is selected with a frame step 128 from the 256th frame; b) Qualitative results. The lower value indicates better quality."
1129
+ },
1130
+ {
1131
+ "type": "text",
1132
+ "bbox": [
1133
+ 0.175,
1134
+ 0.399,
1135
+ 0.822,
1136
+ 0.427
1137
+ ],
1138
+ "angle": 0,
1139
+ "content": "A raccoon dressed in a suit playing A teddy bear washing the dishes. Two pandas discussing an aca- the trumpet, stage background. demic paper."
1140
+ },
1141
+ {
1142
+ "type": "image_caption",
1143
+ "bbox": [
1144
+ 0.171,
1145
+ 0.437,
1146
+ 0.826,
1147
+ 0.466
1148
+ ],
1149
+ "angle": 0,
1150
+ "content": "Figure 9: Long video results via auto-regressive prediction. Best view with Acrobat Reader. Click the images to play the videos."
1151
+ },
1152
+ {
1153
+ "type": "text",
1154
+ "bbox": [
1155
+ 0.236,
1156
+ 0.557,
1157
+ 0.27,
1158
+ 0.569
1159
+ ],
1160
+ "angle": 0,
1161
+ "content": "Ours"
1162
+ },
1163
+ {
1164
+ "type": "text",
1165
+ "bbox": [
1166
+ 0.392,
1167
+ 0.557,
1168
+ 0.434,
1169
+ 0.569
1170
+ ],
1171
+ "angle": 0,
1172
+ "content": "Gen-2"
1173
+ },
1174
+ {
1175
+ "type": "text",
1176
+ "bbox": [
1177
+ 0.556,
1178
+ 0.557,
1179
+ 0.588,
1180
+ 0.569
1181
+ ],
1182
+ "angle": 0,
1183
+ "content": "Ours"
1184
+ },
1185
+ {
1186
+ "type": "text",
1187
+ "bbox": [
1188
+ 0.711,
1189
+ 0.557,
1190
+ 0.752,
1191
+ 0.569
1192
+ ],
1193
+ "angle": 0,
1194
+ "content": "Gen-2"
1195
+ },
1196
+ {
1197
+ "type": "image_caption",
1198
+ "bbox": [
1199
+ 0.171,
1200
+ 0.581,
1201
+ 0.825,
1202
+ 0.611
1203
+ ],
1204
+ "angle": 0,
1205
+ "content": "Figure 10: Image animation results. In each case, our result is on the left and the result of Gen-2 is on the right. Best view with Acrobat Reader. Click the images to play the videos."
1206
+ },
1207
+ {
1208
+ "type": "text",
1209
+ "bbox": [
1210
+ 0.17,
1211
+ 0.638,
1212
+ 0.827,
1213
+ 0.737
1214
+ ],
1215
+ "angle": 0,
1216
+ "content": "our method ensures that the visual quality of the generated content remains pristine while preserving consistent semantic coherence throughout the synthesized results. Image-to-Video Animation. We demonstrate the outcomes of video generation by utilizing an image as the initial frame. This approach can be seamlessly integrated with other T2I models, such as Midjourney*. Here, we compare our results with those obtained from the online API image-to-video generation model, Gen-2 (Esser et al., 2023). From the comparison, it can be observed that despite not specifically training our model for this task, our model still achieves comparable results."
1217
+ },
1218
+ {
1219
+ "type": "title",
1220
+ "bbox": [
1221
+ 0.172,
1222
+ 0.757,
1223
+ 0.321,
1224
+ 0.772
1225
+ ],
1226
+ "angle": 0,
1227
+ "content": "5 CONCLUSION"
1228
+ },
1229
+ {
1230
+ "type": "text",
1231
+ "bbox": [
1232
+ 0.17,
1233
+ 0.788,
1234
+ 0.827,
1235
+ 0.903
1236
+ ],
1237
+ "angle": 0,
1238
+ "content": "In this paper, we introduce SEINE, a S2L video diffusion model that focuses on smooth and creative transitions and auto-regressive predictions. SEINE utilizes a random-mask video diffusion model to automatically generate transitions based on textual descriptions, ensuring coherence and visual quality. The model can also be extended to image-to-video animation and auto-regressive video prediction tasks, allowing for the creation of coherent \"story-level\" long videos. The evaluation of transitions is conducted based on temporal consistency, semantic similarity, and video-text semantic alignment. The experimental results demonstrate the superiority of our approach over existing methods in terms of transition and prediction."
1239
+ },
1240
+ {
1241
+ "type": "page_footnote",
1242
+ "bbox": [
1243
+ 0.195,
1244
+ 0.911,
1245
+ 0.436,
1246
+ 0.925
1247
+ ],
1248
+ "angle": 0,
1249
+ "content": "\\*https://www.midjourney.com"
1250
+ },
1251
+ {
1252
+ "type": "page_number",
1253
+ "bbox": [
1254
+ 0.494,
1255
+ 0.949,
1256
+ 0.505,
1257
+ 0.96
1258
+ ],
1259
+ "angle": 0,
1260
+ "content": "9"
1261
+ }
1262
+ ],
1263
+ [
1264
+ {
1265
+ "type": "header",
1266
+ "bbox": [
1267
+ 0.173,
1268
+ 0.033,
1269
+ 0.48,
1270
+ 0.049
1271
+ ],
1272
+ "angle": 0,
1273
+ "content": "Published as a conference paper at ICLR 2024"
1274
+ },
1275
+ {
1276
+ "type": "title",
1277
+ "bbox": [
1278
+ 0.172,
1279
+ 0.103,
1280
+ 0.378,
1281
+ 0.119
1282
+ ],
1283
+ "angle": 0,
1284
+ "content": "6 ETHICS STATEMENT"
1285
+ },
1286
+ {
1287
+ "type": "text",
1288
+ "bbox": [
1289
+ 0.171,
1290
+ 0.134,
1291
+ 0.827,
1292
+ 0.233
1293
+ ],
1294
+ "angle": 0,
1295
+ "content": "We acknowledge the ethical concerns that are shared with other text-to-image and text-to-video diffusion models (Ramesh et al., 2021; 2022; Rombach et al., 2022; Sahara et al., 2022; Ho et al., 2022; He et al., 2022; Wang et al., 2023b). Furthermore, our optimization is based on diffusion model (Ho et al., 2020; Song et al., 2021b), which has the potential to introduce unintended bias as a result of the training data. On the other hand, our approach presents a short-to-long video diffusion model that aims to create a coherent story-level long video, which may have implications for various domains including filmmaking, video games, and artistic creation."
1296
+ },
1297
+ {
1298
+ "type": "title",
1299
+ "bbox": [
1300
+ 0.173,
1301
+ 0.253,
1302
+ 0.37,
1303
+ 0.267
1304
+ ],
1305
+ "angle": 0,
1306
+ "content": "ACKNOWLEDGEMENTS"
1307
+ },
1308
+ {
1309
+ "type": "text",
1310
+ "bbox": [
1311
+ 0.171,
1312
+ 0.283,
1313
+ 0.828,
1314
+ 0.381
1315
+ ],
1316
+ "angle": 0,
1317
+ "content": "This work is supported by the National Key R&D Program of China under Grand NO.2022ZD0160100, the National Natural Science Foundation of China under Grant No. 62102150, the Ministry of Education Singapore under its MOE AcRF Tier 2 (MOE-T2EP20221-0012) and NTU NAP, and the Science and Technology Commission of Shanghai Municipality under Grant No. 23QD1400800, No. 22511105800, and the RIE2020 Industry Alignment Fund - Industry Collaboration Projects (IAF-ICP) Funding Initiative, as well as cash and in-kind contribution from the industry partner(s)."
1318
+ },
1319
+ {
1320
+ "type": "title",
1321
+ "bbox": [
1322
+ 0.174,
1323
+ 0.401,
1324
+ 0.289,
1325
+ 0.416
1326
+ ],
1327
+ "angle": 0,
1328
+ "content": "REFERENCES"
1329
+ },
1330
+ {
1331
+ "type": "ref_text",
1332
+ "bbox": [
1333
+ 0.174,
1334
+ 0.424,
1335
+ 0.826,
1336
+ 0.453
1337
+ ],
1338
+ "angle": 0,
1339
+ "content": "Max Bain, Arsha Nagrani, Gül Varol, and Andrew Zisserman. Frozen in time: A joint video and image encoder for end-to-end retrieval. In ICCV, 2021."
1340
+ },
1341
+ {
1342
+ "type": "ref_text",
1343
+ "bbox": [
1344
+ 0.175,
1345
+ 0.461,
1346
+ 0.826,
1347
+ 0.505
1348
+ ],
1349
+ "angle": 0,
1350
+ "content": "Yogesh Balaji, Seungjun Nah, Xun Huang, Arash Vahdat, Jiaming Song, Karsten Kreis, Miika Aittala, Timo Aila, Samuli Laine, Bryan Catanzaro, et al. edifi: Text-to-image diffusion models with an ensemble of expert denoisers. arXiv preprint arXiv:2211.01324, 2022."
1351
+ },
1352
+ {
1353
+ "type": "ref_text",
1354
+ "bbox": [
1355
+ 0.174,
1356
+ 0.512,
1357
+ 0.825,
1358
+ 0.556
1359
+ ],
1360
+ "angle": 0,
1361
+ "content": "Andreas Blattmann, Robin Rombach, Huan Ling, Tim Dockhorn, Seung Wook Kim, Sanja Fidler, and Karsten Kreis. Align your latents: High-resolution video synthesis with latent diffusion models. In CVPR, 2023."
1362
+ },
1363
+ {
1364
+ "type": "ref_text",
1365
+ "bbox": [
1366
+ 0.174,
1367
+ 0.564,
1368
+ 0.825,
1369
+ 0.607
1370
+ ],
1371
+ "angle": 0,
1372
+ "content": "Mingdeng Cao, Xintao Wang, Zhongang Qi, Ying Shan, Xiaohu Qie, and Yinqiang Zheng. Mas-actr: Tuning-free mutual self-attention control for consistent image synthesis and editing. arXiv preprint arXiv:2304.08465, 2023."
1373
+ },
1374
+ {
1375
+ "type": "ref_text",
1376
+ "bbox": [
1377
+ 0.174,
1378
+ 0.615,
1379
+ 0.825,
1380
+ 0.657
1381
+ ],
1382
+ "angle": 0,
1383
+ "content": "Xinyuan Chen, Chang Xu, Xiaokang Yang, Li Song, and Dacheng Tao. Gated-gan: Adversarial gated networks for multi-collection style transfer. IEEE Transactions on Image Processing, 28 (2):546-560, 2018."
1384
+ },
1385
+ {
1386
+ "type": "ref_text",
1387
+ "bbox": [
1388
+ 0.174,
1389
+ 0.667,
1390
+ 0.825,
1391
+ 0.697
1392
+ ],
1393
+ "angle": 0,
1394
+ "content": "Xinyuan Chen, Chang Xu, Xiaokang Yang, and Dacheng Tao. Long-term video prediction via criticization and retrospection. IEEE Transactions on Image Processing, 29:7090-7103, 2020."
1395
+ },
1396
+ {
1397
+ "type": "ref_text",
1398
+ "bbox": [
1399
+ 0.174,
1400
+ 0.704,
1401
+ 0.825,
1402
+ 0.734
1403
+ ],
1404
+ "angle": 0,
1405
+ "content": "Patrick Esser, Robin Rombach, and Bjorn Ommer. Taming transformers for high-resolution image synthesis. In CVPR, 2021."
1406
+ },
1407
+ {
1408
+ "type": "ref_text",
1409
+ "bbox": [
1410
+ 0.174,
1411
+ 0.741,
1412
+ 0.825,
1413
+ 0.784
1414
+ ],
1415
+ "angle": 0,
1416
+ "content": "Patrick Esser, Johnathan Chiu, Parmida Atighehchian, Jonathan Granskog, and Anastasis Germanidis. Structure and content-guided video synthesis with diffusion models. arXiv preprint arXiv:2302.03011, 2023."
1417
+ },
1418
+ {
1419
+ "type": "ref_text",
1420
+ "bbox": [
1421
+ 0.174,
1422
+ 0.792,
1423
+ 0.825,
1424
+ 0.835
1425
+ ],
1426
+ "angle": 0,
1427
+ "content": "Songwei Ge, Thomas Hayes, Harry Yang, Xi Yin, Guan Pang, David Jacobs, Jia-Bin Huang, and Devi Parikh. Long video generation with time-agnostic vqgan and time-sensitive transformer. In ECCV, 2022."
1428
+ },
1429
+ {
1430
+ "type": "ref_text",
1431
+ "bbox": [
1432
+ 0.174,
1433
+ 0.844,
1434
+ 0.825,
1435
+ 0.887
1436
+ ],
1437
+ "angle": 0,
1438
+ "content": "Songwei Ge, Seungjun Nah, Guilin Liu, Tyler Poon, Andrew Tao, Bryan Catanzaro, David Jacobs, Jia-Bin Huang, Ming-Yu Liu, and Yogesh Balaji. Preserve your own correlation: A noise prior for video diffusion models. arXiv preprint arXiv:2305.10474, 2023."
1439
+ },
1440
+ {
1441
+ "type": "ref_text",
1442
+ "bbox": [
1443
+ 0.174,
1444
+ 0.895,
1445
+ 0.825,
1446
+ 0.925
1447
+ ],
1448
+ "angle": 0,
1449
+ "content": "Yingqing He, Tianyu Yang, Yong Zhang, Ying Shan, and Qifeng Chen. Latent video diffusion models for high-fidelity long video generation. 2022."
1450
+ },
1451
+ {
1452
+ "type": "list",
1453
+ "bbox": [
1454
+ 0.174,
1455
+ 0.424,
1456
+ 0.826,
1457
+ 0.925
1458
+ ],
1459
+ "angle": 0,
1460
+ "content": null
1461
+ },
1462
+ {
1463
+ "type": "page_number",
1464
+ "bbox": [
1465
+ 0.491,
1466
+ 0.948,
1467
+ 0.511,
1468
+ 0.961
1469
+ ],
1470
+ "angle": 0,
1471
+ "content": "10"
1472
+ }
1473
+ ],
1474
+ [
1475
+ {
1476
+ "type": "header",
1477
+ "bbox": [
1478
+ 0.173,
1479
+ 0.033,
1480
+ 0.48,
1481
+ 0.049
1482
+ ],
1483
+ "angle": 0,
1484
+ "content": "Published as a conference paper at ICLR 2024"
1485
+ },
1486
+ {
1487
+ "type": "ref_text",
1488
+ "bbox": [
1489
+ 0.173,
1490
+ 0.103,
1491
+ 0.826,
1492
+ 0.134
1493
+ ],
1494
+ "angle": 0,
1495
+ "content": "Jonathan Ho, Ajay Jain, and Pieter Abbeel. Denoising diffusion probabilistic models. Advances in Neural Information Processing Systems, 33:6840-6851, 2020."
1496
+ },
1497
+ {
1498
+ "type": "ref_text",
1499
+ "bbox": [
1500
+ 0.173,
1501
+ 0.142,
1502
+ 0.826,
1503
+ 0.187
1504
+ ],
1505
+ "angle": 0,
1506
+ "content": "Jonathan Ho, William Chan, Chitwan Sahara, Jay Whang, Ruiqi Gao, Alexey Gritsenko, Diederik P Kingma, Ben Poole, Mohammad Norouzi, David J Fleet, et al. Imagen video: High definition video generation with diffusion models. arXiv preprint arXiv:2210.02303, 2022."
1507
+ },
1508
+ {
1509
+ "type": "ref_text",
1510
+ "bbox": [
1511
+ 0.173,
1512
+ 0.196,
1513
+ 0.826,
1514
+ 0.239
1515
+ ],
1516
+ "angle": 0,
1517
+ "content": "MinGuk Kang, Joonghyuk Shin, and Jaesik Park. StudioGAN: A Taxonomy and Benchmark of GANs for Image Synthesis. IEEE Transactions on Pattern Analysis and Machine Intelligence (TPAMI), 2023."
1518
+ },
1519
+ {
1520
+ "type": "ref_text",
1521
+ "bbox": [
1522
+ 0.173,
1523
+ 0.248,
1524
+ 0.824,
1525
+ 0.279
1526
+ ],
1527
+ "angle": 0,
1528
+ "content": "Alexander Quinn Nichol and Prafulla Dhariwal. Improved denoising diffusion probabilistic models. In ICML, 2021."
1529
+ },
1530
+ {
1531
+ "type": "ref_text",
1532
+ "bbox": [
1533
+ 0.173,
1534
+ 0.288,
1535
+ 0.824,
1536
+ 0.319
1537
+ ],
1538
+ "angle": 0,
1539
+ "content": "Aditya Ramesh, Mikhail Pavlov, Gabriel Goh, Scott Gray, Chelsea Voss, Alec Radford, Mark Chen, and Ilya Sutskever. Zero-shot text-to-image generation. In ICML, 2021."
1540
+ },
1541
+ {
1542
+ "type": "ref_text",
1543
+ "bbox": [
1544
+ 0.173,
1545
+ 0.327,
1546
+ 0.824,
1547
+ 0.358
1548
+ ],
1549
+ "angle": 0,
1550
+ "content": "Aditya Ramesh, Prafulla Dhariwal, Alex Nichol, Casey Chu, and Mark Chen. Hierarchical text-conditional image generation with clip latents. arXiv preprint arXiv:2204.06125, 2022."
1551
+ },
1552
+ {
1553
+ "type": "ref_text",
1554
+ "bbox": [
1555
+ 0.173,
1556
+ 0.366,
1557
+ 0.824,
1558
+ 0.41
1559
+ ],
1560
+ "angle": 0,
1561
+ "content": "Robin Rombach, Andreas Blattmann, Dominik Lorenz, Patrick Esser, and Björn Ommer. High-resolution image synthesis with latent diffusion models. In Proceedings of the IEEE/CVF conference on computer vision and pattern recognition, pp. 10684-10695, 2022."
1562
+ },
1563
+ {
1564
+ "type": "ref_text",
1565
+ "bbox": [
1566
+ 0.173,
1567
+ 0.419,
1568
+ 0.826,
1569
+ 0.476
1570
+ ],
1571
+ "angle": 0,
1572
+ "content": "Chitwan Sahara, William Chan, Saurabh Saxena, Lala Li, Jay Whang, Emily L Denton, Kamyar Ghasemipour, Raphael Gontijo Lopes, Burcu Karagol Ayan, Tim Salimans, et al. Photorealistic text-to-image diffusion models with deep language understanding. Advances in Neural Information Processing Systems, 35:36479-36494, 2022."
1573
+ },
1574
+ {
1575
+ "type": "ref_text",
1576
+ "bbox": [
1577
+ 0.173,
1578
+ 0.485,
1579
+ 0.826,
1580
+ 0.557
1581
+ ],
1582
+ "angle": 0,
1583
+ "content": "Axel Sauer, Katja Schwarz, and Andreas Geiger. Stylegan-xl: Scaling stylegan to large diverse datasets. In Munkhtsetseg Nandigjav, Niloy J. Mitra, and Aaron Hertzmann (eds.), SIGGRAPH '22: Special Interest Group on Computer Graphics and Interactive Techniques Conference, Vancouver, BC, Canada, August 7 - 11, 2022, pp. 49:1-49:10. ACM, 2022. doi: 10.1145/3528233.3530738. URL https://doi.org/10.1145/3528233.3530738."
1584
+ },
1585
+ {
1586
+ "type": "ref_text",
1587
+ "bbox": [
1588
+ 0.173,
1589
+ 0.566,
1590
+ 0.826,
1591
+ 0.597
1592
+ ],
1593
+ "angle": 0,
1594
+ "content": "Eli Shechtman, Alex Rav-Acha, Michal Irani, and Steve Seitz. Regenerative morphing. In IEEE Conference on Computer Vision and Pattern Recognition (CVPR), San-Francisco, CA, June 2010."
1595
+ },
1596
+ {
1597
+ "type": "ref_text",
1598
+ "bbox": [
1599
+ 0.173,
1600
+ 0.605,
1601
+ 0.826,
1602
+ 0.649
1603
+ ],
1604
+ "angle": 0,
1605
+ "content": "Uriel Singer, Adam Polyak, Thomas Hayes, Xi Yin, Jie An, Songyang Zhang, Qiyuan Hu, Harry Yang, Oron Ashual, Oran Gafni, Devi Parikh, Sonal Gupta, and Yaniv Taigman. Make-a-video: Text-to-video generation without text-video data. In ICLR, 2023."
1606
+ },
1607
+ {
1608
+ "type": "ref_text",
1609
+ "bbox": [
1610
+ 0.173,
1611
+ 0.658,
1612
+ 0.824,
1613
+ 0.689
1614
+ ],
1615
+ "angle": 0,
1616
+ "content": "Ivan Skorokhodov, Sergey Tulyakov, and Mohamed Elhoseiny. Stylegan-v: A continuous video generator with the price, image quality and perks of stylegan2. In CVPR, 2022."
1617
+ },
1618
+ {
1619
+ "type": "ref_text",
1620
+ "bbox": [
1621
+ 0.173,
1622
+ 0.697,
1623
+ 0.826,
1624
+ 0.741
1625
+ ],
1626
+ "angle": 0,
1627
+ "content": "Jiaming Song, Chenlin Meng, and Stefano Ermon. Denoising diffusion implicit models. In International Conference on Learning Representations, 2021a. URL https://openreview.net/forum?id=StlgiarCHLP."
1628
+ },
1629
+ {
1630
+ "type": "ref_text",
1631
+ "bbox": [
1632
+ 0.173,
1633
+ 0.75,
1634
+ 0.826,
1635
+ 0.793
1636
+ ],
1637
+ "angle": 0,
1638
+ "content": "Yang Song, Jascha Sohl-Dickstein, Diederik P Kingma, Abhishek Kumar, Stefano Ermon, and Ben Poole. Score-based generative modeling through stochastic differential equations. In ICLRs, 2021b."
1639
+ },
1640
+ {
1641
+ "type": "ref_text",
1642
+ "bbox": [
1643
+ 0.173,
1644
+ 0.803,
1645
+ 0.826,
1646
+ 0.834
1647
+ ],
1648
+ "angle": 0,
1649
+ "content": "Khurram Soomro, Amir Roshan Zamir, and Mubarak Shah. UCF101: A Dataset of 101 Human Action Classes From Videos in The Wild. Technical report, CRCV-TR-12-01, November 2012."
1650
+ },
1651
+ {
1652
+ "type": "ref_text",
1653
+ "bbox": [
1654
+ 0.173,
1655
+ 0.842,
1656
+ 0.826,
1657
+ 0.885
1658
+ ],
1659
+ "angle": 0,
1660
+ "content": "Yu Tian, Jian Ren, Mengei Chai, Kyle Olszewski, Xi Peng, Dimitris N. Metaxas, and Sergey Tulyakov. A good image generator is what you need for high-resolution video synthesis. In ICLR, 2021."
1661
+ },
1662
+ {
1663
+ "type": "ref_text",
1664
+ "bbox": [
1665
+ 0.173,
1666
+ 0.895,
1667
+ 0.826,
1668
+ 0.925
1669
+ ],
1670
+ "angle": 0,
1671
+ "content": "Sergey Tulyakov, Ming-Yu Liu, Xiaodong Yang, and Jan Kautz. MoCoGAN: Decomposing motion and content for video generation. In CVPR, 2018."
1672
+ },
1673
+ {
1674
+ "type": "list",
1675
+ "bbox": [
1676
+ 0.173,
1677
+ 0.103,
1678
+ 0.826,
1679
+ 0.925
1680
+ ],
1681
+ "angle": 0,
1682
+ "content": null
1683
+ },
1684
+ {
1685
+ "type": "page_number",
1686
+ "bbox": [
1687
+ 0.491,
1688
+ 0.949,
1689
+ 0.508,
1690
+ 0.96
1691
+ ],
1692
+ "angle": 0,
1693
+ "content": "11"
1694
+ }
1695
+ ],
1696
+ [
1697
+ {
1698
+ "type": "header",
1699
+ "bbox": [
1700
+ 0.173,
1701
+ 0.033,
1702
+ 0.48,
1703
+ 0.049
1704
+ ],
1705
+ "angle": 0,
1706
+ "content": "Published as a conference paper at ICLR 2024"
1707
+ },
1708
+ {
1709
+ "type": "ref_text",
1710
+ "bbox": [
1711
+ 0.173,
1712
+ 0.103,
1713
+ 0.826,
1714
+ 0.148
1715
+ ],
1716
+ "angle": 0,
1717
+ "content": "Narek Tumanyan, Michal Geyer, Shai Bagon, and Tali Dekel. Plug-and-play diffusion features for text-driven image-to-image translation. In Proceedings of the IEEE/CVF Conference on Computer Vision and Pattern Recognition, pp. 1921-1930, 2023."
1718
+ },
1719
+ {
1720
+ "type": "ref_text",
1721
+ "bbox": [
1722
+ 0.173,
1723
+ 0.155,
1724
+ 0.823,
1725
+ 0.172
1726
+ ],
1727
+ "angle": 0,
1728
+ "content": "Aaron Van Den Oord, Oriol Vinyals, et al. Neural discrete representation learning. NeurIPS, 2017."
1729
+ },
1730
+ {
1731
+ "type": "ref_text",
1732
+ "bbox": [
1733
+ 0.173,
1734
+ 0.179,
1735
+ 0.825,
1736
+ 0.223
1737
+ ],
1738
+ "angle": 0,
1739
+ "content": "Ruben Villegas, Mohammad Babaeizadeh, Pieter-Jan Kindermans, Hernan Moraldo, Han Zhang, Mohammad Taghi Saffar, Santiago Castro, Julius Kunze, and Dumitru Erhan. Phenaki: Variable length video generation from open domain textual descriptions. In ICLR, 2023."
1740
+ },
1741
+ {
1742
+ "type": "ref_text",
1743
+ "bbox": [
1744
+ 0.173,
1745
+ 0.23,
1746
+ 0.825,
1747
+ 0.274
1748
+ ],
1749
+ "angle": 0,
1750
+ "content": "Fu-Yun Wang, Wenshuo Chen, Guanglu Song, Han-Jia Ye, Yu Liu, and Hongsheng Li. Gen-l-video: Multi-text to long video generation via temporal co-denoising. arXiv preprint arXiv:2305.18264, 2023a."
1751
+ },
1752
+ {
1753
+ "type": "ref_text",
1754
+ "bbox": [
1755
+ 0.173,
1756
+ 0.282,
1757
+ 0.825,
1758
+ 0.311
1759
+ ],
1760
+ "angle": 0,
1761
+ "content": "Yaohui Wang, Piotr Bilinski, Francois Bremond, and Antitza Dantcheva. G3AN: Disentangling appearance and motion for video generation. In CVPR, 2020a."
1762
+ },
1763
+ {
1764
+ "type": "ref_text",
1765
+ "bbox": [
1766
+ 0.173,
1767
+ 0.319,
1768
+ 0.825,
1769
+ 0.35
1770
+ ],
1771
+ "angle": 0,
1772
+ "content": "Yaohui Wang, Piotr Bilinski, Francois Bremond, and Antitza Dantcheva. Imaginator: Conditional spatio-temporal gan for video generation. In WACV, 2020b."
1773
+ },
1774
+ {
1775
+ "type": "ref_text",
1776
+ "bbox": [
1777
+ 0.173,
1778
+ 0.357,
1779
+ 0.825,
1780
+ 0.415
1781
+ ],
1782
+ "angle": 0,
1783
+ "content": "Yaohui Wang, Xinyuan Chen, Xin Ma, Shangchen Zhou, Ziqi Huang, Yi Wang, Ceyuan Yang, Yinan He, Yu Jiashuo, Yang Peiqing, Yuwei Guo, Tianxing Wu, Chenyang Si, Yuming Jiang, Cunjian Chen, Change Loy Chen, Bo Dai, Dahua Lin, Yu Qiao, and Ziwei Liu. Lavie: High-quality video generation with cascaded latent diffusion models. arXiv preprint arXiv:2309.5135377, 2023b."
1784
+ },
1785
+ {
1786
+ "type": "ref_text",
1787
+ "bbox": [
1788
+ 0.173,
1789
+ 0.422,
1790
+ 0.825,
1791
+ 0.453
1792
+ ],
1793
+ "angle": 0,
1794
+ "content": "Yaohui Wang, Xin Ma, Xinyuan Chen, Antitza Dantcheva, Bo Dai, and Yu Qiao. Leo: Generative latent image animator for human video synthesis. arXiv preprint arXiv:2305.03989, 2023c."
1795
+ },
1796
+ {
1797
+ "type": "ref_text",
1798
+ "bbox": [
1799
+ 0.173,
1800
+ 0.46,
1801
+ 0.771,
1802
+ 0.477
1803
+ ],
1804
+ "angle": 0,
1805
+ "content": "George Wolberg. Image morphing: a survey. The visual computer, 14(8-9):360-372, 1998."
1806
+ },
1807
+ {
1808
+ "type": "ref_text",
1809
+ "bbox": [
1810
+ 0.173,
1811
+ 0.484,
1812
+ 0.825,
1813
+ 0.514
1814
+ ],
1815
+ "angle": 0,
1816
+ "content": "Wilson Yan, Yunzhi Zhang, Pieter Abbeel, and Aravind Srinivas. Videogpt: Video generation using vq-vae and transformers. arXiv preprint arXiv:2104.10157, 2021."
1817
+ },
1818
+ {
1819
+ "type": "ref_text",
1820
+ "bbox": [
1821
+ 0.173,
1822
+ 0.522,
1823
+ 0.825,
1824
+ 0.566
1825
+ ],
1826
+ "angle": 0,
1827
+ "content": "Shengming Yin, Chenfei Wu, Huan Yang, Jianfeng Wang, Xiaodong Wang, Minheng Ni, Zhengyuan Yang, Linjie Li, Shuguang Liu, Fan Yang, et al. Nuwa-xl: Diffusion over diffusion for extremely long video generation. arXiv preprint arXiv:2303.12346, 2023."
1828
+ },
1829
+ {
1830
+ "type": "ref_text",
1831
+ "bbox": [
1832
+ 0.173,
1833
+ 0.574,
1834
+ 0.825,
1835
+ 0.604
1836
+ ],
1837
+ "angle": 0,
1838
+ "content": "Sihyun Yu, Jihoon Tack, Sangwoo Mo, Hyunsu Kim, Junho Kim, Jung-Woo Ha, and Jinwoo Shin. Generating videos with dynamics-aware implicit generative adversarial networks. In ICLR, 2022."
1839
+ },
1840
+ {
1841
+ "type": "ref_text",
1842
+ "bbox": [
1843
+ 0.173,
1844
+ 0.611,
1845
+ 0.825,
1846
+ 0.64
1847
+ ],
1848
+ "angle": 0,
1849
+ "content": "Lvmin Zhang and Maneesh Agrawala. Adding conditional control to text-to-image diffusion models, 2023."
1850
+ },
1851
+ {
1852
+ "type": "ref_text",
1853
+ "bbox": [
1854
+ 0.173,
1855
+ 0.648,
1856
+ 0.825,
1857
+ 0.68
1858
+ ],
1859
+ "angle": 0,
1860
+ "content": "Daquan Zhou, Weimin Wang, Hanshu Yan, Weiwei Lv, Yizhe Zhu, and Jiashi Feng. Magicvideo: Efficient video generation with latent diffusion models. arXiv preprint arXiv:2211.11018, 2022."
1861
+ },
1862
+ {
1863
+ "type": "list",
1864
+ "bbox": [
1865
+ 0.173,
1866
+ 0.103,
1867
+ 0.826,
1868
+ 0.68
1869
+ ],
1870
+ "angle": 0,
1871
+ "content": null
1872
+ },
1873
+ {
1874
+ "type": "page_number",
1875
+ "bbox": [
1876
+ 0.491,
1877
+ 0.948,
1878
+ 0.509,
1879
+ 0.96
1880
+ ],
1881
+ "angle": 0,
1882
+ "content": "12"
1883
+ }
1884
+ ],
1885
+ [
1886
+ {
1887
+ "type": "header",
1888
+ "bbox": [
1889
+ 0.173,
1890
+ 0.033,
1891
+ 0.48,
1892
+ 0.049
1893
+ ],
1894
+ "angle": 0,
1895
+ "content": "Published as a conference paper at ICLR 2024"
1896
+ },
1897
+ {
1898
+ "type": "title",
1899
+ "bbox": [
1900
+ 0.173,
1901
+ 0.103,
1902
+ 0.3,
1903
+ 0.118
1904
+ ],
1905
+ "angle": 0,
1906
+ "content": "A APPENDIX"
1907
+ },
1908
+ {
1909
+ "type": "title",
1910
+ "bbox": [
1911
+ 0.173,
1912
+ 0.134,
1913
+ 0.503,
1914
+ 0.149
1915
+ ],
1916
+ "angle": 0,
1917
+ "content": "A.1 COMPARED METHODS FOR TRANSITION."
1918
+ },
1919
+ {
1920
+ "type": "text",
1921
+ "bbox": [
1922
+ 0.171,
1923
+ 0.16,
1924
+ 0.825,
1925
+ 0.189
1926
+ ],
1927
+ "angle": 0,
1928
+ "content": "Here we describe the details and implementation details for the compared methods achieving transition."
1929
+ },
1930
+ {
1931
+ "type": "text",
1932
+ "bbox": [
1933
+ 0.172,
1934
+ 0.202,
1935
+ 0.825,
1936
+ 0.259
1937
+ ],
1938
+ "angle": 0,
1939
+ "content": "- Morphing. Morphing is a special effect in motion pictures and animations that changes (or morphs) one image or shape into another through a seamless transition. Traditionally such a depiction would be achieved through dissolving techniques on film. The transition is achieved by using the first and the last frames and generating the intermediate frames."
1940
+ },
1941
+ {
1942
+ "type": "text",
1943
+ "bbox": [
1944
+ 0.172,
1945
+ 0.263,
1946
+ 0.827,
1947
+ 0.319
1948
+ ],
1949
+ "angle": 0,
1950
+ "content": "- SD-based Method. We adopt the SD as our baseline model. Since SD cannot directly generate intermediate frames, we first compute the latent code of the given two images by reverse diffusion process (i.e., DDIM inversion (Song et al., 2021a)), then we use the interpolation of Euclidean distance of the latent codes to denoising and obtain the intermediate frames."
1951
+ },
1952
+ {
1953
+ "type": "text",
1954
+ "bbox": [
1955
+ 0.172,
1956
+ 0.324,
1957
+ 0.825,
1958
+ 0.366
1959
+ ],
1960
+ "angle": 0,
1961
+ "content": "- VQGAN-based Method. VQGAN serves as the latent code layer for SD. We employ the interpolated representation of the codes from the encoder of VQGAN output (prior to quantization) as a reference method."
1962
+ },
1963
+ {
1964
+ "type": "list",
1965
+ "bbox": [
1966
+ 0.172,
1967
+ 0.202,
1968
+ 0.827,
1969
+ 0.366
1970
+ ],
1971
+ "angle": 0,
1972
+ "content": null
1973
+ },
1974
+ {
1975
+ "type": "title",
1976
+ "bbox": [
1977
+ 0.173,
1978
+ 0.383,
1979
+ 0.332,
1980
+ 0.397
1981
+ ],
1982
+ "angle": 0,
1983
+ "content": "A.2 FAILURE CASES"
1984
+ },
1985
+ {
1986
+ "type": "text",
1987
+ "bbox": [
1988
+ 0.171,
1989
+ 0.409,
1990
+ 0.825,
1991
+ 0.495
1992
+ ],
1993
+ "angle": 0,
1994
+ "content": "Watermarks. Since part of our training data (WebVid10M) contains watermarks, there is a chance that generated videos may also exhibit such signals (see Fig. 11 and 12). In the prediction task, we observed that in the autoregressive process, watermarks gradually emerge. Once they appear, they persist throughout the entire video. In the transition task, if the watermarks are present in the given images, the generated intermediate frames will also be affected. However, if no watermarks appear in the given images, watermarks are less likely to appear, and even if they do, they are usually faint."
1995
+ },
1996
+ {
1997
+ "type": "text",
1998
+ "bbox": [
1999
+ 0.176,
2000
+ 0.614,
2001
+ 0.39,
2002
+ 0.653
2003
+ ],
2004
+ "angle": 0,
2005
+ "content": "There is a table by a window with sunlight streaming through illuminating a pile of books."
2006
+ },
2007
+ {
2008
+ "type": "text",
2009
+ "bbox": [
2010
+ 0.422,
2011
+ 0.614,
2012
+ 0.574,
2013
+ 0.627
2014
+ ],
2015
+ "angle": 0,
2016
+ "content": "A view of lake in autumn."
2017
+ },
2018
+ {
2019
+ "type": "text",
2020
+ "bbox": [
2021
+ 0.618,
2022
+ 0.614,
2023
+ 0.809,
2024
+ 0.628
2025
+ ],
2026
+ "angle": 0,
2027
+ "content": "A panda playing on a swing set."
2028
+ },
2029
+ {
2030
+ "type": "text",
2031
+ "bbox": [
2032
+ 0.171,
2033
+ 0.664,
2034
+ 0.825,
2035
+ 0.694
2036
+ ],
2037
+ "angle": 0,
2038
+ "content": "Figure 11: Failure cases for prediction with watermarks. Best view with Acrobat Reader. Click the images to play the videos."
2039
+ },
2040
+ {
2041
+ "type": "text",
2042
+ "bbox": [
2043
+ 0.171,
2044
+ 0.709,
2045
+ 0.827,
2046
+ 0.849
2047
+ ],
2048
+ "angle": 0,
2049
+ "content": "Abrupt Transition. While our method excels in transition generation, it does have limitations regarding the requirement for the similarity of the source and target scenes. A natural and smooth transition relies on finding meaningful correspondences between the two scenes. If the scenes are too dissimilar or lack common elements, the transition may appear abrupt or visually inconsistent. An alternative solution to address this limitation is through a multi-step approach. We utilize image editing methods (Tumanyan et al., 2023; Cao et al., 2023; Zhang & Agrawala, 2023) to transform the source image in the scenes and actions into the target image. This method is particularly beneficial in scene generation as it operates at the image level, naturally preserving similarities such as the structure, background, and objects of the image. As a result, the transition effects produced using this approach often appear highly natural."
2050
+ },
2051
+ {
2052
+ "type": "text",
2053
+ "bbox": [
2054
+ 0.171,
2055
+ 0.855,
2056
+ 0.825,
2057
+ 0.926
2058
+ ],
2059
+ "angle": 0,
2060
+ "content": "Text-video Unalignment. In our S2L model, we aim to optimize \\( p_{\\theta}(z_0|c,\\tilde{z}_0) \\) which \\( \\tilde{z}_0 \\) represents the latent code of the unmasked condition image. However, in our training dataset, videos \\( z_0 \\), unmasked frames \\( \\tilde{z}_0 \\), and captions/prompts \\( (c) \\) are not completely independent and exhibit strong correlations. Consequently, when there is no inherent connection between the given unmasked image and caption, it can lead to discontinuities or difficulties in aligning with video-text alignment."
2061
+ },
2062
+ {
2063
+ "type": "page_number",
2064
+ "bbox": [
2065
+ 0.491,
2066
+ 0.948,
2067
+ 0.509,
2068
+ 0.96
2069
+ ],
2070
+ "angle": 0,
2071
+ "content": "13"
2072
+ }
2073
+ ],
2074
+ [
2075
+ {
2076
+ "type": "header",
2077
+ "bbox": [
2078
+ 0.173,
2079
+ 0.033,
2080
+ 0.48,
2081
+ 0.049
2082
+ ],
2083
+ "angle": 0,
2084
+ "content": "Published as a conference paper at ICLR 2024"
2085
+ },
2086
+ {
2087
+ "type": "image",
2088
+ "bbox": [
2089
+ 0.182,
2090
+ 0.202,
2091
+ 0.283,
2092
+ 0.253
2093
+ ],
2094
+ "angle": 0,
2095
+ "content": null
2096
+ },
2097
+ {
2098
+ "type": "image",
2099
+ "bbox": [
2100
+ 0.289,
2101
+ 0.203,
2102
+ 0.394,
2103
+ 0.253
2104
+ ],
2105
+ "angle": 0,
2106
+ "content": null
2107
+ },
2108
+ {
2109
+ "type": "image",
2110
+ "bbox": [
2111
+ 0.395,
2112
+ 0.203,
2113
+ 0.5,
2114
+ 0.253
2115
+ ],
2116
+ "angle": 0,
2117
+ "content": null
2118
+ },
2119
+ {
2120
+ "type": "image",
2121
+ "bbox": [
2122
+ 0.501,
2123
+ 0.203,
2124
+ 0.603,
2125
+ 0.253
2126
+ ],
2127
+ "angle": 0,
2128
+ "content": null
2129
+ },
2130
+ {
2131
+ "type": "image",
2132
+ "bbox": [
2133
+ 0.605,
2134
+ 0.203,
2135
+ 0.709,
2136
+ 0.253
2137
+ ],
2138
+ "angle": 0,
2139
+ "content": null
2140
+ },
2141
+ {
2142
+ "type": "image",
2143
+ "bbox": [
2144
+ 0.71,
2145
+ 0.203,
2146
+ 0.814,
2147
+ 0.253
2148
+ ],
2149
+ "angle": 0,
2150
+ "content": null
2151
+ },
2152
+ {
2153
+ "type": "image_footnote",
2154
+ "bbox": [
2155
+ 0.182,
2156
+ 0.254,
2157
+ 0.816,
2158
+ 0.291
2159
+ ],
2160
+ "angle": 0,
2161
+ "content": "A panda is in a bamboo forest, The scene has changed from the sea The scene has changed from the shifting from sketch-like to realistic into a playing trumpet raccoon. panda watching television to the style."
2162
+ },
2163
+ {
2164
+ "type": "image_caption",
2165
+ "bbox": [
2166
+ 0.171,
2167
+ 0.302,
2168
+ 0.825,
2169
+ 0.332
2170
+ ],
2171
+ "angle": 0,
2172
+ "content": "Figure 12: Failure cases for transition with watermarks. Best view with Acrobat Reader. Click the images to play the videos."
2173
+ },
2174
+ {
2175
+ "type": "text",
2176
+ "bbox": [
2177
+ 0.171,
2178
+ 0.36,
2179
+ 0.825,
2180
+ 0.43
2181
+ ],
2182
+ "angle": 0,
2183
+ "content": "Additionally, we have observed that the quality of generated videos would be influenced to some extent by the given prompt. Providing prompts that align well with the realistic scenario and have a resemblance to unmasked videos can yield better results. Ensuring the provision of more suitable prompts in the context of generating long videos is a topic we will explore in our subsequent research."
2184
+ },
2185
+ {
2186
+ "type": "image",
2187
+ "bbox": [
2188
+ 0.174,
2189
+ 0.442,
2190
+ 0.268,
2191
+ 0.868
2192
+ ],
2193
+ "angle": 0,
2194
+ "content": null
2195
+ },
2196
+ {
2197
+ "type": "image_caption",
2198
+ "bbox": [
2199
+ 0.199,
2200
+ 0.869,
2201
+ 0.241,
2202
+ 0.879
2203
+ ],
2204
+ "angle": 0,
2205
+ "content": "Scenes"
2206
+ },
2207
+ {
2208
+ "type": "image_caption",
2209
+ "bbox": [
2210
+ 0.304,
2211
+ 0.868,
2212
+ 0.415,
2213
+ 0.879
2214
+ ],
2215
+ "angle": 0,
2216
+ "content": "Transition Video 1"
2217
+ },
2218
+ {
2219
+ "type": "image_caption",
2220
+ "bbox": [
2221
+ 0.49,
2222
+ 0.868,
2223
+ 0.601,
2224
+ 0.879
2225
+ ],
2226
+ "angle": 0,
2227
+ "content": "Transition Video 2"
2228
+ },
2229
+ {
2230
+ "type": "image_caption",
2231
+ "bbox": [
2232
+ 0.675,
2233
+ 0.868,
2234
+ 0.786,
2235
+ 0.879
2236
+ ],
2237
+ "angle": 0,
2238
+ "content": "Transition Video 3"
2239
+ },
2240
+ {
2241
+ "type": "image_caption",
2242
+ "bbox": [
2243
+ 0.171,
2244
+ 0.892,
2245
+ 0.825,
2246
+ 0.921
2247
+ ],
2248
+ "angle": 0,
2249
+ "content": "Figure 13: Transition samples. In each case, transitions are generated by the same prompt with different random seeds. Best view with Acrobat Reader. Click the images to play videos."
2250
+ },
2251
+ {
2252
+ "type": "page_number",
2253
+ "bbox": [
2254
+ 0.491,
2255
+ 0.948,
2256
+ 0.509,
2257
+ 0.96
2258
+ ],
2259
+ "angle": 0,
2260
+ "content": "14"
2261
+ }
2262
+ ],
2263
+ [
2264
+ {
2265
+ "type": "header",
2266
+ "bbox": [
2267
+ 0.173,
2268
+ 0.033,
2269
+ 0.48,
2270
+ 0.049
2271
+ ],
2272
+ "angle": 0,
2273
+ "content": "Published as a conference paper at ICLR 2024"
2274
+ },
2275
+ {
2276
+ "type": "title",
2277
+ "bbox": [
2278
+ 0.172,
2279
+ 0.104,
2280
+ 0.447,
2281
+ 0.119
2282
+ ],
2283
+ "angle": 0,
2284
+ "content": "A.2.1 IMAGE-TO-VIDEO ANIMATION"
2285
+ },
2286
+ {
2287
+ "type": "text",
2288
+ "bbox": [
2289
+ 0.171,
2290
+ 0.128,
2291
+ 0.828,
2292
+ 0.214
2293
+ ],
2294
+ "angle": 0,
2295
+ "content": "We present additional outcomes of image-to-video animation, as depicted in Fig. 14. For each instance, the reference image is displayed on the left, while the corresponding animation video is showcased on the right. Notably, our model demonstrates the ability to accommodate images of various sizes. The figure showcases the animation results obtained from both square and rectangular images. The reference images in the first three rows are generated from Midjourney. The reference images in the last two rows are generated from Stable Diffusion XL."
2296
+ },
2297
+ {
2298
+ "type": "text",
2299
+ "bbox": [
2300
+ 0.362,
2301
+ 0.55,
2302
+ 0.637,
2303
+ 0.565
2304
+ ],
2305
+ "angle": 0,
2306
+ "content": "(a) First Frame is generated from Midjourney"
2307
+ },
2308
+ {
2309
+ "type": "text",
2310
+ "bbox": [
2311
+ 0.338,
2312
+ 0.73,
2313
+ 0.66,
2314
+ 0.744
2315
+ ],
2316
+ "angle": 0,
2317
+ "content": "(b) First Frame is generated from Stable Diffusion XL"
2318
+ },
2319
+ {
2320
+ "type": "text",
2321
+ "bbox": [
2322
+ 0.171,
2323
+ 0.745,
2324
+ 0.825,
2325
+ 0.775
2326
+ ],
2327
+ "angle": 0,
2328
+ "content": "Figure 14: Image-to-video animation results. Best view with Acrobat Reader. Click the images to play the transition videos."
2329
+ },
2330
+ {
2331
+ "type": "page_number",
2332
+ "bbox": [
2333
+ 0.491,
2334
+ 0.948,
2335
+ 0.509,
2336
+ 0.961
2337
+ ],
2338
+ "angle": 0,
2339
+ "content": "15"
2340
+ }
2341
+ ]
2342
+ ]
2024/SEINE_ Short-to-Long Video Diffusion Model for Generative Transition and Prediction/4e0669d7-b95d-4ff4-97bd-d87bb4ad89af_origin.pdf ADDED
@@ -0,0 +1,3 @@
 
 
 
 
1
+ version https://git-lfs.github.com/spec/v1
2
+ oid sha256:3d076643b7283affcbbfd287375fa9de739c2429ebb0d57ec6643932b284d05b
3
+ size 41195738
2024/SEINE_ Short-to-Long Video Diffusion Model for Generative Transition and Prediction/full.md ADDED
@@ -0,0 +1,293 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ # SEINE: SHORT-TO-LONG VIDEO DIFFUSION MODEL FOR GENERATIVE TRANSITION AND PREDICTION
2
+
3
+ Xinyuan Chen $^{1*}$ Yaohui Wang $^{1*}$ Lingjun Zhang $^{2,1‡}$ Shaobin Zhuang $^{1,3}$
4
+
5
+ Xin Ma $^{4,1\ddagger}$ Jiashuo Yu $^{1}$ Yali Wang $^{5,1}$ Dahua Lin $^{1\dagger}$ Yu Qiao $^{1\dagger}$ Ziwei Liu $^{6\dagger}$
6
+
7
+ <sup>1</sup> Shanghai Artificial Intelligence Laboratory, <sup>2</sup> East China Normal University
8
+ $^{3}$ Shanghai Jiao Tong University, $^{4}$ Dept of Data Science & AI, Monash University
9
+ 5 Shenzhen Institute of Advanced Technology, Chinese Academy of Sciences
10
+ $^{6}$ S-Lab, Nanyang Technological University
11
+
12
+ # ABSTRACT
13
+
14
+ Recently video generation has achieved substantial progress with realistic results. Nevertheless, existing AI-generated videos are usually very short clips ("shot-level") depicting a single scene. To deliver a coherent long video ("story-level"), it is desirable to have creative transition and prediction effects across different clips. This paper presents a short-to-long (S2L) video diffusion model, SEINE, that focuses on generative transition and prediction. The goal is to generate high-quality long videos with smooth and creative transitions between scenes and varying lengths of shot-level videos. Specifically, we propose a random-mask video diffusion model to automatically generate transitions based on textual descriptions. By providing the images of different scenes as inputs, combined with text-based control, our model generates transition videos that ensure coherence and visual quality. Furthermore, the model can be readily extended to various tasks such as image-to-video animation and auto-regressive video prediction. To conduct a comprehensive evaluation of this new generative task, we propose three assessing criteria for smooth and creative transition: temporal consistency, semantic similarity, and video-text semantic alignment. Extensive experiments validate the effectiveness of our approach over existing methods for generative transition and prediction, enabling the creation of story-level long videos. Project page: https://vchitec.github.io/SEINE-project/.
15
+
16
+ Animation: a dog in spacesuit.
17
+
18
+ ![](images/5c8068ba2d161bb81800b6191a16cbdcabed2c53676d2909492f27aec693c8c0.jpg)
19
+ Transition: The panda is working in the office and reading a paper
20
+ Figure 1: Generated samples. Our S2L model is able to synthesize high-definition transition (shown in the left two columns) and prediction videos (shown in the right column) by giving textual descriptions. Best view with Acrobat Reader. Click the images to play the videos.
21
+
22
+ ![](images/ffefc3edcf9863ec81e9429db19026b0ab569934f8447e130bc62935b49d0bd2.jpg)
23
+
24
+ ![](images/ac38c6c6e4165f273e967657c0842bf8891b2cf8df770bc338d5a1c1dc86fced.jpg)
25
+ Transition: Spider-man becomes a sand sculpture.
26
+
27
+ ![](images/44baffd3873004fdee343a6400b1048ba300a3afac511b78b535105ea506b1dc.jpg)
28
+ Prediction: Iron Man flying in the sky.
29
+
30
+ ![](images/12072b2ded7397f74e858bb16f7ec32beef38a1ca5ebb0e5e5cdac26635c49e1.jpg)
31
+ Figure 2: Short-to-long (S2L) pipeline. Our S2L video generation model enables the seamless connection of shots from different scenes with transitions and generates videos of varying lengths through autoregressive prediction, facilitating the creation of story-level videos. The red box represents the transition video, while the blue box represents a long video generated through prediction.
32
+
33
+ # 1 INTRODUCTION
34
+
35
+ Currently, with the success of diffusion model-based (Ho et al., 2020; Song et al., 2021a;b) text-to-image generation models (Ramesh et al., 2021; 2022; Sahara et al., 2022; Balaji et al., 2022; Rombach et al., 2022), a series of video generation works (Singer et al., 2023; Ho et al., 2022; Blattmann et al., 2023; Zhou et al., 2022; He et al., 2022; Wang et al., 2023b) have emerged and demonstrated impressive results. However, current video generation methods typically only yield "shot-level" video generation, which only consists of around a few seconds and depicts a single scene. Such shot-level short videos fall short of the demands for cinematic and film productions.
36
+
37
+ In cinematic or industrial-level video productions, "story-level" long video is typically characterized by the creation of distinct shots with different scenes. These individual shots of various lengths are interconnected through techniques like transitions and editing, providing a way for longer video and more intricate visual storytelling. The process of combining scenes or shots in film and video editing, known as transition, plays a crucial role in post-production. Traditional transition methods, including dissolves, fades, and wipes, rely on predefined algorithms or established interfaces. However, these methods lack flexibility and are often limited in their capabilities. An alternative approach to achieve seamless and smooth transitions involves the use of diverse and imaginative shots to smoothly connect between scenes. This technique, commonly employed in films, cannot be directly generated using predefined programs. In this work, we present our model to address the less common problem of generating seamless and smooth transitions by focusing on generating intermediate frames between two different scenes. We establish three criteria that the generated transition frames should meet: 1) semantic relevance to the given scene image; 2) coherence and smoothness within frames; and 3) consistency with the provided text.
38
+
39
+ In this work, we present a short-to-long (S2L) video diffusion model, SEINE, for generative transition and prediction. The goal is to generate high-quality long videos with smooth and creative transitions between scenes and varying lengths of shot-level videos. The pipeline is shown in Fig. 2. We delve into the study of a new task, "generative transition", which aims at producing diverse and creative transition video segments to connect two different scenes. Alongside, we propose an approach to tackle this task and establish criteria for evaluating the efficacy of methods. We approach the problem of transitions as a conditional video generation task. By providing the initial and final frames of a given scene as inputs, we employ a text-based and video conditioning method to generate a smooth transition video in between. This approach allows us to effectively control the transition process and ensure the coherence and visual quality of the generated videos. To this end, we design a flexible random-mask diffusion model. The model is of capable generating transition shots by giving the first frame of one scene and the last frame of another scene, the scene transition is generated by a given textual description. Our model can be extended to image-to-video animation
40
+
41
+ and autoregressive video prediction, enabling the generation of long-shot videos and dynamic video creation in film production.
42
+
43
+ We summarize our contributions as follows: 1) We propose a new problem of generative transition and prediction, aiming at coherent "story-level" long video generation with smooth and creative scene transition and varying lengths of videos; 2) We present a short-to-long video diffusion model, SEINE, focusing on generative transition and prediction; 3) we propose three assessing criteria for transition and extensive experiments demonstrate our method the superior performance on the metrics, as well as its ability to be applied across versatile applications.
44
+
45
+ # 2 RELATED WORKS
46
+
47
+ Text-to-Video Generation. In recent years, diffusion models (Ho et al., 2020; Song et al., 2021a;b) have significantly advanced the field of text-to-image (T2I) generation. Existing methods (Ramesh et al., 2021; He et al., 2022; Ramesh et al., 2022; Sahara et al., 2022) have made remarkable progress in generating realistic images that are closely related to textual prompts. Recent advancements in T2I generation have led to the expansion of diffusion models to develop video generation from domain-specific models (Tulyakov et al., 2018; Wang et al., 2020a;b; Tian et al., 2021; Skorokhodov et al., 2022) to general text-to-video (T2V) models. This extension involves adapting the conventional 2D UNet architecture into a spatial-temporal 3D network to establish temporal correlations between video frames. Make-A-Video (Singer et al., 2023) and Imagen Video Ho et al. (2022) leverage text-to-image diffusion models of DALL-E2 (Ramesh et al., 2022) and Imagen (Saharia et al., 2022) respectively for large-scale T2V generation. PYoCo (Ge et al., 2023) presented a noise prior approach and utilized a pre-trained eDiff-I (Balaji et al., 2022) as initialization. An alternative approach involves constructing a T2V model based on pre-trained Stable Diffusion and subsequently fine-tuning the model either entirely (Zhou et al., 2022; He et al., 2022) or partially (Blattmann et al., 2023) on video data. In addition, LaVie (Wang et al., 2023b) fine-tuned the entire T2V model on both image and video datasets. While these methods demonstrate the potential of text-to-video synthesis, they are mostly limited to generating short videos.
48
+
49
+ Transition Generation. Scene transition is a less common problem but is crucial in storytelling, serving as the bridge that connects different narrative moments. They facilitate the smooth progression of a story through shifts in time, place, or perspective. Several techniques are employed to achieve effective scene transitions, such as "fade", "dissolves", "wipes", "IRIS" or simply cut where a scene abruptly transitions to another. These transitions can be achieved using pre-defined algorithms with fixed patterns. Morphing (Wolberg, 1998; Shechtman et al., 2010) enables smooth transitions involving finding pixel-level similarities and estimating their transitional offsets. Existing generative models (Van Den Oord et al., 2017) can leverage linear interpolation at the latent code level to capture semantic similarities. This approach has been widely explored in various works, e.g., style transfer (Chen et al., 2018), object transfiguration (Sauer et al., 2022; Kang et al., 2023).
50
+
51
+ Long Video Generation. Long video generation is a long-standing challenge in the field. Earlier works (Skorokhodov et al., 2022; Yu et al., 2022; Chen et al., 2020) employing generative adversarial networks (GANs) or variational auto-encoder (VAE) to model video distributions. VideoGPT (Yan et al., 2021) employs a combination of VQVAE (Van Den Oord et al., 2017) and transformer architecture to sequentially produce tokens within a discrete latent space. TATS (Ge et al., 2022) trains a time-agnostic VQGAN and subsequently learns a time-sensitive transformer based on the latent features. Phenaki (Villegas et al., 2023) uses a transformer-based model to compress videos into discrete tokens and generate longer continuous videos based on a sequence of text prompts. Recently, Diffusion Models (DMs) (Ho et al., 2020; Song et al., 2021a; Nichol & Dhariwal, 2021) have made significant advancements in video generation. LEO (Wang et al., 2023c) proposed to produce long human videos in latent motion space. LVDM (He et al., 2022) focuses on generating shot-level long videos by employing a hierarchical latent diffusion model. NUWA-XL (Yin et al., 2023) employs a hierarchical diffusion model to generate long videos, but it has only been trained on the cartoon FlintstonesHD dataset due to the lack of datasets on natural videos. On the other hand, Gen-L-Video (Wang et al., 2023a) generates long videos by utilizing existing short text-to-video generation models and treating them as overlapping short video clips. In contrast, our approach views long videos as compositions of various scenes and shot-level videos of different lengths. Our
52
+
53
+ ![](images/2a7fbcfdde3e7d98f3b8a754193dddf02ac6898d1187be3c7087f2493be4b240.jpg)
54
+ Figure 3: Notations and schematic representation of generative transition objective. Generative transition exhibits semantic similarity between each frame $x^n$ with the two scene images; each frame $x^n$ and its neighboring frames $x^{n-1}$ and $x^{n+1}$ should be temporal coherence; the semantics of generated frames should be alignment to the provided textual description.
55
+
56
+ short-to-long model aims to generate "story-level" videos containing continuous multi-scene videos with varying shot lengths.
57
+
58
+ # 3 METHODOLOGY
59
+
60
+ # 3.1 PRELIMINARIES
61
+
62
+ Text-to-Image Diffusion Model. Stable Diffusion (Rombach et al., 2022) performs image diffusion in a compressed latent space of an autoencoder (i.e., VQ-GAN and VQ-VAE). During training, a given image sample $x_0$ is encoded into the latent code $z = \mathcal{E}(x_0)$ and corrupted by Gaussian noise from a pre-defined Markov chain:
63
+
64
+ $$
65
+ q \left(z _ {t} \mid z _ {t - 1}\right) = \mathcal {N} \left(z _ {t}; \sqrt {1 - \beta_ {t}} z _ {t - 1}, \beta_ {t} I\right) \tag {1}
66
+ $$
67
+
68
+ for $t = 1, \dots, T$ , with $T$ being the number of steps in the forward diffusion process. The sequence of hyperparameters $\beta_{t}$ determines the noise strength at each step. The above iterative process can be reformulated in a closed-form manner as follows:
69
+
70
+ $$
71
+ z _ {t} = \sqrt {\bar {\alpha} _ {t}} z _ {0} + \sqrt {1 - \bar {\alpha} _ {t}} \epsilon , \epsilon \sim \mathcal {N} (0, I) \tag {2}
72
+ $$
73
+
74
+ where $\bar{\alpha}_t = \prod_{i=1}^t \alpha_t, \alpha_t = 1 - \beta_t$ . The model adopts $\epsilon$ -prediction and DDPM to learn a function $\epsilon_\theta$ is minimized by:
75
+
76
+ $$
77
+ \mathcal {L} = \mathbf {E} _ {z _ {0}, c, \epsilon \sim \mathcal {N} (0, I), t} [ \| \epsilon - \epsilon_ {\theta} (z _ {t}, t, c) \| _ {2} ^ {2} ] \tag {3}
78
+ $$
79
+
80
+ where $c$ indicates the condition of the textual description, $\epsilon$ is drawn from a diagonal Gaussian distribution. The $\epsilon_{\theta}$ is commonly implemented by a Unet, where $\theta$ is a parameterized neural network.
81
+
82
+ Text-to-Video Diffusion Model. Our framework is constructed upon a pre-trained diffusion-based T2V model, LaVie (Wang et al., 2023b), which is a cascaded framework that includes a base T2V model, a temporal interpolation model, and a video super-resolution model. LaVie-base, which is part of the LaVie framework, is developed using Stable Diffusion pre-trained model and incorporates a temporal attention module and image-video joint fine-tuning. To benefit from its ability to generate visually and temporally consistent videos with diverse content, we utilize the pre-trained LaVie-base model as the initialization for our framework.
83
+
84
+ # 3.2 GENERATIVE TRANSITION
85
+
86
+ The objective of the transition task is to generate a sequence of intermediate frames, denoted as $x^n$ , between two given images $S_1$ and $S_2$ , using a transition description caption $c$ . We define $x^0$ as $S_1$ and $x^N$ as $S_2$ , so the sequence consists of $N - 2$ target (in-between) frames. The generated sequence should satisfy the following three properties, as shown in Fig. 3: 1) Temporal Coherence: The changes in visual content across the sequence should be smooth and coherent over time. This property ensures that the generated video appears natural and visually consistent. 2) Semantic Similarity: The semantic content of each generated intermediate frame should resemble either of
87
+
88
+ ![](images/55e7683d6a054b44a9711519375a79083bf691e1e13204b236a3107cd2e1ea64.jpg)
89
+ Figure 4: Overview of our proposed method. We present our S2L generation model for generating transition video and long video prediction. Our model supports text as input, which is processed through a clip encoder and injected into the model (blue part). For brevity, we omit the details of the text injection, which is identical to the stable diffusion model.
90
+
91
+ the source images to some extent. This prevents the appearance of the sequence from deviating too much from the source scene images. Additionally, the similarity should gradually change from one source image to the other. 3) Video-text Alignment: The generated frames should align with the provided text description. This alignment allows us to control the transition between the two source images using the text description.
92
+
93
+ # 3.3 SHORT-TO-LONGVIDEODIFFUSIONMODEL
94
+
95
+ We develop a diffusion-based model for S2L videos via transition generation and video prediction. In order to generate unseen frames of transition and prediction, based on visible conditional images or videos, our S2L video diffusion model incorporates a random mask module, as shown in Fig. 4. Given the video dataset $p_{\mathrm{video}}$ , we take a $N$ -frame original video denoted as $x_0 \in \mathbb{R}^{N \times 3 \times H \times W}$ where $x_0$ follows the distribution $p_{\mathrm{video}}$ . The frames of video $x_0$ are first encoded by the pre-trained variational auto-encoder simultaneously as $z_0 \in \mathbb{R}^{n \times c \times h \times w}$ , where $c, h$ and $w$ indicate the channel, height, and width of the latent code, $n$ represents the frame number. To achieve more controllable transition videos and leverage the capability of short text-to-video generation, our model also takes a textual description $c$ as an input. The goal of our model is to learn a dual condition diffusion model: $p_{\theta}(z_0 | c, \tilde{z}_0)$ . In the training stage, the latent code of video is corrupted as Eq. 3: $z_t = \sqrt{\alpha_t} z_0 + \sqrt{1 - \bar{\alpha}_t \epsilon}$ , where the initial noise $\epsilon \sim \mathcal{N}(0, I)$ whose size is same as $z_0$ : $\epsilon \in \mathbb{R}^{n \times c \times h \times w}$ . To capture an intermediate representation of the motion between frames, we introduce a random-mask condition layer at the input stage. This layer applies a binary mask $m \in \mathbb{R}^n$ broadcasting to $\tilde{m} \in \mathbb{R}^{n \times c \times h \times w}$ as the size of the latent code, resulting in a masked latent code:
96
+
97
+ $$
98
+ \tilde {z} _ {0} = z _ {0} \odot m, \tilde {z} _ {0} \in \mathbb {R} ^ {n \times c \times h \times w}. \tag {4}
99
+ $$
100
+
101
+ The binary masks, represented by $m$ , serve as a mechanism to selectively preserve or suppress information from the original latent code. In order to identify which frames are masked and which ones are visible conditional images, our model takes the masked latent code $\tilde{z}_0$ concatenated with the mask $m$ as a conditional input:
102
+
103
+ $$
104
+ \tilde {z} _ {t} = \left[ z _ {t}; m; \tilde {z} _ {0} \right], \tilde {z} _ {t} \in \mathbb {R} ^ {n \times (3 \times c) \times h \times w}, \tag {5}
105
+ $$
106
+
107
+ where $\tilde{z}_t$ represents the final input to the U-Net. The model is trained to predict the noise of the entire corrupted latent code:
108
+
109
+ $$
110
+ \mathcal {L} = \mathcal {E} [ \| \epsilon - \epsilon_ {\theta} (\tilde {z} _ {t}, t, c) \| ]. \tag {6}
111
+ $$
112
+
113
+ This involves learning the underlying distribution of the noise that affects the unmasked frames and textual description. By modeling and predicting the noise, the model aims to generate realistic and visually coherent transition frames that seamlessly blend the visible frames with the unmasked frames. The mask has $n$ elements indicating the index of frames, each of which can take on the values 0 or 1. The probability of the element taking the value 1 is denoted as $p$ : $\mathrm{m} \sim \mathrm{Bernoulli}(p)$ . Given that our model primarily focuses on transitions and predictions, where typically less than 3 frames are involved. In our model, we set $p = 0.15$ considering the probability $\frac{2}{n} < p < \frac{3}{n}$ . This
114
+
115
+ ![](images/9b18b5d28e2f9682c235d8d5eb48269ca9a294cc07bf6e8972ad98a55ed009b6.jpg)
116
+ Figure 5: Qualitative comparisons with existing methods. Left: Spiderman becomes into a sand sculpture. Right: A cat from sitting on the coach transfer to lying on the sand.
117
+
118
+ choice of probability ensures that, on average, approximately two or three out of every $n$ frames will be visible. It aligns with the assumption that the mask is primarily used for capturing transitions between frames, where adjacent frames are more likely to be influenced by the mask. Our random-mask based model is capable of generating frames for any given frames at arbitrary positions within the sequence. Transition can be obtained by providing the first and last frames of a sequence and utilizing prompts to control the transition style and content, resulting in intermediate transition frames that depict the transition or progression within the video sequence. Long video involves recursive using the last few frames of the generated video as input and utilizing masks to predict the subsequent frames. By recursively iterating this process, the model can generate longer video sequences. Image-to-video animation can be achieved by treating the reference image as the first frame. The first binary mask is set as ones and the remaining is set as zeros. The animated video can be obtained through a denoising process and subsequently decoded from the encoder.
119
+
120
+ # 4 EXPERIMENTS
121
+
122
+ Implementation Details. SEINE is initialized from LaVie-base (Wang et al., 2023b), with the addition of a random mask layer being randomly initialized. We first utilize the WebVid10M dataset (Bain et al., 2021) as the main training set, and during the later stages of training, we use a few internal watermark-free datasets to mitigate the presence of watermarks in the generated output. Our model is trained on videos of $320 \times 512$ resolution with 16 frames. During inference, SEINE is able to generate videos of arbitrary aspect ratios. Comparison Methods. Transition video generation is a relatively understudied and novel problem within the field. While traditional methods have explored smooth transitions through image morphing techniques, there is a lack of specific approaches addressing generative transition in the context of video generation. In this part, we conduct analyses between our proposed approach and existing methods that can achieve similar effects: diffusion model-based method (i.e., Stable Diffusion), VQGAN-based model (Esser et al., 2021). Details description and implementation for the compared methods are described in App. A.1.
123
+
124
+ # 4.1 QUALITATIVE COMPARISON
125
+
126
+ Fig. 5 shows the visual comparison with the existing methods. We observe that using interpolation methods for VQVAE to generate intermediate transition scenes often results in a transparent blending of two images. Morphing techniques, on the other hand, can achieve object deformation by matching key points (such as changes in a cat's pose), ensuring that objects do not undergo transparent blending. However, for scenes without significant object deformation, such as transitioning from a cityscape to the sky in a Spiderman scene, simple blending may still occur. Stable Diffusion-based methods do not suffer from simple blending issues, but their lack of sufficient continuity in hidden codes leads to a lack of consistency in the generated intermediate images. In contrast, our method ensures smooth object motion while incorporating plausible phenomena during transitions.
127
+
128
+ # 4.2 QUANTITATIVE COMPARISON
129
+
130
+ We assess the generative transition from three aspects: temporal coherence, semantic similarity, and video-text alignment. To evaluate the semantic similarity between generated frames and given scene images, we use the clip similarity (CLIPSIM) metric. To compute "CLIPSIM-scenes", abbr. "CLIPSIM-s", we calculate the clip image similarity for each frame and the given scene images. To compute "CLIPSIM-frames", abbr. "CLIPSIM-f", we calculate the clip score in between generated frames. Likewise, we utilize the clip text-image similarity as "CLIPSIM-text", abbr. "CLIPSIM-t", to quantify the semantic correlation between the generated videos and their corresponding descriptive text. In our experiments, we employ the MSR-VTT dataset due to its open-domain nature with textual annotations. We randomly selected one caption per video from the official test set (a total of 2,990 videos). In order to evaluate the quality of the generative transition, we considered the given scene images as two frames of a video with a larger interval timestep. This allows us to analyze and compare the smoothness and coherence of the transition between the two images. Specifically, we utilize the first and 64th frames as the reference scene images in our evaluation. Tab. 1 presents the comparative results of our analysis. The results demonstrate that our method outperforms the comparison algorithms. It is worth noting that our method does not achieve significantly higher scores than CLIPSIM-Scene and CLIPSIM-Frames. To further scrutinize the quality of our video transitions, we calculate FVD and frame-wise FID score. The outcomes reveal that our model consistently delivers superior video quality compared to other methods examined in our study.
131
+
132
+ Table 1: Comparison with methods w.r.t. CLIPSIM- $t$ ,CLIPSIM- $s$ ,CLIPSIM- $f$ ,FVD and FID.
133
+
134
+ <table><tr><td>Methods</td><td>CLIPSIM-t(↑)</td><td>CLIPSIM-s(↑)</td><td>CLIPSIM-f(↑)</td><td>FVD(↓)</td><td>FID(↓)</td></tr><tr><td>Morphing</td><td>0.2535</td><td>0.7707</td><td>0.9569</td><td>573.9</td><td>35.3</td></tr><tr><td>VQGAN-based Transition</td><td>0.2528</td><td>0.7389</td><td>0.9542</td><td>445.6</td><td>36.7</td></tr><tr><td>SD-based Transition</td><td>0.2665</td><td>0.6080</td><td>0.8809</td><td>502.0</td><td>62.0</td></tr><tr><td>Ours</td><td>0.2726</td><td>0.7740</td><td>0.9675</td><td>181.6</td><td>13.4</td></tr></table>
135
+
136
+ # 4.3 DIVERSE AND CONTROLLABLE TRANSITION GENERATION
137
+
138
+ We showcase the advantages of our method in handling generative transitions: 1) diverse results by sampling multiple times; and 2) controllable results of our method by employing textural descriptions such as camera movement control. Diverse Transition Generation. We present visual results demonstrating the variety of transitions generated under identical prompts within two equivalent scenes, as depicted in Fig. 6. We can observe that as the raccoon transitions from being in the sea to the stage scene, the first two outcomes depict a form of similarity transition. However, the sequence of transitioning between the objects and backgrounds varies. The final transition, indeed, resembles the unfurling of a curtain, akin to a wave sweeping in from the right side. Controllable Transition Generation. Our method can achieve transitions by controlling the prompt with camera movements. For instance, by employing camera zoom-in and zoom-out control, we create visual occlusions, and during the zoom-out phase, we generate the subsequent scene to achieve a seamless scene transition. This occlusion technique is a widely employed transition method in filmmaking. Fig. 7 illustrates our example of this technique through the prompt, transitioning a scene from an office to a library with the presence of a panda.
139
+
140
+ ![](images/b87e0e2df43d2dc37931a32197c7504b7471f93ad607028b72b16978f07eb646.jpg)
141
+ Figure 6: Diverse transition results. Each row illustrates frames of our transition results by "the scene transition from the sea into a playing trumpet raccoon".
142
+
143
+ $I^{st}$ prompt: A panda working in the office, camera zoom-in.
144
+
145
+ ![](images/90963e0552b7cddef5bfe31a6bd9c91dcba3e524fdc82f3f1169f4ba580f85ec.jpg)
146
+
147
+ $2^{st}$ prompt: A panda working in the library, camera zoom-out.
148
+
149
+ ![](images/ab26af63341749c15b6ad2a89b203dd39cf497a5354e2aceffb4c82771cf7686.jpg)
150
+ Figure 7: Text-controllable transition. Examples of our scene transition are achieved by controlling them through textual descriptions, i.e., camera-motion control.
151
+
152
+ # 4.4 COMPARISON WITH STATE-OF-THE-ART METHOD FOR VIDEO PREDICTION
153
+
154
+ We conducted a comprehensive comparative analysis between our proposed method and the state-of-the-art method TATS for the task of generating long videos consisting of 1024 frames, on the UCF-101 dataset (Soomro et al., 2012). Qualitative and quantitative comparisons are illustrated in Fig. 8. Fig. 8 (a) visually presents the comparative results, showing that TATS tends to degrade over time, leading to the emergence of grid-like artifacts and visual collapse. In contrast, our approach avoids such collapsing phenomena, maintaining stable and visually coherent video generation throughout the sequence. Fig. 8 (b) depicts the quantitative evaluation by FVD. In our study, we compared TATS with the outcomes obtained from our model's zero-shot generation and the results achieved after fine-tuning our model on the UCF-101 dataset. All models were evaluated under the auto-regressive setting. Our results are generated by the DDIM sampling of 100 steps. Our approach demonstrates a slower degradation of video quality over time compared to TATS. In the first few frames, due to the disparity of data distribution between the training set and UCF-101, our model's scores are higher than TATS. However, as TATS degrades over time, our model's FVD score becomes lower than that of TATS. Moreover, by performing fine-tuning on the UCF-101 dataset, our method consistently outperforms TATS.
155
+
156
+ # 4.5 MORE APPLICATIONS
157
+
158
+ Long Video Generation. Fig. 9 demonstrates the generation of long videos through auto-regressive prediction. Each video consists of tens of frames by auto-regressive prediction for 4 times. Notably,
159
+
160
+ ![](images/15f6f3824064c10f40b6b9d2c48e55bf24d2294429b466f8af3e1ec0ca14cd33.jpg)
161
+ Figure 8: Comparison for auto-regressive long video prediction. a) Qualitative Results. Each frame is selected with a frame step 128 from the 256th frame; b) Qualitative results. The lower value indicates better quality.
162
+ Figure 9: Long video results via auto-regressive prediction. Best view with Acrobat Reader. Click the images to play the videos.
163
+ Figure 10: Image animation results. In each case, our result is on the left and the result of Gen-2 is on the right. Best view with Acrobat Reader. Click the images to play the videos.
164
+
165
+ A raccoon dressed in a suit playing A teddy bear washing the dishes. Two pandas discussing an aca- the trumpet, stage background. demic paper.
166
+
167
+ Ours
168
+
169
+ Gen-2
170
+
171
+ Ours
172
+
173
+ Gen-2
174
+
175
+ our method ensures that the visual quality of the generated content remains pristine while preserving consistent semantic coherence throughout the synthesized results. Image-to-Video Animation. We demonstrate the outcomes of video generation by utilizing an image as the initial frame. This approach can be seamlessly integrated with other T2I models, such as Midjourney*. Here, we compare our results with those obtained from the online API image-to-video generation model, Gen-2 (Esser et al., 2023). From the comparison, it can be observed that despite not specifically training our model for this task, our model still achieves comparable results.
176
+
177
+ # 5 CONCLUSION
178
+
179
+ In this paper, we introduce SEINE, a S2L video diffusion model that focuses on smooth and creative transitions and auto-regressive predictions. SEINE utilizes a random-mask video diffusion model to automatically generate transitions based on textual descriptions, ensuring coherence and visual quality. The model can also be extended to image-to-video animation and auto-regressive video prediction tasks, allowing for the creation of coherent "story-level" long videos. The evaluation of transitions is conducted based on temporal consistency, semantic similarity, and video-text semantic alignment. The experimental results demonstrate the superiority of our approach over existing methods in terms of transition and prediction.
180
+
181
+ # 6 ETHICS STATEMENT
182
+
183
+ We acknowledge the ethical concerns that are shared with other text-to-image and text-to-video diffusion models (Ramesh et al., 2021; 2022; Rombach et al., 2022; Sahara et al., 2022; Ho et al., 2022; He et al., 2022; Wang et al., 2023b). Furthermore, our optimization is based on diffusion model (Ho et al., 2020; Song et al., 2021b), which has the potential to introduce unintended bias as a result of the training data. On the other hand, our approach presents a short-to-long video diffusion model that aims to create a coherent story-level long video, which may have implications for various domains including filmmaking, video games, and artistic creation.
184
+
185
+ # ACKNOWLEDGEMENTS
186
+
187
+ This work is supported by the National Key R&D Program of China under Grand NO.2022ZD0160100, the National Natural Science Foundation of China under Grant No. 62102150, the Ministry of Education Singapore under its MOE AcRF Tier 2 (MOE-T2EP20221-0012) and NTU NAP, and the Science and Technology Commission of Shanghai Municipality under Grant No. 23QD1400800, No. 22511105800, and the RIE2020 Industry Alignment Fund - Industry Collaboration Projects (IAF-ICP) Funding Initiative, as well as cash and in-kind contribution from the industry partner(s).
188
+
189
+ # REFERENCES
190
+
191
+ Max Bain, Arsha Nagrani, Gül Varol, and Andrew Zisserman. Frozen in time: A joint video and image encoder for end-to-end retrieval. In ICCV, 2021.
192
+ Yogesh Balaji, Seungjun Nah, Xun Huang, Arash Vahdat, Jiaming Song, Karsten Kreis, Miika Aittala, Timo Aila, Samuli Laine, Bryan Catanzaro, et al. edifi: Text-to-image diffusion models with an ensemble of expert denoisers. arXiv preprint arXiv:2211.01324, 2022.
193
+ Andreas Blattmann, Robin Rombach, Huan Ling, Tim Dockhorn, Seung Wook Kim, Sanja Fidler, and Karsten Kreis. Align your latents: High-resolution video synthesis with latent diffusion models. In CVPR, 2023.
194
+ Mingdeng Cao, Xintao Wang, Zhongang Qi, Ying Shan, Xiaohu Qie, and Yinqiang Zheng. Mas-actr: Tuning-free mutual self-attention control for consistent image synthesis and editing. arXiv preprint arXiv:2304.08465, 2023.
195
+ Xinyuan Chen, Chang Xu, Xiaokang Yang, Li Song, and Dacheng Tao. Gated-gan: Adversarial gated networks for multi-collection style transfer. IEEE Transactions on Image Processing, 28 (2):546-560, 2018.
196
+ Xinyuan Chen, Chang Xu, Xiaokang Yang, and Dacheng Tao. Long-term video prediction via criticization and retrospection. IEEE Transactions on Image Processing, 29:7090-7103, 2020.
197
+ Patrick Esser, Robin Rombach, and Bjorn Ommer. Taming transformers for high-resolution image synthesis. In CVPR, 2021.
198
+ Patrick Esser, Johnathan Chiu, Parmida Atighehchian, Jonathan Granskog, and Anastasis Germanidis. Structure and content-guided video synthesis with diffusion models. arXiv preprint arXiv:2302.03011, 2023.
199
+ Songwei Ge, Thomas Hayes, Harry Yang, Xi Yin, Guan Pang, David Jacobs, Jia-Bin Huang, and Devi Parikh. Long video generation with time-agnostic vqgan and time-sensitive transformer. In ECCV, 2022.
200
+ Songwei Ge, Seungjun Nah, Guilin Liu, Tyler Poon, Andrew Tao, Bryan Catanzaro, David Jacobs, Jia-Bin Huang, Ming-Yu Liu, and Yogesh Balaji. Preserve your own correlation: A noise prior for video diffusion models. arXiv preprint arXiv:2305.10474, 2023.
201
+ Yingqing He, Tianyu Yang, Yong Zhang, Ying Shan, and Qifeng Chen. Latent video diffusion models for high-fidelity long video generation. 2022.
202
+
203
+ Jonathan Ho, Ajay Jain, and Pieter Abbeel. Denoising diffusion probabilistic models. Advances in Neural Information Processing Systems, 33:6840-6851, 2020.
204
+ Jonathan Ho, William Chan, Chitwan Sahara, Jay Whang, Ruiqi Gao, Alexey Gritsenko, Diederik P Kingma, Ben Poole, Mohammad Norouzi, David J Fleet, et al. Imagen video: High definition video generation with diffusion models. arXiv preprint arXiv:2210.02303, 2022.
205
+ MinGuk Kang, Joonghyuk Shin, and Jaesik Park. StudioGAN: A Taxonomy and Benchmark of GANs for Image Synthesis. IEEE Transactions on Pattern Analysis and Machine Intelligence (TPAMI), 2023.
206
+ Alexander Quinn Nichol and Prafulla Dhariwal. Improved denoising diffusion probabilistic models. In ICML, 2021.
207
+ Aditya Ramesh, Mikhail Pavlov, Gabriel Goh, Scott Gray, Chelsea Voss, Alec Radford, Mark Chen, and Ilya Sutskever. Zero-shot text-to-image generation. In ICML, 2021.
208
+ Aditya Ramesh, Prafulla Dhariwal, Alex Nichol, Casey Chu, and Mark Chen. Hierarchical text-conditional image generation with clip latents. arXiv preprint arXiv:2204.06125, 2022.
209
+ Robin Rombach, Andreas Blattmann, Dominik Lorenz, Patrick Esser, and Björn Ommer. High-resolution image synthesis with latent diffusion models. In Proceedings of the IEEE/CVF conference on computer vision and pattern recognition, pp. 10684-10695, 2022.
210
+ Chitwan Sahara, William Chan, Saurabh Saxena, Lala Li, Jay Whang, Emily L Denton, Kamyar Ghasemipour, Raphael Gontijo Lopes, Burcu Karagol Ayan, Tim Salimans, et al. Photorealistic text-to-image diffusion models with deep language understanding. Advances in Neural Information Processing Systems, 35:36479-36494, 2022.
211
+ Axel Sauer, Katja Schwarz, and Andreas Geiger. Stylegan-xl: Scaling stylegan to large diverse datasets. In Munkhtsetseg Nandigjav, Niloy J. Mitra, and Aaron Hertzmann (eds.), SIGGRAPH '22: Special Interest Group on Computer Graphics and Interactive Techniques Conference, Vancouver, BC, Canada, August 7 - 11, 2022, pp. 49:1-49:10. ACM, 2022. doi: 10.1145/3528233.3530738. URL https://doi.org/10.1145/3528233.3530738.
212
+ Eli Shechtman, Alex Rav-Acha, Michal Irani, and Steve Seitz. Regenerative morphing. In IEEE Conference on Computer Vision and Pattern Recognition (CVPR), San-Francisco, CA, June 2010.
213
+ Uriel Singer, Adam Polyak, Thomas Hayes, Xi Yin, Jie An, Songyang Zhang, Qiyuan Hu, Harry Yang, Oron Ashual, Oran Gafni, Devi Parikh, Sonal Gupta, and Yaniv Taigman. Make-a-video: Text-to-video generation without text-video data. In ICLR, 2023.
214
+ Ivan Skorokhodov, Sergey Tulyakov, and Mohamed Elhoseiny. Stylegan-v: A continuous video generator with the price, image quality and perks of stylegan2. In CVPR, 2022.
215
+ Jiaming Song, Chenlin Meng, and Stefano Ermon. Denoising diffusion implicit models. In International Conference on Learning Representations, 2021a. URL https://openreview.net/forum?id=StlgiarCHLP.
216
+ Yang Song, Jascha Sohl-Dickstein, Diederik P Kingma, Abhishek Kumar, Stefano Ermon, and Ben Poole. Score-based generative modeling through stochastic differential equations. In ICLRs, 2021b.
217
+ Khurram Soomro, Amir Roshan Zamir, and Mubarak Shah. UCF101: A Dataset of 101 Human Action Classes From Videos in The Wild. Technical report, CRCV-TR-12-01, November 2012.
218
+ Yu Tian, Jian Ren, Mengei Chai, Kyle Olszewski, Xi Peng, Dimitris N. Metaxas, and Sergey Tulyakov. A good image generator is what you need for high-resolution video synthesis. In ICLR, 2021.
219
+ Sergey Tulyakov, Ming-Yu Liu, Xiaodong Yang, and Jan Kautz. MoCoGAN: Decomposing motion and content for video generation. In CVPR, 2018.
220
+
221
+ Narek Tumanyan, Michal Geyer, Shai Bagon, and Tali Dekel. Plug-and-play diffusion features for text-driven image-to-image translation. In Proceedings of the IEEE/CVF Conference on Computer Vision and Pattern Recognition, pp. 1921-1930, 2023.
222
+ Aaron Van Den Oord, Oriol Vinyals, et al. Neural discrete representation learning. NeurIPS, 2017.
223
+ Ruben Villegas, Mohammad Babaeizadeh, Pieter-Jan Kindermans, Hernan Moraldo, Han Zhang, Mohammad Taghi Saffar, Santiago Castro, Julius Kunze, and Dumitru Erhan. Phenaki: Variable length video generation from open domain textual descriptions. In ICLR, 2023.
224
+ Fu-Yun Wang, Wenshuo Chen, Guanglu Song, Han-Jia Ye, Yu Liu, and Hongsheng Li. Gen-l-video: Multi-text to long video generation via temporal co-denoising. arXiv preprint arXiv:2305.18264, 2023a.
225
+ Yaohui Wang, Piotr Bilinski, Francois Bremond, and Antitza Dantcheva. G3AN: Disentangling appearance and motion for video generation. In CVPR, 2020a.
226
+ Yaohui Wang, Piotr Bilinski, Francois Bremond, and Antitza Dantcheva. Imaginator: Conditional spatio-temporal gan for video generation. In WACV, 2020b.
227
+ Yaohui Wang, Xinyuan Chen, Xin Ma, Shangchen Zhou, Ziqi Huang, Yi Wang, Ceyuan Yang, Yinan He, Yu Jiashuo, Yang Peiqing, Yuwei Guo, Tianxing Wu, Chenyang Si, Yuming Jiang, Cunjian Chen, Change Loy Chen, Bo Dai, Dahua Lin, Yu Qiao, and Ziwei Liu. Lavie: High-quality video generation with cascaded latent diffusion models. arXiv preprint arXiv:2309.5135377, 2023b.
228
+ Yaohui Wang, Xin Ma, Xinyuan Chen, Antitza Dantcheva, Bo Dai, and Yu Qiao. Leo: Generative latent image animator for human video synthesis. arXiv preprint arXiv:2305.03989, 2023c.
229
+ George Wolberg. Image morphing: a survey. The visual computer, 14(8-9):360-372, 1998.
230
+ Wilson Yan, Yunzhi Zhang, Pieter Abbeel, and Aravind Srinivas. Videogpt: Video generation using vq-vae and transformers. arXiv preprint arXiv:2104.10157, 2021.
231
+ Shengming Yin, Chenfei Wu, Huan Yang, Jianfeng Wang, Xiaodong Wang, Minheng Ni, Zhengyuan Yang, Linjie Li, Shuguang Liu, Fan Yang, et al. Nuwa-xl: Diffusion over diffusion for extremely long video generation. arXiv preprint arXiv:2303.12346, 2023.
232
+ Sihyun Yu, Jihoon Tack, Sangwoo Mo, Hyunsu Kim, Junho Kim, Jung-Woo Ha, and Jinwoo Shin. Generating videos with dynamics-aware implicit generative adversarial networks. In ICLR, 2022.
233
+ Lvmin Zhang and Maneesh Agrawala. Adding conditional control to text-to-image diffusion models, 2023.
234
+ Daquan Zhou, Weimin Wang, Hanshu Yan, Weiwei Lv, Yizhe Zhu, and Jiashi Feng. Magicvideo: Efficient video generation with latent diffusion models. arXiv preprint arXiv:2211.11018, 2022.
235
+
236
+ # A APPENDIX
237
+
238
+ # A.1 COMPARED METHODS FOR TRANSITION.
239
+
240
+ Here we describe the details and implementation details for the compared methods achieving transition.
241
+
242
+ - Morphing. Morphing is a special effect in motion pictures and animations that changes (or morphs) one image or shape into another through a seamless transition. Traditionally such a depiction would be achieved through dissolving techniques on film. The transition is achieved by using the first and the last frames and generating the intermediate frames.
243
+ - SD-based Method. We adopt the SD as our baseline model. Since SD cannot directly generate intermediate frames, we first compute the latent code of the given two images by reverse diffusion process (i.e., DDIM inversion (Song et al., 2021a)), then we use the interpolation of Euclidean distance of the latent codes to denoising and obtain the intermediate frames.
244
+ - VQGAN-based Method. VQGAN serves as the latent code layer for SD. We employ the interpolated representation of the codes from the encoder of VQGAN output (prior to quantization) as a reference method.
245
+
246
+ # A.2 FAILURE CASES
247
+
248
+ Watermarks. Since part of our training data (WebVid10M) contains watermarks, there is a chance that generated videos may also exhibit such signals (see Fig. 11 and 12). In the prediction task, we observed that in the autoregressive process, watermarks gradually emerge. Once they appear, they persist throughout the entire video. In the transition task, if the watermarks are present in the given images, the generated intermediate frames will also be affected. However, if no watermarks appear in the given images, watermarks are less likely to appear, and even if they do, they are usually faint.
249
+
250
+ There is a table by a window with sunlight streaming through illuminating a pile of books.
251
+
252
+ A view of lake in autumn.
253
+
254
+ A panda playing on a swing set.
255
+
256
+ Figure 11: Failure cases for prediction with watermarks. Best view with Acrobat Reader. Click the images to play the videos.
257
+
258
+ Abrupt Transition. While our method excels in transition generation, it does have limitations regarding the requirement for the similarity of the source and target scenes. A natural and smooth transition relies on finding meaningful correspondences between the two scenes. If the scenes are too dissimilar or lack common elements, the transition may appear abrupt or visually inconsistent. An alternative solution to address this limitation is through a multi-step approach. We utilize image editing methods (Tumanyan et al., 2023; Cao et al., 2023; Zhang & Agrawala, 2023) to transform the source image in the scenes and actions into the target image. This method is particularly beneficial in scene generation as it operates at the image level, naturally preserving similarities such as the structure, background, and objects of the image. As a result, the transition effects produced using this approach often appear highly natural.
259
+
260
+ Text-video Unalignment. In our S2L model, we aim to optimize $p_{\theta}(z_0|c,\tilde{z}_0)$ which $\tilde{z}_0$ represents the latent code of the unmasked condition image. However, in our training dataset, videos $z_0$ , unmasked frames $\tilde{z}_0$ , and captions/prompts $(c)$ are not completely independent and exhibit strong correlations. Consequently, when there is no inherent connection between the given unmasked image and caption, it can lead to discontinuities or difficulties in aligning with video-text alignment.
261
+
262
+ Figure 12: Failure cases for transition with watermarks. Best view with Acrobat Reader. Click the images to play the videos.
263
+ ![](images/43c293381ab9bb0c2488eb7e22fec6878660490a4613c3691faf21be9b9960eb.jpg)
264
+ A panda is in a bamboo forest, The scene has changed from the sea The scene has changed from the shifting from sketch-like to realistic into a playing trumpet raccoon. panda watching television to the style.
265
+
266
+ ![](images/79a16785fe4f8002117f63f08f29f951836be36a28d4732d7d2e7022895b2308.jpg)
267
+
268
+ ![](images/fd791af1aea05f540c04c289cd82bc5045957844e84f741e111f444b1be94d79.jpg)
269
+
270
+ ![](images/5da44f6b73aaadcf2d9056622bc32d72921da7c7ba7b79ac0239359ec5dbe32e.jpg)
271
+
272
+ ![](images/38336a06fe54cda5fafdae16f4cb3e2a5855fb7b92e291d16c257345e5bf7cec.jpg)
273
+ Transition Video 3
274
+
275
+ ![](images/bdc188068c6d1fdc0cbf39d69e899281098eecffacab0fb92720f3311d76c992.jpg)
276
+
277
+ Additionally, we have observed that the quality of generated videos would be influenced to some extent by the given prompt. Providing prompts that align well with the realistic scenario and have a resemblance to unmasked videos can yield better results. Ensuring the provision of more suitable prompts in the context of generating long videos is a topic we will explore in our subsequent research.
278
+
279
+ ![](images/bcc7b01d9ab3806737aae2078f271af05dbb20584900446e61bcdfff7a1d4ee4.jpg)
280
+ Scenes
281
+ Transition Video 1
282
+ Transition Video 2
283
+ Figure 13: Transition samples. In each case, transitions are generated by the same prompt with different random seeds. Best view with Acrobat Reader. Click the images to play videos.
284
+
285
+ # A.2.1 IMAGE-TO-VIDEO ANIMATION
286
+
287
+ We present additional outcomes of image-to-video animation, as depicted in Fig. 14. For each instance, the reference image is displayed on the left, while the corresponding animation video is showcased on the right. Notably, our model demonstrates the ability to accommodate images of various sizes. The figure showcases the animation results obtained from both square and rectangular images. The reference images in the first three rows are generated from Midjourney. The reference images in the last two rows are generated from Stable Diffusion XL.
288
+
289
+ (a) First Frame is generated from Midjourney
290
+
291
+ (b) First Frame is generated from Stable Diffusion XL
292
+
293
+ Figure 14: Image-to-video animation results. Best view with Acrobat Reader. Click the images to play the transition videos.
2024/SEINE_ Short-to-Long Video Diffusion Model for Generative Transition and Prediction/images.zip ADDED
@@ -0,0 +1,3 @@
 
 
 
 
1
+ version https://git-lfs.github.com/spec/v1
2
+ oid sha256:b6751e063730c8f490c5897cfebafc4ad85d38fa0959c72e8c11b5c9d50555c3
3
+ size 692941
2024/SEINE_ Short-to-Long Video Diffusion Model for Generative Transition and Prediction/layout.json ADDED
The diff for this file is too large to render. See raw diff
 
2024/SEPT_ Towards Efficient Scene Representation Learning for Motion Prediction/96a0a7fc-6af1-4e6b-b9d3-714a11bd3b55_content_list.json ADDED
@@ -0,0 +1,1885 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ [
2
+ {
3
+ "type": "text",
4
+ "text": "SEPT: TOWARDS EFFICIENT SCENE REPRESENTATION LEARNING FOR MOTION PREDICTION",
5
+ "text_level": 1,
6
+ "bbox": [
7
+ 171,
8
+ 98,
9
+ 823,
10
+ 148
11
+ ],
12
+ "page_idx": 0
13
+ },
14
+ {
15
+ "type": "text",
16
+ "text": "Zhiqian Lan*, Yuxuan Jiang*, Yao Mu, Chen Chen, Shengbo Eben Li†",
17
+ "bbox": [
18
+ 179,
19
+ 169,
20
+ 676,
21
+ 184
22
+ ],
23
+ "page_idx": 0
24
+ },
25
+ {
26
+ "type": "text",
27
+ "text": "School of Vehicle and Mobility, Tsinghua University {lanzq21, jyxx21}@mails.tsinghua.edu.cn lishbo@tsinghua.edu.cn",
28
+ "bbox": [
29
+ 183,
30
+ 185,
31
+ 557,
32
+ 226
33
+ ],
34
+ "page_idx": 0
35
+ },
36
+ {
37
+ "type": "text",
38
+ "text": "ABSTRACT",
39
+ "text_level": 1,
40
+ "bbox": [
41
+ 450,
42
+ 262,
43
+ 547,
44
+ 277
45
+ ],
46
+ "page_idx": 0
47
+ },
48
+ {
49
+ "type": "text",
50
+ "text": "Motion prediction is crucial for autonomous vehicles to operate safely in complex traffic environments. Extracting effective spatiotemporal relationships among traffic elements is key to accurate forecasting. Inspired by the successful practice of pretrained large language models, this paper presents SEPT, a modeling framework that leverages self-supervised learning to develop powerful spatiotemporal understanding for complex traffic scenes. Specifically, our approach involves three masking-reconstruction modeling tasks on scene inputs including agents' trajectories and road network, pretraining the scene encoder to capture kinematics within trajectory, spatial structure of road network, and interactions among roads and agents. The pretrained encoder is then finetuned on the downstream forecasting task. Extensive experiments demonstrate that SEPT, without elaborate architectural design or manual feature engineering, achieves state-of-the-art performance on the Argoverse 1 and Argoverse 2 motion forecasting benchmarks, outperforming previous methods on all main metrics by a large margin.",
51
+ "bbox": [
52
+ 228,
53
+ 295,
54
+ 769,
55
+ 491
56
+ ],
57
+ "page_idx": 0
58
+ },
59
+ {
60
+ "type": "text",
61
+ "text": "1 INTRODUCTION",
62
+ "text_level": 1,
63
+ "bbox": [
64
+ 171,
65
+ 518,
66
+ 339,
67
+ 535
68
+ ],
69
+ "page_idx": 0
70
+ },
71
+ {
72
+ "type": "text",
73
+ "text": "Accurately predicting the future trajectories of surrounding road users is crucial to a safe and efficient autonomous driving system. In addition to kinematic constraints, the future motions of traffic agents may be shaped by many factors in the traffic scene, including shape and topology of roads, and surrounding agents' behaviors. Modeling and understanding these intricate relationships within the scene has long been a core challenge for motion prediction.",
74
+ "bbox": [
75
+ 169,
76
+ 550,
77
+ 826,
78
+ 622
79
+ ],
80
+ "page_idx": 0
81
+ },
82
+ {
83
+ "type": "text",
84
+ "text": "Researches in the early stage predominantly use rasterized semantic images to represent the whole scene from a top-down view, and fuse the information with convolutional neural networks (Lee et al., 2017; Chai et al., 2020; Phan-Minh et al., 2020). Due to the information loss during rasterization, recent researches have shifted to a vectorized paradigm in which the agents and roads are represented as a set of vectors. This representation has served as the foundation for numerous advanced methods that employ graph neural networks and transformers for scene encoding (Liang et al., 2020; Zhou et al., 2022). However, these prevailing SOTA methods typically embrace sophisticated architectural designs, which often rely on anchor-based modeling (Wang et al., 2022) or proposal-refinement scheme (Shi et al., 2022; Wang et al., 2023b) to enhance the prediction performance. These empirical techniques consequently lead to an intricate information processing pipeline.",
85
+ "bbox": [
86
+ 169,
87
+ 627,
88
+ 826,
89
+ 768
90
+ ],
91
+ "page_idx": 0
92
+ },
93
+ {
94
+ "type": "text",
95
+ "text": "While previous attempts on scene encoding have focused on innovations in feature engineering and architectural design, we believe that the encoders built on universal architectures can develop strong comprehension on traffic scenes through a properly designed training scheme. A promising direction is to explore self-supervised learning (SSL). Large language models like GPT-3 (Brown et al., 2020) have leveraged SSL on large text corpora to learn broadly applicable linguistic knowledge, achieving significant advancement on a diverse set of NLP tasks. This inspires us that motion prediction models can implicitly be endowed with useful knowledge about traffic scenes such as environment dynamics and social interactions by effective self-supervised objectives.",
96
+ "bbox": [
97
+ 169,
98
+ 773,
99
+ 826,
100
+ 886
101
+ ],
102
+ "page_idx": 0
103
+ },
104
+ {
105
+ "type": "header",
106
+ "text": "Published as a conference paper at ICLR 2024",
107
+ "bbox": [
108
+ 171,
109
+ 32,
110
+ 478,
111
+ 47
112
+ ],
113
+ "page_idx": 0
114
+ },
115
+ {
116
+ "type": "page_footnote",
117
+ "text": "*Equal contribution.",
118
+ "bbox": [
119
+ 197,
120
+ 897,
121
+ 323,
122
+ 909
123
+ ],
124
+ "page_idx": 0
125
+ },
126
+ {
127
+ "type": "page_footnote",
128
+ "text": "$^{\\dagger}$ Correspondence to Shengbo Eben Li, email: lishbo@tsinghua.edu.cn",
129
+ "bbox": [
130
+ 200,
131
+ 910,
132
+ 616,
133
+ 924
134
+ ],
135
+ "page_idx": 0
136
+ },
137
+ {
138
+ "type": "page_number",
139
+ "text": "1",
140
+ "bbox": [
141
+ 493,
142
+ 948,
143
+ 504,
144
+ 959
145
+ ],
146
+ "page_idx": 0
147
+ },
148
+ {
149
+ "type": "image",
150
+ "img_path": "images/17badd58e277371143cc33db8027cb824e337a7a9bc8b71212d9924e98170d17.jpg",
151
+ "image_caption": [
152
+ "(a) MTM"
153
+ ],
154
+ "image_footnote": [],
155
+ "bbox": [
156
+ 184,
157
+ 111,
158
+ 385,
159
+ 231
160
+ ],
161
+ "page_idx": 1
162
+ },
163
+ {
164
+ "type": "image",
165
+ "img_path": "images/08fac3871ad9fe161ba18b1059ecca912109f506c6f7963e5e489443878834df.jpg",
166
+ "image_caption": [
167
+ "(b)MRM",
168
+ "Figure 1: Illustration for our proposed scene understanding training tasks. For each picture, the masked or truncated scene inputs are painted in black while the corresponding reconstructed results are painted in blue."
169
+ ],
170
+ "image_footnote": [],
171
+ "bbox": [
172
+ 398,
173
+ 112,
174
+ 599,
175
+ 232
176
+ ],
177
+ "page_idx": 1
178
+ },
179
+ {
180
+ "type": "image",
181
+ "img_path": "images/2d08699f374235ac2017dc79b8020f3dcb38ce624f34600cc2cd6ebb68155747.jpg",
182
+ "image_caption": [
183
+ "(c) TP"
184
+ ],
185
+ "image_footnote": [],
186
+ "bbox": [
187
+ 611,
188
+ 112,
189
+ 812,
190
+ 232
191
+ ],
192
+ "page_idx": 1
193
+ },
194
+ {
195
+ "type": "text",
196
+ "text": "Driven by this inspiration, we propose Scene Encoding Predictive Transformer (SEPT), a neat and powerful motion prediction framework that leverages SSL to progressively develop the spatiotemporal understanding for traffic scenes. We construct the self-supervised pretraining scheme for SEPT's scene encoder to capture three key aspects of scene context: temporal dependency within historical trajectory, spatial structure of road network, and interactions among roads and agents, yielding three corresponding pretraining tasks: Masked Trajectory Modeling (MTM), Masked Road Modeling (MRM), and Tail Prediction (TP). MTM, as shown in Figure 1a, randomly masks and reconstructs some waypoints in the agents' trajectories, to encode the temporal dependency arising from kinematic constraints. Similarly, MRM (Figure 1b) randomly masks some portion of the road vectors and then predicts the masked part, allowing the encoder to effectively capture the topology and connectivity of road network. While the previous two tasks handle single input modality, the third task TP (Figure 1c) focuses on interactions between modalities by conducting a short-term motion prediction task. In this task, we divide the agents' trajectories into two sections, named as head and tail, and the objective is to predict the tail section based on the preceding head section and the road context. The pretrained encoder is then finetuned to the downstream motion prediction task. Compared to several recent works exploring SSL in motion prediction (Chen et al., 2023; Cheng et al., 2023), our method adopts a unique pretraining task design and achieves better prediction performance.",
197
+ "bbox": [
198
+ 169,
199
+ 332,
200
+ 826,
201
+ 569
202
+ ],
203
+ "page_idx": 1
204
+ },
205
+ {
206
+ "type": "text",
207
+ "text": "The effectiveness of the proposed SEPT are demonstrated by extensive experiments from two aspects. First, the model with pretraining achieves significant improvement over the model learned from scratch on all motion forecasting metrics consistently, showing that the model gains beneficial knowledge through pretraining objectives. Second, the three self-supervised pretraining tasks effectively collaborate with each other and yield positive effects on the final performance in an additive manner. Meanwhile, our experimental results on Argoverse 1 and Argoverse 2 datasets establish SEPT as a top-performing model, ranking $1^{\\text{st}}$ across all primary metrics on both large-scale motion forecasting benchmarks. Moreover, compared to the strongest baseline (Zhou et al., 2023) to our knowledge, our model achieves twice faster inference speed with only $40\\%$ network parameters.",
208
+ "bbox": [
209
+ 169,
210
+ 575,
211
+ 823,
212
+ 702
213
+ ],
214
+ "page_idx": 1
215
+ },
216
+ {
217
+ "type": "text",
218
+ "text": "2 RELATED WORKS",
219
+ "text_level": 1,
220
+ "bbox": [
221
+ 171,
222
+ 724,
223
+ 354,
224
+ 739
225
+ ],
226
+ "page_idx": 1
227
+ },
228
+ {
229
+ "type": "text",
230
+ "text": "Scene encoding with transformers. Inspired by the remarkable success of transformer architecture, attention mechanism has been extensively used in motion prediction to model the long-range and complicated interactions within the traffic scene. Early attempts have employed attention in specific sub-modules to encode spatial relationships such as social interactions (Mercat et al., 2020; Salzmann et al., 2020), or agent-map relationships (Huang et al., 2022). A few works model traffic elements as graph and adopt transformer structure to exploit relations in graph-based inputs (Wang et al., 2022; Jia et al., 2023). Recent SOTA approaches, on the other hand, tend to process all input modalities, including trajectories and road network, jointly with hierarchically stacked transformer blocks (Ngiam et al., 2022; Nayakanti et al., 2023; Zhou et al., 2023). These approaches represent the whole traffic scene as 3-D tensors (space-time-feature) and perform factorized attention alternately along the temporal and spatial axes for several rounds to exploit spatiotemporal dependencies. Though sharing the same architectural design concept, the proposed SEPT adopts a more compact",
231
+ "bbox": [
232
+ 169,
233
+ 757,
234
+ 826,
235
+ 925
236
+ ],
237
+ "page_idx": 1
238
+ },
239
+ {
240
+ "type": "header",
241
+ "text": "Published as a conference paper at ICLR 2024",
242
+ "bbox": [
243
+ 171,
244
+ 32,
245
+ 478,
246
+ 47
247
+ ],
248
+ "page_idx": 1
249
+ },
250
+ {
251
+ "type": "page_number",
252
+ "text": "2",
253
+ "bbox": [
254
+ 493,
255
+ 948,
256
+ 503,
257
+ 959
258
+ ],
259
+ "page_idx": 1
260
+ },
261
+ {
262
+ "type": "text",
263
+ "text": "information processing pipeline, where temporal and spatial information are encoded sequentially. This leads to a neat model architecture with fewer functional blocks.",
264
+ "bbox": [
265
+ 169,
266
+ 103,
267
+ 823,
268
+ 132
269
+ ],
270
+ "page_idx": 2
271
+ },
272
+ {
273
+ "type": "text",
274
+ "text": "Self-supervised learning in motion prediction. Some previous studies have explored self-supervised learning in motion prediction. To the best of our knowledge, the works most closely related to our research are Traj-MAE (Chen et al., 2023) and Forecast-MAE (Cheng et al., 2023). Following the idea of masked autoencoder (He et al., 2022), Traj-MAE designs two independent mask-reconstruction tasks on trajectories and road map input, to train its trajectory and map encoder separately. Such separation leads to a notable limitation that the spatial relationship between agents and roads are not stressed during pretraining. In contrast, SEPT introduces the Tail prediction (TP) pretraining task, which considers both trajectories and roads inputs to capture the spatiotemporal relationships in the traffic scene. Our ablation study has shown the significant impact of TP on the final performance. The other work, Forecast-MAE, adopts a distinct masking strategy for agent trajectory. This approach incorporates the ground truth future trajectories of agents into its pretraining stage and predict the future given its history or vice versa. Its main difference with our SEPT is the granularity of the tokenization for the scene inputs: it takes the whole historical trajectory or a polyline of lane segments as a single token. SEPT, on the other hand, treats a waypoint in a trajectory or a short road vector as a token, which can better capture the motion patterns, as well as the dependency between motions and road structure. In addition, not all self-supervisory tasks in Forecast-MAE contribute to the downstream prediction task positively. As is reported in its ablation study, several combinations of tasks may degrade the final performance compared to models learned from scratch. Instead, SEPT's ablation studies show that all task combinations could improve performance in a consistent and additive manner.",
275
+ "bbox": [
276
+ 169,
277
+ 138,
278
+ 826,
279
+ 417
280
+ ],
281
+ "page_idx": 2
282
+ },
283
+ {
284
+ "type": "text",
285
+ "text": "3 APPROACH",
286
+ "text_level": 1,
287
+ "bbox": [
288
+ 171,
289
+ 439,
290
+ 302,
291
+ 455
292
+ ],
293
+ "page_idx": 2
294
+ },
295
+ {
296
+ "type": "text",
297
+ "text": "3.1 INPUT REPRESENTATION",
298
+ "text_level": 1,
299
+ "bbox": [
300
+ 171,
301
+ 472,
302
+ 385,
303
+ 487
304
+ ],
305
+ "page_idx": 2
306
+ },
307
+ {
308
+ "type": "text",
309
+ "text": "SEPT represents the traffic scene input with the following modalities:",
310
+ "bbox": [
311
+ 171,
312
+ 500,
313
+ 630,
314
+ 515
315
+ ],
316
+ "page_idx": 2
317
+ },
318
+ {
319
+ "type": "text",
320
+ "text": "Agent trajectories are represented as a tensor $[A, T, D_h]$ , which captures the recent trajectories of $A$ nearest traffic agents relative to the target agent, including itself. Each agent's trajectory is represented as a time series of $T$ state vectors, containing coordinates, timestamp, agent type, and any other attributes provided in the dataset. All position coordinates are transformed into the local coordinate system of the target agent at its $T$ -th frame. In addition, not all agents have full $T$ frames of history as the target agent. Shorter agent history is padded to $T$ frames and properly masked for further attention computation.",
321
+ "bbox": [
322
+ 169,
323
+ 521,
324
+ 826,
325
+ 619
326
+ ],
327
+ "page_idx": 2
328
+ },
329
+ {
330
+ "type": "text",
331
+ "text": "Road network is represented as a set of $R$ road vectors $[R, D_r]$ , based on the vectorized map representation from VectorNet (Gao et al., 2020). Each road vector is a directed lane centerline segment with features including start and end positions, length, turn direction, and other semantics from the dataset. To obtain fine-grained inputs for the road network, lane centerlines are segmented into vectors spanning no longer than 5 meters in length. Representing the entire road network in this way results in an input vector set of massive scale, bringing excessive computational and memory burden in self-attention modules. SEPT introduces a road pruning module based on the idea of static path planning (Guan et al., 2022; Jiang et al., 2023), to identify potential routes feasible for traversal by the target agent within the predictive horizon and construct a more compact subset $[S, D_r]$ .",
332
+ "bbox": [
333
+ 169,
334
+ 625,
335
+ 826,
336
+ 752
337
+ ],
338
+ "page_idx": 2
339
+ },
340
+ {
341
+ "type": "text",
342
+ "text": "3.2 MODEL ARCHITECTURE",
343
+ "text_level": 1,
344
+ "bbox": [
345
+ 171,
346
+ 770,
347
+ 382,
348
+ 784
349
+ ],
350
+ "page_idx": 2
351
+ },
352
+ {
353
+ "type": "text",
354
+ "text": "Figure 2 illustrates the simple but expressive model architecture of the proposed SEPT. The model comprises an encoder for scene encoding and a decoder that predicts a weighted set of trajectories based on scene memory embeddings.",
355
+ "bbox": [
356
+ 169,
357
+ 797,
358
+ 823,
359
+ 840
360
+ ],
361
+ "page_idx": 2
362
+ },
363
+ {
364
+ "type": "text",
365
+ "text": "Projection layer projects different input modalities into a shared high dimensional vector space $\\mathbb{R}^D$ in order to perform follow-up attention operations. A projection layer in SEPT is a single linear layer with ReLU activation, i.e., $\\mathrm{Project}(x) = \\max (Wx + b,0)$ .",
366
+ "bbox": [
367
+ 169,
368
+ 845,
369
+ 823,
370
+ 888
371
+ ],
372
+ "page_idx": 2
373
+ },
374
+ {
375
+ "type": "text",
376
+ "text": "TempoNet consists of $K_{T}$ stacked Transformer encoder blocks, and is used for agent history encoding. TempoNet takes as input agent history embeddings $[A,T,D]$ and conducts self-attention",
377
+ "bbox": [
378
+ 169,
379
+ 895,
380
+ 823,
381
+ 925
382
+ ],
383
+ "page_idx": 2
384
+ },
385
+ {
386
+ "type": "header",
387
+ "text": "Published as a conference paper at ICLR 2024",
388
+ "bbox": [
389
+ 171,
390
+ 32,
391
+ 478,
392
+ 47
393
+ ],
394
+ "page_idx": 2
395
+ },
396
+ {
397
+ "type": "page_number",
398
+ "text": "3",
399
+ "bbox": [
400
+ 493,
401
+ 948,
402
+ 504,
403
+ 959
404
+ ],
405
+ "page_idx": 2
406
+ },
407
+ {
408
+ "type": "image",
409
+ "img_path": "images/69dacfd84d60f35c56126722f6298c661abb337cee052738e874fef020ae36df.jpg",
410
+ "image_caption": [
411
+ "Figure 2: The overall architecture of SEPT"
412
+ ],
413
+ "image_footnote": [],
414
+ "bbox": [
415
+ 174,
416
+ 101,
417
+ 823,
418
+ 282
419
+ ],
420
+ "page_idx": 3
421
+ },
422
+ {
423
+ "type": "text",
424
+ "text": "operation along temporal dimension $T$ . After that, the embeddings across time steps are aggregated through max pooling to produce agent embeddings $[A, D]$ . Additionally, TempoNet applies the simplified relative position embedding proposed in T5 (Raffel et al., 2020), to encode relative order of time steps.",
425
+ "bbox": [
426
+ 169,
427
+ 335,
428
+ 823,
429
+ 393
430
+ ],
431
+ "page_idx": 3
432
+ },
433
+ {
434
+ "type": "text",
435
+ "text": "SpaNet concatenates $K_{S}$ Transformer encoder blocks as TempoNet does, and its primary objective is to capture spatial relationships within the traffic scene. Its scene embedding input is formed by concatenating agent and road embeddings. Notably, compared to many previous SOTA methods, SEPT avoids the use of dedicated modules that separately encode agent interaction, road network, and agent-road relations. Instead, SpaNet leverage self attention across spatial dimension $A + S$ to fulfill these encoding objectives in a unified way.",
436
+ "bbox": [
437
+ 169,
438
+ 398,
439
+ 823,
440
+ 484
441
+ ],
442
+ "page_idx": 3
443
+ },
444
+ {
445
+ "type": "text",
446
+ "text": "Cross Attender comprises $K_{C}$ stacked cross attention layers. This module cross attends a set of $N$ learnable queries $[N, D]$ with the scene memory embeddings $[A + S, D]$ from the encoder. This generates $N$ embeddings $[N, D]$ corresponding to the $N$ output modalities. Each embedding vector is then mapped from the hidden space to the physical world through two MLPs, producing the predicted 2D trajectory and its associated confidence score.",
447
+ "bbox": [
448
+ 169,
449
+ 489,
450
+ 826,
451
+ 561
452
+ ],
453
+ "page_idx": 3
454
+ },
455
+ {
456
+ "type": "text",
457
+ "text": "3.3 SCENE UNDERSTANDING TRAINING",
458
+ "text_level": 1,
459
+ "bbox": [
460
+ 171,
461
+ 578,
462
+ 460,
463
+ 592
464
+ ],
465
+ "page_idx": 3
466
+ },
467
+ {
468
+ "type": "text",
469
+ "text": "In the scene understanding training stage, we train the encoder of SEPT to understand the temporal and spatial relationships in the traffic scene, and produce high quality latent representations for the downstream trajectory prediction task. This is achieved with three self-supervised mask-reconstruction learning tasks on TempoNet, SpaNet, and their alignment, as is shown in Figure 3. In this stage, the model is optimized with the summation of the three tasks' objectives.",
470
+ "bbox": [
471
+ 169,
472
+ 604,
473
+ 823,
474
+ 676
475
+ ],
476
+ "page_idx": 3
477
+ },
478
+ {
479
+ "type": "text",
480
+ "text": "3.3.1 TASK 1: MASKED TRAJECTORY MODELING (MTM)",
481
+ "text_level": 1,
482
+ "bbox": [
483
+ 171,
484
+ 690,
485
+ 591,
486
+ 705
487
+ ],
488
+ "page_idx": 3
489
+ },
490
+ {
491
+ "type": "text",
492
+ "text": "MTM targets TempoNet for understanding the temporal dependencies in agents' trajectories. As is shown in Figure 3a, we randomly substitute a certain ratio of frames with a learnable mask token for all eligible input trajectories. By eligible here, we refer to trajectories longer than a certain threshold, because too short trajectories are often of low quality, and may not be informative enough for the model to learn meaningful representations. For MTM and two more scene understanding tasks below, the hidden vectors are fed into a shallow MLP decoder to produce reconstruction vectors, and the objective function is defined as the masked $L_{2}$ loss between reconstruction and original vectors.",
493
+ "bbox": [
494
+ 169,
495
+ 715,
496
+ 823,
497
+ 827
498
+ ],
499
+ "page_idx": 3
500
+ },
501
+ {
502
+ "type": "text",
503
+ "text": "3.3.2 TASK 2: MASKED ROAD MODELING (MRM)",
504
+ "text_level": 1,
505
+ "bbox": [
506
+ 171,
507
+ 843,
508
+ 540,
509
+ 858
510
+ ],
511
+ "page_idx": 3
512
+ },
513
+ {
514
+ "type": "text",
515
+ "text": "As is shown in Figure 3b, MRM shares a similar idea with MTM but it targets SpaNet to learn the spatial structure of road vector input. Different from the trajectories in MTM, road segments form a graph rather than a sequence, where simple positional encoding becomes unsuitable. Without bias about relative position information, learning with the token-level mask would be difficult, since a",
516
+ "bbox": [
517
+ 169,
518
+ 867,
519
+ 823,
520
+ 925
521
+ ],
522
+ "page_idx": 3
523
+ },
524
+ {
525
+ "type": "header",
526
+ "text": "Published as a conference paper at ICLR 2024",
527
+ "bbox": [
528
+ 173,
529
+ 32,
530
+ 478,
531
+ 47
532
+ ],
533
+ "page_idx": 3
534
+ },
535
+ {
536
+ "type": "page_number",
537
+ "text": "4",
538
+ "bbox": [
539
+ 493,
540
+ 948,
541
+ 504,
542
+ 959
543
+ ],
544
+ "page_idx": 3
545
+ },
546
+ {
547
+ "type": "image",
548
+ "img_path": "images/14a83934a36241a00b5a2aa58ffed13f87191b629d9372d4cf5e0d2fbcff95a8.jpg",
549
+ "image_caption": [
550
+ "(a) Masked Trajectory Modeling"
551
+ ],
552
+ "image_footnote": [],
553
+ "bbox": [
554
+ 196,
555
+ 104,
556
+ 542,
557
+ 196
558
+ ],
559
+ "page_idx": 4
560
+ },
561
+ {
562
+ "type": "image",
563
+ "img_path": "images/0ebef1ee7673d731eebbf80513c625f90b3c271e58035440c0d5b0a095313934.jpg",
564
+ "image_caption": [
565
+ "(b) Masked Road Modeling"
566
+ ],
567
+ "image_footnote": [],
568
+ "bbox": [
569
+ 584,
570
+ 117,
571
+ 795,
572
+ 196
573
+ ],
574
+ "page_idx": 4
575
+ },
576
+ {
577
+ "type": "image",
578
+ "img_path": "images/24964ad0a86e92b9cd0b99e38b61843c37684a96025f558d3ac7ad4c3d0d49ce.jpg",
579
+ "image_caption": [
580
+ "(c) Tail Prediction",
581
+ "Figure 3: SEPT tasks to learn the temporal and spatial relationship in the traffic scene"
582
+ ],
583
+ "image_footnote": [],
584
+ "bbox": [
585
+ 197,
586
+ 228,
587
+ 802,
588
+ 342
589
+ ],
590
+ "page_idx": 4
591
+ },
592
+ {
593
+ "type": "text",
594
+ "text": "time consuming linear assignment problem needs to be solved to compute the reconstruction loss. We instead employ an attribute-level mask technique by setting all attributes, except for the coordinates of the starting point, to zero for selected road feature vectors. The starting point serves as a hint for SpaNet to reconstruct the original vectors. In doing so, SpaNet has to be aware of the connectivity and continuity among unordered road vectors in order to recover the masked attributes like coordinates of endpoint.",
595
+ "bbox": [
596
+ 169,
597
+ 416,
598
+ 823,
599
+ 500
600
+ ],
601
+ "page_idx": 4
602
+ },
603
+ {
604
+ "type": "text",
605
+ "text": "3.3.3 TASK 3: TAIL PREDICTION (TP)",
606
+ "text_level": 1,
607
+ "bbox": [
608
+ 171,
609
+ 518,
610
+ 452,
611
+ 532
612
+ ],
613
+ "page_idx": 4
614
+ },
615
+ {
616
+ "type": "text",
617
+ "text": "In TP, the agents' historical trajectories are divided into two sections along the trajectory axis: the head and the tail. The model is trained to predict the tail section given the head section by employing TempoNet and SpaNet jointly, which can be seen as a simplified version of motion prediction, as is shown in Figure 3c. Specifically, the agents' historical trajectories are truncated to the first $T_{h}$ tokens before fed into TempoNet. Trajectories shorter than a threshold $kT_{h}$ are excluded from prediction. Then, the embedding vectors of the truncated trajectories and the road embeddings are concatenated and fed into SpaNet. Finally, the hidden vectors of corresponding agents are fed into a shallow MLP decoder to predict the tail sections. This task is designed to align the trajectory representation learned in MTM with the road context representation learned in MRM and model their relationships, since accurate prediction requires effective use of both spatial and temporal information.",
618
+ "bbox": [
619
+ 169,
620
+ 544,
621
+ 823,
622
+ 684
623
+ ],
624
+ "page_idx": 4
625
+ },
626
+ {
627
+ "type": "text",
628
+ "text": "3.4 MOTION PREDICTION TRAINING",
629
+ "text_level": 1,
630
+ "bbox": [
631
+ 171,
632
+ 704,
633
+ 437,
634
+ 718
635
+ ],
636
+ "page_idx": 4
637
+ },
638
+ {
639
+ "type": "text",
640
+ "text": "In the motion prediction training stage, we concatenate the pretrained encoder with the decoder, and train the whole model on the labeled dataset in an end-to-end fashion. For the motion prediction task, the loss function $\\mathcal{L}$ consists of two terms: the trajectory regression loss $\\mathcal{L}_{reg}$ and the classification loss $\\mathcal{L}_{cls}$ , which are defined in (1).",
641
+ "bbox": [
642
+ 169,
643
+ 731,
644
+ 823,
645
+ 787
646
+ ],
647
+ "page_idx": 4
648
+ },
649
+ {
650
+ "type": "equation",
651
+ "text": "\n$$\n\\mathcal {L} = \\mathcal {L} _ {r e g} + \\mathcal {L} _ {c l s},\n$$\n",
652
+ "text_format": "latex",
653
+ "bbox": [
654
+ 439,
655
+ 799,
656
+ 557,
657
+ 814
658
+ ],
659
+ "page_idx": 4
660
+ },
661
+ {
662
+ "type": "equation",
663
+ "text": "\n$$\n\\mathcal {L} _ {r e g} = L _ {1} \\operatorname {L o s s} \\left(\\tau_ {j}, \\tau_ {g t}\\right), \\tag {1}\n$$\n",
664
+ "text_format": "latex",
665
+ "bbox": [
666
+ 416,
667
+ 816,
668
+ 823,
669
+ 832
670
+ ],
671
+ "page_idx": 4
672
+ },
673
+ {
674
+ "type": "equation",
675
+ "text": "\n$$\n\\mathcal {L} _ {c l s} = - \\log p _ {j},\n$$\n",
676
+ "text_format": "latex",
677
+ "bbox": [
678
+ 444,
679
+ 834,
680
+ 553,
681
+ 849
682
+ ],
683
+ "page_idx": 4
684
+ },
685
+ {
686
+ "type": "text",
687
+ "text": "where $\\tau_{i}, p_{i}$ for $i = 1, \\dots, N$ are predicted trajectories with their normalized probabilities, and $j$ refers to the index of the trajectory closest to ground truth in terms of average displacement error (ADE):",
688
+ "bbox": [
689
+ 169,
690
+ 859,
691
+ 823,
692
+ 901
693
+ ],
694
+ "page_idx": 4
695
+ },
696
+ {
697
+ "type": "equation",
698
+ "text": "\n$$\nj = \\arg \\min _ {i} A D E (\\tau_ {i}, \\tau_ {g t}).\n$$\n",
699
+ "text_format": "latex",
700
+ "bbox": [
701
+ 403,
702
+ 905,
703
+ 589,
704
+ 926
705
+ ],
706
+ "page_idx": 4
707
+ },
708
+ {
709
+ "type": "header",
710
+ "text": "Published as a conference paper at ICLR 2024",
711
+ "bbox": [
712
+ 171,
713
+ 32,
714
+ 478,
715
+ 47
716
+ ],
717
+ "page_idx": 4
718
+ },
719
+ {
720
+ "type": "page_number",
721
+ "text": "5",
722
+ "bbox": [
723
+ 493,
724
+ 948,
725
+ 503,
726
+ 959
727
+ ],
728
+ "page_idx": 4
729
+ },
730
+ {
731
+ "type": "text",
732
+ "text": "4 EXPERIMENTS",
733
+ "text_level": 1,
734
+ "bbox": [
735
+ 171,
736
+ 102,
737
+ 328,
738
+ 118
739
+ ],
740
+ "page_idx": 5
741
+ },
742
+ {
743
+ "type": "text",
744
+ "text": "4.1 EXPERIMENTAL SETTINGS",
745
+ "text_level": 1,
746
+ "bbox": [
747
+ 171,
748
+ 133,
749
+ 398,
750
+ 148
751
+ ],
752
+ "page_idx": 5
753
+ },
754
+ {
755
+ "type": "text",
756
+ "text": "Dataset. The effectiveness of our approach is verified on Argoverse 1 and Argoverse 2, two widely-used large-scale motion forecasting datasets collected from real world. The Argoverse 1 dataset consists of 324 557 driving scenarios, with each scenario contains 2-second historical context and 3-second future to predict. In contrast, the Argoverse 2 dataset comprises 250 000 scenarios, characterized by an extended 5-second historical context and a longer prediction horizon of 6 seconds. The trajectories in both datasets are sampled at $10\\mathrm{Hz}$ .",
757
+ "bbox": [
758
+ 169,
759
+ 160,
760
+ 826,
761
+ 247
762
+ ],
763
+ "page_idx": 5
764
+ },
765
+ {
766
+ "type": "text",
767
+ "text": "Metrics. Following the evaluation protocol used by Argoverse competition, we calculate the following metrics:",
768
+ "bbox": [
769
+ 169,
770
+ 251,
771
+ 823,
772
+ 280
773
+ ],
774
+ "page_idx": 5
775
+ },
776
+ {
777
+ "type": "list",
778
+ "sub_type": "text",
779
+ "list_items": [
780
+ "- $\\min \\mathbf{FDE}_k$ : the $l_2$ distance between the endpoint of the best of $k$ forecasted trajectories and the ground truth.",
781
+ "- $\\min\\mathbf{ADE}_k$ : the average $l_2$ distance between the best of $k$ forecasted trajectories and the ground truth.",
782
+ "- miss rate $(\\mathbf{MR}_k)$ : the ratio of scenarios where $\\min FDE_k$ exceeds a threshold of $2\\mathrm{m}$ .",
783
+ "- b-minFDEk: the minFDEk added by $(1.0 - p)^{2}$ where $p$ is the probability of the best forecasted trajectory."
784
+ ],
785
+ "bbox": [
786
+ 215,
787
+ 292,
788
+ 823,
789
+ 409
790
+ ],
791
+ "page_idx": 5
792
+ },
793
+ {
794
+ "type": "text",
795
+ "text": "The best of $k$ trajectories refers to the trajectory with its endpoint closest to ground truth endpoint. These metrics are calculated for $k = 6$ and $k = 1$ , except for b-minFDE $_k$ , which is only calculated for $k = 6$ .",
796
+ "bbox": [
797
+ 169,
798
+ 421,
799
+ 823,
800
+ 463
801
+ ],
802
+ "page_idx": 5
803
+ },
804
+ {
805
+ "type": "text",
806
+ "text": "Training. In the scene understanding training stage, we concatenate train, validation and test dataset as the pretrain dataset with labels dropped. The model is trained for 150 epochs with a constant learning rate of $2 \\times 10^{-4}$ . In the downstream motion prediction training stage, we train and validate following the split of the Argoverse dataset. The model is trained for 50 epochs with the learning rate decayed linearly from $2 \\times 10^{-4}$ to 0. Both stages are trained with a batch size of 96 on a single NVIDIA GeForce RTX 3090 Ti GPU.",
807
+ "bbox": [
808
+ 169,
809
+ 470,
810
+ 826,
811
+ 554
812
+ ],
813
+ "page_idx": 5
814
+ },
815
+ {
816
+ "type": "text",
817
+ "text": "4.2 EXPERIMENTAL RESULTS",
818
+ "text_level": 1,
819
+ "bbox": [
820
+ 171,
821
+ 571,
822
+ 390,
823
+ 585
824
+ ],
825
+ "page_idx": 5
826
+ },
827
+ {
828
+ "type": "text",
829
+ "text": "Comparison with baselines. We compare SEPT performance with SOTA published methods on the Argoverse 1 and Argoverse 2 leaderboards, including DenseTNT Gu et al. (2021), HOME Gilles et al. (2021), MultiPath++ Varadarajan et al. (2022), GANet Wang et al. (2023a), MacFormer Feng et al. (2023), DCMS Ye et al. (2023), Gnet Gao et al. (2023), Wayformer Nayakanti et al. (2023), ProphNet Wang et al. (2023b) and QCNet Zhou et al. (2023), as is shown in Table 1 & 2.",
830
+ "bbox": [
831
+ 169,
832
+ 598,
833
+ 825,
834
+ 671
835
+ ],
836
+ "page_idx": 5
837
+ },
838
+ {
839
+ "type": "table",
840
+ "img_path": "images/5a91086ef291e5cb524a35315fd819a47edce36b963c834ba730eede80b06630.jpg",
841
+ "table_caption": [],
842
+ "table_footnote": [],
843
+ "table_body": "<table><tr><td>Method</td><td>b-minFDE6</td><td>minADE6</td><td>minFDE6</td><td>MR6</td><td>minADE1</td><td>minFDE1</td><td>MR1</td></tr><tr><td>DenseTNT</td><td>1.976</td><td>0.882</td><td>1.281</td><td>0.126</td><td>1.679</td><td>3.632</td><td>0.584</td></tr><tr><td>HOME</td><td>1.860</td><td>0.890</td><td>1.292</td><td>0.085</td><td>1.699</td><td>3.681</td><td>0.572</td></tr><tr><td>MultiPath++</td><td>1.793</td><td>0.790</td><td>1.214</td><td>0.132</td><td>1.624</td><td>3.614</td><td>0.565</td></tr><tr><td>GANet</td><td>1.790</td><td>0.806</td><td>1.161</td><td>0.118</td><td>1.592</td><td>3.455</td><td>0.550</td></tr><tr><td>MacFormer</td><td>1.767</td><td>0.812</td><td>1.214</td><td>0.127</td><td>1.656</td><td>3.608</td><td>0.560</td></tr><tr><td>DCMS</td><td>1.756</td><td>0.766</td><td>1.135</td><td>0.109</td><td>1.477</td><td>3.251</td><td>0.532</td></tr><tr><td>Gnet</td><td>1.751</td><td>0.789</td><td>1.160</td><td>0.117</td><td>1.569</td><td>3.407</td><td>0.545</td></tr><tr><td>Wayformer</td><td>1.741</td><td>0.768</td><td>1.162</td><td>0.119</td><td>1.636</td><td>3.656</td><td>0.572</td></tr><tr><td>ProphNet</td><td>1.694</td><td>0.762</td><td>1.134</td><td>0.110</td><td>1.491</td><td>3.263</td><td>0.526</td></tr><tr><td>QCNet</td><td>1.693</td><td>0.734</td><td>1.067</td><td>0.106</td><td>1.523</td><td>3.342</td><td>0.526</td></tr><tr><td>SEPT (Ours)</td><td>1.682</td><td>0.728</td><td>1.057</td><td>0.103</td><td>1.441</td><td>3.178</td><td>0.515</td></tr></table>",
844
+ "bbox": [
845
+ 187,
846
+ 681,
847
+ 808,
848
+ 864
849
+ ],
850
+ "page_idx": 5
851
+ },
852
+ {
853
+ "type": "text",
854
+ "text": "Table 1: Argoverse 1 leaderboard results sorted by b-minFDE<sub>6</sub>. The best entry for a metric is marked bold, and the second best is underlined.",
855
+ "bbox": [
856
+ 169,
857
+ 875,
858
+ 823,
859
+ 902
860
+ ],
861
+ "page_idx": 5
862
+ },
863
+ {
864
+ "type": "header",
865
+ "text": "Published as a conference paper at ICLR 2024",
866
+ "bbox": [
867
+ 171,
868
+ 32,
869
+ 478,
870
+ 47
871
+ ],
872
+ "page_idx": 5
873
+ },
874
+ {
875
+ "type": "page_number",
876
+ "text": "6",
877
+ "bbox": [
878
+ 493,
879
+ 948,
880
+ 504,
881
+ 960
882
+ ],
883
+ "page_idx": 5
884
+ },
885
+ {
886
+ "type": "table",
887
+ "img_path": "images/80d99250c9e977eab307cf3d9f861b6853087a01d8e8430d23f187de12f8c13f.jpg",
888
+ "table_caption": [],
889
+ "table_footnote": [],
890
+ "table_body": "<table><tr><td>Method</td><td>b-minFDE6</td><td>minADE6</td><td>minFDE6</td><td>MR6</td><td>minADE1</td><td>minFDE1</td><td>MR1</td></tr><tr><td>MacFormer</td><td>1.905</td><td>0.701</td><td>1.377</td><td>0.186</td><td>1.838</td><td>4.686</td><td>0.612</td></tr><tr><td>Gnet</td><td>1.896</td><td>0.694</td><td>1.337</td><td>0.180</td><td>1.724</td><td>4.398</td><td>0.588</td></tr><tr><td>ProphNet</td><td>1.882</td><td>0.657</td><td>1.317</td><td>0.179</td><td>1.764</td><td>4.768</td><td>0.610</td></tr><tr><td>QCNet</td><td>1.779</td><td>0.619</td><td>1.191</td><td>0.144</td><td>1.563</td><td>3.962</td><td>0.548</td></tr><tr><td>SEPT (Ours)</td><td>1.736</td><td>0.605</td><td>1.151</td><td>0.137</td><td>1.485</td><td>3.700</td><td>0.545</td></tr></table>",
891
+ "bbox": [
892
+ 187,
893
+ 101,
894
+ 803,
895
+ 200
896
+ ],
897
+ "page_idx": 6
898
+ },
899
+ {
900
+ "type": "text",
901
+ "text": "On the Argoverse 1 dataset, our result outperforms all previous entries and ranks $1^{\\text{st}}$ on all metrics except for $\\mathrm{MR}_6$ . For $\\mathrm{MR}_6$ , HOME employs a \"sparse sampling\" technique to specialize miss rate performance while sacrifices other metrics. In this case, SEPT, being a general purpose method, ranks $2^{\\text{nd}}$ . Furthermore, for the Argoverse 2 dataset, SEPT consistently maintains its leading position on the leaderboard, ranking $1^{\\text{st}}$ on all metrics. Moreover, compared to QCNet, the strongest baseline in both benchmarks, SEPT has only $40\\%$ of its network parameters (around 9.6 million) while exhibits inference speed which is twice faster.",
902
+ "bbox": [
903
+ 169,
904
+ 250,
905
+ 823,
906
+ 348
907
+ ],
908
+ "page_idx": 6
909
+ },
910
+ {
911
+ "type": "text",
912
+ "text": "Comparison with related works. As is discussed in related works, Traj-MAE and Forecast-MAE share a similar idea of mask-reconstruction for trajectory prediction, but struggle to reach SOTA performance to justify pretraining. Traj-MAE reports $\\mathrm{minADE}_6$ , $\\mathrm{minFDE}_6$ and $\\mathrm{MR}_6$ on Argoverse 1 test set, and Forecast-MAE reports these metrics on Argoverse 2 test set. As is shown in Table 3, SEPT outperforms these two methods by a large margin, further demonstrating our method's effectiveness.",
913
+ "bbox": [
914
+ 169,
915
+ 354,
916
+ 823,
917
+ 436
918
+ ],
919
+ "page_idx": 6
920
+ },
921
+ {
922
+ "type": "table",
923
+ "img_path": "images/a191e628a324a2c6e11e973d3be2e4d89797bec5b4843fb1b0d9b6751e2de8de.jpg",
924
+ "table_caption": [
925
+ "Table 2:Argoverse 2 leaderboard results."
926
+ ],
927
+ "table_footnote": [
928
+ "(a) Comparison with Traj-MAE on Argoverse 1"
929
+ ],
930
+ "table_body": "<table><tr><td>Method</td><td>minADE6</td><td>minFDE6</td><td>MR6</td></tr><tr><td>Traj-MAE</td><td>0.81</td><td>1.25</td><td>0.137</td></tr><tr><td>SEPT</td><td>0.728</td><td>1.057</td><td>0.103</td></tr></table>",
931
+ "bbox": [
932
+ 173,
933
+ 460,
934
+ 467,
935
+ 515
936
+ ],
937
+ "page_idx": 6
938
+ },
939
+ {
940
+ "type": "table",
941
+ "img_path": "images/e7d452d763714bfebd668e99b5708b119ec6fc5a1823fa4ca8d0bd99df8fd6b5.jpg",
942
+ "table_caption": [],
943
+ "table_footnote": [
944
+ "(b) Comparison with Forecast-MAE on Argoverse 2"
945
+ ],
946
+ "table_body": "<table><tr><td>Method</td><td>minADE6</td><td>minFDE6</td><td>MR6</td></tr><tr><td>Forecast-MAE</td><td>0.690</td><td>1.338</td><td>0.173</td></tr><tr><td>SEPT</td><td>0.605</td><td>1.151</td><td>0.137</td></tr></table>",
947
+ "bbox": [
948
+ 501,
949
+ 460,
950
+ 820,
951
+ 513
952
+ ],
953
+ "page_idx": 6
954
+ },
955
+ {
956
+ "type": "text",
957
+ "text": "Table 3: Performance comparison with related works",
958
+ "bbox": [
959
+ 321,
960
+ 542,
961
+ 671,
962
+ 556
963
+ ],
964
+ "page_idx": 6
965
+ },
966
+ {
967
+ "type": "text",
968
+ "text": "Trajectory prediction visualization. We compare the prediction results between the model with pretraining and the model trained from scratch in Figure 4. The visualization demonstrates that the model with pretraining can better capture the multimodality of driving purposes (shown in case 1) and generate the trajectories with improved conformity to road shapes (shown in case 2 & 3).",
969
+ "bbox": [
970
+ 169,
971
+ 574,
972
+ 823,
973
+ 631
974
+ ],
975
+ "page_idx": 6
976
+ },
977
+ {
978
+ "type": "text",
979
+ "text": "4.3 ABLATION STUDIES",
980
+ "text_level": 1,
981
+ "bbox": [
982
+ 171,
983
+ 647,
984
+ 352,
985
+ 659
986
+ ],
987
+ "page_idx": 6
988
+ },
989
+ {
990
+ "type": "text",
991
+ "text": "The ablation studies focus on the scene understanding stage, specifically the effectiveness of various combinations of scene understanding tasks and the impact of their hyperparameters. We conduct ablation experiments following the same routine as the main experiment, and report the evaluation performance on the Argoverse 1 validation dataset. To minimize the impact of randomness, we conduct multiple experiments with different seeds for each configuration.",
992
+ "bbox": [
993
+ 169,
994
+ 672,
995
+ 823,
996
+ 743
997
+ ],
998
+ "page_idx": 6
999
+ },
1000
+ {
1001
+ "type": "text",
1002
+ "text": "Effectiveness of scene understanding tasks. MTM, MRM and TP are three tasks introduced to learn a good prior for the downstream trajectory prediction task. To investigate the effectiveness, we conduct experiments for all 8 combinations, and the results are shown in Figure 5 and Table 4.",
1003
+ "bbox": [
1004
+ 169,
1005
+ 750,
1006
+ 823,
1007
+ 792
1008
+ ],
1009
+ "page_idx": 6
1010
+ },
1011
+ {
1012
+ "type": "text",
1013
+ "text": "In Figure 5, we use solid lines for combinations involving task TP, and dashed lines for combinations without this task. It is clear that combinations with TP consistently outperform the opposites by learning faster at the beginning and performing better after convergence. This indicates that TP is effective to align TempoNet and SpaNet, therefore improve the overall representation quality of scene encoding. The other two tasks, MTM and MRM, can also improve performance in a consistent and additive manner. Furthermore, it should be noted that the configuration with all tasks active not only achieves the best performance, but also has the lowest variance over 5 runs among all combinations, as is shown in the shaded area in Figure 5. This suggests that our proposed training approach can help the model converge to a good level consistently. Table 4 includes the",
1014
+ "bbox": [
1015
+ 169,
1016
+ 797,
1017
+ 825,
1018
+ 925
1019
+ ],
1020
+ "page_idx": 6
1021
+ },
1022
+ {
1023
+ "type": "header",
1024
+ "text": "Published as a conference paper at ICLR 2024",
1025
+ "bbox": [
1026
+ 173,
1027
+ 32,
1028
+ 478,
1029
+ 47
1030
+ ],
1031
+ "page_idx": 6
1032
+ },
1033
+ {
1034
+ "type": "page_number",
1035
+ "text": "7",
1036
+ "bbox": [
1037
+ 493,
1038
+ 948,
1039
+ 503,
1040
+ 959
1041
+ ],
1042
+ "page_idx": 6
1043
+ },
1044
+ {
1045
+ "type": "image",
1046
+ "img_path": "images/7a792e810ba074d1d9f87f4477ee153c07036f3f84362bf7ce0f6f4e521f1073.jpg",
1047
+ "image_caption": [],
1048
+ "image_footnote": [],
1049
+ "bbox": [
1050
+ 181,
1051
+ 114,
1052
+ 388,
1053
+ 251
1054
+ ],
1055
+ "page_idx": 7
1056
+ },
1057
+ {
1058
+ "type": "image",
1059
+ "img_path": "images/1840b7397081c056493e7af4950d7ffec69f94b5bef5aa4e9fd1366b96c9642d.jpg",
1060
+ "image_caption": [],
1061
+ "image_footnote": [],
1062
+ "bbox": [
1063
+ 395,
1064
+ 114,
1065
+ 602,
1066
+ 251
1067
+ ],
1068
+ "page_idx": 7
1069
+ },
1070
+ {
1071
+ "type": "image",
1072
+ "img_path": "images/b99c9e6dd2b6aed24304265a6d47dfef9ba52d303355ccacc3b01c0077ef13f1.jpg",
1073
+ "image_caption": [],
1074
+ "image_footnote": [],
1075
+ "bbox": [
1076
+ 607,
1077
+ 114,
1078
+ 816,
1079
+ 251
1080
+ ],
1081
+ "page_idx": 7
1082
+ },
1083
+ {
1084
+ "type": "image",
1085
+ "img_path": "images/b0cc7e741f0a38fff3d7fd7bde329975f79617186d6ea9591b9bbe883c3b0945.jpg",
1086
+ "image_caption": [
1087
+ "(a) case 1"
1088
+ ],
1089
+ "image_footnote": [],
1090
+ "bbox": [
1091
+ 181,
1092
+ 253,
1093
+ 388,
1094
+ 388
1095
+ ],
1096
+ "page_idx": 7
1097
+ },
1098
+ {
1099
+ "type": "image",
1100
+ "img_path": "images/a5fda892f2ff0bb50eb2925f1e50c1310bb14e88bc3e773c9b409248f8228918.jpg",
1101
+ "image_caption": [
1102
+ "(b) case 2"
1103
+ ],
1104
+ "image_footnote": [],
1105
+ "bbox": [
1106
+ 393,
1107
+ 253,
1108
+ 602,
1109
+ 388
1110
+ ],
1111
+ "page_idx": 7
1112
+ },
1113
+ {
1114
+ "type": "image",
1115
+ "img_path": "images/12d2c3f7a176d4c13500cdcda396d2352b2ceb7bab77bf141c094c0d18264503.jpg",
1116
+ "image_caption": [
1117
+ "(c) case 3"
1118
+ ],
1119
+ "image_footnote": [],
1120
+ "bbox": [
1121
+ 607,
1122
+ 253,
1123
+ 816,
1124
+ 388
1125
+ ],
1126
+ "page_idx": 7
1127
+ },
1128
+ {
1129
+ "type": "image",
1130
+ "img_path": "images/7eb7c7301def1338a7365fc374b1484fec7b8f023d04c48bc63f8c1ac05ef9cd.jpg",
1131
+ "image_caption": [
1132
+ "Figure 4: Visualization results on three selected scenarios from Argoverse 1 validation set. The target agent's history and ground truth future are shown in red and green, respectively, while model's predictions are shown in blue. In each case, the upper image corresponds to the model that learns from scratch while the lower image corresponds to the model with scene understanding training.",
1133
+ "Figure 5 & Table 4: The training curves report b-minFDE $_6$ performance for all task combinations. The solid or dashed lines correspond to the mean and the shaded regions correspond to $1 - \\sigma$ confidence interval over 5 runs. The table reports the final performance of all $k = 6$ metrics. The best entry for a metric is marked bold."
1134
+ ],
1135
+ "image_footnote": [],
1136
+ "bbox": [
1137
+ 163,
1138
+ 502,
1139
+ 408,
1140
+ 662
1141
+ ],
1142
+ "page_idx": 7
1143
+ },
1144
+ {
1145
+ "type": "table",
1146
+ "img_path": "images/21817079cc5cf40844dc291b1233ec84002f980d3a374d1852d757a31dac76b8.jpg",
1147
+ "table_caption": [],
1148
+ "table_footnote": [],
1149
+ "table_body": "<table><tr><td colspan=\"3\">Task configuration</td><td colspan=\"4\">Final evaluation metrics</td></tr><tr><td>MTM</td><td>MRM</td><td>TP</td><td>b-minFDE6</td><td>minADE6</td><td>minFDE6</td><td>MR6</td></tr><tr><td></td><td></td><td></td><td>1.657</td><td>0.687</td><td>1.016</td><td>0.100</td></tr><tr><td>✓</td><td></td><td></td><td>1.620</td><td>0.670</td><td>0.980</td><td>0.095</td></tr><tr><td></td><td>✓</td><td></td><td>1.628</td><td>0.674</td><td>0.988</td><td>0.096</td></tr><tr><td>✓</td><td>✓</td><td></td><td>1.603</td><td>0.663</td><td>0.964</td><td>0.091</td></tr><tr><td></td><td></td><td>✓</td><td>1.605</td><td>0.661</td><td>0.964</td><td>0.091</td></tr><tr><td>✓</td><td></td><td>✓</td><td>1.586</td><td>0.653</td><td>0.947</td><td>0.089</td></tr><tr><td></td><td>✓</td><td>✓</td><td>1.588</td><td>0.653</td><td>0.950</td><td>0.090</td></tr><tr><td>✓</td><td>✓</td><td>✓</td><td>1.563</td><td>0.643</td><td>0.927</td><td>0.086</td></tr></table>",
1150
+ "bbox": [
1151
+ 421,
1152
+ 503,
1153
+ 823,
1154
+ 657
1155
+ ],
1156
+ "page_idx": 7
1157
+ },
1158
+ {
1159
+ "type": "text",
1160
+ "text": "final performance for all $k = 6$ metrics. It can be seen that other metrics exhibit similar patterns of improvement to b-minFDE $_6$ discussed above. Training curves for those metrics are included in the Appendix.",
1161
+ "bbox": [
1162
+ 169,
1163
+ 777,
1164
+ 823,
1165
+ 821
1166
+ ],
1167
+ "page_idx": 7
1168
+ },
1169
+ {
1170
+ "type": "text",
1171
+ "text": "Effects of mask hyperparameters. In this ablation experiment, we show the impact of mask hyperparameters on final performance. For MTM and MRM, the main mask hyperparameter is the mask ratio $p$ , implemented as sampling a mask from Bernoulli $(p)$ . For TP, the mask hyperparameter is the length of visible history $T_{h}$ . For each of these three hyperparameters, we pretrain with the single corresponding task, then finetune with identical setting to get the final performance. As is shown in Figure 6, mask hyperparameters do not have a significant impact in suitable ranges and always outperform the model that trains from scratch. This suggests the effectiveness of our task design and",
1172
+ "bbox": [
1173
+ 169,
1174
+ 825,
1175
+ 826,
1176
+ 925
1177
+ ],
1178
+ "page_idx": 7
1179
+ },
1180
+ {
1181
+ "type": "header",
1182
+ "text": "Published as a conference paper at ICLR 2024",
1183
+ "bbox": [
1184
+ 173,
1185
+ 32,
1186
+ 478,
1187
+ 47
1188
+ ],
1189
+ "page_idx": 7
1190
+ },
1191
+ {
1192
+ "type": "page_number",
1193
+ "text": "8",
1194
+ "bbox": [
1195
+ 493,
1196
+ 948,
1197
+ 503,
1198
+ 959
1199
+ ],
1200
+ "page_idx": 7
1201
+ },
1202
+ {
1203
+ "type": "text",
1204
+ "text": "its robustness to choices of hyperparameters. In our main experiment, we simply use $p_{\\mathrm{MTM}} = 0.5$ , $p_{\\mathrm{MRM}} = 0.5$ and $T_h = 8/20$ (for Argoverse 1/2) without tuning.",
1205
+ "bbox": [
1206
+ 169,
1207
+ 103,
1208
+ 823,
1209
+ 133
1210
+ ],
1211
+ "page_idx": 8
1212
+ },
1213
+ {
1214
+ "type": "image",
1215
+ "img_path": "images/cd0818dd661f90f7dabd44205a871c7c82dca9274fb425d93ae5d86b2ce7a42e.jpg",
1216
+ "image_caption": [
1217
+ "(a) MTM"
1218
+ ],
1219
+ "image_footnote": [],
1220
+ "bbox": [
1221
+ 178,
1222
+ 159,
1223
+ 390,
1224
+ 263
1225
+ ],
1226
+ "page_idx": 8
1227
+ },
1228
+ {
1229
+ "type": "image",
1230
+ "img_path": "images/01b3fa0d12818cd0bf73246d02358546a791ba235b464506ee028c25e3d4b601.jpg",
1231
+ "image_caption": [
1232
+ "(b)MRM"
1233
+ ],
1234
+ "image_footnote": [],
1235
+ "bbox": [
1236
+ 392,
1237
+ 159,
1238
+ 604,
1239
+ 263
1240
+ ],
1241
+ "page_idx": 8
1242
+ },
1243
+ {
1244
+ "type": "image",
1245
+ "img_path": "images/966ca9d6e849239c2386b8f0106b859ba326529ed4a2271a6d88a43a17da7fe5.jpg",
1246
+ "image_caption": [
1247
+ "(c) TP",
1248
+ "Figure 6: Final b-minFDE $_6$ performance of varying mask settings for each task, averaged over 5 runs."
1249
+ ],
1250
+ "image_footnote": [],
1251
+ "bbox": [
1252
+ 607,
1253
+ 159,
1254
+ 820,
1255
+ 265
1256
+ ],
1257
+ "page_idx": 8
1258
+ },
1259
+ {
1260
+ "type": "text",
1261
+ "text": "5 CONCLUSION",
1262
+ "text_level": 1,
1263
+ "bbox": [
1264
+ 171,
1265
+ 352,
1266
+ 320,
1267
+ 367
1268
+ ],
1269
+ "page_idx": 8
1270
+ },
1271
+ {
1272
+ "type": "text",
1273
+ "text": "In this paper, we present Scene Encoding Predictive Transformer (SEPT), a powerful modeling framework for accurate and efficient motion prediction. Leveraging three self-supervised mask-reconstruction learning tasks for scene understanding, we achieve SOTA performance on two large-scale motion forecasting datasets with a neat and unified model architecture. The ablation studies further demonstrate that introduced pretraining tasks can significantly improve prediction performance in a consistent and additive manner. Meanwhile, we acknowledge the limitation that, due to its agent-centric scene representation, SEPT is a single-agent prediction framework, and is not trivially extendable to multi-agent joint prediction. In the future, we will investigate further and generalize it to a more powerful multi-agent prediction framework.",
1274
+ "bbox": [
1275
+ 169,
1276
+ 383,
1277
+ 823,
1278
+ 508
1279
+ ],
1280
+ "page_idx": 8
1281
+ },
1282
+ {
1283
+ "type": "text",
1284
+ "text": "6 ACKNOWLEDGEMENT",
1285
+ "text_level": 1,
1286
+ "bbox": [
1287
+ 171,
1288
+ 530,
1289
+ 388,
1290
+ 544
1291
+ ],
1292
+ "page_idx": 8
1293
+ },
1294
+ {
1295
+ "type": "text",
1296
+ "text": "This work is supported by NSF China under 52221005. It is also partially supported by Tsinghua University-Didi Joint Research Center for Future Mobility.",
1297
+ "bbox": [
1298
+ 169,
1299
+ 560,
1300
+ 823,
1301
+ 590
1302
+ ],
1303
+ "page_idx": 8
1304
+ },
1305
+ {
1306
+ "type": "text",
1307
+ "text": "REFERENCES",
1308
+ "text_level": 1,
1309
+ "bbox": [
1310
+ 171,
1311
+ 609,
1312
+ 287,
1313
+ 625
1314
+ ],
1315
+ "page_idx": 8
1316
+ },
1317
+ {
1318
+ "type": "list",
1319
+ "sub_type": "ref_text",
1320
+ "list_items": [
1321
+ "Tom Brown, Benjamin Mann, Nick Ryder, Melanie Subbiah, Jared D Kaplan, Prafulla Dhariwal, Arvind Neelakantan, Pranav Shyam, Girish Sastry, Amanda Askell, et al. Language models are few-shot learners. Advances in neural information processing systems, 33:1877-1901, 2020.",
1322
+ "Yuning Chai, Benjamin Sapp, Mayank Bansal, and Dragomir Anguelov. Multipath: Multiple probabilistic anchor trajectory hypotheses for behavior prediction. In Leslie Pack Kaelbling, Danica Kragic, and Komei Sugiura, editors, Proceedings of the Conference on Robot Learning, volume 100 of Proceedings of Machine Learning Research, pages 86-99. PMLR, 30 Oct-01 Nov 2020. URL https://proceedings.mlr.press/v100/chai20a.html.",
1323
+ "Hao Chen, Jiaze Wang, Kun Shao, Furui Liu, Jianye Hao, Chenyong Guan, Guangyong Chen, and Pheng-Ann Heng. Traj-mae: Masked autoencoders for trajectory prediction. In Proceedings of the IEEE/CVF International Conference on Computer Vision (ICCV), pages 8351-8362, October 2023.",
1324
+ "Jie Cheng, Xiaodong Mei, and Ming Liu. Forecast-mae: Self-supervised pre-training for motion forecasting with masked autoencoders. In Proceedings of the IEEE/CVF International Conference on Computer Vision (ICCV), pages 8679-8689, October 2023.",
1325
+ "Chen Feng, Hangning Zhou, Huadong Lin, Zhigang Zhang, Ziyao Xu, Chi Zhang, Boyu Zhou, and Shaojie Shen. Macformer: Map-agent coupled transformer for real-time and robust trajectory prediction, 2023."
1326
+ ],
1327
+ "bbox": [
1328
+ 173,
1329
+ 633,
1330
+ 826,
1331
+ 924
1332
+ ],
1333
+ "page_idx": 8
1334
+ },
1335
+ {
1336
+ "type": "header",
1337
+ "text": "Published as a conference paper at ICLR 2024",
1338
+ "bbox": [
1339
+ 171,
1340
+ 32,
1341
+ 478,
1342
+ 47
1343
+ ],
1344
+ "page_idx": 8
1345
+ },
1346
+ {
1347
+ "type": "page_number",
1348
+ "text": "9",
1349
+ "bbox": [
1350
+ 493,
1351
+ 948,
1352
+ 504,
1353
+ 959
1354
+ ],
1355
+ "page_idx": 8
1356
+ },
1357
+ {
1358
+ "type": "list",
1359
+ "sub_type": "ref_text",
1360
+ "list_items": [
1361
+ "Jiyang Gao, Chen Sun, Hang Zhao, Yi Shen, Dragomir Anguelov, Congcong Li, and Cordelia Schmid. Vectornet: Encoding hd maps and agent dynamics from vectorized representation. In Proceedings of the IEEE/CVF Conference on Computer Vision and Pattern Recognition, pages 11525-11533, 2020.",
1362
+ "Xing Gao, Xiaogang Jia, Yikang Li, and Hongkai Xiong. Dynamic scenario representation learning for motion forecasting with heterogeneous graph convolutional recurrent networks. IEEE Robotics Autom. Lett., 8(5):2946-2953, 2023. doi: 10.1109/LRA.2023.3262150. URL https://doi.org/10.1109/LRA.2023.3262150.",
1363
+ "Thomas Gilles, Stefano Sabatini, Dzmitry Tsishkou, Bogdan Stanciulescu, and Fabien Moutarde. HOME: heatmap output for future motion estimation. In 24th IEEE International Intelligent Transportation Systems Conference, ITSC 2021, Indianapolis, IN, USA, September 19-22, 2021, pages 500-507. IEEE, 2021. doi: 10.1109/ITSC48978.2021.9564944. URL https://doi.org/10.1109/ITSC48978.2021.9564944.",
1364
+ "Junru Gu, Chen Sun, and Hang Zhao. Densetnt: End-to-end trajectory prediction from dense goal sets. In 2021 IEEE/CVF International Conference on Computer Vision, ICCV 2021, Montreal, QC, Canada, October 10-17, 2021, pages 15283-15292. IEEE, 2021. doi: 10.1109/ICCV48922.2021.01502. URL https://doi.org/10.1109/ICCV48922.2021.01502.",
1365
+ "Yang Guan, Yangang Ren, Qi Sun, Shengbo Eben Li, Haitong Ma, Jingliang Duan, Yifan Dai, and Bo Cheng. Integrated decision and control: Toward interpretable and computationally efficient driving intelligence. IEEE transactions on cybernetics, 53(2):859-873, 2022.",
1366
+ "Kaiming He, Xinlei Chen, Saining Xie, Yanghao Li, Piotr Dólár, and Ross Girshick. Masked autoencoders are scalable vision learners. In Proceedings of the IEEE/CVF conference on computer vision and pattern recognition, pages 16000-16009, 2022.",
1367
+ "Zhiyu Huang, Xiaoyu Mo, and Chen Lv. Multi-modal motion prediction with transformer-based neural network for autonomous driving. In 2022 International Conference on Robotics and Automation (ICRA), pages 2605-2611. IEEE, 2022.",
1368
+ "Xiaosong Jia, Penghao Wu, Li Chen, Yu Liu, Hongyang Li, and Junchi Yan. Hdgt: Heterogeneous driving graph transformer for multi-agent trajectory prediction via scene encoding. IEEE transactions on pattern analysis and machine intelligence, 2023.",
1369
+ "Yuxuan Jiang, Guojian Zhan, Zhiqian Lan, Chang Liu, Bo Cheng, and Shengbo Eben Li. A reinforcement learning benchmark for autonomous driving in general urban scenarios. IEEE Transactions on Intelligent Transportation Systems, 2023.",
1370
+ "Namhoon Lee, Wongun Choi, Paul Vernaza, Christopher B Choy, Philip HS Torr, and Manmohan Chandraker. Desire: Distant future prediction in dynamic scenes with interacting agents. In Proceedings of the IEEE conference on computer vision and pattern recognition, pages 336-345, 2017.",
1371
+ "Ming Liang, Bin Yang, Rui Hu, Yun Chen, Renjie Liao, Song Feng, and Raquel Urtasun. Learning lane graph representations for motion forecasting. In Computer Vision-ECCV 2020: 16th European Conference, Glasgow, UK, August 23-28, 2020, Proceedings, Part II 16, pages 541-556. Springer, 2020.",
1372
+ "Jean Mercat, Thomas Gilles, Nicole El Zoghby, Guillaume Sandou, Dominique Beauvois, and Guillermo Pita Gil. Multi-head attention for multi-modal joint vehicle motion forecasting. In 2020 IEEE International Conference on Robotics and Automation (ICRA), pages 9638-9644. IEEE, 2020.",
1373
+ "Nigamaa Nayakanti, Rami Al-Rfou, Aurick Zhou, Kratarth Goel, Khaled S. Refaat, and Benjamin Sapp. Wayformer: Motion forecasting via simple & efficient attention networks. In IEEE International Conference on Robotics and Automation, ICRA 2023, London, UK, May 29 - June 2, 2023, pages 2980-2987. IEEE, 2023. doi: 10.1109/ICRA48891.2023.10160609. URL https://doi.org/10.1109/ICRA48891.2023.10160609."
1374
+ ],
1375
+ "bbox": [
1376
+ 171,
1377
+ 102,
1378
+ 825,
1379
+ 924
1380
+ ],
1381
+ "page_idx": 9
1382
+ },
1383
+ {
1384
+ "type": "header",
1385
+ "text": "Published as a conference paper at ICLR 2024",
1386
+ "bbox": [
1387
+ 171,
1388
+ 32,
1389
+ 478,
1390
+ 47
1391
+ ],
1392
+ "page_idx": 9
1393
+ },
1394
+ {
1395
+ "type": "page_number",
1396
+ "text": "10",
1397
+ "bbox": [
1398
+ 490,
1399
+ 946,
1400
+ 509,
1401
+ 959
1402
+ ],
1403
+ "page_idx": 9
1404
+ },
1405
+ {
1406
+ "type": "list",
1407
+ "sub_type": "ref_text",
1408
+ "list_items": [
1409
+ "Jiquan Ngiam, Vijay Vasudevan, Benjamin Caine, Zhengdong Zhang, Hao-Tien Lewis Chiang, Jeffrey Ling, Rebecca Roelofs, Alex Bewley, Chenxi Liu, Ashish Venugopal, David J Weiss, Benjamin Sapp, Zhifeng Chen, and Jonathon Shlens. Scene transformer: A unified architecture for predicting future trajectories of multiple agents. In International Conference on Learning Representations, 2022. URL https://openreview.net/forum?id=Wm3EA5OlHsG.",
1410
+ "Tung Phan-Minh, Elena Corina Grigore, Freddy A Boulton, Oscar Beijbom, and Eric M Wolff. Covernet: Multimodal behavior prediction using trajectory sets. In Proceedings of the IEEE/CVF conference on computer vision and pattern recognition, pages 14074-14083, 2020.",
1411
+ "Colin Raffel, Noam Shazeer, Adam Roberts, Katherine Lee, Sharan Narang, Michael Matena, Yanqi Zhou, Wei Li, and Peter J Liu. Exploring the limits of transfer learning with a unified text-to-text transformer. The Journal of Machine Learning Research, 21(1):5485-5551, 2020.",
1412
+ "Tim Salzmann, Boris Ivanovic, Punarjay Chakravarty, and Marco Pavone. Trajectory++. Dynamically-feasible trajectory forecasting with heterogeneous data. In Computer Vision-ECCV 2020: 16th European Conference, Glasgow, UK, August 23-28, 2020, Proceedings, Part XVIII 16, pages 683-700. Springer, 2020.",
1413
+ "Shaoshuai Shi, Li Jiang, Dengxin Dai, and Bernt Schiele. Motion transformer with global intention localization and local movement refinement. Advances in Neural Information Processing Systems, 35:6531-6543, 2022.",
1414
+ "Balakrishnan Varadarajan, Ahmed Hefny, Avikalp Srivastava, Khaled S. Refaat, Nigamaa Nayakanti, Andre Cornman, Kan Chen, Bertrand Douillard, Chi-Pang Lam, Dragomir Anguelov, and Benjamin Sapp. Multipath++: Efficient information fusion and trajectory aggregation for behavior prediction. In 2022 International Conference on Robotics and Automation, ICRA 2022, Philadelphia, PA, USA, May 23-27, 2022, pages 7814-7821. IEEE, 2022. doi: 10.1109/ICRA46639.2022.9812107. URL https://doi.org/10.1109/ICRA46639.2022.9812107.",
1415
+ "Jingke Wang, Tengju Ye, Ziqing Gu, and Junbo Chen. Ltp: Lane-based trajectory prediction for autonomous driving. In Proceedings of the IEEE/CVF Conference on Computer Vision and Pattern Recognition, pages 17134-17142, 2022.",
1416
+ "Mingkun Wang, Xinge Zhu, Changqian Yu, Wei Li, Yuexin Ma, Ruochun Jin, Xiaoguang Ren, Dongchun Ren, Mingxu Wang, and Wenjing Yang. Ganet: Goal area network for motion forecasting. In IEEE International Conference on Robotics and Automation, ICRA 2023, London, UK, May 29 - June 2, 2023, pages 1609-1615. IEEE, 2023a. doi: 10.1109/ICRA48891.2023.10160468. URL https://doi.org/10.1109/ICRA48891.2023.10160468.",
1417
+ "Xishun Wang, Tong Su, Fang Da, and Xiaodong Yang. Prophnet: Efficient agent-centric motion forecasting with anchor-informed proposals, 2023b.",
1418
+ "Maosheng Ye, Jiamiao Xu, Xunnong Xu, Tengfei Wang, Tongyi Cao, and Qifeng Chen. Bootstrap motion forecasting with self-consistent constraints, 2023.",
1419
+ "Zikang Zhou, Luyao Ye, Jianping Wang, Kui Wu, and Kejie Lu. Hivt: Hierarchical vector transformer for multi-agent motion prediction. In Proceedings of the IEEE/CVF Conference on Computer Vision and Pattern Recognition, pages 8823-8833, 2022.",
1420
+ "Zikang Zhou, Jianping Wang, Yung-Hui Li, and Yu-Kai Huang. Query-centric trajectory prediction. In Proceedings of the IEEE/CVF Conference on Computer Vision and Pattern Recognition (CVPR), pages 17863-17873, June 2023."
1421
+ ],
1422
+ "bbox": [
1423
+ 171,
1424
+ 102,
1425
+ 825,
1426
+ 810
1427
+ ],
1428
+ "page_idx": 10
1429
+ },
1430
+ {
1431
+ "type": "header",
1432
+ "text": "Published as a conference paper at ICLR 2024",
1433
+ "bbox": [
1434
+ 171,
1435
+ 32,
1436
+ 478,
1437
+ 47
1438
+ ],
1439
+ "page_idx": 10
1440
+ },
1441
+ {
1442
+ "type": "page_number",
1443
+ "text": "11",
1444
+ "bbox": [
1445
+ 490,
1446
+ 946,
1447
+ 506,
1448
+ 959
1449
+ ],
1450
+ "page_idx": 10
1451
+ },
1452
+ {
1453
+ "type": "text",
1454
+ "text": "7 APPENDIX",
1455
+ "text_level": 1,
1456
+ "bbox": [
1457
+ 171,
1458
+ 102,
1459
+ 295,
1460
+ 118
1461
+ ],
1462
+ "page_idx": 11
1463
+ },
1464
+ {
1465
+ "type": "text",
1466
+ "text": "7.1 RESULTS OF ABLATION STUDIES",
1467
+ "text_level": 1,
1468
+ "bbox": [
1469
+ 171,
1470
+ 133,
1471
+ 439,
1472
+ 148
1473
+ ],
1474
+ "page_idx": 11
1475
+ },
1476
+ {
1477
+ "type": "text",
1478
+ "text": "Results of ablation studies for more evaluation metrics are shown in the following figures, which further corroborated the conclusions drawn in the main text.",
1479
+ "bbox": [
1480
+ 169,
1481
+ 159,
1482
+ 823,
1483
+ 188
1484
+ ],
1485
+ "page_idx": 11
1486
+ },
1487
+ {
1488
+ "type": "image",
1489
+ "img_path": "images/800425fa8a72fcc4d74b1e130febb9bb3f793f202bc0c65998a3afe2070075db.jpg",
1490
+ "image_caption": [
1491
+ "(a) minFDE6"
1492
+ ],
1493
+ "image_footnote": [],
1494
+ "bbox": [
1495
+ 178,
1496
+ 212,
1497
+ 390,
1498
+ 353
1499
+ ],
1500
+ "page_idx": 11
1501
+ },
1502
+ {
1503
+ "type": "image",
1504
+ "img_path": "images/6c08722ecaa24a92d7b92c4c4e59d4a18dab68c5230b421259ad113863c589d2.jpg",
1505
+ "image_caption": [
1506
+ "(b) minADE6",
1507
+ "Figure 7: The training curves report $\\mathrm{minFDE}_6$ , $\\mathrm{minADE}_6$ and $\\mathrm{MR}_6$ performance of all task combinations. The solid or dashed lines correspond to the mean and the shaded regions correspond to 1-sigma confidence interval over 5 runs."
1508
+ ],
1509
+ "image_footnote": [],
1510
+ "bbox": [
1511
+ 392,
1512
+ 212,
1513
+ 604,
1514
+ 352
1515
+ ],
1516
+ "page_idx": 11
1517
+ },
1518
+ {
1519
+ "type": "image",
1520
+ "img_path": "images/969aee5ccb2d3fd051380d4f3ef315674cfbc35d7305605710ef8fc7ceefcc56.jpg",
1521
+ "image_caption": [
1522
+ "(c) $\\mathbf{MR}_6$"
1523
+ ],
1524
+ "image_footnote": [],
1525
+ "bbox": [
1526
+ 604,
1527
+ 213,
1528
+ 818,
1529
+ 352
1530
+ ],
1531
+ "page_idx": 11
1532
+ },
1533
+ {
1534
+ "type": "image",
1535
+ "img_path": "images/e791973eef68937066f890f703f7ef61903dc0963373a22236c7489a4cf082c8.jpg",
1536
+ "image_caption": [
1537
+ "(a) MTM",
1538
+ "Figure 8: Final minFDE $_6$ performance of varying mask settings for each task, averaged over 5 runs."
1539
+ ],
1540
+ "image_footnote": [],
1541
+ "bbox": [
1542
+ 178,
1543
+ 468,
1544
+ 390,
1545
+ 574
1546
+ ],
1547
+ "page_idx": 11
1548
+ },
1549
+ {
1550
+ "type": "image",
1551
+ "img_path": "images/e7df6b4f489ec41d579c94c341f3e3f428f1cdad2c380fa9f9cd47f2140051a8.jpg",
1552
+ "image_caption": [
1553
+ "(b)MRM"
1554
+ ],
1555
+ "image_footnote": [],
1556
+ "bbox": [
1557
+ 392,
1558
+ 468,
1559
+ 604,
1560
+ 574
1561
+ ],
1562
+ "page_idx": 11
1563
+ },
1564
+ {
1565
+ "type": "image",
1566
+ "img_path": "images/fbf60d686b8b29cb045f4dbc2a0230eac7b660760916015bfca62d794e96f5e4.jpg",
1567
+ "image_caption": [
1568
+ "(c) TP"
1569
+ ],
1570
+ "image_footnote": [],
1571
+ "bbox": [
1572
+ 607,
1573
+ 468,
1574
+ 818,
1575
+ 574
1576
+ ],
1577
+ "page_idx": 11
1578
+ },
1579
+ {
1580
+ "type": "image",
1581
+ "img_path": "images/a6b1d916b90b9001c9853b6c78617ceaf3a77957a1abd8129f640d7483f47685.jpg",
1582
+ "image_caption": [
1583
+ "(a) MTM",
1584
+ "Figure 9: Final $\\mathrm{minADE}_6$ performance of varying mask settings for each task, averaged over 5 runs."
1585
+ ],
1586
+ "image_footnote": [],
1587
+ "bbox": [
1588
+ 178,
1589
+ 654,
1590
+ 390,
1591
+ 758
1592
+ ],
1593
+ "page_idx": 11
1594
+ },
1595
+ {
1596
+ "type": "image",
1597
+ "img_path": "images/8706697763d596abc398ecb56567a6c78f8a79596e36c85fb84ed378abdf6017.jpg",
1598
+ "image_caption": [
1599
+ "(b)MRM"
1600
+ ],
1601
+ "image_footnote": [],
1602
+ "bbox": [
1603
+ 392,
1604
+ 654,
1605
+ 604,
1606
+ 758
1607
+ ],
1608
+ "page_idx": 11
1609
+ },
1610
+ {
1611
+ "type": "image",
1612
+ "img_path": "images/7d0a4f94d53bbf94f3363f9ea5d64c4a416ab38a8d8c14d2157d9838878d8c2f.jpg",
1613
+ "image_caption": [
1614
+ "(c) TP"
1615
+ ],
1616
+ "image_footnote": [],
1617
+ "bbox": [
1618
+ 604,
1619
+ 654,
1620
+ 818,
1621
+ 758
1622
+ ],
1623
+ "page_idx": 11
1624
+ },
1625
+ {
1626
+ "type": "header",
1627
+ "text": "Published as a conference paper at ICLR 2024",
1628
+ "bbox": [
1629
+ 171,
1630
+ 32,
1631
+ 478,
1632
+ 47
1633
+ ],
1634
+ "page_idx": 11
1635
+ },
1636
+ {
1637
+ "type": "page_number",
1638
+ "text": "12",
1639
+ "bbox": [
1640
+ 490,
1641
+ 946,
1642
+ 509,
1643
+ 959
1644
+ ],
1645
+ "page_idx": 11
1646
+ },
1647
+ {
1648
+ "type": "image",
1649
+ "img_path": "images/27a058c6b26cf90b0d9fa148787615c54e76ed3eafbfc8642f4e68df293243d2.jpg",
1650
+ "image_caption": [
1651
+ "(a) MTM"
1652
+ ],
1653
+ "image_footnote": [],
1654
+ "bbox": [
1655
+ 178,
1656
+ 114,
1657
+ 390,
1658
+ 220
1659
+ ],
1660
+ "page_idx": 12
1661
+ },
1662
+ {
1663
+ "type": "image",
1664
+ "img_path": "images/ea2b6ee39e1e27ddc09d78c9ce527d7052708e025ff5aaa1b3d873c97f04e8b9.jpg",
1665
+ "image_caption": [
1666
+ "(b)MRM",
1667
+ "Figure 10: Final $\\mathrm{MR}_6$ performance of varying mask settings for each task, averaged over 5 runs."
1668
+ ],
1669
+ "image_footnote": [],
1670
+ "bbox": [
1671
+ 392,
1672
+ 114,
1673
+ 604,
1674
+ 220
1675
+ ],
1676
+ "page_idx": 12
1677
+ },
1678
+ {
1679
+ "type": "image",
1680
+ "img_path": "images/f60c71c732ec9404a0b9875c298c744b9a9f07d2adcfb3cb91bed9ddeeed8d87.jpg",
1681
+ "image_caption": [
1682
+ "(c) TP"
1683
+ ],
1684
+ "image_footnote": [],
1685
+ "bbox": [
1686
+ 604,
1687
+ 114,
1688
+ 816,
1689
+ 220
1690
+ ],
1691
+ "page_idx": 12
1692
+ },
1693
+ {
1694
+ "type": "text",
1695
+ "text": "7.2 IMPACT OF PRETRAINING DATASET",
1696
+ "text_level": 1,
1697
+ "bbox": [
1698
+ 171,
1699
+ 292,
1700
+ 457,
1701
+ 306
1702
+ ],
1703
+ "page_idx": 12
1704
+ },
1705
+ {
1706
+ "type": "text",
1707
+ "text": "To assess the impact of pretraining data on the downstream task, we compare the models pretrained on varying datasets: (a) train set, (b) train and validation set, and (c) train, validation and test set (consistent with the main experiment's setting). The performances are evaluated on the validation set, as reported in Figure 11 and Table 5. Our preliminary observations offer two insights. Firstly, there is only minor performance differences between setting (a) and (b). This suggests that the improvement brought about by pretraining cannot be simply attributed to exposure to the dataset for evaluation. Secondly, augmenting pretraining with additional data from the test set also improves performance on validation set. This hints at the notion that pretraining might derive benefits from a more diverse dataset, aligning with the discoveries in LLM pretraining studies.",
1708
+ "bbox": [
1709
+ 169,
1710
+ 320,
1711
+ 826,
1712
+ 446
1713
+ ],
1714
+ "page_idx": 12
1715
+ },
1716
+ {
1717
+ "type": "image",
1718
+ "img_path": "images/1f6baf7d00dfad399795cdfef5bc019a9cfc037d4bae5d12be846e623e5f4767.jpg",
1719
+ "image_caption": [
1720
+ "(a) b-minFDE6"
1721
+ ],
1722
+ "image_footnote": [],
1723
+ "bbox": [
1724
+ 222,
1725
+ 476,
1726
+ 478,
1727
+ 643
1728
+ ],
1729
+ "page_idx": 12
1730
+ },
1731
+ {
1732
+ "type": "image",
1733
+ "img_path": "images/acce72eb42d9d9eda6e0b0bc4e73b26b28b224b774b5fefd51741a05bb6d2beb.jpg",
1734
+ "image_caption": [
1735
+ "(b) minFDE6"
1736
+ ],
1737
+ "image_footnote": [],
1738
+ "bbox": [
1739
+ 517,
1740
+ 474,
1741
+ 774,
1742
+ 643
1743
+ ],
1744
+ "page_idx": 12
1745
+ },
1746
+ {
1747
+ "type": "image",
1748
+ "img_path": "images/d1bc5ae70f60c6f5d11b3e185bf6139c85a3dcc3578eac2595c13e8380ccd300.jpg",
1749
+ "image_caption": [
1750
+ "(c) minADE<sub>6</sub>",
1751
+ "Figure 11: The training curves report b-minFDE $_6$ , minFDE $_6$ , minADE $_6$ and MR $_6$ performance of models pretrained with different pretraining dataset settings. The solid lines correspond to the mean and the shaded regions correspond to 1-sigma confidence interval over 5 runs."
1752
+ ],
1753
+ "image_footnote": [],
1754
+ "bbox": [
1755
+ 222,
1756
+ 678,
1757
+ 478,
1758
+ 847
1759
+ ],
1760
+ "page_idx": 12
1761
+ },
1762
+ {
1763
+ "type": "image",
1764
+ "img_path": "images/fdcdd86ab2d3a0ac41885d3853681d87e5aa9ee49151f6eba636b6bf76670349.jpg",
1765
+ "image_caption": [
1766
+ "(d) $\\mathrm{MR}_6$"
1767
+ ],
1768
+ "image_footnote": [],
1769
+ "bbox": [
1770
+ 517,
1771
+ 678,
1772
+ 774,
1773
+ 847
1774
+ ],
1775
+ "page_idx": 12
1776
+ },
1777
+ {
1778
+ "type": "header",
1779
+ "text": "Published as a conference paper at ICLR 2024",
1780
+ "bbox": [
1781
+ 171,
1782
+ 32,
1783
+ 478,
1784
+ 47
1785
+ ],
1786
+ "page_idx": 12
1787
+ },
1788
+ {
1789
+ "type": "page_number",
1790
+ "text": "13",
1791
+ "bbox": [
1792
+ 490,
1793
+ 946,
1794
+ 508,
1795
+ 959
1796
+ ],
1797
+ "page_idx": 12
1798
+ },
1799
+ {
1800
+ "type": "table",
1801
+ "img_path": "images/0a00ab5ba699f976d0e40c5c5737c198a0776f835bee980e5f0b164a57d8ae14.jpg",
1802
+ "table_caption": [],
1803
+ "table_footnote": [],
1804
+ "table_body": "<table><tr><td rowspan=\"2\">Train</td><td rowspan=\"2\">Data split Validation</td><td rowspan=\"2\">Test</td><td colspan=\"4\">Final evaluation metrics</td></tr><tr><td>b-minFDE6</td><td>minADE6</td><td>minFDE6</td><td>MR6</td></tr><tr><td>✓</td><td></td><td></td><td>1.577</td><td>0.650</td><td>0.937</td><td>0.088</td></tr><tr><td>✓</td><td>✓</td><td></td><td>1.569</td><td>0.647</td><td>0.931</td><td>0.087</td></tr><tr><td>✓</td><td>✓</td><td>✓</td><td>1.563</td><td>0.643</td><td>0.927</td><td>0.086</td></tr></table>",
1805
+ "bbox": [
1806
+ 282,
1807
+ 101,
1808
+ 712,
1809
+ 186
1810
+ ],
1811
+ "page_idx": 13
1812
+ },
1813
+ {
1814
+ "type": "text",
1815
+ "text": "7.3 HYPERPARAMETERS",
1816
+ "text_level": 1,
1817
+ "bbox": [
1818
+ 171,
1819
+ 244,
1820
+ 357,
1821
+ 258
1822
+ ],
1823
+ "page_idx": 13
1824
+ },
1825
+ {
1826
+ "type": "text",
1827
+ "text": "Table 6 reports the hyperparameters for the SEPT network architecture. In all transformer layers, layer norm is done prior to attention and feedforward operations, and bias is cancelled in feedforward networks.",
1828
+ "bbox": [
1829
+ 169,
1830
+ 270,
1831
+ 823,
1832
+ 311
1833
+ ],
1834
+ "page_idx": 13
1835
+ },
1836
+ {
1837
+ "type": "table",
1838
+ "img_path": "images/7281c2e0dc059f05b8e77f382a63407b24818ee5fa6251410001e9b8a826bced.jpg",
1839
+ "table_caption": [
1840
+ "Table 5: Final performance of different pretraining dataset settings."
1841
+ ],
1842
+ "table_footnote": [],
1843
+ "table_body": "<table><tr><td>Arch</td><td>Parameters</td><td>Values</td></tr><tr><td>Projection</td><td>output size</td><td>256</td></tr><tr><td rowspan=\"3\">TempoNet</td><td>depth</td><td>3</td></tr><tr><td>num_head</td><td>8</td></tr><tr><td>dim_head</td><td>64</td></tr><tr><td rowspan=\"3\">SpaNet</td><td>depth</td><td>2</td></tr><tr><td>num_head</td><td>8</td></tr><tr><td>dim_head</td><td>64</td></tr><tr><td rowspan=\"4\">Cross attender</td><td>depth</td><td>3</td></tr><tr><td>num_head</td><td>8</td></tr><tr><td>dim_head</td><td>64</td></tr><tr><td>query size</td><td>256</td></tr><tr><td rowspan=\"2\">MLP_traj / MLP_score</td><td>num Hidden</td><td>1</td></tr><tr><td>hidden size</td><td>512</td></tr></table>",
1844
+ "bbox": [
1845
+ 330,
1846
+ 323,
1847
+ 666,
1848
+ 597
1849
+ ],
1850
+ "page_idx": 13
1851
+ },
1852
+ {
1853
+ "type": "text",
1854
+ "text": "Table 6: Network hyperparameters",
1855
+ "bbox": [
1856
+ 380,
1857
+ 607,
1858
+ 614,
1859
+ 623
1860
+ ],
1861
+ "page_idx": 13
1862
+ },
1863
+ {
1864
+ "type": "header",
1865
+ "text": "Published as a conference paper at ICLR 2024",
1866
+ "bbox": [
1867
+ 173,
1868
+ 32,
1869
+ 478,
1870
+ 47
1871
+ ],
1872
+ "page_idx": 13
1873
+ },
1874
+ {
1875
+ "type": "page_number",
1876
+ "text": "14",
1877
+ "bbox": [
1878
+ 490,
1879
+ 946,
1880
+ 508,
1881
+ 959
1882
+ ],
1883
+ "page_idx": 13
1884
+ }
1885
+ ]