model = MoneyModel(50, 10, 10, seed=0)
fixed_params = { "width": 10, "height": 10, "seed": 0, # change this according to your needs } variable_params = {"N": range(10, 500, 10)} # The variables parameters will be invoke along with the fixed parameters allowing for either or both to be honored. batch_run = BatchRunner( MoneyModel, variable_params, fixed_params, iterations=5, max_steps=100, model_reporters={"Gini": compute_gini} ) batch_run.run_all()
--
Project repos: github.com/projectmesa
---
You received this message because you are subscribed to the Google Groups "ProjectMesa" group.
To unsubscribe from this group and stop receiving emails from it, send an email to projectmesa...@googlegroups.com.
To view this discussion on the web visit https://groups.google.com/d/msgid/projectmesa/7b705c4b-e332-4fff-96ab-c7192f3614d4n%40googlegroups.com.
parameter_sweep = {'scenario': range(0, 9), 'seed': ['1234567', '123']}
num_iterations = 1
...
batch_run = BatchRunner(MyModel, variable_parameters=parameter_sweep,
display_progress=False, iterations=num_iterations, max_steps=num_steps,
agent_reporters=agent_reporter_dict)
def _prepare_report_table
2. In batch run, is it possible to set/control the seeds of the iterations? How?
On 10 Mar 2021, at 11:10, Yilin Huang <huang....@gmail.com> wrote:
Hi Majd,I did something like this:parameter_sweep = {'scenario': range(0, 9), 'seed': ['1234567', '123']}num_iterations = 1
...
batch_run = BatchRunner(MyModel, variable_parameters=parameter_sweep,
display_progress=False, iterations=num_iterations, max_steps=num_steps,
agent_reporters=agent_reporter_dict)With the above, the scenario/seed combinations (set as variable parameters) are actually configured as individual runs. That’s why num_iternations=1.But I got strange results:
<Screenshot 2021-03-10 at 10.48.05.png><Screenshot 2021-03-10 at 10.49.48.png>