finds.dev← search

// the find

Code-Bullet/SnakeFusion

★ 802 · Processing · updated Oct 2020

Using the genetic algorithm and neural networks I trained up 5 snakes who will then fuse to become the ultimate snake, this is how I did it

A Processing sketch that trains snake game agents using a genetic algorithm and neural networks, then merges the five best survivors into a single 'super snake'. It's a weekend project / YouTube companion piece from Code-Bullet, not a library or framework — you run it, watch it learn, and that's the point.

The fusion mechanic is genuinely novel — averaging weights across independently trained networks is a simple but interesting experiment in ensemble neuroevolution. The code is split into clean single-responsibility files (NeuralNet, Population, Snake, SuperSnake) which makes it readable for a Processing project. It ships serialized weights in a CSV so you can pick up training without starting from scratch. Good interactive controls for live experimentation (mutation rate tuning, replaying saved individuals).

Last touched in 2020 and hasn't moved since — it's a finished demo, not maintained software. No documentation on the network architecture, training hyperparameters, or what 'fusing' actually does to the weights, so learning from it requires reading all the code. Processing is a dead-end runtime; there's no path to deploying or extending this outside the Processing IDE. 800 stars almost entirely from the YouTube video — the actual codebase has no tests, no config, and no structure beyond what a tutorial needs.

View on GitHub →

// want more like this?

We dig through GitHub every week and send a few repos picked for what you actually care about — each with an honest take like this one.

Get finds in your inbox → Search again →