About the book

Robot with transparent background A Field Guide to Genetic Programming (ISBN 978-1-4092-0073-4) is an introduction to genetic programming (GP). GP is a systematic, domain-independent method for getting computers to solve problems automatically starting from a high-level statement of what needs to be done. Using ideas from natural evolution, GP starts from an ooze of random computer programs, and progressively refines them through processes of mutation and sexual recombination, until solutions emerge. All this without the user having to know or specify the form or structure of solutions in advance. GP has generated a plethora of human-competitive results and applications, including novel scientific discoveries and patentable inventions.

The book is freely downloadable under a Creative Commons license as a PDF and low cost printed copies can be purchased from lulu.com. This web site will be used for information relating to the book, and other pertinent announcements. We also have a discussion group for questions and conversation related to the book.

Tuesday 6 May 2008

Bug in TinyGP Java Code

Sander Land found a bug in the constructor "tiny_gp" of the TinyGP system described in appendix B: the "x" array is initialized (lines 345-346) after the population is (line 344), causing invalid fitness evaluations during the initialization of the population, thereby wasting the first generation. The mistakes has been fixed in the code available here. Many thanks Sander (and apologies to all users).


rosanny said...

i've tried the new code. and i'm having problem with GENERATIONS variable.

i can't change the value of the variable easily, while in the old code it can be done easily.

for example, i want to use 200 generations (so i change the value of variable to 200, from default GENERATIONS = 100), and then the result shows that there's only 100 generations (default value)

Riccardo Poli said...

Hi Sanny, I'm not sure I understand your point. As explained in the original post, the bug fix involved simply moving one line down a couple of lines. The GENERATIONS variable wasn't affected. So, I suspect you did not recompile the java code after you made your change. I hope this helps. -- Riccardo