I'd like to use Repast Simphony's batch runner in headless mode using an unrolled parameter file to avoid using a nxn experiment setup. I have managed to create a jar using the console and the parameter file, but cannot find a way to actually launch the model jar that was created, since the -run option does not appear to be valid when using custom unrolled parameter files.
Does anyone have some advice on how to proceed there?
Currently, there's no way to use a custom upf and have simphony chunk the upf and distribute and run those chunks on different hosts. You can use the -u / --upf
arguments to include your custom upf in the payload and then run that on an HPC system via the slurm or PBS scheduler. There's instructions for that in the batch runs getting started doc.
Those HPC runs use a script that runs some chunk of the upf file individually. That might be a useful workaround here for you.
sed -n "$begin","$end"p "$paramFile" > localParamFile.txt
mkdir $instanceDir
cd $instanceDir
java -Xmx512m -cp "../lib/*" repast.simphony.batch.InstanceRunner \
-pxml ../scenario.rs/batch_params.xml \
-scenario ../scenario.rs \
-id $instance \
-pinput localParamFile.txt
The idea here is that sed
is used to chunk the upf file beginning at line $begin and ending at line $end and write that into localParamFile.txt
. Then the InstanceRunner
is started and that iterates over each line in that file and performs a model run using each line as input.
You could adapt this and manually chunk your custom file and then run the InstanceRunner.