NeurIPS 2026Coming to NeurIPS?Explore papers, orals & directions

Gradient Projection Memory for Continual Learning

Gobinda Saha, Isha Garg, Kaushik Roy

Introduction

The ability to learn continually without forgetting past tasks is a highly desired attribute for artificial learning systems. However, Artificial Neural Networks (ANNs) are notoriously bad at multitasking over time. When a model trained on Task A is asked to learn Task B, the gradient descent process modifies weights to minimize the new loss, often overwriting the parameters essential for Task A. This phenomenon is known as Catastrophic Forgetting.

Existing solutions generally fall into three camps:

  1. Expansion: Adding new neurons for every task, which is expensive and non-scalable.
  2. Regularization: Penalizing changes to "important" weights (e.g., EWC), which often struggles with long task sequences.
  3. Memory Replay: Storing and re-training on old data (e.g., GEM), which raises significant data privacy concerns and requires large storage buffers.

To address these limitations, researchers have proposed Gradient Projection Memory (GPM), a novel continual learning framework. GPM prevents catastrophic forgetting by ensuring new task updates occur only in directions orthogonal to the gradient spaces of past tasks. By using Singular Value Decomposition (SVD) on network activations to identify and store these essential subspaces, GPM achieves state-of-the-art performance with significantly lower memory overhead and better data privacy than traditional replay-based methods.

The GPM Approach: Orthogonal Gradient Descent

The core idea of GPM is to leverage Orthogonal Gradient Descent. If we can identify the specific "subspace" of the weight matrix responsible for a past task's performance, we can restrict all future updates to the orthogonal complement of that space. In simpler terms, the network learns new things only in the "directions" the old tasks aren't using.

The GPM algorithm follows a three-step cycle for each task:

  1. Representation Analysis: After learning a task, the model passes a small subset of data through the network and collects the "activations" (the outputs of each layer).
  2. Subspace Identification (SVD): Singular Value Decomposition (SVD) is performed on these activations to identify the most important directions (bases) in the data. These bases form the Core Gradient Space (CGS)—the directions that must be protected.
  3. Gradient Projection: When learning the next task, the optimizer calculates a raw gradient. GPM then "projects" this gradient to remove any components that overlap with the stored CGS. The resulting "cleaned" gradient is used to update the weights, ensuring zero interference with past knowledge.
Forward and backward passes illustrating the relationship between input activations and weight gradients.

Crucially, GPM is incremental. For each new task, it only adds new orthogonal bases to its memory that weren't already captured by previous tasks.

Key Insights

  • Activations as Proxies for Gradients: The paper's most elegant insight is the mathematical proof that the span of a layer's input (activations) is equivalent to the span of the gradients for that layer's weights. This allows the model to find "important directions" just by looking at how data flows through the network, rather than storing every single gradient vector.
  • The Stability-Plasticity Threshold: GPM uses a hyperparameter ($\epsilon_{th}$) to decide how many SVD bases to keep. A high threshold preserves more "core" space (high stability/low forgetting) but leaves less room for new learning (low plasticity).
  • Privacy by Design: Unlike "Replay" methods, GPM never stores raw images. It only stores abstract mathematical bases, making it much more suitable for applications involving sensitive user data.

Experimental Results

The authors evaluated GPM on several standard continual learning benchmarks, including Permuted MNIST, 10-Split CIFAR-100, 20-Split miniImageNet, and a 5-Dataset sequence.

  • Superior Accuracy and Zero Forgetting: On Permuted MNIST, GPM achieved 93.91% accuracy, outperforming EWC (89.97%) and GEM (83.38%). Remarkably, in the 20-split miniImageNet experiment, GPM showed a Backward Transfer (BWT) of 0.00, meaning the model literally did not forget Task 1 even after learning 19 subsequent tasks.
  • Speed and Memory Efficiency: Compared to Orthogonal Gradient Descent (OGD), which stores actual gradient vectors for every sample, GPM is orders of magnitude more memory-efficient because it only stores a few dozen or hundred basis vectors per layer. For PMNIST, it was the fastest method tested, taking only 245 seconds compared to OGD's 1658 seconds, while using roughly 400x less memory.
Comparison of memory and time overhead across different continual learning methods.

Limitations and Future Work

While GPM is highly effective, it operates within a fixed-capacity network. As more tasks are learned, the Core Gradient Space grows. Eventually, the gradient space will become "full," leaving no orthogonal directions left for new tasks, causing plasticity to drop to zero.

Future work could explore "forgetting" the least important bases in the GPM to make room for new ones, or combining GPM with a very small, privacy-preserving generative replay mechanism to handle even longer task sequences. Additionally, removing the reliance on "task hints" (knowing which task is being performed during training) remains an important frontier for this framework.

Summary updated

BibTeX
@inproceedings{saha2021gradient,
  author = {Gobinda Saha and Isha Garg and Kaushik Roy},
  title = {{Gradient Projection Memory for Continual Learning}},
  booktitle = {International Conference on Learning Representations},
  year = {2021},
  url = {https://openreview.net/forum?id=3AOj0RCNC2},
}
Figure