LGCLMLMay 22, 2017

On-the-fly Operation Batching in Dynamic Computation Graphs

arXiv:1705.07860v162 citations
Originality Incremental advance
AI Analysis

This solves the batching problem for developers using dynamic toolkits, enabling efficient computation without manual effort, though it is incremental as it builds on existing toolkit capabilities.

The paper tackles the difficulty of manually batching operations in dynamic neural network toolkits by introducing an automatic batching algorithm implemented in DyNet, achieving throughput similar to manual batching and comparable speedups on complex architectures.

Dynamic neural network toolkits such as PyTorch, DyNet, and Chainer offer more flexibility for implementing models that cope with data of varying dimensions and structure, relative to toolkits that operate on statically declared computations (e.g., TensorFlow, CNTK, and Theano). However, existing toolkits - both static and dynamic - require that the developer organize the computations into the batches necessary for exploiting high-performance algorithms and hardware. This batching task is generally difficult, but it becomes a major hurdle as architectures become complex. In this paper, we present an algorithm, and its implementation in the DyNet toolkit, for automatically batching operations. Developers simply write minibatch computations as aggregations of single instance computations, and the batching algorithm seamlessly executes them, on the fly, using computationally efficient batched operations. On a variety of tasks, we obtain throughput similar to that obtained with manual batches, as well as comparable speedups over single-instance learning on architectures that are impractical to batch manually.

Code Implementations3 repos
Foundations

The foundational work for this paper's niche, ranked by how specifically the neighbourhood builds on it — not by global fame.

Your Notes