Episodic looking - using reinforcement learning to bias perception enhances few-shot and continual learning with protection from forgetting
Organizations: Cerenaut Melbourne Australia
Abstract
There is a fundamental contradiction between the desire for models that can generalize, and models that can continuously adapt to recent input with changing statistics. These conditions, captured in few-shot and continual learning settings, can bias or disrupt learned representations. This harms generalization to a broader context, leaving the model unable to overcome input variance. This paper proposes a solution based on the Complementary Learning System architecture (CLS), in which a Short-Term Memory (STM) delegates generalization to a slow, statistical Long-Term Memory (LTM). Delegation is achieved by working in a space of robust, generalized perceptions produced by the LTM. With this separation, the STM can focus on memorizing recent input and avoiding interference between memories. We show that on an image classification task, the resulting CLS model is more resistant to forgetting in a domain-incremental continual learning setting than a baseline ResNet LTM, and generalizes more effectively in a few-shot setting than other continual learners. In the continual setting, overall accuracy is slightly worse than existing continual learning models, but with a different mix of performance characteristics. Results analysis suggests that the model is limited by the representations and representational plasticity of the LTM. In future work, we will seek to address this by replaying STM memories to the LTM.
Figures & tables
| Pair | Coarse classes | Fine classes | |||||
|---|---|---|---|---|---|---|---|
| 1 | 2 | 3 | 4 | 5 | |||
| A | 1 | Aquatic mammals | Beaver | Dolphin | Otter | Seal | Whale |
| A | 2 | Fish | Aquarium fish | Flatfish | Rays | Shark | Trout |
| B | 3 | Flowers | Orchids | Poppies | Roses | Sunflowers | Tulips |
| B | 4 | Food containers | Bottles | Bowls | Cans | Cups | Plates |
| C | 6 | Electrical devices | Clock | Keyboard | Lamp | Telephone | TV |
| STM variant | Target labels | Label-routed updates | Differentiable task loss | Phase change input |
|---|---|---|---|---|
| RL-STM | no | no | no | no |
| Sparse supervised STM, linear probe, SDMLP | yes | no | yes | no |
| FlyModel, NCM | yes | yes | no | no |
| LTM-only fine-tuning | yes | no | yes | no |
| SDMLP+EWC or EWC (not evaluated) | yes | no | yes | yes |
| Pair | Model | ACC | LA | BWT | BWT 0 | FWT | Forgetting | Budget | |
| A | RL-STM | 3 | 0.753 0.010 | 0.795 | 0.086 | 12 | |||
| Sparse supervised STM | 3 | 0.722 0.012 | 0.822 | 0.169 | 12 | ||||
| Linear probe | 5 | 0.773 0.002 | 0.813 | 0.100 | 8 | ||||
| NCM | 5 | 0.792 0.000 | 0.794 | 0.035 | 49 | ||||
| FlyModel | 5 | 0.791 0.005 | 0.771 | 0.017 | 1 | ||||
| SDMLP | 5 | 0.794 0.001 | 0.794 | 0.031 | 16 |
| Model | Start | |||||
|---|---|---|---|---|---|---|
| Trained class | ||||||
| RL-STM | 0.471 | 0.501 0.018 | 0.658 0.041 | 0.781 0.016 | 0.804 0.010 | 0.814 0.012 |
| Sparse supervised STM | 0.640 | 0.641 0.029 | 0.669 0.030 | 0.708 0.027 | 0.717 0.036 | 0.720 0.037 |
| Linear probe | 0.506 | 0.509 0.002 | 0.684 0.021 | 0.721 0.024 | 0.764 0.006 | 0.793 0.001 |
| NCM | 0.673 | 0.673 0.000 | 0.716 0.010 | 0.758 0.011 | 0.745 0.003 | 0.767 0.000 |
| FlyModel | 0.671 | 0.672 0.005 | 0.673 0.004 | 0.677 0.006 | 0.729 0.005 | 0.778 0.005 |
Appendix figures & tables5 assets
Supplementary material from the paper’s appendix.
Appendix
| Model | Learning rates |
|---|---|
| RL-STM | Not tuned (0.1); learning rate 0.2 with zero momentum tested on validation set for Pair A and found to be equivalent. Few-shot training budget optimized, but not continual. |
| Sparse supervised STM | 0.1, 0.03, 0.01 |
| Linear probe | 0.0003, 0.001, 0.003 |
| NCM | none |
| FlyModel | Not tuned (0.2) |
| SDMLP | 0.015, 0.05, 0.15 |
| Few-shot, | |||||||
|---|---|---|---|---|---|---|---|
| Model | LR | Continual | 1 | 4 | 16 | 64 | 400 |
| RL-STM | 0.1 | 12 (fixed) | 1 (0.571) | 24 (0.646) ‡ | 26 (0.721) § | 21 (0.735) § | 21 (0.731) |
| Sparse supervised STM | 0.01 | 12 (fixed) | 1 (0.714) | 8 (0.721) | 42 (0.736) | 6 (0.735) | 1 (0.740) |
| FlyModel | – | 1 (0.749) | 1 (0.745) | 1 (0.746) | 1 (0.744) | 3 (0.756) | 1 (0.770) |
| Linear probe | 0.0003 | 24 (0.770) | 1 (0.659) | 2060 (0.705) | 471 (0.721) | 126 (0.748) | 24 (0.755) |
| Linear probe | 0.001 | 8 (0.775) | 1 (0.658) | 589 (0.705) | 148 (0.722) | 36 (0.745) | 8 (0.759) |
| Component | Output dimension |
|---|---|
| Input | |
| Stem: conv., 64 channels, stride 1 | |
| Stage 1: conv., 64 channels, stride 1 | |
| Stage 2: conv., 128 channels, stride 2 | |
| Multiplicative “bias” applied here. | |
| Stage 3: conv., 256 channels, stride 2 |
| Name | Value |
|---|---|
| Pretraining mini-batch size | 128 (16 in fine-tuning) |
| Optimizer | Adam |
| Learning rate | 0.001 (varied for fine-tuning) |
| Name | Value |
| Pretraining mini-batch size | 16 |
| Fine-tuning mini-batch size | 16 |
| Optimizer | SGD |
| Learning rate | 0.1 |
| Momentum | 0.5 |
| Memory capacity | 1000 |
Continual Learning
Continual Learning studies how models acquire knowledge from changing data streams while retaining or selectively revising what they learned before.
See all 307 papers