Live data from Hacker News

Show HN: Genetic Hello World

github.com

1–10 of 19 posts

Re: Show HN: Genetic Hello World

#2
Up-voting because even though genetic algorithms seem inefficient compared to back-propagation with gradient descent, it still is an elegant optimization heuristic for many classes of practical problems, and often easier to implement compared to NNs if you're trying to apply on a novel domain.

Re: Show HN: Genetic Hello World

#3

Up-voting because even though genetic algorithms seem inefficient compared to back-propagation with gradient descent, it still is an elegant optimization heuristic for many classes of practical problems, and often easier to implement compared to NNs if you're trying to apply on a novel domain.

Very true - I had some time at work and remembered how big genetic algorithms were a couple years ago so I decided to get my feet wet in the subject.

Re: Show HN: Genetic Hello World

#4
post #3

Up-voting because even though genetic algorithms seem inefficient compared to back-propagation with gradient descent, it still is an elegant optimization heuristic for many classes of practical problems, and often easier to implement compared to NNs if you're trying to apply on a novel domain.

Very true - I had some time at work and remembered how big genetic algorithms were a couple years ago so I decided to get my feet wet in the subject.

A common use case is solving design constraints:

https://www.google.com/?q=genetic+algorithm+placement+format...

Re: Show HN: Genetic Hello World

#5
The cost function just looks like difference squared, but I'm not sure how that yields results like this:

  Hglmo,wosmd! (8)
  Gflln* wosle! (9)
  Hello, wosld! (9999)
  Hello, world (9999)
The bottom two seem to be much closer to the desired result, but the top two score lower cost? Seems weird to me. :-/

Re: Show HN: Genetic Hello World

#6

Up-voting because even though genetic algorithms seem inefficient compared to back-propagation with gradient descent, it still is an elegant optimization heuristic for many classes of practical problems, and often easier to implement compared to NNs if you're trying to apply on a novel domain.

>Easier to implement.

I heard about it first while reviewing literature for some of my operations research classes. They were supposedly good heuristics for hard problems like scheduling and facility layouts, but of course I didn't really get in to that for those introductory classes. I wonder if it's really less scary (harder) than I originally thought? I can't seem to find good resources on them online though, as all the moocs and resources are still raving on about machine learning and data science.

Re: Show HN: Genetic Hello World

#7

The cost function just looks like difference squared, but I'm not sure how that yields results like this: Hglmo,wosmd! (8) Gflln* wosle! (9) Hello, wosld! (9999) Hello, world (9999) The bottom two seem to be much closer to the desired result, but the top two score lower cost? Seems weird to me. :-/

Oh, I was splitting the two of the top genes within the pool and giving each other half of their respective genes and inserting it at the bottom which is why the ones that look closer to the goal are at the bottom. I added a sorting feature after the creation of children to fix that!

Re: Show HN: Genetic Hello World

#8

Up-voting because even though genetic algorithms seem inefficient compared to back-propagation with gradient descent, it still is an elegant optimization heuristic for many classes of practical problems, and often easier to implement compared to NNs if you're trying to apply on a novel domain.

GAs are also more relevant to problems that cannot be represented in continuous vector space, i.e. where the problem is symbolic and not real-numbered.
Post reply on HN