Policy gradients and PPO

Instead of learning values and acting greedily, adjust the policy itself in the direction that raises expected reward. The log-derivative trick makes that gradient computable, baselines make it usable, and PPO's clipped objective makes it safe.

50 min

After this lesson you can

  • Derive the policy gradient with the log-derivative trick, and explain why the environment's dynamics drop out
  • Implement REINFORCE and explain why a baseline reduces variance without adding bias
  • Define the advantage and describe actor–critic methods and GAE
  • Read PPO's clipped surrogate objective and say, case by case, when a sample gets no gradient

In this lesson

  1. The objective and the obstacle
  2. The log-derivative trick
  3. REINFORCE on a bandit, and the variance problem
  4. Reward-to-go, advantage and the critic
  5. Steps that are too big: trust regions and PPO
  6. Where this goes next

This lesson is part of Descent Pro

Descent Pro unlocks every lesson on the route, from base camp to the summit. Every plan starts with a free trial.

Descent Pro

Start your free trial to keep reading

This lesson, and every other lesson on the route, is part of Descent Pro. Every plan starts with a free trial, and students with a .edu email get longer. Cancel before the trial ends and you pay nothing.