1
1

Delete article

Deleted articles cannot be recovered.

Draft of this article would be also deleted.

Are you sure you want to delete this article?

More than 5 years have passed since last update.

ベイズ推論の勉強用ノート(1)ー 基本的な定義

Last updated at Posted at 2019-02-03

目的

ベイズ推論による機械学習入門の勉強用のノート。
式を後で参照するために残しておく。

各種定義

期待値

\langle f(x) \rangle _{p(x)} := \int f(x)p(x)dx
  • $\langle \rangle _{p(x)} : linear$
  • $i.e. \langle af(x)+bg(x) \rangle _{p(x)} = a\langle f(x) \rangle _{p(x)} + b\langle g(x) \rangle _{p(x)}$
  • ただし、$a, b \in \mathbb{R}, f, g: \mathbb{R}^D \rightarrow \mathbb{R}; measurable function$

エントロピー

\begin{align}
\mathtt{H}[p(x)] 
  &:= - \int p(x)\ln p(x)dx \\
  & = -\langle \ln p(x) \rangle _{p(x)}
\end{align}

KLダイバージェンス

\begin{align}
\mathtt{KL}[q(x) \| p(x)] 
  &:= - \int q(x)\ln \frac{p(x)}{q(x)}dx \\
  &= - \langle \ln \frac{p(x)}{q(x)} \rangle_{q(x)} \\
  &= \langle \ln \frac{q(x)}{p(x)} \rangle_{q(x)} \\
  & = \langle \ln q(x) \rangle _{q(x)} - \langle \ln p(x) \rangle _{q(x)}
\end{align}
  • $\mathtt{KL}[q(x)||p(x)] \geq 0$
  • $\mathtt{KL}[q(x)||p(x)] = 0 \Rightarrow
    \forall x (q(x)=p(x))$
  • $\mathtt{KL}[q(x) || p(x)] \neq \mathtt{KL}[p(x)||q(x)]$
  • i.e. 距離の公式は、満たさない

サンプリングによる期待値の近似

\langle f(x) \rangle _{p(x)} \approx \frac{1}{L} \sum_{i=1}^{L}f(x^{(i)})
  • ただし、$x^{(1)}, ..., x^{(L)} \sim p(x)$ は、
    確率分布$p(x)$ からの$L$個のサンプル点
1
1
0

Register as a new user and use Qiita more conveniently

  1. You get articles that match your needs
  2. You can efficiently read back useful information
  3. You can use dark theme
What you can do with signing up
1
1

Delete article

Deleted articles cannot be recovered.

Draft of this article would be also deleted.

Are you sure you want to delete this article?