LISTSERV mailing list manager LISTSERV 16.0

Help for ECJ-INTEREST-L Archives


ECJ-INTEREST-L Archives

ECJ-INTEREST-L Archives


ECJ-INTEREST-L@LISTSERV.GMU.EDU


View:

Message:

[

First

|

Previous

|

Next

|

Last

]

By Topic:

[

First

|

Previous

|

Next

|

Last

]

By Author:

[

First

|

Previous

|

Next

|

Last

]

Font:

Proportional Font

LISTSERV Archives

LISTSERV Archives

ECJ-INTEREST-L Home

ECJ-INTEREST-L Home

ECJ-INTEREST-L  May 2009

ECJ-INTEREST-L May 2009

Subject:

Re: ADF: tree as argument

From:

Eric B <[log in to unmask]>

Reply-To:

ECJ Evolutionary Computation Toolkit <[log in to unmask]>

Date:

Mon, 4 May 2009 06:02:13 -0400

Content-Type:

text/plain

Parts/Attachments:

Parts/Attachments

text/plain (130 lines)

Hello, I'm sorry to keep bugging you all with this problem however I'd
really appreciate the help. My thesis is pretty much complete but I'd like
to use ADFs, something I wanted to use since day 1 of my thesis, to test
some things.

I have a little problem with ECJ. Can anyone help me?

Thank you.

>I was busy writing parts of my thesis so I couldn't spend time reading your
>response.
>
>Sean, what you write here is exactly what I want:
>>For example, let's say the result branch is the one you listed below.
>>I'll put it in Lisp form:
>>
>> (if xx (adf (if yx yy yz)) xy)
>>
>>When the 'adf' node is called, we first call its subtree (if yx yy yz)
>>and store that in a variable called, say, foo0.  Then ccontrol is
>>transferred to its corresponding ADF tree.  Let's say that tree looks
>>like this:
>>
>>ADF:  (* (sin adfargument0) (+ x 1))
>
>
>This is the kind of ADF Argument I want: a tree. However, none of the
>examples provided with ECJ has an ADF argument that's really (or could be) a
>function instead of a terminal. This can be seen for example for the two-box
>problem:
>gp.fs.1.func.6 = ec.gp.ADFArgument
>gp.fs.1.func.6.arg = 2
>gp.fs.1.func.6.nc = nc0
>
>nc0 means it's a terminal (i.e. a function with 0 arguments = terminal).
>
>So I tried changing the nc0 constraint with a constraint (if-constraint)
>that I also use in the ADF tree and the result producing branch. Simply put,
>this constraint just checks that there are 3 arguments. The first argument
>is pretty much restricted to terminals, the other arguments can be anything.
>I've been working with this constraint for months now. So I can be certain
>that it's well defined.
>
>Here are my parameters, I really don't understand what's wrong with it. I
>first give the uninteresting parts. The parameters that matter are at the end:
># Now, let's define what tc0 and tc1 are.
># Each has a different function set, f0 and f1
>
>gp.tc.size = 2
>
>gp.tc.0 = ec.gp.GPTreeConstraints
>gp.tc.0.name = tc0
>gp.tc.0.fset = f0
>gp.tc.0.returns = void-sort-of
>gp.tc.0.init = ec.gp.koza.HalfBuilder
>gp.tc.0.init.growp = 0.5
>gp.tc.0.init.min = 2
># ==============================
># ==============================
># ==============================
>gp.tc.1 = ec.gp.GPTreeConstraints
>gp.tc.1.name = tc1
>gp.tc.1.fset = f1
>gp.tc.1.returns = void-sort-of
>gp.tc.1.init = ec.gp.koza.HalfBuilder
>gp.tc.1.init.growp = 0.5
>gp.tc.1.init.min = 1
>gp.tc.1.init.max = 3
>
>
>
># Now, let's define the two function sets.
>gp.fs.size = 2
>
># We have 12 functions in the function set.  They are:
>gp.fs.0 = ec.gp.GPFunctionSet
>gp.fs.0.name = f0
>gp.fs.0.info = ec.gp.GPFuncInfo
>gp.fs.0.size = 11
>[...]
>gp.fs.0.func.10 = ec.gp.ADF
># tree 1 (the "ADF0 body"), 1 argument
>gp.fs.0.func.10.nc = if-constraint
>gp.fs.0.func.10.tree = 1
>gp.fs.0.func.10.name = 0
>
>
>
># The "ADF0 body" -- see Koza-II p. 245
>gp.fs.1 = ec.gp.GPFunctionSet
>gp.fs.1.name = f1
>gp.fs.1.info = ec.gp.GPFuncInfo
>gp.fs.1.size = 3
>gp.fs.1.func.0 = ec.app.connect4.functions.If
>gp.fs.1.func.0.nc = if-constraint
>gp.fs.1.func.1 = ec.app.connect4.functions.Win
>gp.fs.1.func.1.nc = nc0
># ARG0
>gp.fs.1.func.2 = ec.gp.ADFArgument
>gp.fs.1.func.2.arg = 0 # Meaning it's the first argument!
>gp.fs.1.func.2.nc = if-constraint
>
>
>
>The error I get when running this:
>Processing GP Function Sets
>ERROR:
>Incorrect number of children for ADF Argument terminal -- should be 0.
>Check the constraints.
>PARAMETER: gp.fs.1.func.2
>     ALSO: gp.adf-argument
>SYSTEM EXITING FROM ERRORS
>
>With gp.fs.1.func.2.nc = nc0 everything works except that the ADF argument
>is a terminal and not a tree!
>
>Don't mind the logic of the ADF, I admit it's simple. I just want to test
>the strength of an ADF to solve a (simple) subtask which is actually what an
>ADF is supposed to do.
>That's why I'd like to limit the depth of the ADF tree (not the depth of the
>argument tree) to say 5.
>gp.tc.1.maxdepth = 5 or gp.tc.1.max-depth = 5 doesn't work. How can I solve
>this little problem?
>
>
>It's a pretty long mail, sorry for that. To resume I ask two things:
>1. How can I have a tree as ADF argument instead of just a terminal?
>2. How can I change the depth of a tree which is set to 17 by default I
believe?
>=========================================================================

