SMAC: Score-Matched Actor-Critics for Robust Offline-to-Online Transfer
Organizations: Department of Computer Science, University of Toronto, Toronto, Canada · Vector Institute
Abstract
Modern offline Reinforcement Learning (RL) methods find performant actor-critics, however, fine-tuning these actor-critics online with value-based RL algorithms typically causes immediate drops in performance. We provide evidence consistent with the hypothesis that, in the loss landscape, offline maxima for prior algorithms and online maxima are separated by low-performance valleys that gradient-based fine-tuning traverses. Following this, we present Score Matched Actor-Critic (SMAC), an offline RL method designed to learn actor-critics that transition to online value-based RL algorithms with no drop in performance. SMAC avoids valleys between offline and online maxima by regularizing the Q-function during the offline phase to respect a first-order derivative equality between the score of the policy and action-gradient of the Q-function. We experimentally demonstrate that SMAC converges to offline maxima that are connected to better online maxima via paths with monotonically increasing reward found by first-order optimization. SMAC achieves smooth transfer to Soft Actor-Critic and TD3 in 6/6 D4RL tasks. In 4/6 environments, it reduces regret by 34-58% over the best baseline.
Figures & tables
| Online Algorithm | ||||
|---|---|---|---|---|
| Offline Algorithm | AWR | SAC | TD3 | TD3+BC |
| IQL | 0.508 | 0.471 | 0.653 | 0.494 |
| SMAC | 0.380 | 0.031 | 0.090 | 0.226 |
| TD3+BC | 0.654 | 0.962 | 0.545 | 0.562 |
| CalQL/CQL | 0.482 | 0.448 | 0.442 | 0.614 |
Appendix figures & tables22 assets
Supplementary material from the paper’s appendix.
Appendix
| Offline Algorithm | ||||
|---|---|---|---|---|
| Environment | CalQL/CQL | IQL | SMAC | TD3+BC |
| door | 134.5 1.6 | 120.0 0.8 | 50.3 2.7 | 129.7 2.4 |
| hopper | 293.7 20.4 | 798.0 126.5 | 386.3 10.8 | 3213.3 16.3 |
| kitchen | 467.1 38.1 | 492.9 13.7 | 131.4 13.0 | 762.5 11.4 |
| pen | 8.0 0.7 | 10.3 0.7 | 5.3 0.7 | 55.2 1.9 |
| relocate | 98.1 0.4 | 97.4 0.4 | 62.8 2.1 | 99.2 0.0 |
| Offline Algorithm | ||||
|---|---|---|---|---|
| Environment | CalQL/CQL | IQL | SMAC | TD3+BC |
| door | 131.1 3.0 | 126.1 0.4 | 65.5 2.1 | 137.7 1.4 |
| hopper | 311.4 46.5 | 1834.3 150.3 | 297.3 6.5 | 329.3 39.0 |
| kitchen | 526.6 32.3 | 445.9 13.2 | 259.3 22.8 | 529.1 21.6 |
| pen | 8.4 0.7 | 16.1 0.5 | 8.5 0.8 | 41.6 2.9 |
| relocate | 97.8 0.5 | 95.2 0.3 | 58.3 1.3 | 99.1 0.0 |
| Offline Algorithm | ||||
|---|---|---|---|---|
| Environment | CalQL/CQL | IQL | SMAC | TD3+BC |
| door | 129.9 0.7 | 127.9 0.4 | 122.8 0.8 | 136.0 0.7 |
| hopper | 533.7 43.0 | 958.0 89.9 | 353.0 2.6 | 552.4 26.8 |
| kitchen | 343.7 7.3 | 446.4 10.0 | 340.6 15.8 | 837.0 3.7 |
| pen | 28.8 2.6 | 18.0 0.5 | 13.3 0.7 | 32.9 3.0 |
| relocate | 99.0 0.1 | 95.8 0.3 | 98.3 0.2 | 98.1 0.2 |
| Offline Algorithm | ||||
|---|---|---|---|---|
| Environment | CalQL/CQL | IQL | SMAC | TD3+BC |
| door | 140.8 0.1 | 127.0 0.3 | 72.3 1.8 | 140.3 0.2 |
| hopper | 2469.9 42.3 | 1392.6 118.4 | 425.5 44.3 | 1295.4 62.3 |
| kitchen | 256.6 4.0 | 385.2 7.6 | 262.2 14.6 | 373.4 11.5 |
| pen | 17.8 2.9 | 16.1 0.6 | 7.7 0.6 | 31.8 1.0 |
| relocate | 99.1 0.0 | 95.3 0.3 | 84.9 2.0 | 98.2 0.2 |
| Hyper-parameter | Locomotion | Adroit Tasks | Kitchen |
|---|---|---|---|
| Obs Dimension / Emb Dimension | 64 / 64 | 64 / 64 | 64 / 64 |
| Hidden Dimension | 512 | 512 | 512 |
| # of blocks | 3 | 5 | 5 |
| Condition Network architecture | MLP | MLP | MLP |
| Condition Network Hidden Dimensions | [512, 512, 512] | [256, 256, 256] | [256, 256, 256] |
| Condition out dim | 64 | 64 | 64 |
| Hyper-parameter | Locomotion | Adroit Tasks | Kitchen |
|---|---|---|---|
| Critic Learning rate | |||
| Critic hidden dims | [512, 512, 512] | [512, 512, 512, 512] | [512, 512, 512, 512] |
| Critic activations | tanh | tanh | tanh |
| Critic ensemble size | 10 | 10 | 10 |
| Critic Target Update Ratio | 0.005 | 0.005 | 0.005 |
| Policy Learning rate |
| Hyper-parameter | Locomotion | Door (Adroit) | Kitchen |
|---|---|---|---|
| Critic learning rate | |||
| Critic hidden dims | [256, 256] | [256, 256, 256] | [512, 512, 512] |
| Critic activations | relu | relu | relu |
| Critic ensemble size | 2 | 2 | 2 |
| Target update rate | |||
| Value net learning rate |
| Hyper-parameter | Locomotion | Adroit | Kitchen |
|---|---|---|---|
| Critic learning rate | |||
| Critic hidden dims | [512, 512, 512] | [512, 512, 512, 512] | [512, 512, 512] |
| Critic activations | relu | relu | relu |
| Critic ensemble size | 10 | 10 | 10 |
| Target update rate | |||
| Policy tanh-squash dist. | True | True | True |
| Hyper-parameter | Locomotion | Adroit | Kitchen |
| Critic learning rate | |||
| Critic hidden dims | [512, 512, 512] | [512, 512] | [512, 512, 512] |
| Critic activations | relu | relu | relu |
| Critic ensemble size | |||
| Critic target update ratio | |||
| Policy learning rate |
Offline RL
Offline reinforcement learning learns decision-making policies from fixed datasets without interacting with the environment during training.
See all 298 papers