論文紹介 markov chain monte carlo and variational inferences bridging the gap

32
Salimans, T., Kingma, D. P., & Welling, M. Proceedings of The 32nd International Conference on Machine Learning, pp. 1218–1226, 2015 (ICML 2015) Markov Chain Monte Carlo and Variational Inference: Bridging the Gap Presenter : S5lab. Shuuji Mihara

Upload: shuuji-mihara

Post on 12-Jan-2017

203 views

Category:

Data & Analytics


0 download

TRANSCRIPT

Page 1: 論文紹介 Markov chain monte carlo and variational inferences bridging the gap

Salimans, T., Kingma, D. P., & Welling, M.Proceedings of The 32nd International Conference on Machine Learning, pp. 1218–1226, 2015 (ICML 2015)

Markov Chain Monte Carlo and Variational Inference: Bridging the Gap

Presenter : S5lab. Shuuji Mihara

Shuuji Mihara
従来法との比較, 選んだモチベーションを書くこと
Page 2: 論文紹介 Markov chain monte carlo and variational inferences bridging the gap

Abstract in this paper2

潜在変数モデルにおいて , 主流なパラメータのベイズ推定の方法に , MCMC と VI (Variational Inference, 変分ベイズ法 ) がある .

本論文では , MCMC に SGVI を組み込んだ手法(MCVI, HMCVI, SMCVI) とその理論的背景を示す .

Page 3: 論文紹介 Markov chain monte carlo and variational inferences bridging the gap

3Table of Contents

1. Introduction2. MCMC and Auxiliary Variables3. MCMC lower bound estimate4. MCVI5. SMCVI6. Review

論文では HMC( ハミルトニアンモンテカルロ法 ) についても言及がありますが , 前提知識が多いため今回は簡単にしか触れません

Page 4: 論文紹介 Markov chain monte carlo and variational inferences bridging the gap

4Table of Contents

1. Introduction2. MCMC and Auxiliary Variables3. MCMC lower bound estimate4. MCVI5. SMCVI6. Review

Page 5: 論文紹介 Markov chain monte carlo and variational inferences bridging the gap

5生成モデル

観測データは未知の真の確率分布から生起していると考え , その確率分布を推定することでデータの振る舞いを分析する考え方

Ex. サイコロ

真の分布

すべての目が 1/6の確率で出る ?

shuuji mihara
Page 6: 論文紹介 Markov chain monte carlo and variational inferences bridging the gap

6潜在変数モデル

生成モデルにおいて , 観測不可能なデータが本来持つ特性( クラス情報など ) や欠損値があると考え , それらを潜在変数( 観測できないデータに関する情報 ) として扱うモデルEx.

LDA(NLP でよく用いられる )GMM を用いたクラスタリング

Page 7: 論文紹介 Markov chain monte carlo and variational inferences bridging the gap

7ベイズ推定

推定対象をベイズの定理を用いて分布推定する方法の総称 ?(↔ 点推定 ( 最尤推定 ))

𝜃 𝜃最尤推定( 点推定 )

ベイズ推定( 区間推定 )

Page 8: 論文紹介 Markov chain monte carlo and variational inferences bridging the gap

8Markov Chain Monte Calro(MCMC)

調べたい真の分布からのサンプリング系列 ( マルコフ連鎖 )を構成することによって , 分布に関する情報を調べる方法

http://visualize-mcmc.appspot.com/2_metropolis.html

◎分布にパラメトリックな仮定をおかない

×計算コスト大

Page 9: 論文紹介 Markov chain monte carlo and variational inferences bridging the gap

9Variational Inference

調べたい真の分布に対してパラメトリックな仮定をおき , 一部のパラメータ群の独立性を仮定した近似事後確率をKL 情報量の最小化 ( 変分下限 (ELBO) の最大化 ) により , 解析的に計算する .

𝐿= log𝑝(𝑥 )−𝐾𝐿(𝑞𝜃 (𝑧|𝑥 )∨¿𝑝 (𝑧∨𝑥))

最大化 最小化

◎大規模なモデルでも比較的計算が早い

×事前に解析的な手計算が必要

¿𝐸𝑞𝜃 (𝑧∨𝑥) [ log𝑝 (𝑥 , 𝑧 )− log𝑞𝜃 (𝑧∨𝑥)]

(1), (2) 式

Page 10: 論文紹介 Markov chain monte carlo and variational inferences bridging the gap

 事後確率の計算に近似を導入し , 計算量を減らす .  計算式が解析的に導け , 計算コストが少ない ,  しかし , 精度は損なわれる .

 理論上 , 任意の精度での計算が可能 . しかし計算コスト大

MCMC と VI10

大抵の計算問題では正確さと計算量はトレードオフ

MCMC( マルコフ連鎖モンテカルロ法 )

VI(Variational Bayes, 変分ベイズ法 )

大規模問題への適用が困難 !

本論文ではこの 2 つの手法を融合させる

Page 11: 論文紹介 Markov chain monte carlo and variational inferences bridging the gap

Abstract in this paper11

潜在変数モデルにおいて , 主流なパラメータのベイズ推定の方法に , MCMC と VI (Variational Inference, 変分ベイズ法 ) がある .

本論文では , MCMC に SGVI を組み込んだ手法(MCVI, HMCVI, SMCVI) とその理論的背景を示す .

Page 12: 論文紹介 Markov chain monte carlo and variational inferences bridging the gap

12Table of Contents

1. Introduction2. MCMC and Auxiliary Variables3. MCMC lower bound estimate4. MCVI5. SMCVI6. Review

