10 Offline RL and data coverage

Home | Previous: 09 Reinforcement Learning | Next: 11 World Models and Planning

Offline reinforcement learning uses a fixed dataset of transitions. This is attractive when robot interaction is costly: reuse logged experience instead of collecting every trial anew. The central difficulty is estimating the value of actions that the dataset barely contains.

Why maximization can amplify error

A simple Q-learning target is

where indicates a true terminal state and denotes target parameters. The maximization may select an unsupported action with an accidentally high predicted value. Training then propagates that error.

data_coverage.png

Synthetic action values: a fitted estimate can look optimistic outside the region covered by data.

One state, logged actions only in . A degree-4 fit agrees with the data, but its maximum is at , predicting 21.8 where the true reward is . Maximising an ensemble’s mean minus two standard deviations, a simple pessimistic estimate, picks (true reward 0.97). Bootstrapping with multiplies the error in the max by . Across 200 random datasets the greedy pick left the data 52% of the time. Source: Tools/animations/ch10_offline_overestimation.py.

Offline methods address this through ideas such as pessimistic value estimates, restricting how far the policy departs from the data, or learning advantage-weighted imitation. The appropriate constraint depends on whether the dataset includes diverse successful behavior, recoveries, or mainly failures.

Coverage is a physical question

Ask which states and actions your dataset contains. A hundred successful demonstrations from one initial pose may cover less useful variation than a smaller set spanning different poses and recoveries. More frames do not necessarily mean more independent experience.

If a dataset has only expert actions and no usable rewards, behavior cloning may be the clearer starting point. Offline RL needs a defensible reward or outcome signal and sufficient transition information. Reconstructing a reward after collection can introduce label noise.

Practical distinctions

Offline RL improves reward using fixed logged transitions. Off-policy online RL learns from a replay buffer but can still collect new experience. Offline evaluation estimates deployment performance from logs; it is a separate problem and can be unreliable when the candidate policy differs greatly from the logging policy.

Exercise: your data contains only slow movements near the center of the workspace. A learned Q-function predicts very high return for fast movements at the edge. Is that evidence the fast policy works?

Connection: 06 Imitation and Distribution Shift explains the related distribution mismatch for imitation. For deeper primary reading, see Conservative Q-Learning and Implicit Q-Learning; these are further-reading links, not claims of implementation or replication here.