Enabling Large Batch Size Training for DNN Models Beyond the Memory Limit While Maintaining Performance

要約

最近の深層学習モデルは、大きなバッチ サイズを使用してトレーニングすることが困難です。これは、汎用マシンにはモデルと大きなデータ バッチ サイズの両方に対応するのに十分なメモリがない可能性があるためです。
バッチ サイズはトレーニング モデルで使用されるハイパーパラメーターの 1 つであり、バッチ サイズはモデルのアップロード後に残りのメモリにのみ収まるため、ターゲット マシンのメモリ容量に依存し、制限されます。
さらに、各データ項目のサイズが大きくなると、残りのメモリに収まるバッチ サイズが小さくなるため、データ項目のサイズも重要な要素です。
この論文では、この問題に対処するためのマイクロバッチ処理 (MBP) と呼ばれる手法を提案します。
このメソッドは、残りのメモリに収まるサイズにバッチを分割し、順次処理するバッチ処理メソッドを提供することで、ディープ ラーニング モデルのトレーニングを支援します。
小さなバッチを個別に処理した後、勾配の累積に基づく損失正規化アルゴリズムを使用してパフォーマンスを維持します。
私たちの方法の目的は、メモリ サイズを増やしたり複数のデバイス (GPU) を使用したりすることなく、システムのメモリ容量を超える大きなバッチ サイズを使用してディープ ラーニング モデルをトレーニングできるようにすることです。

要約(オリジナル)

Recent deep learning models are difficult to train using a large batch size, because commodity machines may not have enough memory to accommodate both the model and a large data batch size. The batch size is one of the hyper-parameters used in the training model, and it is dependent on and is limited by the target machine memory capacity because the batch size can only fit into the remaining memory after the model is uploaded. Moreover, the data item size is also an important factor because if each data item size is larger then the batch size that can fit into the remaining memory becomes smaller. This paper proposes a method called Micro-Batch Processing (MBP) to address this problem. This method helps deep learning models to train by providing a batch processing method that splits a batch into a size that can fit in the remaining memory and processes them sequentially. After processing the small batches individually, a loss normalization algorithm based on the gradient accumulation is used to maintain the performance. The purpose of our method is to allow deep learning models to train using larger batch sizes that exceed the memory capacity of a system without increasing the memory size or using multiple devices (GPUs).

arxiv情報

著者 XinYu Piao,DoangJoo Synn,JooYoung Park,Jong-Kook Kim
発行日 2024-07-02 13:33:39+00:00
arxivサイト arxiv_id(pdf)

提供元, 利用サービス

arxiv.jp, Google

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