Computer Chess Club Archives


Search

Terms

Messages

Subject: Symbolic: Status report 2005.05.16

Author: Steven Edwards

Date: 01:24:07 05/16/05


Symbolic: Status report 2005.05.16

I've been experimenting with the mating attack move suggester GA (Genetic
Algorithm) subproject.  Using the 1,001 position BWTC test suite, my simple
approach was unable to match more than about 75% of the key moves.  This is not
that bad, but it could be better.  One of the difficulties is that a trial
organism is given credit only when its idea of a best move matches a best move
in a test suite position; it should also get some partial credit if, say, its
second or third ranked move matches.  I may fold in this improvement at a later
date.

The gene weights are now integers instead of floating point numbers, and the
standard mutation is either an addition or subtraction of an integer from one to
four to a single gene weight.  This makes the GA run significantly faster
because the ChessLisp interpreter has special storage optimizations for small
integer values (-2028..2048).

The fitness of an organism was given by its total match count against a test
suite.  I have changed this slightly to have a secondary fitness based on
minimizing the sum of the squares of the gene weights.  The intent here is to
promote better selection opportunities by encouraging diversity.

A addition to the GA related to the technique of simulated annealing has been
added.  This process kicks in when a new organism is breed (and slightly mutated
as above) by randomly selecting a gene, creating eight new organisms with
different weights (+/- 1..4) , running all nine organisms against the test
suite, and finally selecting the most fit for possible insertion into the
habitat.  This slows down everything quite a bit, but the overall progress rate
seems to be improved.

Testing of the above addition resulted in a hard-to-reproduce error that
occurred from several minutes to several hours of GA activity.  This was
eventually tracked down to a bug in the ChessLisp interpreter for the "clone"
intrinsic.  It turned out that an intermediate result was not protected from the
automated storage reclamation facility and so was getting trashed on occasion.
The dynamic window for getting trashed was very, very small, so that's why it
took a relatively long time (many hundreds of millions of Lisp evaluations) for
the bug to manifest itself.  The clone problem has been fixed, and the resulting
code has been well tested with no problems.  The assault on BWTC has begun anew
and is running at this moment.

The 14 position Bloss suite has also been used for testing.  Here is an organism
that matches all 14 problems:

Species: SpMAtk   MfSymCount: 20
BirthCycle: 869   MatchCount: 14   SumOfSquares: 35
  Gene: MfAdjCheck   Weight: 0
  Gene: MfAdjDefenderCapture   Weight: -1
  Gene: MfAdjDefenderDecoy   Weight: 0
  Gene: MfCapture   Weight: 0
  Gene: MfCheck   Weight: 1
  Gene: MfDiscoveredCheck   Weight: 1
  Gene: MfDoesMateIn1   Weight: 0
  Gene: MfDoesMateIn2   Weight: 3
  Gene: MfDoubleCheck   Weight: 2
  Gene: MfFlightDecrease   Weight: 0
  Gene: MfFlightIncrease   Weight: 0
  Gene: MfForceCEInterposition   Weight: -1
  Gene: MfForceCEKingNoncapture   Weight: -1
  Gene: MfNoCheck   Weight: 0
  Gene: MfResponseCountEq1   Weight: 3
  Gene: MfResponseCountEq2   Weight: 2
  Gene: MfResponseCountGt4   Weight: -2
  Gene: MfResponseCountLe4   Weight: 0
  Gene: MfThreatenMateIn1   Weight: 0
  Gene: MfThreatenMateIn2   Weight: 0

Note that half of the genes have zero value weights.

--------

More to come.



This page took 0 seconds to execute

Last modified: Thu, 15 Apr 21 08:11:13 -0700

Current Computer Chess Club Forums at Talkchess. This site by Sean Mintz.