shibhansh/loss-of-plasticity
Demonstrations of Loss of Plasticity and Implementation of Continual Backpropagation
What it solves
Deep learning usually happens in two steps: first, the network's weights are updated (training), then they are held fixed while the network is used or evaluated. This works well until you need continual learning, where the network must keep learning from a changing environment. This research shows that standard deep learning methods fail in those settings - they gradually lose plasticity and end up learning no better than a shallow network. This repository provides the exact code used in the scientific paper to reproduce and study this problem.
How it works
The repository is a Python package (called lop) split into several subdirectories. It includes all the algorithms used in the paper, including a proposed fix called 'continual backpropagation', which continually reinitializes a small fraction of less-used units to keep injecting diversity into the network. The code covers experiments for task-incremental learning on ImageNet, class-incremental learning on CIFAR, a small slowly-changing regression problem (for a quick demonstration), and reinforcement learning using the PPO algorithm. To run it, you create a Python 3.8 virtual environment, clone the repository, and install its requirements - a standard laptop with 8GB of RAM and an internet connection is enough for most experiments, though a GPU speeds up larger ones.
Who it's for
This is for researchers, students, and practitioners who work on deep learning and continual learning. It is useful if you want to verify the paper's findings, understand why networks lose the ability to learn, or apply continual backpropagation to keep your own models adaptable in changing conditions.
Highlights
- Includes all source code needed to reproduce experiments published in the Nature paper 'Loss of Plasticity in Deep Continual Learning'.
- Introduces 'continual backpropagation', a simple variation of backpropagation that randomly reinitializes a small fraction of under-used units to preserve learning ability.
- Covers multiple diverse settings: task-incremental (ImageNet), class-incremental (CIFAR), a quick regression demo, and reinforcement learning with PPO.
- Minimal system requirements: works on a standard laptop with 8GB of RAM (GPU optional for faster large-network experiments).
Related
- Project
- Project
- Project
- Project