TE
TechEcho
Home24h TopNewestBestAskShowJobs
GitHubTwitter
Home

TechEcho

A tech news platform built with Next.js, providing global tech news and discussions.

GitHubTwitter

Home

HomeNewestBestAskShowJobs

Resources

HackerNews APIOriginal HackerNewsNext.js

© 2025 TechEcho. All rights reserved.

Genetic Algorithm 2D Car Thingy

162 pointsby sconxuover 9 years ago

12 comments

ColinWrightover 9 years ago
This is brilliantly cool, and utterly hypnotic. I still always wonder about implementations of genetic algorithms, though. In real life, from which inspiration has been taken, the phenotype is often radically affected by small changes in the genotype. In computer implementation of the concept this is rarely the case. The computer versions are small, clean, spare, and nowhere near as messy as the real life version.<p>I wonder if the messiness actually matters. I wonder if &quot;optimization by genetic algorithm&quot; would be significantly improved by using a more faithful algorithm.<p>========<p>Anyway, here&#x27;s a previous discussion of this particular toy:<p><a href="https:&#x2F;&#x2F;news.ycombinator.com&#x2F;item?id=5942757" rel="nofollow">https:&#x2F;&#x2F;news.ycombinator.com&#x2F;item?id=5942757</a> (169 comments)<p>Other submissions:<p><a href="https:&#x2F;&#x2F;news.ycombinator.com&#x2F;item?id=10596079" rel="nofollow">https:&#x2F;&#x2F;news.ycombinator.com&#x2F;item?id=10596079</a><p><a href="https:&#x2F;&#x2F;news.ycombinator.com&#x2F;item?id=10134390" rel="nofollow">https:&#x2F;&#x2F;news.ycombinator.com&#x2F;item?id=10134390</a><p><a href="https:&#x2F;&#x2F;news.ycombinator.com&#x2F;item?id=5952145" rel="nofollow">https:&#x2F;&#x2F;news.ycombinator.com&#x2F;item?id=5952145</a><p><a href="https:&#x2F;&#x2F;news.ycombinator.com&#x2F;item?id=2226137" rel="nofollow">https:&#x2F;&#x2F;news.ycombinator.com&#x2F;item?id=2226137</a><p>Also, genetic development of walkers:<p><a href="https:&#x2F;&#x2F;news.ycombinator.com&#x2F;item?id=8911719" rel="nofollow">https:&#x2F;&#x2F;news.ycombinator.com&#x2F;item?id=8911719</a> (74 comments)
评论 #10600708 未加载
评论 #10601364 未加载
评论 #10600934 未加载
评论 #10600863 未加载
sevensorover 9 years ago
This is a very beautiful illustration of a woefully outdated algorithm. Its proportional selection operator was superseded in 1994 (at the latest) when Bäck published his comparison of selection operators. Its approach to crossover looks like an ad-hoc extension of binary crossover, which Deb improved on in the same year. It&#x27;s using uniform mutation, although better options have been demonstrated by Evolution Strategies since the &#x27;70s, if not earlier.<p>But it&#x27;s really fun to watch. I&#x27;ll give it that.
评论 #10601365 未加载
评论 #10600887 未加载
评论 #10601446 未加载
评论 #10601524 未加载
评论 #10601048 未加载
pjs_over 9 years ago
Here&#x27;s my version from a decade ago:<p><a href="http:&#x2F;&#x2F;peteshadbolt.co.uk&#x2F;ga&#x2F;" rel="nofollow">http:&#x2F;&#x2F;peteshadbolt.co.uk&#x2F;ga&#x2F;</a><p>It&#x27;s so old that it&#x27;s written in Flash! One of these days I will port it to canvas, I swear...
评论 #10601827 未加载
评论 #10603870 未加载
bentpinsover 9 years ago
It&#x27;s a little dead, but there&#x27;s a few more similar natural selection simulators over at <a href="https:&#x2F;&#x2F;www.reddit.com&#x2F;r&#x2F;NSIP&#x2F;top&#x2F;?sort=top&amp;t=all" rel="nofollow">https:&#x2F;&#x2F;www.reddit.com&#x2F;r&#x2F;NSIP&#x2F;top&#x2F;?sort=top&amp;t=all</a>
IanDrakeover 9 years ago
It would be cool if someone added a car designer to this. I wonder if I could design a car based on intuition that would perform better than the algo could generate.
评论 #10602533 未加载
shostackover 9 years ago
Would be cool to display the current world seed somewhere if it isn&#x27;t explicitly entered.<p>I was going to paste an example track I came across that seemed literally impossible to conquer within the constraints of the mutations, but I can&#x27;t grab the seed.<p>In any event, would love more depth to the mutations. Longer&#x2F;taller cars, etc. Maybe even other things like randomly firing after burners, wings to let it glide, etc.<p>Nice work!
sanoliover 9 years ago
I keep looking for the version of this simulator where <i>you</i> get to draw your own car, and then you run it and see how well it handles the terrain. played with it many years ago, never found it again. maybe someone here can help?
542458over 9 years ago
Bizarrely, I seem to get much better performance in safari than in chrome with this, which runs contrary to my expectations. I wonder why that is.
nmcover 9 years ago
OP, please append &quot;(2012)&quot; to the title.
ixtliover 9 years ago
So how long do I have to leave it running before the cars create art or try to figure out who I am?
raldiover 9 years ago
What does &quot;Floor: [fixed &#x2F; mutable]&quot; mean?
评论 #10601917 未加载
scottmcdotover 9 years ago
Does the best one look like a Strandbeest?