Published On Oct 4, 2023
🎬 Coding Quests Episode 1: Implementing the NEAT Algorithm from scrach in C++ 🎬
🔍 What's this video about?
I was reading a lot about genetics lately, so I got inspired to write code on that topic. I actually wanted to build a simulation with creatures that are evolving over time because I saw multiple videos on that topic and they looked fun. However, I ended up implementing the NEAT algorithm because I was very curious how it works in detail.
I also trained 2D snake AI and I got some surprising results that I'd like to share. For the end, I played a bit with "genetic engineering".
Full source code is available for Patreon supporters: / source-code-neat-91016984
Official NEAT whitepaper: https://nn.cs.utexas.edu/downloads/pa...
🚀 If you found this video helpful, don't forget to like, share, and subscribe for more tech tutorials!
🔗 If you enjoy this video, please like, share, and subscribe!
🌐 SiteGround: the hosting solution I like (affiliate link): https://www.siteground.com/index.htm?...
🔗 Connect with me:
Support me on patreon: / techwithnikola
Join my discord: / discord
Visit my blog: https://techwithnikola.com
Follow me on Instagram: / techwithnikola
Follow me on Twitter: / techwithnikola
Timecodes
00:00 Intro
00:56 Neural Networks
03:43 Genetic Algorithms
05:46 NEAT genotype and phenotype
06:18 NEAT Crossover + impl
08:35 NEAT Mutations + impl
11:16 NEAT implementation
15:32 Snake Engine
16:33 Snake UI
19:19 Fitness Function
20:33 Training (food)
20:59 Training (wall)
22:18 Training (snake body)
23:33 NEAT Species
25:44 Genetic Engineering
27:52 Outro