Abstract
Methods proposed in the literature towards continual deep learning typically operate in a task-based sequential learning setup. A sequence of tasks is learned, one at a time, with all data of current task available but not of previous or future tasks. Task boundaries and identities are known at all times. This setup, however, is rarely encountered in practical applications. Therefore we investigate how to transform continual learning to an online setup. We develop a system that keeps on learning over time in a streaming fashion, with data distributions gradually changing and without the notion of separate tasks. To this end, we build on the work on Memory Aware Synapses, and show how this method can be made online by providing a protocol to decide i) when to update the importance weights, ii) which data to use to update them, and iii) how to accumulate the importance weights at each update step. Experimental results show the validity of the approach in the context of two applications: (self-)supervised learning of a face recognition model by watching soap series and learning a robot to avoid collisions.
Introduction
Deep learning models are notoriously "forgetful." When trained on a new set of data, they often overwrite the parameters used for previous data—a phenomenon known as catastrophic interference. While Continual Learning (CL) aims to mitigate this, most existing research relies on artificial "task boundaries"—explicit signals indicating when one task ends and another begins.
In real-world scenarios, such as a robot navigating a changing environment or a system processing a continuous video stream, these boundaries are absent. This paper introduces a framework for Task-Free Continual Learning, enabling models to autonomously manage knowledge consolidation in streaming, non-i.i.d. (non-independent and identically distributed) environments without needing a human to signal task shifts.
Methodology: Making CL Task-Free
The proposed method extends Memory Aware Synapses (MAS), a regularization technique that assigns importance weights to network parameters. To adapt MAS for an online, task-free setting, the authors introduce three primary innovations:
1. Plateau Detection in the Loss Surface
Instead of relying on external task IDs, the model monitors its own training loss. By analyzing the mean and variance of the loss within a sliding window, the system identifies "plateaus"—periods of stable learning. These plateaus serve as internal signals to trigger the update of parameter importance weights, effectively consolidating knowledge when the model has mastered a particular data distribution.
2. The "Hard Buffer"
To provide stable estimates for importance weights without storing massive amounts of data, the authors employ a small "hard buffer" (e.g., 100 samples). This buffer prioritizes samples with the highest loss, ensuring the model continues to learn from challenging examples and maintains a representative memory of past distributions.
3. Cumulative Moving Average (CMA)
To prevent gradient explosion and ensure stable regularization in an online setting, importance weights are accumulated using a Cumulative Moving Average rather than simple addition. This ensures that the penalty for changing critical parameters remains balanced over long training durations.
Experimental Evaluation
The framework was tested across three diverse scenarios:
- Synthetic Data: A 4D binary classification problem serving as a proof-of-concept.
- Actor Labeling in TV Series: Recognizing faces in episodes of The Big Bang Theory, Breaking Bad, and Mad Men. This involves highly correlated data and significant distribution shifts (e.g., indoor vs. outdoor scenes).
- Robot Navigation: Collision avoidance for a drone in simulation (Gazebo) and a Turtlebot in a real-world lab arena.
Key Results and Insights
The task-free approach demonstrated significant improvements over standard online learning baselines:
- Face Recognition: In The Big Bang Theory, the method achieved accuracy comparable to "Joint Training" (offline training on all data). In the more challenging Breaking Bad dataset, it showed a 100% improvement over the online baseline, which failed to retain knowledge across episodes.
- Robotics: The Turtlebot learned faster and experienced fewer collisions, proving the method's efficacy in real-time physical environments.
A core insight is that the loss function serves as a natural signal for distribution shifts. A dropping loss indicates active learning, a plateau suggests mastery, and a spike signals new, unfamiliar data. However, a trade-off exists between stability and plasticity; protecting old knowledge can occasionally slow the adaptation to radically new information.
Limitations and Future Work
The current implementation assumes a fixed network architecture, which limits its ability to handle "class-incremental" learning (e.g., adding new actors dynamically). Additionally, the thresholds for plateau detection currently require manual tuning. Future research could explore meta-learning to automate hyperparameter selection and investigate methods for dynamic architecture expansion in task-free settings.
Summary updated