DSSAT Archives

DSSAT - Crop Models and Applications

DSSAT@LISTSERV.UGA.EDU

Options: Use Forum View

Use Monospaced Font
Show Text Part by Default
Show All Mail Headers

Message: [<< First] [< Prev] [Next >] [Last >>]
Topic: [<< First] [< Prev] [Next >] [Last >>]
Author: [<< First] [< Prev] [Next >] [Last >>]

Print Reply
Subject:
From:
Paul Wilkens <[log in to unmask]>
Reply To:
DSSAT - Crop Models and Applications <[log in to unmask]>
Date:
Tue, 18 Jul 2006 07:56:20 -0500
Content-Type:
text/plain
Parts/Attachments:
text/plain (116 lines)
Heidi,

If you look at a typical batch file created by DSSAT v 4.0.2.0, it gives
some hints on how to call the model independent of the shell.  In this
example, the command line to actually run the model has the DSCSM040
model as the primary executable, and the arguments are the rest of the
line, in this case "B D4Batch.dv4".  Lines starting with "!" are
comments and ignored by the model. The D4Batch.dv4 file, as shown below,
runs treatment numbers 1 and 2 in the chickpea experiment ITBP8502.CHX.
To run more treatments, set up your FileX with as many treatments as you
like and put all the treatments in a similar batch file as below.  The
DSCSM040 model will then run all the files/treatments specified in the
batch file sequentially without any keyboard input.

*BATCH
!
! Directory    : C:\DSSAT4\CHICKPEA
! Command Line : C:\DSSAT4\DSCSM040.EXE B D4Batch.DV4
! Crop         : Chickpea
! Experiment   : ITBP8502.CHX
! ExpNo        : 1
! Debug        : C:\DSSAT4\DSCSM040.EXE " B D4Batch.DV4"
!
@FILEX       TRTNO
ITBP8502.CHX     1
ITBP8502.CHX     2

Hope this helps,

PW

Paul Wilkens
Resource Development Division
IFDC
An International Center for Soil Fertility and Agricultural Development
P.O. Box 2040 Muscle Shoals, Alabama 35662

(256) 381-6600 (Tel)
(256) 381-7408 (Fax)
[log in to unmask]

http://www.ifdc.org/

-----Original Message-----
From: DSSAT - Crop Models and Applications
[mailto:[log in to unmask]] On Behalf Of Heidi Webber
Sent: Monday, July 17, 2006 4:14 PM
To: [log in to unmask]
Subject: Re: Change in cultivar file

Hello,

Thank you Gerrit for the clarification on the refresh function in
X-Build.

In trying to generate the cultivar parameters using genetic algorithms,
I am stuck on how to run DSSAT (actually DSCSM040) with the genetic
algorithm (code in C).  While I can open DSCSM040.exe with both System()
and ShellExecute(), I can not pass the needed keystrokes (ENTER,
experiment number, cultivar, etc.) to the executable; it sits waiting
for the keyboard input.  I have also tried using System or ShellExecute
to open a batch file to pass the inputs, but still cannot pass the
keystrokes to DSCSM040.

Are there any command line arguments that could override the input from
the keyboard?  If not, can anyone offer any advice on how to run the
model within the optimization code?

Thanks

Heidi Webber

-----Original Message-----
From: DSSAT - Crop Models and Applications
[mailto:[log in to unmask]] On Behalf Of Gerrit Hoogenboom
Sent: Friday, July 07, 2006 6:40 PM
To: [log in to unmask]
Subject: Re: Change in cultivar file

Heidi,

There is no need to use the refresh button in XBuild when you change
the values of an existing cultivar. You only need to use refresh in
XBuild when you add a new cultivar, a new soil profile or new weather
data to the DSSAT database. Refresh only applies to XBuild's internal
database and it does not affect the operation of the other tools and
programs within DSSAT.

Please keep us informed about your progress with the GA.

Regards,

Gerrit


At 06:24 PM 07/07/2006, you wrote:
>Hello:
>
>I am working with an unknown cultivar of common bean in Uzbekistan and
>would like to use genetic algorithms to select appropriate cultivar
>parameters following much the same approach as in Pabico, Hoogenboom
and
>McClendon (1999).  I am currently working on the code to write the
>output of the genetic algorithm to the cultivar file.  My question is
>whether or not I will need to use the "refresh" function in X-build
with
>each pass of new parameter values to DSSAT?  Or is this only needed
when
>a new cultivar is added (i.e. not changes to an existing cultivar)?
>
>Thanks for any clarifications.
>
>
>
>Heidi Webber

ATOM RSS1 RSS2