3d simulation

Carl Banks invalidemail at aerojockey.com
Thu Jul 13 23:27:38 EDT 2006


Edmond Dantes wrote:
> I would tend to think that Lisp is more suited for Genetic Programming than
> Python is. However, it is possible to do. Heck, I even had the crazy idea
> of doing Genetic Programming in C++ once, however ugly that would've
> been!!!!!
>
> Actually, there is an AI project that I'm doing in Python rather than Lisp
> because Python is much better supported. A pity, really, since Lisp has so
> much more power and expressiveness. Alas, Python has extensive libraries
> and are well documented to boot. Only an academic would have the time to do
> anything with Lisp. :-(

I'm not sure how important expressiveness is for GP.  The number of
operations on programs you have to support is quite small
(recombination, mutation, duplication, anything else?), and any
advantage LISP has in handling the tree structures is probably not all
that important.

Of course, the big advantage of LISP is the data/code equivalence.  In
LISP, you can just eval the programs, whereas in Python you have to
expend quite a bit of effort running them.  And that's no small thing.
It's not too bad, though.  I've done GP in Python myself, and I it was
pretty straightforward to convert the program trees into expressions
(to be evaled in Python, or compiled and executed in C or Fortran).

But there's really no question that genetic programming is a problem
tailor-made for LISP.


Carl Banks




More information about the Python-list mailing list