Full Stack Optimization of Transformer Inference: a Survey

要約

最先端の DNN アーキテクチャ設計における最近の進歩は、Transformer モデルに移行しています。
これらのモデルは、幅広いアプリケーションで優れた精度を実現します。
この傾向は、Transformer モデルが最初に導入されて以来、過去数年間一貫しています。
ただし、最近の Transformer モデルの推論に必要なコンピューティングと帯域幅の量は大幅に増加しており、これにより、レイテンシの影響を受けやすいアプリケーションへの展開が困難になっています。
そのため、アーキテクチャ設計の変更から専用のドメイン固有アクセラレータの開発に至るまで、Transformer モデルをより効率的にすることにますます注目が集まっています。
この作業では、次のような効率的な Transformer 推論のためのさまざまなアプローチを調査します。(i) 既存の Transformer アーキテクチャのボトルネックと、以前の畳み込みモデルとの類似点と相違点の分析とプロファイル
(ii) レイヤー正規化、Softmax、GELU などの非線形演算や線形演算のハードウェア設計への影響を含む、ハードウェアに対する Transformer アーキテクチャの影響。
(iii) 固定 Transformer アーキテクチャを最適化するためのアプローチ。
(iv) Transformer モデルの操作の適切なマッピングとスケジューリングを見つける際の課題。
(v)ニューラルアーキテクチャ検索を使用してアーキテクチャを適応させることにより、Transformer モデルを最適化するためのアプローチ。
最後に、調査した最適化をオープンソースのフルスタック DNN アクセラレーター ジェネレーターである Gemmini に適用してケース スタディを行い、Gemmini での以前のベンチマーク結果と比較して、これらの各アプローチがどのように改善をもたらすかを示します。
とりわけ、前述の方法を使用したフルスタック協調設計アプローチにより、Transformer 推論のパフォーマンス低下を最小限に抑えながら、最大 88.7 倍のスピードアップを実現できることがわかりました。

要約(オリジナル)

Recent advances in state-of-the-art DNN architecture design have been moving toward Transformer models. These models achieve superior accuracy across a wide range of applications. This trend has been consistent over the past several years since Transformer models were originally introduced. However, the amount of compute and bandwidth required for inference of recent Transformer models is growing at a significant rate, and this has made their deployment in latency-sensitive applications challenging. As such, there has been an increased focus on making Transformer models more efficient, with methods that range from changing the architecture design, all the way to developing dedicated domain-specific accelerators. In this work, we survey different approaches for efficient Transformer inference, including: (i) analysis and profiling of the bottlenecks in existing Transformer architectures and their similarities and differences with previous convolutional models; (ii) implications of Transformer architecture on hardware, including the impact of non-linear operations such as Layer Normalization, Softmax, and GELU, as well as linear operations, on hardware design; (iii) approaches for optimizing a fixed Transformer architecture; (iv) challenges in finding the right mapping and scheduling of operations for Transformer models; and (v) approaches for optimizing Transformer models by adapting the architecture using neural architecture search. Finally, we perform a case study by applying the surveyed optimizations on Gemmini, the open-source, full-stack DNN accelerator generator, and we show how each of these approaches can yield improvements, compared to previous benchmark results on Gemmini. Among other things, we find that a full-stack co-design approach with the aforementioned methods can result in up to 88.7x speedup with a minimal performance degradation for Transformer inference.

arxiv情報

著者 Sehoon Kim,Coleman Hooper,Thanakul Wattanawong,Minwoo Kang,Ruohan Yan,Hasan Genc,Grace Dinh,Qijing Huang,Kurt Keutzer,Michael W. Mahoney,Yakun Sophia Shao,Amir Gholami
発行日 2023-02-27 18:18:13+00:00
arxivサイト arxiv_id(pdf)

提供元, 利用サービス

arxiv.jp, Google

カテゴリー: cs.CL, cs.LG パーマリンク