Upgrade to Pro
— share decks privately, control downloads, hide ads and more …
Speaker Deck
Sign up for free
Menu
Search
Features
All features
Private URLs
Password Protection
Custom URLS
Scheduled publishing
Remove Branding
Restrict embedding
Deck Collections
Notes
Features
All features
Private URLs
Password Protection
Custom URLS
Scheduled publishing
Remove Branding
Restrict embedding
Deck Collections
Notes
Explore
Featured decks
Featured speakers
Programming
Technology
Storyboards
Explore
Featured decks
Featured speakers
Programming
Technology
Storyboards
Pricing
Search
Sign in
Sign up for free
[Journal club] LambdaNetworks: Modeling Long-R...
Search
Semantic Machine Intelligence Lab., Keio Univ.
PRO
September 03, 2021
Technology
250
0
Share
Embed
Copy iframe code
Copy JS code
Copy link
Start on current slide
[Journal club] LambdaNetworks: Modeling Long-Range Interactions Without Attention
Semantic Machine Intelligence Lab., Keio Univ.
PRO
September 03, 2021
More Decks by Semantic Machine Intelligence Lab., Keio Univ.
See All by Semantic Machine Intelligence Lab., Keio Univ.
[EMNLP26] RIGEL: Self-Distilled Score Adaptation for Image and Video Captioning Evaluation
keio_smilab
PRO
0
65
[RSJ26] Building a VLA Model Based on Self-Distilled Classification
keio_smilab
PRO
0
210
[RSJ26] AnoleVLA: Lightweight Vision-Language-Action Model with Deep State Space Models for Mobile Manipulation
keio_smilab
PRO
0
180
[RSJ26] NarrativeFlow: Flow-Based Vision-Language-Action Model Using Robot Velocity Fields
keio_smilab
PRO
0
250
[RSJ26] Flow as Flow: Modeling Robot Velocity Fields as Probability Velocity Fields
keio_smilab
PRO
1
240
[RSJ26] Hierarchy-Aware Multimodal Retrieval-Augmented Generation for Embodied Question Answering
keio_smilab
PRO
1
200
[MIRU26] Open-Vocabulary Intention-Guided Object Detection in Diverse Scenes
keio_smilab
PRO
0
250
[Journal club] Evo-1: Lightweight Vision-Language-Action Model with Preserved Semantic Alignment
keio_smilab
PRO
0
74
[MIRU26] To What Extent Does MLLM-as-a-Judge Exhibit Cross-Model Preference Bias?
keio_smilab
PRO
0
330
Other Decks in Technology
See All in Technology
実践!Cloud Run ハンズオン!! / Cloud Run handson
y0hgi
2
300
大型犬好きによるPugの紹介
yamanoku
1
160
夫婦で子育てするための育児標準化
codmoninc
PRO
0
450
Getting Started with Google Antigravity
glaforge
0
320
古い指輪から広がった JAVA コミュニティ とのつながり
yamad
0
130
トークン化預金DCJPYの取り組みと活用ユースケース
finengine
0
160
AIにシークレットを見せない、WSL2で安全な開発環境
yazm
0
310
FinOps Agentが生んだ技術負債:コスト自動調査の落とし穴と解消までの道のり
oasis1994liveforever
2
140
ウォンテッドリーの最近のプロダクトと技術の紹介
stomk
0
130
AI × アーキテクト 第1・2章|生成AIの課題とアーキテクトの素養
daidaidai
0
180
Kiro Crewをはじめよう
kizawa2020
1
160
OptunaHub: ブラックボックス最適化のためのプラットフォーム
pfn
PRO
0
140
Featured
See All Featured
A Soul's Torment
seathinner
8
3.8k
Visual Storytelling: How to be a Superhuman Communicator
reverentgeek
2
710
For a Future-Friendly Web
brad_frost
184
10k
Agile that works and the tools we love
rasmusluckow
331
22k
Scaling GitHub
holman
464
140k
Code Review Best Practice
trishagee
74
20k
Intergalactic Javascript Robots from Outer Space
tanoku
273
28k
Mozcon NYC 2025: Stop Losing SEO Traffic
samtorres
1
580
Impact Scores and Hybrid Strategies: The future of link building
tamaranovitovic
0
460
How To Stay Up To Date on Web Technology
chriscoyier
790
250k
Stewardship and Sustainability of Urban and Community Forests
pwiseman
0
560
Navigating Weather and Climate Data
rabernat
0
560
Transcript
-BNCEB/FUXPSLT .PEFMJOH-POH3BOHF*OUFSBDUJPOT 8JUIPVU"UUFOUJPO 慶應義塾大学 杉浦孔明研究室 飯田 紡 Irwan Bello (Google)
ICLR 2021 Bello, I. (2021). Lambdanetworks: Modeling long-range interactions without attention. arXiv preprint arXiv:2102.08602.
എܠɿ"UUFOUJPOͷܭࢉྔଟ͍ Self-Attention シーケンス長 ! -> "(!!) 画像をFlattenして入力する場合 画像全体を入力は困難(256×256 → 256")
わずかな部分しか入力不可 画像全体との関係を捉えられない 1 I have a pen I 0.5 0.2 0.1 0.2 have 0.1 0.4 0.1 0.4 a 0.2 0.1 0.5 0.2 pen 0.2 0.2 0.1 0.5
ؔ࿈ݚڀ Attentionの計算量削減手法は汎用的 画像特有の構造を考慮しつつ画像全体を入力したい 2 Linear Transformer [Katharopoulos+, ICML20] Transformerを低ランク近似することで計算量削減 [Shazeer,
arXiv preprint19] Queryを分割することでattentionの計算量削減 ViT [Dosovitskiy+, arXiv preprint21] パッチ入力により画像にTransformerを適用 パッチは高解像度の画像やdetectionに応用できるか不明
ఏҊख๏ɿ-BNCEB/FUXPSLT 3 入力 Inputs: ! ∈ ℝ!×# Context: $
∈ ℝ$×# ! = $のときSelf-attentionと同等 出力 & ∈ ℝ!×# ': Query, (: Key, ): Value ' = !*% , ( = $*& , ) = $*' + Content Lambda Position Lambdas * ! + , - . / 0# = 2# $3# = 2% + 2# & $ 3# 5 = 2' , 2! , ⋯ , 2( 2# = 2% + 2# &
ఏҊख๏ɿ$POUFOU-BNCEB Attentionに対応 Key, Valueを集約後Queryに作用 → 計算量削減 4 + Position Lambdas
Content Lambda * ! + - . /
"UUFOUJPOͱ$POUFOU-BNCEBͷൺֱ 5 +(×* *+×* /(×, -!×# -+×, .+×* -!×# -!×!
8(×+ 9 8(×+ soft max ,(×* !, #の積でAttention map を作成 画像データでは一般に データ長 $, % : 大 &, ' ∶ 小さくできる(ハイパラ) 大きな ! × : を使用せずに ! × ; の出力できないか? Attention Layer
"UUFOUJPOͱ$POUFOU-BNCEBͷൺֱ 6 画像データでは一般に データ長 :, ! : 大 ;, <
∶ 小さくできる(ハイパラ) -, .の積で5%を作成 ! × : → k × ; Content Lambda +(×* *+×* /(×, -!×# -+×, .+×* -!×# -!×! ,(×* soft max ? -+×, 5% ,×* ※正確には.$と同じ/×0の Position Lambdasを足したものを1にかける
"UUFOUJPOͱ$POUFOU-BNCEBͷൺֱ 7 /(×, -+×, .+×* 8(×+ 9 8(×+ soft max
,(×* /(×, -+×, .+×* ,(×* soft max ? -+×, 5% ,×* " !:(< + ; ) " ! + : <; Attention Layer Content Lambda 2×3, 3×5行列の積は6(235) 時間計算量 空間計算量 " !: " <; ((*+)などもありえますが 後にO +. しか使わないので省略
ఏҊख๏ɿ1PTJUJPO-BNCEBT Positional Encodingに対応 ポジション1つ(1〜,)につき -×/の行列0を使用 0は全てのデータで同じ 時間計算量 1(,-/3) 空間計算量 1(,-/)
8 + Content Lambda Position Lambdas * ! + , - . / . +×* @' +×, 5' & ,×* 5! & ,×* 5( & ,×* … @( +×, …
ܭࢉྔͷൺֱ 9 時間計算量 空間計算量 Attention 6(9:; / + 0 )
6(9:;) Content only 6( : + ; /0) 6(9/0) Position only 6(9:;/0) 6(:;/) Lambda 6(9:;/0) 6(:;/ + 9:/0) 入力サイズ %×& , $×& バッチサイズ * !, #の大きさ ' 時間計算量 ほぼ等しい(工夫で高速化可能) 空間計算量 Positionは全部同じ → *に非依存 = 大きな%$がバッチサイズ非依存 → バッチサイズを大きくできる 画像サイズ224 × 224, バッチサイズ 128 Attention: 120 GB Lambda: 0.63 GB
ߴԽͷ Multi-Query Queryをℎ 個に分割 ! = [!! , !"
, ⋯ , !# ] 並列にlambdaを計算して結合 0 = 1 !! , 1 !" , ⋯ , 1 !# % → $ # より時間計算量 3 %$&'( # に(Key, Valueはそのまま) Lambda Convolution 計算量の多いPosition LambdasをCNNに置き換え 4) &×' = Conv2D(<) 11
ఆྔత݁Ռɿ-BNCEB͕BUUFOUJPO$//Λ্ճΔ 12 ResNet50の3 × 3Convを Layerに置き換え ImageNetの 224 ×224画像を使用 最も少ないパラメータ数で
Top-1 accuracy最大を達成
ఆྔత݁Ռɿܭࢉྔগ͔ͭਫ਼ྑ 13 Lambda Layerは • メモリ使用量 少 • Throughput 大
全レイヤーでpos lambdasを 共有しても精度は落ちない Attentionでは画像全体を使 用できない(Global ~) 9 ∶ バッチサイズ, ℎ ∶ ヘッド/クエリ数, : ∶ inputの長さ ; ∶ contextの長さ, / ∶ Q, Kのdepth, ? ∶ レイヤー数 画像全体 軸ごと クロップ
ఆྔత݁Ռɿগͳ͍ύϥϝʔλ͔ͭߴͰେܕϞσϧʹ ඖఢ͢Δਫ਼Λୡ 14 横軸:Trainにかかる時間 ≒ モデルサイズ LambdaResNet420, 画像サイズ320 LambdaResNet350, 画像サイズ320
350 epochの訓練をしたとき 3〜4倍高速でEfficientNetに匹敵 ViTには劣るものの、非常に高速
"CMBUJPO4UVEJFT 16 Content, Position片方のみを使用 Positionが精度に大きく貢献 ConvとLambdaの併用 前方にL → Throughput低下 後方にL
→ Throughputそのまま 後ろ2つL → 精度向上かつ高速
·ͱΊ 17 背景 Attentionの計算量削減 提案 先にKey, ValueをまとめるLambda Networks 結果 高速かつ大規模モデルに匹敵する精度