HyperAIHyperAI

Command Palette

Search for a command to run...

4 months ago

Learning Longer-term Dependencies in RNNs with Auxiliary Losses

Trieu H. Trinh; Andrew M. Dai; Minh-Thang Luong; Quoc V. Le

Learning Longer-term Dependencies in RNNs with Auxiliary Losses

Abstract

Despite recent advances in training recurrent neural networks (RNNs), capturing long-term dependencies in sequences remains a fundamental challenge. Most approaches use backpropagation through time (BPTT), which is difficult to scale to very long sequences. This paper proposes a simple method that improves the ability to capture long term dependencies in RNNs by adding an unsupervised auxiliary loss to the original objective. This auxiliary loss forces RNNs to either reconstruct previous events or predict next events in a sequence, making truncated backpropagation feasible for long sequences and also improving full BPTT. We evaluate our method on a variety of settings, including pixel-by-pixel image classification with sequence lengths up to 16\,000, and a real document classification benchmark. Our results highlight good performance and resource efficiency of this approach over competitive baselines, including other recurrent models and a comparable sized Transformer. Further analyses reveal beneficial effects of the auxiliary loss on optimization and regularization, as well as extreme cases where there is little to no backpropagation.

Code Repositories

younggyoseo/rnn-auxiliary-loss
pytorch
Mentioned in GitHub

Benchmarks

BenchmarkMethodologyMetrics
sequential-image-classification-on-sequential-1Transformer (self-attention) (Trinh et al., 2018)
Unpermuted Accuracy: 62.2%

Build AI with AI

From idea to launch — accelerate your AI development with free AI co-coding, out-of-the-box environment and best price of GPUs.

AI Co-coding
Ready-to-use GPUs
Best Pricing
Get Started

Hyper Newsletters

Subscribe to our latest updates
We will deliver the latest updates of the week to your inbox at nine o'clock every Monday morning
Powered by MailChimp
Learning Longer-term Dependencies in RNNs with Auxiliary Losses | Papers | HyperAI