arXivDaily arXiv每日学术速递 周一至周五更新
arXiv 2306.01129cs.LG
收藏

通过稀疏率压缩实现白盒 Transformer

White-Box Transformers via Sparse Rate Reduction

University of California, Berkeley(加利福尼亚大学伯克利分校);TTIC(芝加哥理论计算机科学研究所);Johns Hopkins University(约翰斯·霍普金斯大学)

Yaodong Yu, Sam Buchanan, Druv Pai, Tianzhe Chu, Ziyang Wu, Shengbang Tong, Benjamin D. Haeffele, Yi Ma

AI总结:

论文从 sparse rate reduction 目标推导出多头自注意力与 MLP 的作用,构建数学可解释的白盒类 transformer 架构 CRATE,并在 ImageNet 上达到接近 ViT 的性能。

摘要:

本文认为,表示学习的目标是将数据(例如 token 集合)的分布压缩并变换为支撑在不相干子空间上的低维高斯分布混合。最终表示的质量可通过一个称为 sparse rate reduction 的统一目标函数来衡量。从这一视角看,transformer 等流行深度网络可自然地被视为以增量方式优化该目标的迭代方案。特别地,我们表明标准 transformer 块可由对该目标互补部分的交替优化导出:多头自注意力算子可视为通过最小化 token 集合的有损编码率来压缩这些集合的梯度下降步骤,而随后的多层感知机可被视为尝试稀疏化 token 的表示。由此得到一类在数学上完全可解释的、类似 transformer 的白盒深度网络架构。尽管结构简单,实验表明这些网络确实学会了优化所设计的目标:它们对 ImageNet 等大规模真实视觉数据集的表示进行压缩和稀疏化,并取得了与 ViT 等经过充分工程设计的 transformer 非常接近的性能。代码位于 https://github.com/Ma-Lab-Berkeley/CRATE。

英文摘要:

In this paper, we contend that the objective of representation learning is to compress and transform the distribution of the data, say sets of tokens, towards a mixture of low-dimensional Gaussian distributions supported on incoherent subspaces. The quality of the final representation can be measured by a unified objective function called sparse rate reduction. From this perspective, popular deep networks such as transformers can be naturally viewed as realizing iterative schemes to optimize this objective incrementally. Particularly, we show that the standard transformer block can be derived from alternating optimization on complementary parts of this objective: the multi-head self-attention operator can be viewed as a gradient descent step to compress the token sets by minimizing their lossy coding rate, and the subsequent multi-layer perceptron can be viewed as attempting to sparsify the representation of the tokens. This leads to a family of white-box transformer-like deep network architectures which are mathematically fully interpretable. Despite their simplicity, experiments show that these networks indeed learn to optimize the designed objective: they compress and sparsify representations of large-scale real-world vision datasets such as ImageNet, and achieve performance very close to thoroughly engineered transformers such as ViT. Code is at \url{https://github.com/Ma-Lab-Berkeley/CRATE}.

机构、总结、中文摘要均由AI分析而来,可能存在错误,请以论文正文为准。

↑