The document discusses hyperparameter optimization in machine learning models. It introduces various hyperparameters that can affect model performance, and notes that as models become more complex, the number of hyperparameters increases, making manual tuning difficult. It formulates hyperparameter optimization as a black-box optimization problem to minimize validation loss and discusses challenges like high function evaluation costs and lack of gradient information.
The document discusses hyperparameter optimization in machine learning models. It introduces various hyperparameters that can affect model performance, and notes that as models become more complex, the number of hyperparameters increases, making manual tuning difficult. It formulates hyperparameter optimization as a black-box optimization problem to minimize validation loss and discusses challenges like high function evaluation costs and lack of gradient information.
Tensor Decomposition and its ApplicationsKeisuke OTAKI
This document discusses tensor factorizations and decompositions and their applications in data mining. It introduces tensors as multi-dimensional arrays and covers 2nd order tensors (matrices) and 3rd order tensors. It describes how tensor decompositions like the Tucker model and CANDECOMP/PARAFAC (CP) model can be used to decompose tensors into core elements to interpret data. It also discusses singular value decomposition (SVD) as a way to decompose matrices and reduce dimensions while approximating the original matrix.
【DL輪読会】Towards Understanding Ensemble, Knowledge Distillation and Self-Distil...Deep Learning JP
Ad
[DL輪読会]A Bayesian Perspective on Generalization and Stochastic Gradient Descent
1. 1
DEEP LEARNING JP
[DL Papers]
http://deeplearning.jp/
A Bayesian Perspective on
Generalization and Stochastic Gradient Descent
Masahiro Suzuki, Matsuo Lab
2. 本輪読発表について
• A Bayesian Perspective on Generalization and Stochastic
Gradient Descent
– Samuel L. Smith, Quoc V. Le
• arXiv:1710.06451(11/6現在ICLR投稿中)
• ちなみにSmith氏はICLRにこれともう1本出している模様
– Don't Decay the Learning Rate, Increase the Batch Size
– 元のタイトルはUnderstanding Generalization and Stochastic Gradient
Descent(redditでディスられてたから変えた?)
• 深層学習における汎化の疑問に,ベイジアンの観点から考える.
• 合わせて,深層学習と汎化に関する話題について簡単にまとめました.
– もっと知りたい方がいる場合は完全版作ります
2
18. ベイズ的観点からの汎化とSGD
• A Bayesian Perspective on Generalization and Stochastic
Gradient Decent[Smith+ 17]
– この論文では,汎化とSGDについて次の2つの問題に取り組んでいる.
• 訓練で獲得した局所解が汎化するかどうか.
• なぜSGDは汎化性能の高い局所解を獲得するのか.
– ベイズ的な視点で検証するといろいろわかってくる.
18
19. ベイズの定理と事後分布
• モデルをM,パラメータをω とすると,パラメータの事後分布は,
– 尤度をone-hotのクロスエントロピーとすると,
,
– 事前分布は,ガウス分布 .
• したがって事後分布は,
• は正則化パラメータ
• これはL2正則化クロスエントロピーコスト関数となる
{ }i 1
P(!|{y}, {x}; M) =
P({y}|!, {x}; M)P(!; M)
P({y}|{x}; M)
P({y}|!, {x}; M) =
Q
i P(yi|!, xi; M) = e−H(!;M)
( )
P
( ( | ))
{ } )
Q
i (y | )
H(!; M) = −
P
i ln (P(yi|!, xi; M)).
p 2
P(!; M) =
p
λ/2⇡e−λ!2
/2
P(!|{y}, {x}; M) /
p
λ/2⇡e−C(!;M)
, where C(!; M) = H(!; M) + λ!2
/2
/ P({y}|!, {x}; M)P(!; M).
λ
19
20. 予測分布
• 予測分布は,パラメータを周辺化して
– ここで,パラメータの積分のほとんどが の領域で, が滑らかだと
すると,コスト関数Cを最小化してパラメータ を求めて,予測分布を
と近似できる.
P(yt|xt, {x}, {y}; M) =
Z
d! P(yt|!, xt; M)P(!|{y}, {x}; M)
=
R
d! P(yt|!, xt; M)e−C(!;M)
R
d! e−C(!;M)
.
P(yt|!, xt; M)
( )
!0,
!0,
y g
P(yt|xt; M) ⇡ P(yt|!0, xt; M)
20
22. ランダムラベルとの比較
• この研究では,ラベルが完全にランダムで,各クラスに等しい確率を
割り当てるモデルとしてnullモデルを考えて,比較する.
– nはモデルクラス数,Nはラベル数
• エビデンスの比は,
ただし
– この比が0より小さければ,予測モデルが信頼できないことになる.
• [Dinh+ 17]と違い,モデルのパラメータ化に依存しない.
– [Dinh+ 17]では,ヘッセ行列の固有値 を変更してパラメータ化を変えていた
が,正則化パラメータ も変える必要があった.
– 一方,本手法では となっているので,オッカム係数は変わらない.
P({y}|{x}; NULL) = (1/n)N
= e−N ln (n)
h b f i i l b l h h id
P({y}|{x}; M)
P({y}|{x}; NULL)
= e−E(!0)
,
E(!0) = C(!0)+(1/2)
P
i ln(λi/λ)−N ln(n) i
λ
λi
ln(λi/λ)
22
31. バッチサイズと各パラメータの関係
• 最適なバッチサイズが,学習率ε,訓練集合サイズN ,そしてモーメ
ンタムの係数ωにどのように影響するかを調べる.
• SGDは
– は真の勾配, はバッチの期待勾配
• 上の式を,確率的微分方程式の離散更新とみなす.
• すると,最終的に というルールが得られる.
– 式展開の詳細は,論文参照.
– バッチサイズと,学習率,訓練集合サイズ ,モーメンタムの係数の関係を示
している.
∆! =
✏
N
dC
d!
+
d ˆC
d!
−
dC
d!
!!
dC
d! =
PN
i=1
dCi
d!
h d
d ˆC
d! = N
B
PB
i=1
dCi
d!
d!
dt
=
dC
d!
+ ⌘(t)
g = ✏(N
B − 1) ⇡ ✏N/B.
fl i i
31
37. 感想
• 汎化ギャップを考えるには,モデルや損失関数だけではなく,アルゴ
リズムやデータ集合についても考える必要がある(定義の通り).
– SGDはflat minimaの獲得に貢献している?
– データによる正則化(data augmentationとか)による違いは?
• この分野は,今くらいが楽しい時期かも.
• 今回,発表時間的に断念した論文(おすすめ)
– [Kawaguchi+ 17] Generalization in Deep Learning
• 最初の定式化が素晴らしい(参考にしました).まとめ方が博論っぽくてすごい.
– [Neyshabur+ 17] Exploring Generalization in Deep Learning
• この辺りの研究をずっとされているNeyshabur氏の論文.
– [Wu+ 17] Towards Understanding Generalization of Deep Learning:
Perspective of Loss Landscapes
• Flat minimaに落ちる理由に納得感がある説明. 37
38. 参考資料(論文)
• [Dinh+ 17] Sharp Minima can Generalize for Deep Nets
• [Hardt+ 16] Train faster, generalize better: Stability of stochastic gradient
descent
• [Hoffer+ 17] Train longer, generalize better: closing the generalization gap in large
batch training of neural networks
• [Kawaguchi+ 17] Generalization in Deep Learning
• [Keskar+ 16] On large-batch training for deep learning: Generalization gap and sharp
minima
• [Krueger+ 17] Deep Nets Don't Learn via Memorization
• [Mandt+ 17] Stochastic Gradient Descent as Approximate Bayesian Inference
• [Smith+ 17] A Bayesian Perspective on Generalization and Stochastic Gradient
Decent
• [Neyshabur+ 17] Geometry of Optimization and Implicit Regularization in Deep
Learning
• [Neyshabur+ 17] Exploring Generalization in Deep Learning
• [Wu+ 17] Towards Understanding Generalization of Deep Learning: Perspective of
Loss Landscapes
• [Zhang+ 16] Understanding deep learning requires rethinking generalization
38
39. 参考資料(スライドや本等)
• [Bousquet,17] Why Deep Learning works?(http://www.ds3-datascience-
polytechnique.fr/wp-content/uploads/2017/08/2017_08_31_1630-
1730_Olivier_Bousquet_Understanding_Deep_Learning.pdf)
• [Deng+ 14] Rademacher Complexity
(http://web.eecs.umich.edu/~cscott/past_courses/eecs598w14/notes/10_rade
macher.pdf)
• [Goodfellow+ 16] Deep Learning
• [岡野原, 17] Deep Learning Practice and Theory
(https://www.slideshare.net/pfi/deep-learning-practice-and-theory)
• [金森,15] 統計的学習理論 (機械学習プロフェッショナルシリーズ)
39