Master Reinforcement Learning: Teach an AI to Play Snake with Python, PyTorch, & Pygame ๐ฎ
Learn how to build and train an AI to master Snake using Python, PyTorch, and Pygame. Step-by-step guide to create your own intelligent game player from scratch!

freeCodeCamp.org
468.7K views โข Apr 25, 2022

About this video
In this Python Reinforcement Learning course you will learn how to teach an AI to play Snake! We build everything from scratch using Pygame and PyTorch.
๐ป Code: https://github.com/python-engineer/snake-ai-pytorch
โ๏ธ Course developed by Python Engineer. Check out his YouTube channel: https://www.youtube.com/channel/UCbXgNpp0jedKWcQiULLbDTA
๐จ Art by Rachel: http://rachel.likespizza.com/
โค๏ธ Try interactive Python courses we love, right in your browser: https://scrimba.com/freeCodeCamp-Python (Made possible by a grant from our friends at Scrimba)
โญ๏ธ Course Contents โญ๏ธ
โจ๏ธ (0:00:00) Part 1: Basics of Reinforcement Learning and Deep Q Learning
โจ๏ธ (0:17:22) Part 2: Setup environment and implement snake game
โจ๏ธ (0:40:07) Part 3: Implement agent to control game
โจ๏ธ (1:10:59) Part 4: Create and train neural network
๐ Thanks to our Champion and Sponsor supporters:
๐พ Raymond Odero
๐พ Agustรญn Kussrow
๐พ aldo ferretti
๐พ Otis Morgan
๐พ DeezMaster
--
Learn to code for free and get a developer job: https://www.freecodecamp.org
Read hundreds of articles on programming: https://freecodecamp.org/news
๐ป Code: https://github.com/python-engineer/snake-ai-pytorch
โ๏ธ Course developed by Python Engineer. Check out his YouTube channel: https://www.youtube.com/channel/UCbXgNpp0jedKWcQiULLbDTA
๐จ Art by Rachel: http://rachel.likespizza.com/
โค๏ธ Try interactive Python courses we love, right in your browser: https://scrimba.com/freeCodeCamp-Python (Made possible by a grant from our friends at Scrimba)
โญ๏ธ Course Contents โญ๏ธ
โจ๏ธ (0:00:00) Part 1: Basics of Reinforcement Learning and Deep Q Learning
โจ๏ธ (0:17:22) Part 2: Setup environment and implement snake game
โจ๏ธ (0:40:07) Part 3: Implement agent to control game
โจ๏ธ (1:10:59) Part 4: Create and train neural network
๐ Thanks to our Champion and Sponsor supporters:
๐พ Raymond Odero
๐พ Agustรญn Kussrow
๐พ aldo ferretti
๐พ Otis Morgan
๐พ DeezMaster
--
Learn to code for free and get a developer job: https://www.freecodecamp.org
Read hundreds of articles on programming: https://freecodecamp.org/news
Video Information
Views
468.7K
Likes
11.2K
Duration
01:38:34
Published
Apr 25, 2022
User Reviews
4.8
(93)