Live data from Hacker News

Watch cars evolve using genetic algorithm

rednuht.org

61–70 of 76 posts

Re: Watch cars evolve using genetic algorithm

#63
post #33

It seems to always get into a rut where one design lucks out and dominates generation after generation, with no mutations producing anything even close to working. Like, the top ten don't change after hundreds of generations. Maybe this is just an attribute of genetic algorithms. They quickly zero in on something kind of good, and then get stuck at this local maxima. Or maybe I need to just play around with the Mutat…

Sounds like you're running with a single elite clone. That's a really bad idea in genetic heuristics for exactly the phenomenon you mention.

Is the correct number 0 or >1?

Re: Watch cars evolve using genetic algorithm

#64

It seems to always get into a rut where one design lucks out and dominates generation after generation, with no mutations producing anything even close to working. Like, the top ten don't change after hundreds of generations. Maybe this is just an attribute of genetic algorithms. They quickly zero in on something kind of good, and then get stuck at this local maxima. Or maybe I need to just play around with the Mutat…

This is why I said it needed crossover and got downvoted into oblivion :) turns out it at least tries to have crossover, so maybe the genome doesn't translate to crossover doing anything relevant.

I wasn't fooling. Think about it for a second, if your process involves a lot of crossover that means large sections of working genome will be passed on. If the ONLY mechanism for changing anything is mutation, then mostly you're just breaking what works.

That's what you're describing, so I'd look at how the genome is constructed to understand why it's not doing more.

Re: Watch cars evolve using genetic algorithm

#65
might go much faster if it recorded a set of states where ancestors died shortly after and then test all the new candidates against those states.

The new candidate might actually survive because its prior history kept it from ever getting into that particular death state, but I think biasing towards designs that don't immediately die in those hard cases is good anyways, since given a long enough run it would likely encounter a similar state.

One could co-evolve the test case collection by simulating only the best candidates according to the test cases, and then retaining test cases based on a running score for how well they predicted the actual performance.

Re: Watch cars evolve using genetic algorithm

#66
post #40

It seems to always get into a rut where one design lucks out and dominates generation after generation, with no mutations producing anything even close to working. Like, the top ten don't change after hundreds of generations. Maybe this is just an attribute of genetic algorithms. They quickly zero in on something kind of good, and then get stuck at this local maxima. Or maybe I need to just play around with the Mutat…

>Maybe this is just an attribute of genetic algorithms It happened to crocodiles and it could happen to you too.

Crabs too https://en.m.wikipedia.org/wiki/Carcinisation

Re: Watch cars evolve using genetic algorithm

#70

It seems to always get into a rut where one design lucks out and dominates generation after generation, with no mutations producing anything even close to working. Like, the top ten don't change after hundreds of generations. Maybe this is just an attribute of genetic algorithms. They quickly zero in on something kind of good, and then get stuck at this local maxima. Or maybe I need to just play around with the Mutat…

What happens in an evolutionary algorithm depends on what you write it for. This is a fun toy, but what it does specifically is explore a very limited simulation of evolution by natural selection. Metaheuristics aimed at optimization have a lot of techniques aimed at not stalling out on a prematurely converged design, as well as improving other desirable properties of the population, at the expense of any pretense of fidelity to real-world evolution processes.
Post reply on HN