Building self evolving video game AI in Python
summary
Builds an imitation AI that uses two hours of gameplay and a hierarchical random forest to predict human actions on the Pygame title LaserCat (handles structural missing objects explicitly), then implements a self‑evolving agent via a Q‑learning variant (Bayesian Q‑learning) using a moving grid (mobile-to coding) centered on the current target to discretize continuous state space. The pipeline runs at ~50 frames/sec, converges to near‑optimal play in hours, and the self‑evolving agent achieves super‑human performance.
AI-written summary · about
chapters (17)
- 0:00Self-evolving game AI intro
- 1:05Video games for AI testing
- 3:08Laser Cat mechanics
- 4:30Imitation learning AI
- 8:31From imitation to self-evolving
- 9:13Reinforcement learning basics
- 14:10Value functions and rewards
- 17:27Q-learning for policy
- 21:16Continuous states handling
- 23:26Discretizing states
- 27:20AI techniques recap
- 29:05Q&A: Policy insights
- 31:33Q&A: Game complexity
- 32:59Q&A: Bayesian vs classical Q-learning
- 35:49Q&A: Dimensionality handling
- 36:32Q&A: Algorithm convergence
- 37:34Q&A: Emergent strategies
related talks
02mDesigning a Video Game AI
46mAI Takeover
01h 47mGamified Reinforcement Learning: Mastering AI through Video Games
56mCan I do AI?
01h 01mReinforcement Learning: Pac-Man
54mTeaching a Computer to Fight Itself (Implementing an OGRE AI)
35mHow I Built an AI to Beat the 1990s Arcade Game Double Dragon
32mAI and Minecraft