Page 13: 論文紹介 Markov chain monte carlo and variational inferences bridging the gap

13What’s difficult in MCMC?

MCMC(MH 法 ) の難しい点

• 提案分布をどのように構成するか

• 何回サンプリングを繰り返せば精度のいい近似事後分布が得られるかわからない

Page 14: 論文紹介 Markov chain monte carlo and variational inferences bridging the gap

14What’s difficult in MCMC?

MCMC(MH 法 ) の難しい点

• 提案分布をどのように構成するか

• 何回サンプリングを繰り返せば精度のいい近似事後分布が得られるかわからない

提案手法で解決

Page 15: 論文紹介 Markov chain monte carlo and variational inferences bridging the gap

15The central idea of this paper(1)

MCMC で得られる事後分布はマルコフ連鎖なので以下のように分解できる .

𝑞 (𝑧|𝑥 )=𝑞(𝑧 0∨𝑥)∏𝑡=1

𝑇

𝑞(𝑧 𝑡∨𝑧𝑡 −1 ,𝑥)

補助変数の集合 および補助分布 を導入することで , (2) 式で見た補助変分下限 ( 変分下限の下限 )が (3) 式のように求められる

Page 16: 論文紹介 Markov chain monte carlo and variational inferences bridging the gap

16The central idea of this paper(2)

[]

{}

(3) 式

Page 17: 論文紹介 Markov chain monte carlo and variational inferences bridging the gap

17The central idea of this paper(3)

補助分布にマルコフ性を仮定することで , 以下の補助変分下限の逐次更新式を得る .((4) 式 )

𝐿𝑎𝑢𝑥=𝐸𝑞[ log [𝑝 (𝑥 , 𝑧𝑇 )− log𝑞 (𝑧 0|𝑥 ) ]+∑𝑡=1

𝑇

log [𝑟 𝑡 (𝑧𝑡 −1∨𝑥 ,𝑧 𝑡)/𝑞𝑡 (𝑧 𝑡∨𝑥 ,𝑧 𝑡− 1)] ]

MCMC の各ステップで変分下限の推定量が得られる

Algorithm1

Page 18: 論文紹介 Markov chain monte carlo and variational inferences bridging the gap

18Table of Contents

1. Introduction2. MCMC and Auxiliary Variables3. MCMC lower bound estimate4. MCVI5. SMCVI6. Review

Page 19: 論文紹介 Markov chain monte carlo and variational inferences bridging the gap

19Algorithm 1

Page 20: 論文紹介 Markov chain monte carlo and variational inferences bridging the gap

20Table of Contents

1. Introduction2. MCMC and Auxiliary Variables3. MCMC lower bound estimate4. MCVI5. SMCVI6. Review

Page 21: 論文紹介 Markov chain monte carlo and variational inferences bridging the gap

21Stochastic Gradient Variational Bayes

Reparameterization Trick:から直接をサンプリングする代わりに、がに従うようを決める

例 )からサンプリングする代わりに、とする

Page 22: 論文紹介 Markov chain monte carlo and variational inferences bridging the gap

22MCVI 概要

Algorithm1 において提案分布に Reparameterization trick() を導入することで , 推定量を

の確率的最適化により , 計算=提案分布のパラメータが決定される

Page 23: 論文紹介 Markov chain monte carlo and variational inferences bridging the gap

23Algorithm 2

Page 24: 論文紹介 Markov chain monte carlo and variational inferences bridging the gap

24Example : bivariate Gaussian

Page 25: 論文紹介 Markov chain monte carlo and variational inferences bridging the gap

25Hamiltonian Variational Inference

State of the art

Page 26: 論文紹介 Markov chain monte carlo and variational inferences bridging the gap

26Table of Contents

1. Introduction2. MCMC and Auxiliary Variables3. MCMC lower bound estimate4. MCVI5. SMCVI6. Review

Page 27: 論文紹介 Markov chain monte carlo and variational inferences bridging the gap

27SMCVI

MCVI は全ステップで変分下限の最適化を行うのに対して , 代わりに各ステップでの変分下限の更新量の期待値() の最適化を行い , 各ステップで潜在変数の事後分布を計算する .

Page 28: 論文紹介 Markov chain monte carlo and variational inferences bridging the gap

28Algorithm4

Page 29: 論文紹介 Markov chain monte carlo and variational inferences bridging the gap

29Table of Contents

1. Introduction2. MCMC and Auxiliary Variables3. MCMC lower bound estimate4. MCVI5. SMCVI6. Review

Page 30: 論文紹介 Markov chain monte carlo and variational inferences bridging the gap

30Review

• VI を MCMC に組み込む手法を開発し , VI の手法をMCMC のフレームワークに組み込むことに成功した .

• 数値実験で推定速度の向上を示し , HMCVI では画像の生成モデルを推定する問題で State of the artの手法と遜色ない結果が得られた .

Page 31: 論文紹介 Markov chain monte carlo and variational inferences bridging the gap

31Table of Contents

1. Introduction2. MCMC and Auxiliary Variables3. MCMC lower bound estimate4. MCVI5. SMCVI6. Specification of the Markov chain7. Review

Page 32: 論文紹介 Markov chain monte carlo and variational inferences bridging the gap

32Detailed balance

MCMC では通常 , 得られる分布が普遍分布となるよう以下の詳細釣り合い条件をみたすようにマルコフ連鎖を構成する .

このとき Algorithm1 のの式が以下のように書き換えられる .