[ODE] My brainless virtual creatures

lukasz@datafast.net.au lukasz at datafast.net.au
Mon Apr 21 22:26:02 2003


> A genetic algorithm is used to evolve a set of parameters for the
> phase,  offset, and amplitude of sine waves controlling motor velocity
> for each of  the creature’s 4 legs (instead of evolving a neural net,
> which is probably  much better).
Note that you do not have any sensory input as to which legs are touching
the ground. Due to the innacuracies built into ODE to make it run faster, a
nicelly evolved gait could become unstable and fall over, or not even move
forward anymore, if you let it run for a while. I would suggest
incorporating at least one contact point per leg into the walking algorithm.

> The fitness function measures the distance each creature  travels from
> the start point within a set time.
You're measuring the displacement from the origin as the fitness. So a
creature that walks sideways or backwards (or even jumps up or falls down)
further than one that walks forwards would be prefered by the evolutionary
strategy. I would suggest setting a constant forward vector and letting the
fitness equal the scalar projection of the displacement of the creature
onto the forward vector.

> I think I need to re-examine how I have chosen to cross-over
> chromosomes  (single-point cross-over), which ends up just copying some
> legs from one  parent, and some from the other, and trying it again.
This should work fine, since there are approximatelly 30 different gaits
used by quadraped animals on earth. I haven't looked deeply enough into
your Simulation.cpp but you could try introducing mutation if you haven't
already done so.