《深度学习的互信息：无监督提取特征》一文中，我们通过先验分布和最大化互信息两个loss的加权组合来得到Deep INFOMAX模型最后的loss。在那篇文章中，虽然把故事讲完了，但是某种意义上来说，那只是个拼凑的loss。而本文则要证明那个loss可以由变分自编码器自然地导出来。

## 过程 #

\begin{equation}\begin{aligned}&KL(\tilde{p}(x)p(z|x)\Vert q(z)q(x|z))\\
=&\iint \tilde{p}(x)p(z|x)\log \frac{\tilde{p}(x)p(z|x)}{q(x|z)q(z)} dzdx\end{aligned}\end{equation}

\begin{equation}\begin{aligned}&KL(\tilde{p}(x)p(z|x)\Vert q(z)q(x|z))\\
=&\iint \tilde{p}(x)p(z|x)\log \frac{p(z|x)}{q(z)} dzdx-\iint \tilde{p}(x)p(z|x)\log \frac{q(x|z)}{\tilde{p}(x)} dzdx\end{aligned}\end{equation}

\begin{equation}KL(q(x|z)p(z)\Vert \tilde{p}(x)p(z))=KL(\tilde{p}(x)p(z|x)\Vert \tilde{p}(x)p(z))\end{equation}

## 结语 #

@online{kexuefm-6088,
title={变分自编码器 = 最小化先验分布 + 最大化互信息},
author={苏剑林},
year={2018},
month={Oct},
url={\url{https://spaces.ac.cn/archives/6088}},
}
{"ft_lang_label":"__label__zh","ft_lang_prob":0.90344095,"math_prob":0.99997795,"size":4987,"snap":"2022-27-2022-33","text_gpt3_token_len":4079,"char_repetition_ratio":0.12061007,"word_repetition_ratio":0.0,"special_character_ratio":0.26168036,"punctuation_ratio":0.06987952,"nsfw_num_words":0,"has_unicode_error":false,"math_prob_llama3":0.9999745,"pos_list":[0],"im_url_duplicate_count":[null],"WARC_HEADER":"{\"WARC-Type\":\"response\",\"WARC-Date\":\"2022-07-07T14:40:01Z\",\"WARC-Record-ID\":\"<urn:uuid:e144b6d5-18e2-4c34-8e98-0a3277747084>\",\"Content-Length\":\"96498\",\"Content-Type\":\"application/http; msgtype=response\",\"WARC-Warcinfo-ID\":\"<urn:uuid:18b51100-56f7-422c-9913-b137f588a0a1>\",\"WARC-Concurrent-To\":\"<urn:uuid:8a77d8a1-2482-4f35-9645-ae64cd73f521>\",\"WARC-IP-Address\":\"120.77.64.127\",\"WARC-Target-URI\":\"https://spaces.ac.cn/archives/6088/comment-page-1?replyTo=11136\",\"WARC-Payload-Digest\":\"sha1:6HNOXVO7XTVZFEW3TYZG5PZOYGQAISHC\",\"WARC-Block-Digest\":\"sha1:JJREBI5VGGRGQL37SJDK25KPH25CMVQG\",\"WARC-Identified-Payload-Type\":\"application/xhtml+xml\",\"warc_filename\":\"/cc_download/warc_2022/CC-MAIN-2022-27/CC-MAIN-2022-27_segments_1656104692018.96_warc_CC-MAIN-20220707124050-20220707154050-00158.warc.gz\"}"}