Skip to main content
QUICK REVIEW

[Paper Review] Adaptive Computation Time for Recurrent Neural Networks

Alex Graves|arXiv (Cornell University)|Mar 29, 2016
Topic ModelingComputer Science32 references361 citations
TL;DR

The paper introduces Adaptive Computation Time (ACT), enabling RNNs to learn how many computation steps to perform per input, improving performance on several synthetic tasks and providing insights in language modeling. ACT adapts computation with a differentiable halting mechanism and a global time-penalty in the loss.

ABSTRACT

This paper introduces Adaptive Computation Time (ACT), an algorithm that allows recurrent neural networks to learn how many computational steps to take between receiving an input and emitting an output. ACT requires minimal changes to the network architecture, is deterministic and differentiable, and does not add any noise to the parameter gradients. Experimental results are provided for four synthetic problems: determining the parity of binary vectors, applying binary logic operations, adding integers, and sorting real numbers. Overall, performance is dramatically improved by the use of ACT, which successfully adapts the number of computational steps to the requirements of the problem. We also present character-level language modelling results on the Hutter prize Wikipedia dataset. In this case ACT does not yield large gains in performance; however it does provide intriguing insight into the structure of the data, with more computation allocated to harder-to-predict transitions, such as spaces between words and ends of sentences. This suggests that ACT or other adaptive computation methods could provide a generic method for inferring segment boundaries in sequence data.

Motivation & Objective

  • Enable recurrent networks to dynamically vary the number of internal updates per input step.
  • Introduce a differentiable halting mechanism to determine computation depth.
  • Encourage efficient computation by adding a time-penalty to the loss function.
  • Demonstrate ACT on parity, logic, addition, sort, and Wikipedia character prediction tasks.

Proposed method

  • Augment the RNN with a sigmoidal halting unit to decide when to stop computation at each input step.
  • Compute intermediate states s_t^n and outputs y_t^n for n = 1..N(t) using the same state transition S.
  • Define halting probabilities p_t^n from the halting activations and ensure they form a valid distribution with sum 1.
  • Use mean-field updates s_t = sum_n p_t^n s_t^n and y_t = sum_n p_t^n y_t^n to avoid sampling noise.
  • Add a ponder cost P(x) = sum_t rho_t with rho_t = N(t) + R(t) and incorporate it into the loss as L_hat = L + tau P(x).
  • Derive gradients for halting units and perform backpropagation through time with the ACT-specific gradients and limits M (max updates) and epsilon (halt threshold).

Experimental results

Research questions

  • RQ1Does ACT improve sequence learning performance on tasks requiring sequential processing (parity, logic, addition, sort) compared to standard RNNs/LSTMs?
  • RQ2How does the time-penalty parameter tau influence learned computation time and accuracy across tasks?
  • RQ3Can ACT reveal interpretable computation patterns or boundaries in sequential data, such as natural language text?
  • RQ4What are the trade-offs in computation time versus accuracy for different tasks when using ACT?
  • RQ5Does ACT enable or hinder learning of internal state coherence across time in longer sequences?

Key findings

  • ACT-enabled networks substantially reduce error on synthetic sequential tasks compared with fixed-computation baselines.
  • Lower time-penalty values (more pondering) generally yield faster and more accurate solutions on parity and logic problems, with diverse ponder times across runs.
  • On the addition task, ACT networks achieved perfect accuracy for all tau values and exhibited near-linear ponder time proportional to digit count.
  • On the sort task, ACT gave notable error reductions but at a large computational cost, with ponder time increasing nonlinearly and more strongly with sequence length.
  • Character-level Wikipedia prediction showed little overall accuracy gain, but ACT revealed systematic pauses at word boundaries and punctuation, suggesting boundaries inferred by computation time.
  • Across tasks, the relationship between tau, ponder time, and accuracy varied by task, with ACT providing interpretable patterns of computation density and timing.

Read this paper

Open the full text in the Nubint reader and ask about any passage as you read.

Read this paper on Nubint

This review was generated by AI from the original paper. Please check the paper before citing it.