Model-Based RL

2025년에 진행한 CS224R 강의 중 Lecture 11. Model-Based RL에 대한 강의 요약
Lecture
CS224R
저자
소속
공개

2026년 3월 24일

강의 및 자료

Lecture Summary with NotebookLM

Recap

지금까지 다룬 강화학습 강의 요약을 통해서 다양한 알고리즘들을 살펴보았다.

그림 1: Model-Free RL

먼저 블로그에선 다루지 않았지만, 현재 학습중인 policy가 경험한 trajectory들을 활용하여 policy를 update하는 On-Policy RL에 대해서 소개하였고, 이때 가장 기본적인 Policy Gradient인 REINFORCE(Williams (1992)) 에 대해서 다뤘다. 물론 학습중인 policy를 직접적으로 학습하면, interaction에 따른 feedback을 바로 반영할 수 있기 때문에 학습 효율성은 좋겠지만, 그만큼 데이터를 많이 활용할 수 없는 Data Inefficiency 문제가 존재한다. 반면, 다음으로 소개된 Off-Policy RL에서는 학습중인 policy가 아니더라도, 과거의 다른 정책들이 쌓았던 경험을 바탕으로 policy를 update할 수 있게 되었고, 해당 강의에서 처음 소개한 내용이 Off-Policy Actor-Critic 기법인 PPO (Schulman 기타 (2017)) 이었다. Off-Policy RL에서는 기본적으로 학습하는 policy와 분리된 Behavior Policy, 즉 경험을 수집하는 policy가 따로 존재하기 때문에, 수집된 분포의 경향에 따라 Weight를 다르게 부여하는 Importance Sampling 같은 기법도 소개했었다. 소개된 두 기법은 샘플링된 trajectory에 대해서 여러번 gradient step을 밟아 update하는 형태로 되어 있다. 이어서 설명된 Q-Learning 강의에서는 Actor-Critic 방식에서 Action을 취하는 Actor를 빼고, 현재 state에 대한 가치를 최대화하는 방향으로 policy를 정의하는 DQN (Mnih 기타 (2013)) 나 SAC (Haarnoja 기타 (2018)) 을 소개했었다. 이 두 방법에서는 Replay Buffer를 사용해서 과거에 수집된 trajectory를 활용함으로써 Data Efficiency를 높인 사례로 소개되었다.

앞에서 소개한 알고리즘들이 환경과의 실시간 interaction이 전제가 된 Online RL이었고, 이어진 강의에서는 이런 전제없이 static dataset을 기반으로 policy learning이 이뤄지는 Offline RL에 대해서 설명했다. 여러번 강의에서도 설명되었던 내용이지만 Offline RL에서 발생할 수 있는 가장 큰 문제는 dataset에 없는 action, 즉 Out-of-Distribution Action을 통해서 Q-value를 추정함으로서 발생하는 overestimation이었고, 이를 완화하기 위해서 아예 dataset에 없는 Action을 취하지 않게 하거나(AWR (Peng 기타 (2019)), AWAC (Nair 기타 (2020)), IQL (Kostrikov, Nair, 와/과 Levine (2021))), 아니면 Q-value를 비관적으로 추정해서 Overestimation에 빠지지 않게 하는 방법 (CQL (Kumar 기타 (2020))) 들이 제안되었다. 물론 이렇게 강화학습처럼 학습하는 것이 아니라, expert data를 바탕으로 지도학습 방식으로 학습한 경우도 존재한다. 해당 내용은 강의 첫 주제였던 Imitation Learning에서 다뤄졌으며, offline 데이터만으로 학습하는 기본적인 Behavior Cloning과, online demonstration으로 Imitation Learning을 수행하는 DAgger (Ross, Gordon, 와/과 Bagnell (2011)) 에 대해서 소개했다.

지금까지 Policy Gradient, Actor-Critic, Q-Learning, Offline RL 등 다양한 terminology가 등장했는데, 지금까지 다룬 알고리즘은 모두 환경에 대한 정보를 dataset으로든, 환경과의 interaction을 통해서 policy를 학습하는 방식이다. 한마디로 “환경에 대한 사전 정보가 없는 상태”에서 탐색을 통해서 경험을 쌓고, 이를 기반으로 policy update하는 방식이었다. 그런데 사람이 경험 기반으로 학습할때를 상상해보면, 실제로 환경에서 경험한 것도 있겠지만, 혼자서 머리속으로 가상으로 상상

참고문헌

Haarnoja, Tuomas, Aurick Zhou, Pieter Abbeel, 와/과 Sergey Levine. 2018. “Soft actor-critic: Off-policy maximum entropy deep reinforcement learning with a stochastic actor”. In International conference on machine learning, 1861–70. Pmlr.
Kostrikov, Ilya, Ashvin Nair, 와/과 Sergey Levine. 2021. “Offline reinforcement learning with implicit q-learning”. arXiv preprint arXiv:2110.06169.
Kumar, Aviral, Aurick Zhou, George Tucker, 와/과 Sergey Levine. 2020. “Conservative q-learning for offline reinforcement learning”. Advances in neural information processing systems 33: 1179–91.
Mnih, Volodymyr, Koray Kavukcuoglu, David Silver, Alex Graves, Ioannis Antonoglou, Daan Wierstra, 와/과 Martin Riedmiller. 2013. “Playing atari with deep reinforcement learning”. arXiv preprint arXiv:1312.5602.
Nair, Ashvin, Abhishek Gupta, Murtaza Dalal, 와/과 Sergey Levine. 2020. “Awac: Accelerating online reinforcement learning with offline datasets”. arXiv preprint arXiv:2006.09359.
Peng, Xue Bin, Aviral Kumar, Grace Zhang, 와/과 Sergey Levine. 2019. “Advantage-weighted regression: Simple and scalable off-policy reinforcement learning”. arXiv preprint arXiv:1910.00177.
Ross, Stéphane, Geoffrey Gordon, 와/과 Drew Bagnell. 2011. “A reduction of imitation learning and structured prediction to no-regret online learning”. In Proceedings of the fourteenth international conference on artificial intelligence and statistics, 627–35. JMLR Workshop; Conference Proceedings.
Schulman, John, Filip Wolski, Prafulla Dhariwal, Alec Radford, 와/과 Oleg Klimov. 2017. “Proximal policy optimization algorithms”. arXiv preprint arXiv:1707.06347.
Williams, Ronald J. 1992. “Simple Statistical Gradient-Following Algorithms for Connectionist Reinforcement Learning”. Mach. Learn. 8 (3–4): 229–56. https://doi.org/10.1007/BF00992696.

라이센스