Check out the javadoc for Evolve.java
The basic Evolve class has a main() loop with a simple job iteration
facility. If you'd like to run the evolutionary system four times, each
with a different random seed, you might do:
java ec.Evolve -file parameter_file -p jobs=4
Here, Evolve will run the first time with the random seed equal to
whatever's specified in your file, then job#2 will be run with the seed +
1, job#3 with the seed + 2, and job#4 with the seed + 3. If you have
multiple seeds, ECJ will try to make sure they're all different even
across jobs by adding the job number * numberOfSeeds to each of them. This
means that if you're doing multiple jobs with multiple seeds, you should
probably set seed.0 to x, seed.1 to x+1, seed.2 to x+2, etc. for best
results. It also works if seed.0 is x, seed.1 is y (a number much bigger
than x), seed.2 is z (a number much bigger than y) etc. If you set
seed.0=time etc. for multiple jobs, the values of each seed will be set to
the current time that the job starts plus the job number * numberOfSeeds.
As current time always goes up, this shouldn't be an issue. However it's
theoretically possible that if you checkpoint and restart on another
system with a clock set back in time, you could get the same seed in a
On Wed, 16 Jan 2008, Loretta Macklem wrote:
> I am working with ECJ and I have made a shell script to do 30 runs in a row.
> I am running into a seeding issue. It is always using the same seed. Is
> there a way to set the seed to use a random number?