Top of Message | Previous Page | Permalink

Advanced Options


Options

Log In

Log In

Get Password

Get Password


Search Archives

Search Archives


Subscribe or Unsubscribe

Subscribe or Unsubscribe


Archives

June 2019
April 2019
March 2019
January 2019
December 2018
November 2018
October 2018
July 2018
May 2018
January 2018
December 2017
November 2017
October 2017
September 2017
August 2017
July 2017
June 2017
May 2017
April 2017
March 2017
February 2017
January 2017
December 2016
November 2016
October 2016
September 2016
August 2016
July 2016
June 2016
May 2016
April 2016
March 2016
February 2016
January 2016
December 2015
November 2015
October 2015
September 2015
August 2015
July 2015
June 2015
May 2015
April 2015
March 2015
February 2015
January 2015
December 2014
November 2014
September 2014
August 2014
July 2014
June 2014
May 2014
April 2014
March 2014
February 2014
January 2014
December 2013
November 2013
October 2013
September 2013
August 2013
July 2013
June 2013
May 2013
April 2013
March 2013
February 2013
January 2013
December 2012
November 2012
October 2012
September 2012
July 2012
June 2012
May 2012
April 2012
March 2012
February 2012
January 2012
December 2011
November 2011
October 2011
September 2011
August 2011
July 2011
June 2011
May 2011
April 2011
March 2011
February 2011
January 2011
December 2010
November 2010
October 2010
September 2010
August 2010
July 2010
June 2010
May 2010
April 2010
March 2010
February 2010
January 2010
December 2009
November 2009
October 2009
September 2009
August 2009
July 2009
June 2009
May 2009
April 2009
March 2009
February 2009
January 2009
December 2008
November 2008
October 2008
September 2008
August 2008
July 2008
June 2008
May 2008
April 2008
March 2008
February 2008
January 2008
December 2007
November 2007
October 2007
September 2007
August 2007
July 2007
June 2007
May 2007
April 2007
March 2007
February 2007
January 2007
December 2006
November 2006
October 2006
September 2006
August 2006
July 2006
June 2006
May 2006
April 2006
March 2006
February 2006
January 2006
December 2005
November 2005
October 2005
September 2005
August 2005
July 2005
June 2005
May 2005
April 2005
March 2005
February 2005
January 2005
December 2004
November 2004
September 2004
August 2004
July 2004
June 2004
May 2004
April 2004
March 2004

ATOM RSS1 RSS2



LISTSERV.GMU.EDU

CataList Email List Search Powered by the LISTSERV Email List Manager