www.gp-field-guide.org.uk
Contents Top Previous Next

A.4 GP Implementations

One of the reasons behind the success of GP is that it is easy to implement own versions, and implementing a simple GP system from scratch remains an excellent way to make sure one really understands the mechanics of GP. In addition to being an exceptionally useful exercise, it is often easier to customise (e.g., adding new, application specific genetic operators or implementing unusual, knowledge-based initialisation strategies) a system one has built for new purposes than a large GP distribution. All of this, however, requires reasonable programming skills and the will to thoroughly test the resulting system until it behaves as expected.

This is actually an extremely tricky issue in highly stochastic systems such as GP, as we discussed in Section  13.1 . The problem is that almost any system will produce "interesting" behaviour, but it is typically very hard to test whether it is exhibiting the correct interesting behaviour. It is remarkably easy for small mistakes to go unnoticed for extended periods of time (even years).2 It is also easy to incorrectly assume that "minor" implementation decisions will not significantly affect the behaviour of the system (see Section  13.4 ).

An alternative is to use one of the many public domain GP implementations and adapt this for one's purposes. This process is faster, and good implementations are often robust, efficient, well documented and comprehensive. The small price to pay is the need to study the available documentation and examples. These often explain how to modify the GP system to some extent. However, deeper modifications (such as the introduction of new or unusual operators) will often require studying the actual source code and a substantial amount of trial and error. Good publicly available GP implementations include: Lil-GP (Punch and Zongker1998), ECJ (Luke, Panait, Balan, Paus, Skolicki, Popovici, Harrison, Bassett, Hubley, and Chircop2000-2007), Open Beagle (Gagné and Parizeau2002) and GPC++ (Fraser and Weinbrenner1993-1997). The most prominent commercial implementation remains Discipulus (RML Technologies1998-2007); see (Foster2001) for a review. A number of older unsupported tools can be found at ftp://cs.ucl.ac.uk/genetic/ftp.io.com/.

While the earliest GP systems were implemented in Lisp, people have since coded GP in a huge range of different languages, including C/C++, Java (see an example in Appendix  B ), JavaScript, Perl, Prolog, Mathematica, Pop-11, MATLAB, Fortran, Occam and Haskell. Typically, these evolve expressions and programs which look like simplified Lisp. More complex target languages can be supported, however, especially with the use of more advanced tools such as grammars and type systems (see Chapter  6 ). Conversely, many successful programs in machine code or low-level languages have also climbed from the primordial ooze of initial randomness.


www.gp-field-guide.org.uk
Contents Top Previous Next