Skip to content
Merged
Changes from 1 commit
Commits
Show all changes
26 commits
Select commit Hold shift + click to select a range
728456c
Fix: Auto-increment seed across batch_run iterations
EwoutH Oct 7, 2025
c03c6fa
[pre-commit.ci] auto fixes from pre-commit.com hooks
pre-commit-ci[bot] Oct 7, 2025
37a0839
Merge remote-tracking branch 'upstream/main' into batch_seed
quaquel Nov 12, 2025
7f456af
add rng as kwarg and deprecate iterations
quaquel Nov 12, 2025
10136f9
[pre-commit.ci] auto fixes from pre-commit.com hooks
pre-commit-ci[bot] Nov 12, 2025
904e796
fix for typo in value error message
quaquel Nov 12, 2025
7972638
Update batchrunner.py
quaquel Nov 12, 2025
529f3ac
Update migration_guide.md
quaquel Nov 16, 2025
7b6eaef
Update migration_guide.md
quaquel Nov 16, 2025
e53e16b
Update migration_guide.md
quaquel Nov 16, 2025
4113a11
Update 9_batch_run.ipynb
quaquel Nov 16, 2025
94c44e3
add support for both seed and rng
quaquel Nov 16, 2025
0778ff4
Update migration_guide.md
quaquel Nov 16, 2025
5db0058
[pre-commit.ci] auto fixes from pre-commit.com hooks
pre-commit-ci[bot] Nov 16, 2025
27a777d
Update test_batch_run.py
quaquel Nov 17, 2025
0a4ea99
Update test_batch_run.py
quaquel Nov 17, 2025
4726920
Update docs/migration_guide.md
quaquel Nov 17, 2025
7ba67df
Update mesa/batchrunner.py
quaquel Nov 17, 2025
088425a
Update mesa/batchrunner.py
quaquel Nov 17, 2025
435399c
Update batchrunner.py
quaquel Nov 17, 2025
f5b017a
Merge branch 'main' into batch_seed
quaquel Nov 25, 2025
f0167e6
remove forced newlines from migration guide
EwoutH Nov 26, 2025
f2007e3
Merge remote-tracking branch 'upstream/main' into batch_seed
quaquel Dec 5, 2025
9341cce
Update batchrunner.py
quaquel Dec 5, 2025
4ebe7d8
Update test_batch_run.py
quaquel Dec 5, 2025
8b338a9
Update test_batch_run.py
quaquel Dec 5, 2025
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Prev Previous commit
Next Next commit
Update migration_guide.md
  • Loading branch information
quaquel committed Nov 16, 2025
commit 529f3acfeaa1604c0462e25a747eee4dea52091b
32 changes: 32 additions & 0 deletions docs/migration_guide.md
Original file line number Diff line number Diff line change
Expand Up @@ -3,6 +3,38 @@ This guide contains breaking changes between major Mesa versions and how to reso

Non-breaking changes aren't included, for those see our [Release history](https://github.com/projectmesa/mesa/releases).

## Mesa 3.4.0

### batch run
`batch_run` has been updated to offer explicit control over the random seeds that are used to run
multiple replications of a given experiment. For this a new keyword argument, `rng` has been
added and `iterations` will issue a `DeprecatinWarning`. The new `rng` keyword argument
takes a valid value for seeding or a list of valid values. If you want to run multiple iterations/replications
of a given experiment, you need to pass the required seeds explicitly.

Below is a simple example of the new recommeded usage of `batch_run`. Note how we first
create 5 random integers which we then use as seed values for the new `rng` keyword argument.

```python
import numpy as np
import sys

rng = np.random.default_rng(42)
rng_values = rng.integers(0, sys.maxsize, size=(5,))

results = mesa.batch_run(
MoneyModel,
parameters=params,
rng=rng_values,
max_steps=100,
number_processes=1,
data_collection_period=1,
display_progress=True,
)


```

## Mesa 3.3.0

Mesa 3.3.0 is a visualization upgrade introducing a new and improved API, full support for both `altair` and `matplotlib` backends, and resolving several recurring issues from previous versions.
Expand Down