Stack Long Short-Term Memory (StackLSTM) is useful for various applications such as parsing and string-to-tree neural machine translation, but it is also known to be notoriously difficult to parallelize for GPU training due to the fact that the computations are dependent on discrete operations. In this paper, we tackle this problem by utilizing state access patterns of StackLSTM to homogenize computations with regard to different discrete operations. Our parsing experiments show that the method scales up almost linearly with increasing batch size, and our parallelized PyTorch implementation trains significantly faster compared to the Dynet C++ implementation.
翻译:堆积长的短期内存(Stack Stack-LSTM)对于诸如剖析和线到树的神经机翻译等各种应用都有用,但众所周知,由于计算取决于离散操作,GPU培训也很难平行进行,这众所周知。 在本文中,我们通过使用 StackLSTM(Stack-LSTM)的国家存取模式来解决这个问题,以对不同离散操作的计算进行同质化。我们的解析实验显示,这种方法随着批量规模的扩大而几乎线性地扩大,而我们平行的PyTorch执行火车比Dynet C++执行速度要快得多。