Skip to content

Instantly share code, notes, and snippets.

@chasset
Last active May 23, 2017
Embed
What would you like to do?
val density = Val[Double]
val seed = Val[Int]
val burned = Val[Double]
val cmds =
List(
"random-seed ${seed}",
"setup",
"while [any? turtles] [go]"
)
val fireTask =
NetLogo6Task(workDirectory / "Fire.nlogo", cmds) set (
inputs += seed,
outputs += (seed, density),
netLogoInputs += (density, "density"),
netLogoOutputs += ("burned-trees", burned)
)
val csvHook = CSVHook(workDirectory / "result.csv", density, burned, seed)
val env = SLURMEnvironment(
login0,
domain0,
port = port0
)
val exploration =
DirectSampling(
evaluation = Replication(fireTask hook csvHook on env, seed, 100),
sampling = density in (20.0 to 80.0 by 1.0)
)
exploration
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment