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

长序列的反向传播:超越内存限制,开销不变

Backpropagation for long sequences: beyond memory constraints with constant overheads

Navjot Kukreja, Jan Hückelheim, Gerard J. Gorman

摘要:

由于需要存储前向传播的每个状态,通过时间的朴素反向传播具有在序列长度上线性增长的内存占用。这对于大型网络来说是个问题。已经开发了一些策略来用内存换取额外的计算,这导致内存占用或计算开销的次线性增长。在这项工作中,我们提出了一个库,使用异步存储和预取移动数据和缓慢和廉价的存储。该库仅尽可能频繁地存储和预取状态,而不会延迟计算,并在计算之间使用最佳的Revolve反向传播策略。因此,反向传播的存储器占用可以减少到任何大小(例如,以适应DRAM),而计算开销在序列长度中是恒定的,并且仅取决于给定硬件上的计算时间和传输时间之间的比率。我们在实验中表明,通过利用超时空数据传输,我们的策略总是至少一样快,通常比以前研究的“最佳”策略更快。

英文摘要:

Naive backpropagation through time has a memory footprint that grows linearly in the sequence length, due to the need to store each state of the forward propagation. This is a problem for large networks. Strategies have been developed to trade memory for added computations, which results in a sublinear growth of memory footprint or computation overhead. In this work, we present a library that uses asynchronous storing and prefetching to move data to and from slow and cheap stor- age. The library only stores and prefetches states as frequently as possible without delaying the computation, and uses the optimal Revolve backpropagation strategy for the computations in between. The memory footprint of the backpropagation can thus be reduced to any size (e.g. to fit into DRAM), while the computational overhead is constant in the sequence length, and only depends on the ratio between compute and transfer times on a given hardware. We show in experiments that by exploiting asyncronous data transfer, our strategy is always at least as fast, and usually faster than the previously studied "optimal" strategies.

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

↑