Hacker Newsnew | past | comments | ask | show | jobs | submitlogin

I would agree. With a population size of only 20 the algorithm is closer to being hill-climbing with random restart. Crossover can't do much if there isn't a lot of diversity in the population, and a small population can't be very diverse.

But it still worked.



Right, I was thinking it was more of a random walk algorithm: http://en.wikipedia.org/wiki/Random_walk

There was too much randomness in his evolving. When I was evolving agents for my M.S., I used tournament selection (http://en.wikipedia.org/wiki/Tournament_selection) with an 80% crossover rate for the top 2 winners and only a 5% mutation rate on the offspring. I also started off with a population of 500 individuals. This approach seemed to produce much better results.


There was too much randomness in his evolving. When I was evolving agents for my M.S., I used tournament selection (http://en.wikipedia.org/wiki/Tournament_selection) with an 80% crossover rate for the top 2 winners and only a 5% mutation rate on the offspring. I also started off with a population of 500 individuals. This approach seemed to produce much better results.

I don't know about that - with a population size of 500, every generation is very expensive to test, so your runway is a lot shorter.

I set up a test using your parameters, and it seemed to take an average of about 50 generations to evolve "Hello, World". That's a total of 50x500=25000 fitness evaluations (assuming you've cached results properly) to solve the problem. Whereas with a population size of 20, 100% crossover and mutation rates, the average is about 150 gens, for 150x20 = 3000 evaluations, beating your parameter set by a factor of 8.

Which doesn't mean much, other than that this is not such a good problem to use evolutionary methods on.


Yeah, I was taught roulette wheel at university but I think that tournament is a much better way of doing selection.


And ... throwing away the least fit every time can lead you to climb the hill to a local maxima. In this case, the only way to leave a local maxima is to get lucky with a mutation, but if you cull the population randomly with a log probability that more fit parents will be kept, you could reach the goal in fewer generations.

You could even eliminate mutations altogether if you have the proper character in each position in at least one member of the starting population.




Guidelines | FAQ | Lists | API | Security | Legal | Apply to YC | Contact

Search: