25 ms·
This doesn't look like a good framework for GAs. It assumes that the best solution to a given problem is explicitly provided but if it is, then there's no point
by jakubw 15y ago
This doesn't look like a good framework for GAs. It assumes that the best solution to a given problem is explicitly provided but if it is, then there's no point in running a GA any more. A good framework would only represent the genetic data in the form of a binary string but evaluate the fitness using an external function that actually extracts meaningful information from the string. Shameless plug: here's an example I wrote in Coffee: https://github.com/fawek/distributed-monalisa-evolution/tree/master/vries https://github.com/fawek/distributed-monalisa-evolution/tree.... It also makes it somewhat easy to distribute the evolution to multiple populations which can reside in different processes or machines.
Another problem with GAs that model individuals as arbitrary binary strings is that they unnecessarily create a lot of invalid strings that don't correspond to the solution space of a given problem. Sometimes it's easy to convert the solution space to the entire sequence range of 0 and 1s but sometimes it's not.
- leejw00t354 15y agoI agree and thank you for comment, but I wanted to keep it as simple as possible so readers can understand the basic logic and structure behind a GA it. If I started talking about more complex ways to represent different search spaces while calculating the fitness in a more abstract way it would probably lead to confusion for beginners.