Mesa 3.1.0.dev0__tar.gz → 3.1.1__tar.gz
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Potentially problematic release.
This version of Mesa might be problematic. Click here for more details.
- {mesa-3.1.0.dev0 → mesa-3.1.1}/.codespellignore +1 -0
- {mesa-3.1.0.dev0 → mesa-3.1.1}/.github/PULL_REQUEST_TEMPLATE/bug.md +5 -5
- {mesa-3.1.0.dev0 → mesa-3.1.1}/.github/PULL_REQUEST_TEMPLATE/feature.md +5 -5
- {mesa-3.1.0.dev0 → mesa-3.1.1}/.github/workflows/build_lint.yml +1 -1
- {mesa-3.1.0.dev0 → mesa-3.1.1}/.pre-commit-config.yaml +1 -1
- {mesa-3.1.0.dev0 → mesa-3.1.1}/Dockerfile +8 -9
- {mesa-3.1.0.dev0 → mesa-3.1.1}/HISTORY.md +104 -0
- {mesa-3.1.0.dev0 → mesa-3.1.1}/PKG-INFO +1 -1
- {mesa-3.1.0.dev0 → mesa-3.1.1}/codecov.yaml +0 -1
- {mesa-3.1.0.dev0 → mesa-3.1.1}/docker-compose.yml +1 -1
- {mesa-3.1.0.dev0 → mesa-3.1.1}/docs/apis/api_main.md +1 -0
- mesa-3.1.1/docs/apis/mesa_logging.md +7 -0
- {mesa-3.1.0.dev0 → mesa-3.1.1}/docs/getting_started.md +10 -0
- {mesa-3.1.0.dev0 → mesa-3.1.1}/docs/index.md +4 -0
- {mesa-3.1.0.dev0 → mesa-3.1.1}/docs/migration_guide.md +11 -0
- {mesa-3.1.0.dev0 → mesa-3.1.1}/docs/tutorials/MoneyModel.py +6 -5
- {mesa-3.1.0.dev0 → mesa-3.1.1}/docs/tutorials/intro_tutorial.ipynb +108 -114
- {mesa-3.1.0.dev0 → mesa-3.1.1}/docs/tutorials/visualization_tutorial.ipynb +70 -64
- {mesa-3.1.0.dev0 → mesa-3.1.1}/mesa/__init__.py +3 -3
- {mesa-3.1.0.dev0 → mesa-3.1.1}/mesa/agent.py +48 -0
- {mesa-3.1.0.dev0 → mesa-3.1.1}/mesa/batchrunner.py +14 -1
- {mesa-3.1.0.dev0 → mesa-3.1.1}/mesa/datacollection.py +1 -6
- {mesa-3.1.0.dev0 → mesa-3.1.1}/mesa/examples/advanced/epstein_civil_violence/app.py +5 -0
- {mesa-3.1.0.dev0 → mesa-3.1.1}/mesa/examples/advanced/pd_grid/agents.py +2 -1
- {mesa-3.1.0.dev0 → mesa-3.1.1}/mesa/examples/advanced/pd_grid/app.py +5 -0
- {mesa-3.1.0.dev0 → mesa-3.1.1}/mesa/examples/advanced/pd_grid/model.py +3 -5
- {mesa-3.1.0.dev0 → mesa-3.1.1}/mesa/examples/advanced/sugarscape_g1mt/agents.py +12 -65
- {mesa-3.1.0.dev0 → mesa-3.1.1}/mesa/examples/advanced/sugarscape_g1mt/app.py +24 -19
- {mesa-3.1.0.dev0 → mesa-3.1.1}/mesa/examples/advanced/sugarscape_g1mt/model.py +45 -52
- {mesa-3.1.0.dev0 → mesa-3.1.1}/mesa/examples/advanced/wolf_sheep/agents.py +3 -1
- {mesa-3.1.0.dev0 → mesa-3.1.1}/mesa/examples/advanced/wolf_sheep/model.py +17 -16
- {mesa-3.1.0.dev0 → mesa-3.1.1}/mesa/examples/basic/boid_flockers/app.py +5 -0
- {mesa-3.1.0.dev0 → mesa-3.1.1}/mesa/examples/basic/boltzmann_wealth_model/app.py +8 -5
- {mesa-3.1.0.dev0 → mesa-3.1.1}/mesa/examples/basic/boltzmann_wealth_model/st_app.py +1 -1
- {mesa-3.1.0.dev0 → mesa-3.1.1}/mesa/examples/basic/conways_game_of_life/app.py +5 -0
- {mesa-3.1.0.dev0 → mesa-3.1.1}/mesa/examples/basic/conways_game_of_life/st_app.py +2 -2
- {mesa-3.1.0.dev0 → mesa-3.1.1}/mesa/examples/basic/schelling/agents.py +11 -5
- {mesa-3.1.0.dev0 → mesa-3.1.1}/mesa/examples/basic/schelling/app.py +6 -1
- {mesa-3.1.0.dev0 → mesa-3.1.1}/mesa/examples/basic/virus_on_network/app.py +5 -0
- mesa-3.1.1/mesa/experimental/__init__.py +20 -0
- mesa-3.1.1/mesa/experimental/cell_space/__init__.py +50 -0
- {mesa-3.1.0.dev0 → mesa-3.1.1}/mesa/experimental/cell_space/cell.py +22 -37
- {mesa-3.1.0.dev0 → mesa-3.1.1}/mesa/experimental/cell_space/cell_agent.py +12 -1
- {mesa-3.1.0.dev0 → mesa-3.1.1}/mesa/experimental/cell_space/cell_collection.py +18 -3
- {mesa-3.1.0.dev0 → mesa-3.1.1}/mesa/experimental/cell_space/discrete_space.py +15 -64
- {mesa-3.1.0.dev0 → mesa-3.1.1}/mesa/experimental/cell_space/grid.py +74 -4
- {mesa-3.1.0.dev0 → mesa-3.1.1}/mesa/experimental/cell_space/network.py +13 -1
- mesa-3.1.1/mesa/experimental/cell_space/property_layer.py +444 -0
- {mesa-3.1.0.dev0 → mesa-3.1.1}/mesa/experimental/cell_space/voronoi.py +13 -1
- mesa-3.1.1/mesa/experimental/devs/__init__.py +24 -0
- {mesa-3.1.0.dev0 → mesa-3.1.1}/mesa/experimental/devs/eventlist.py +19 -1
- {mesa-3.1.0.dev0 → mesa-3.1.1}/mesa/experimental/devs/simulator.py +24 -8
- mesa-3.1.1/mesa/experimental/mesa_signals/__init__.py +23 -0
- mesa-3.1.1/mesa/experimental/mesa_signals/mesa_signal.py +485 -0
- mesa-3.1.1/mesa/experimental/mesa_signals/observable_collections.py +133 -0
- mesa-3.1.1/mesa/experimental/mesa_signals/signals_util.py +52 -0
- mesa-3.1.1/mesa/mesa_logging.py +190 -0
- {mesa-3.1.0.dev0 → mesa-3.1.1}/mesa/model.py +17 -23
- {mesa-3.1.0.dev0 → mesa-3.1.1}/mesa/visualization/mpl_space_drawing.py +8 -5
- {mesa-3.1.0.dev0 → mesa-3.1.1}/mesa/visualization/solara_viz.py +49 -11
- {mesa-3.1.0.dev0 → mesa-3.1.1}/tests/test_agent.py +24 -0
- {mesa-3.1.0.dev0 → mesa-3.1.1}/tests/test_batch_run.py +31 -0
- {mesa-3.1.0.dev0 → mesa-3.1.1}/tests/test_cell_space.py +271 -59
- {mesa-3.1.0.dev0 → mesa-3.1.1}/tests/test_components_matplotlib.py +1 -1
- mesa-3.1.1/tests/test_mesa_logging.py +47 -0
- mesa-3.1.1/tests/test_mesa_signals.py +290 -0
- {mesa-3.1.0.dev0 → mesa-3.1.1}/tests/test_solara_viz.py +17 -0
- mesa-3.1.0.dev0/mesa/experimental/UserParam.py +0 -67
- mesa-3.1.0.dev0/mesa/experimental/__init__.py +0 -13
- mesa-3.1.0.dev0/mesa/experimental/cell_space/__init__.py +0 -38
- mesa-3.1.0.dev0/mesa/experimental/components/altair.py +0 -81
- mesa-3.1.0.dev0/mesa/experimental/components/matplotlib.py +0 -242
- mesa-3.1.0.dev0/mesa/experimental/devs/__init__.py +0 -6
- mesa-3.1.0.dev0/mesa/experimental/devs/examples/epstein_civil_violence.py +0 -305
- mesa-3.1.0.dev0/mesa/experimental/devs/examples/wolf_sheep.py +0 -250
- mesa-3.1.0.dev0/mesa/experimental/solara_viz.py +0 -453
- {mesa-3.1.0.dev0 → mesa-3.1.1}/.coveragerc +0 -0
- {mesa-3.1.0.dev0 → mesa-3.1.1}/.github/ISSUE_TEMPLATE/bug-report.md +0 -0
- {mesa-3.1.0.dev0 → mesa-3.1.1}/.github/ISSUE_TEMPLATE/config.yml +0 -0
- {mesa-3.1.0.dev0 → mesa-3.1.1}/.github/ISSUE_TEMPLATE/feature-request.md +0 -0
- {mesa-3.1.0.dev0 → mesa-3.1.1}/.github/dependabot.yml +0 -0
- {mesa-3.1.0.dev0 → mesa-3.1.1}/.github/pull_request_template.md +0 -0
- {mesa-3.1.0.dev0 → mesa-3.1.1}/.github/release.yml +0 -0
- {mesa-3.1.0.dev0 → mesa-3.1.1}/.github/workflows/benchmarks.yml +0 -0
- {mesa-3.1.0.dev0 → mesa-3.1.1}/.github/workflows/release.yml +0 -0
- {mesa-3.1.0.dev0 → mesa-3.1.1}/.gitignore +0 -0
- {mesa-3.1.0.dev0 → mesa-3.1.1}/.readthedocs.yml +0 -0
- {mesa-3.1.0.dev0 → mesa-3.1.1}/CITATION.bib +0 -0
- {mesa-3.1.0.dev0 → mesa-3.1.1}/CODE_OF_CONDUCT.md +0 -0
- {mesa-3.1.0.dev0 → mesa-3.1.1}/CONTRIBUTING.md +0 -0
- {mesa-3.1.0.dev0 → mesa-3.1.1}/LICENSE +0 -0
- {mesa-3.1.0.dev0 → mesa-3.1.1}/NOTICE +0 -0
- {mesa-3.1.0.dev0 → mesa-3.1.1}/README.md +0 -0
- {mesa-3.1.0.dev0 → mesa-3.1.1}/benchmarks/compare_timings.py +0 -0
- {mesa-3.1.0.dev0 → mesa-3.1.1}/benchmarks/configurations.py +0 -0
- {mesa-3.1.0.dev0 → mesa-3.1.1}/benchmarks/global_benchmark.py +4 -4
- {mesa-3.1.0.dev0 → mesa-3.1.1}/binder/environment.yml +0 -0
- {mesa-3.1.0.dev0 → mesa-3.1.1}/docs/Makefile +0 -0
- {mesa-3.1.0.dev0 → mesa-3.1.1}/docs/README.md +0 -0
- {mesa-3.1.0.dev0 → mesa-3.1.1}/docs/_static/switcher.json +0 -0
- {mesa-3.1.0.dev0 → mesa-3.1.1}/docs/apis/agent.md +0 -0
- {mesa-3.1.0.dev0 → mesa-3.1.1}/docs/apis/batchrunner.md +0 -0
- {mesa-3.1.0.dev0 → mesa-3.1.1}/docs/apis/datacollection.md +0 -0
- {mesa-3.1.0.dev0 → mesa-3.1.1}/docs/apis/experimental.md +0 -0
- {mesa-3.1.0.dev0 → mesa-3.1.1}/docs/apis/model.md +0 -0
- {mesa-3.1.0.dev0 → mesa-3.1.1}/docs/apis/space.md +0 -0
- {mesa-3.1.0.dev0 → mesa-3.1.1}/docs/apis/visualization.md +0 -0
- {mesa-3.1.0.dev0 → mesa-3.1.1}/docs/best-practices.md +0 -0
- {mesa-3.1.0.dev0 → mesa-3.1.1}/docs/conf.py +0 -0
- {mesa-3.1.0.dev0 → mesa-3.1.1}/docs/example_template.txt +0 -0
- {mesa-3.1.0.dev0 → mesa-3.1.1}/docs/examples_overview_template.txt +0 -0
- {mesa-3.1.0.dev0 → mesa-3.1.1}/docs/images/mesa_logo.ico +0 -0
- {mesa-3.1.0.dev0 → mesa-3.1.1}/docs/images/mesa_logo.png +0 -0
- {mesa-3.1.0.dev0 → mesa-3.1.1}/docs/images/tutorial/br_ginis.png +0 -0
- {mesa-3.1.0.dev0 → mesa-3.1.1}/docs/images/tutorial/dc_endwealth.png +0 -0
- {mesa-3.1.0.dev0 → mesa-3.1.1}/docs/images/tutorial/dc_gini.png +0 -0
- {mesa-3.1.0.dev0 → mesa-3.1.1}/docs/images/tutorial/dc_oneagent.png +0 -0
- {mesa-3.1.0.dev0 → mesa-3.1.1}/docs/images/tutorial/first_hist.png +0 -0
- {mesa-3.1.0.dev0 → mesa-3.1.1}/docs/images/tutorial/multirun_hist.png +0 -0
- {mesa-3.1.0.dev0 → mesa-3.1.1}/docs/images/tutorial/numpy_grid.png +0 -0
- {mesa-3.1.0.dev0 → mesa-3.1.1}/docs/images/tutorial/viz_chart.png +0 -0
- {mesa-3.1.0.dev0 → mesa-3.1.1}/docs/images/tutorial/viz_empty.png +0 -0
- {mesa-3.1.0.dev0 → mesa-3.1.1}/docs/images/tutorial/viz_greycircles.png +0 -0
- {mesa-3.1.0.dev0 → mesa-3.1.1}/docs/images/tutorial/viz_histogram.png +0 -0
- {mesa-3.1.0.dev0 → mesa-3.1.1}/docs/images/tutorial/viz_redcircles.png +0 -0
- {mesa-3.1.0.dev0 → mesa-3.1.1}/docs/images/wolf_sheep.png +0 -0
- {mesa-3.1.0.dev0 → mesa-3.1.1}/docs/make.bat +0 -0
- {mesa-3.1.0.dev0 → mesa-3.1.1}/docs/mesa.md +0 -0
- {mesa-3.1.0.dev0 → mesa-3.1.1}/docs/tutorials/files/viz_chart.png +0 -0
- {mesa-3.1.0.dev0 → mesa-3.1.1}/docs/tutorials/files/viz_empty.png +0 -0
- {mesa-3.1.0.dev0 → mesa-3.1.1}/docs/tutorials/files/viz_greycircles.png +0 -0
- {mesa-3.1.0.dev0 → mesa-3.1.1}/docs/tutorials/files/viz_histogram.png +0 -0
- {mesa-3.1.0.dev0 → mesa-3.1.1}/docs/tutorials/files/viz_redcircles.png +0 -0
- {mesa-3.1.0.dev0 → mesa-3.1.1}/docs/tutorials/files/viz_slider.png +0 -0
- {mesa-3.1.0.dev0 → mesa-3.1.1}/maintenance/fetch_unlabeled_prs.py +0 -0
- {mesa-3.1.0.dev0 → mesa-3.1.1}/mesa/examples/README.md +0 -0
- {mesa-3.1.0.dev0 → mesa-3.1.1}/mesa/examples/__init__.py +2 -2
- {mesa-3.1.0.dev0 → mesa-3.1.1}/mesa/examples/advanced/__init__.py +0 -0
- {mesa-3.1.0.dev0 → mesa-3.1.1}/mesa/examples/advanced/epstein_civil_violence/Epstein Civil Violence.ipynb +0 -0
- {mesa-3.1.0.dev0 → mesa-3.1.1}/mesa/examples/advanced/epstein_civil_violence/Readme.md +0 -0
- {mesa-3.1.0.dev0 → mesa-3.1.1}/mesa/examples/advanced/epstein_civil_violence/__init__.py +0 -0
- {mesa-3.1.0.dev0 → mesa-3.1.1}/mesa/examples/advanced/epstein_civil_violence/agents.py +0 -0
- {mesa-3.1.0.dev0 → mesa-3.1.1}/mesa/examples/advanced/epstein_civil_violence/model.py +0 -0
- {mesa-3.1.0.dev0 → mesa-3.1.1}/mesa/examples/advanced/pd_grid/Readme.md +0 -0
- {mesa-3.1.0.dev0 → mesa-3.1.1}/mesa/examples/advanced/pd_grid/__init__.py +0 -0
- {mesa-3.1.0.dev0 → mesa-3.1.1}/mesa/examples/advanced/pd_grid/analysis.ipynb +0 -0
- {mesa-3.1.0.dev0 → mesa-3.1.1}/mesa/examples/advanced/sugarscape_g1mt/Readme.md +0 -0
- {mesa-3.1.0.dev0 → mesa-3.1.1}/mesa/examples/advanced/sugarscape_g1mt/__init__.py +0 -0
- {mesa-3.1.0.dev0 → mesa-3.1.1}/mesa/examples/advanced/sugarscape_g1mt/sugar-map.txt +0 -0
- {mesa-3.1.0.dev0 → mesa-3.1.1}/mesa/examples/advanced/sugarscape_g1mt/tests.py +0 -0
- {mesa-3.1.0.dev0 → mesa-3.1.1}/mesa/examples/advanced/wolf_sheep/Readme.md +0 -0
- {mesa-3.1.0.dev0 → mesa-3.1.1}/mesa/examples/advanced/wolf_sheep/__init__.py +0 -0
- {mesa-3.1.0.dev0 → mesa-3.1.1}/mesa/examples/advanced/wolf_sheep/app.py +0 -0
- {mesa-3.1.0.dev0 → mesa-3.1.1}/mesa/examples/basic/__init__.py +0 -0
- {mesa-3.1.0.dev0 → mesa-3.1.1}/mesa/examples/basic/boid_flockers/Readme.md +0 -0
- {mesa-3.1.0.dev0 → mesa-3.1.1}/mesa/examples/basic/boid_flockers/__init__.py +0 -0
- {mesa-3.1.0.dev0 → mesa-3.1.1}/mesa/examples/basic/boid_flockers/agents.py +0 -0
- {mesa-3.1.0.dev0 → mesa-3.1.1}/mesa/examples/basic/boid_flockers/model.py +0 -0
- {mesa-3.1.0.dev0 → mesa-3.1.1}/mesa/examples/basic/boltzmann_wealth_model/Readme.md +0 -0
- {mesa-3.1.0.dev0 → mesa-3.1.1}/mesa/examples/basic/boltzmann_wealth_model/__init__.py +0 -0
- {mesa-3.1.0.dev0 → mesa-3.1.1}/mesa/examples/basic/boltzmann_wealth_model/agents.py +0 -0
- {mesa-3.1.0.dev0 → mesa-3.1.1}/mesa/examples/basic/boltzmann_wealth_model/model.py +0 -0
- {mesa-3.1.0.dev0 → mesa-3.1.1}/mesa/examples/basic/conways_game_of_life/Readme.md +0 -0
- {mesa-3.1.0.dev0 → mesa-3.1.1}/mesa/examples/basic/conways_game_of_life/__init__.py +0 -0
- {mesa-3.1.0.dev0 → mesa-3.1.1}/mesa/examples/basic/conways_game_of_life/agents.py +0 -0
- {mesa-3.1.0.dev0 → mesa-3.1.1}/mesa/examples/basic/conways_game_of_life/model.py +0 -0
- {mesa-3.1.0.dev0 → mesa-3.1.1}/mesa/examples/basic/schelling/Readme.md +0 -0
- {mesa-3.1.0.dev0 → mesa-3.1.1}/mesa/examples/basic/schelling/__init__.py +0 -0
- {mesa-3.1.0.dev0 → mesa-3.1.1}/mesa/examples/basic/schelling/analysis.ipynb +0 -0
- {mesa-3.1.0.dev0 → mesa-3.1.1}/mesa/examples/basic/schelling/model.py +0 -0
- {mesa-3.1.0.dev0 → mesa-3.1.1}/mesa/examples/basic/virus_on_network/Readme.md +0 -0
- {mesa-3.1.0.dev0 → mesa-3.1.1}/mesa/examples/basic/virus_on_network/__init__.py +0 -0
- {mesa-3.1.0.dev0 → mesa-3.1.1}/mesa/examples/basic/virus_on_network/agents.py +0 -0
- {mesa-3.1.0.dev0 → mesa-3.1.1}/mesa/examples/basic/virus_on_network/model.py +0 -0
- {mesa-3.1.0.dev0 → mesa-3.1.1}/mesa/space.py +0 -0
- {mesa-3.1.0.dev0 → mesa-3.1.1}/mesa/visualization/__init__.py +2 -2
- {mesa-3.1.0.dev0 → mesa-3.1.1}/mesa/visualization/components/__init__.py +0 -0
- {mesa-3.1.0.dev0 → mesa-3.1.1}/mesa/visualization/components/altair_components.py +0 -0
- {mesa-3.1.0.dev0 → mesa-3.1.1}/mesa/visualization/components/matplotlib_components.py +0 -0
- {mesa-3.1.0.dev0 → mesa-3.1.1}/mesa/visualization/user_param.py +0 -0
- {mesa-3.1.0.dev0 → mesa-3.1.1}/mesa/visualization/utils.py +0 -0
- {mesa-3.1.0.dev0 → mesa-3.1.1}/mypy.ini +0 -0
- {mesa-3.1.0.dev0 → mesa-3.1.1}/pyproject.toml +0 -0
- {mesa-3.1.0.dev0 → mesa-3.1.1}/tests/__init__.py +0 -0
- {mesa-3.1.0.dev0 → mesa-3.1.1}/tests/read_requirements.py +0 -0
- {mesa-3.1.0.dev0 → mesa-3.1.1}/tests/test_datacollector.py +0 -0
- {mesa-3.1.0.dev0 → mesa-3.1.1}/tests/test_devs.py +0 -0
- {mesa-3.1.0.dev0 → mesa-3.1.1}/tests/test_end_to_end_viz.sh +0 -0
- {mesa-3.1.0.dev0 → mesa-3.1.1}/tests/test_examples.py +0 -0
- {mesa-3.1.0.dev0 → mesa-3.1.1}/tests/test_grid.py +0 -0
- {mesa-3.1.0.dev0 → mesa-3.1.1}/tests/test_import_namespace.py +0 -0
- {mesa-3.1.0.dev0 → mesa-3.1.1}/tests/test_lifespan.py +0 -0
- {mesa-3.1.0.dev0 → mesa-3.1.1}/tests/test_model.py +0 -0
- {mesa-3.1.0.dev0 → mesa-3.1.1}/tests/test_space.py +0 -0
|
@@ -1,16 +1,16 @@
|
|
|
1
|
-
|
|
1
|
+
### Summary
|
|
2
2
|
<!-- Provide a brief summary of the bug and its impact. -->
|
|
3
3
|
|
|
4
|
-
|
|
4
|
+
### Bug / Issue
|
|
5
5
|
<!-- Link to the related issue(s) and describe the bug. Include details like the context, what was expected, and what actually happened. -->
|
|
6
6
|
|
|
7
|
-
|
|
7
|
+
### Implementation
|
|
8
8
|
<!-- Describe the changes made to resolve the issue. Highlight any important parts of the code that were modified. -->
|
|
9
9
|
|
|
10
|
-
|
|
10
|
+
### Testing
|
|
11
11
|
<!-- Detail the testing performed to verify the fix. Include information on test cases, steps taken, and any relevant results.
|
|
12
12
|
|
|
13
13
|
If you're fixing the visualisation, add before/after screenshots. -->
|
|
14
14
|
|
|
15
|
-
|
|
15
|
+
### Additional Notes
|
|
16
16
|
<!-- Add any additional information that may be relevant for the reviewers, such as potential side effects, dependencies, or related work.
|
|
@@ -1,16 +1,16 @@
|
|
|
1
|
-
|
|
1
|
+
### Summary
|
|
2
2
|
<!-- Provide a concise summary of the feature and its purpose. -->
|
|
3
3
|
|
|
4
|
-
|
|
4
|
+
### Motive
|
|
5
5
|
<!-- Explain the reasoning behind this feature. Include details on the problem it addresses or the enhancement it provides. -->
|
|
6
6
|
|
|
7
|
-
|
|
7
|
+
### Implementation
|
|
8
8
|
<!-- Describe how the feature was implemented. Include details on the approach taken, important decisions made, and code changes. -->
|
|
9
9
|
|
|
10
|
-
|
|
10
|
+
### Usage Examples
|
|
11
11
|
<!-- Provide code snippets or examples demonstrating how to use the new feature. Highlight key scenarios where this feature will be beneficial.
|
|
12
12
|
|
|
13
13
|
If you're modifying the visualisation, add before/after screenshots. -->
|
|
14
14
|
|
|
15
|
-
|
|
15
|
+
### Additional Notes
|
|
16
16
|
<!-- Add any additional information that may be relevant for the reviewers, such as potential side effects, dependencies, or related work. -->
|
|
@@ -57,7 +57,7 @@ jobs:
|
|
|
57
57
|
run: pytest --durations=10 --cov=mesa tests/ --cov-report=xml
|
|
58
58
|
- if: matrix.os == 'ubuntu'
|
|
59
59
|
name: Codecov
|
|
60
|
-
uses: codecov/codecov-action@
|
|
60
|
+
uses: codecov/codecov-action@v5
|
|
61
61
|
with:
|
|
62
62
|
fail_ci_if_error: true
|
|
63
63
|
token: ${{ secrets.CODECOV_TOKEN }}
|
|
@@ -1,14 +1,12 @@
|
|
|
1
1
|
# We can't use slim because we need either git/wget/curl to
|
|
2
2
|
# download mesa-examples, and so installing them requires
|
|
3
3
|
# updating the system anyway.
|
|
4
|
-
# We can't use alpine because NumPy doesn't support musllinux yet.
|
|
5
|
-
# But it's in the RC version https://github.com/numpy/numpy/issues/20089.
|
|
6
4
|
FROM python:bookworm
|
|
7
|
-
LABEL maintainer="
|
|
5
|
+
LABEL maintainer="projectmesa maintainers@projectmesa.dev"
|
|
8
6
|
|
|
9
7
|
# To use this Dockerfile:
|
|
10
|
-
# 1. `docker build . -t
|
|
11
|
-
# 2. `docker run --name
|
|
8
|
+
# 1. `docker build . -t mesa_image`
|
|
9
|
+
# 2. `docker run --name mesa_instance -p 8765:8765 -it mesa_image`
|
|
12
10
|
# 3. In your browser, visit http://127.0.0.1:8765
|
|
13
11
|
#
|
|
14
12
|
# Currently, this Dockerfile defaults to running the Schelling model, as an
|
|
@@ -19,7 +17,7 @@ LABEL maintainer="rht <rhtbot@protonmail.com>"
|
|
|
19
17
|
# `docker run --name mymesa_instance -p 8765:8765 -e MODEL_DIR=/mesa-examples/examples/sugarscape_cg -it mymesa_image`
|
|
20
18
|
# Note: the model directory MUST contain an app.py file.
|
|
21
19
|
|
|
22
|
-
ENV MODEL_DIR=/mesa
|
|
20
|
+
ENV MODEL_DIR=/opt/mesa/mesa/examples/basic/schelling
|
|
23
21
|
|
|
24
22
|
# Don't buffer output:
|
|
25
23
|
# https://docs.python.org/3.10/using/cmdline.html?highlight=pythonunbuffered#envvar-PYTHONUNBUFFERED
|
|
@@ -29,10 +27,11 @@ WORKDIR /opt/mesa
|
|
|
29
27
|
|
|
30
28
|
COPY . /opt/mesa
|
|
31
29
|
|
|
32
|
-
RUN cd / && git clone https://github.com/projectmesa/mesa-examples.git
|
|
33
|
-
|
|
34
30
|
EXPOSE 8765/tcp
|
|
35
31
|
|
|
36
|
-
RUN pip3 install -e /opt/mesa
|
|
32
|
+
RUN pip3 install -e /opt/mesa[rec]
|
|
37
33
|
|
|
38
34
|
CMD ["sh", "-c", "cd $MODEL_DIR && solara run app.py --host=0.0.0.0"]
|
|
35
|
+
|
|
36
|
+
# To check file system:
|
|
37
|
+
# docker exec -it mesa_instance bash
|
|
@@ -1,6 +1,110 @@
|
|
|
1
1
|
---
|
|
2
2
|
title: Release History
|
|
3
3
|
---
|
|
4
|
+
# 3.1.1 (2024-12-14)
|
|
5
|
+
## Highlights
|
|
6
|
+
Mesa 3.1.1 is a maintenance release that includes visualization improvements and documentation updates. The key enhancement is the addition of an interactive play interval control to the visualization interface, allowing users to dynamically adjust simulation speed between 1ms and 500ms through a slider in the Controls panel.
|
|
7
|
+
|
|
8
|
+
Several example models were updated to use Mesa 3.1's recommended practices, particularly the `create_agents()` method for more efficient agent creation and NumPy's `rng.integers()` for random number generation. The Sugarscape example was modernized to use PropertyLayers.
|
|
9
|
+
|
|
10
|
+
Bug fixes include improvements to PropertyLayer visualization and a correction to the Schelling model's neighbor similarity calculation. The tutorials were also updated to reflect current best practices in Mesa 3.1.
|
|
11
|
+
|
|
12
|
+
## What's Changed
|
|
13
|
+
### 🎉 New features added
|
|
14
|
+
* Add Interactive Play Interval Control to Mesa Visualization by @AdamZh0u in https://github.com/projectmesa/mesa/pull/2540
|
|
15
|
+
### 🐛 Bugs fixed
|
|
16
|
+
* bug fixes for draw_property_layers by @quaquel in https://github.com/projectmesa/mesa/pull/2548
|
|
17
|
+
### 🔍 Examples updated
|
|
18
|
+
* Wolf-sheep to use `create_agent` by @quaquel in https://github.com/projectmesa/mesa/pull/2543
|
|
19
|
+
* Shift sugarscape example to using create_agent by @quaquel in https://github.com/projectmesa/mesa/pull/2544
|
|
20
|
+
* Fix: Schelling Model Neighbor Similarity Calculation by @Sahil-Chhoker in https://github.com/projectmesa/mesa/pull/2518
|
|
21
|
+
* Change pd_grid example to use create_agents by @quaquel in https://github.com/projectmesa/mesa/pull/2545
|
|
22
|
+
* Switch sugarscape to using property layers by @quaquel in https://github.com/projectmesa/mesa/pull/2546
|
|
23
|
+
### 📜 Documentation improvements
|
|
24
|
+
* Updated docs and check_model param by @nissu99 in https://github.com/projectmesa/mesa/pull/2510
|
|
25
|
+
* Update tutorials to use `create_agents` and `rng.integers` by @DarshPareek in https://github.com/projectmesa/mesa/pull/2541
|
|
26
|
+
|
|
27
|
+
## New Contributors
|
|
28
|
+
* @nissu99 made their first contribution in https://github.com/projectmesa/mesa/pull/2510
|
|
29
|
+
* @DarshPareek made their first contribution in https://github.com/projectmesa/mesa/pull/2541
|
|
30
|
+
|
|
31
|
+
**Full Changelog**: https://github.com/projectmesa/mesa/compare/v3.1.0...3.1.1
|
|
32
|
+
|
|
33
|
+
# 3.1.0 (2024-12-04)
|
|
34
|
+
## Highlights
|
|
35
|
+
With Mesa 3.1.0 we're back on our regular release schedule after the big Mesa 3.0 release, with some exciting new features.
|
|
36
|
+
|
|
37
|
+
This release adds experimental support for Observables and Computed, enabling a more reactive and responsive programming model for agent-based simulations. The new `Observable` and `Computable` classes allow developers to declaratively define attributes that automatically emit signals when their values change, and compute derived values that update dynamically. This lays the groundwork for more advanced event handling and data visualization features in future releases (#2291).
|
|
38
|
+
|
|
39
|
+
The experimental cell space module has been updated with full support for n-dimensional property layers. These allow agents to easily interact with and modify spatial properties of the environment, such as terrain, resources, or environmental conditions. The new implementation provides a more intuitive attribute-based API and ensures tight integration with the cell space architecture (#2512).
|
|
40
|
+
|
|
41
|
+
Mesa now includes built-in support for logging using the standard Python `logging` module. This provides developers with a flexible and powerful way to add structured diagnostic and debug output to their simulations, without the need for custom logging solutions. The logging system is integrated throughout the library, including the new SolaraViz visualization system (#2506).
|
|
42
|
+
|
|
43
|
+
Creating multiple agents with varying initialization parameters is now significantly easier with the new `Agent.create_agents` class method. This factory function supports both uniform and per-agent parameters, simplifying the code required to set up a simulation with a large number of heterogeneous agents (#2351).
|
|
44
|
+
|
|
45
|
+
In addition to the major new features, this release includes a number of smaller enhancements and bug fixes that improve the overall developer experience. These include removing deprecated functionality, cleaning up examples, and addressing various edge cases reported by the community. Mesa 3.1 requires Python 3.11 or higher.
|
|
46
|
+
|
|
47
|
+
## What's Changed
|
|
48
|
+
### 🧪 Experimental features
|
|
49
|
+
* Add support for Observables to MESA by @quaquel in https://github.com/projectmesa/mesa/pull/2291
|
|
50
|
+
* Add full support for property layers to cell spaces by @quaquel in https://github.com/projectmesa/mesa/pull/2512
|
|
51
|
+
### 🎉 New features added
|
|
52
|
+
* Add logging to MESA by @quaquel in https://github.com/projectmesa/mesa/pull/2506
|
|
53
|
+
* Add `create_agents` factory method to Agent by @quaquel in https://github.com/projectmesa/mesa/pull/2351
|
|
54
|
+
### 🔍 Examples updated
|
|
55
|
+
* Add seed control to all examples by @quaquel in https://github.com/projectmesa/mesa/pull/2496
|
|
56
|
+
### 📜 Documentation improvements
|
|
57
|
+
* doc fix for pip install error on mac by @quaquel in https://github.com/projectmesa/mesa/pull/2508
|
|
58
|
+
* Refactored docs for Introductory Tutorial by @Spartan-71 in https://github.com/projectmesa/mesa/pull/2511
|
|
59
|
+
* Add module-level docstring to experimental features by @EwoutH in https://github.com/projectmesa/mesa/pull/2532
|
|
60
|
+
### 🔧 Maintenance
|
|
61
|
+
* Remove deprecated time module by @EwoutH in https://github.com/projectmesa/mesa/pull/2476
|
|
62
|
+
* Drop support for Python 3.10, require Python >= 3.11 by @EwoutH in https://github.com/projectmesa/mesa/pull/2474
|
|
63
|
+
* Remove deprecated functionality by @EwoutH in https://github.com/projectmesa/mesa/pull/2483
|
|
64
|
+
* Remove visualization modules from `mesa.experimental` by @quaquel in https://github.com/projectmesa/mesa/pull/2495
|
|
65
|
+
* Cleanup two occurrences of removed scheduler by @EwoutH in https://github.com/projectmesa/mesa/pull/2499
|
|
66
|
+
* move _setup_agent_registration into `Model.__init__` by @quaquel in https://github.com/projectmesa/mesa/pull/2501
|
|
67
|
+
* remove devs related examples from devs/examples by @quaquel in https://github.com/projectmesa/mesa/pull/2507
|
|
68
|
+
* added empty iterable checks and updated tests by @Sahil-Chhoker in https://github.com/projectmesa/mesa/pull/2523
|
|
69
|
+
* Fix: running Mesa in Docker with Schelling model by @AdamZh0u in https://github.com/projectmesa/mesa/pull/2524
|
|
70
|
+
|
|
71
|
+
## New Contributors
|
|
72
|
+
* @Spartan-71 made their first contribution in https://github.com/projectmesa/mesa/pull/2511
|
|
73
|
+
* @Sahil-Chhoker made their first contribution in https://github.com/projectmesa/mesa/pull/2523
|
|
74
|
+
* @AdamZh0u made their first contribution in https://github.com/projectmesa/mesa/pull/2524
|
|
75
|
+
|
|
76
|
+
**Full Changelog**: https://github.com/projectmesa/mesa/compare/v3.0.3...v3.1.0
|
|
77
|
+
|
|
78
|
+
# 3.0.3 (2024-11-14)
|
|
79
|
+
## Highlights
|
|
80
|
+
A small bugfix release that fixes two bugs.
|
|
81
|
+
|
|
82
|
+
## What's Changed
|
|
83
|
+
### 🧪 Experimental features
|
|
84
|
+
* cell_space: Allow CellCollection to be empty by @EwoutH in https://github.com/projectmesa/mesa/pull/2502
|
|
85
|
+
### 🐛 Bugs fixed
|
|
86
|
+
* Only set model_parameters once by @Corvince in https://github.com/projectmesa/mesa/pull/2505
|
|
87
|
+
|
|
88
|
+
**Full Changelog**: https://github.com/projectmesa/mesa/compare/v3.0.2...v3.0.3
|
|
89
|
+
|
|
90
|
+
# 3.0.2 (2024-11-11)
|
|
91
|
+
## Highlighst
|
|
92
|
+
Mesa 3.0.2 is a small follow-up patch release, in which we fixed a lot of small bugs in the example models their visualisation, and improved their testing.
|
|
93
|
+
|
|
94
|
+
## What's Changed
|
|
95
|
+
### 🐛 Bugs fixed
|
|
96
|
+
* allow components as a positional argument again by @Corvince in https://github.com/projectmesa/mesa/pull/2488
|
|
97
|
+
### 🔍 Examples updated
|
|
98
|
+
* examples: Add required components keyword by @EwoutH in https://github.com/projectmesa/mesa/pull/2485
|
|
99
|
+
* examples: Fix boid_flockers viz by @EwoutH in https://github.com/projectmesa/mesa/pull/2492
|
|
100
|
+
* examples: Fix schelling viz by @EwoutH in https://github.com/projectmesa/mesa/pull/2490
|
|
101
|
+
* example: Add input sliders to Sugerscape viz by @EwoutH in https://github.com/projectmesa/mesa/pull/2487
|
|
102
|
+
* examples/gol: Add initial fraction alive, add sliders to viz by @EwoutH in https://github.com/projectmesa/mesa/pull/2489
|
|
103
|
+
### 🔧 Maintenance
|
|
104
|
+
* test app init of examples by @Corvince in https://github.com/projectmesa/mesa/pull/2491
|
|
105
|
+
|
|
106
|
+
**Full Changelog**: https://github.com/projectmesa/mesa/compare/v3.0.1...v3.0.2
|
|
107
|
+
|
|
4
108
|
# 3.0.1 (2024-11-11)
|
|
5
109
|
## Highlights
|
|
6
110
|
After our huge [3.0.0 release](https://github.com/projectmesa/mesa/releases/tag/v3.0.0), Mesa 3.0.1 follows up with two improvements to experimental features, examples and docs.
|
|
@@ -16,6 +16,6 @@ services:
|
|
|
16
16
|
# within the current directory.
|
|
17
17
|
# E.g. if it is at my-model, then you specify it as
|
|
18
18
|
# /opt/mesa/my-model.
|
|
19
|
-
MODEL_DIR: /mesa
|
|
19
|
+
MODEL_DIR: /opt/mesa/mesa/examples/basic/schelling
|
|
20
20
|
ports:
|
|
21
21
|
- 8765:8765
|
|
@@ -180,6 +180,16 @@ Mesa now uses a new browser-based visualization system called SolaraViz. This al
|
|
|
180
180
|
|
|
181
181
|
> **Note:** SolaraViz is experimental and still in active development for Mesa 3.0. While we attempt to minimize them, there might be API breaking changes between Mesa 3.0 and 3.1. There won't be breaking changes between Mesa 3.0.x patch releases.
|
|
182
182
|
|
|
183
|
+
> **Note:** SolaraViz instantiates new models using `**model_parameters.value`, so all model inputs must be keyword arguments.
|
|
184
|
+
|
|
185
|
+
Ensure your model's `__init__` method accepts keyword arguments matching the `model_params` keys.
|
|
186
|
+
|
|
187
|
+
```python
|
|
188
|
+
class MyModel(Model):
|
|
189
|
+
def __init__(self, n_agents=10, seed=None):
|
|
190
|
+
super().__init__(seed=seed)
|
|
191
|
+
# Initialize the model with N agents
|
|
192
|
+
|
|
183
193
|
The core functionality for building your own visualizations resides in the [`mesa.visualization`](apis/visualization) namespace
|
|
184
194
|
|
|
185
195
|
Here's a basic example of how to set up a visualization:
|
|
@@ -43,6 +43,10 @@ To also install our recommended dependencies:
|
|
|
43
43
|
pip install -U mesa[rec]
|
|
44
44
|
```
|
|
45
45
|
|
|
46
|
+
On a Mac, this command might cause an error stating `zsh: no matches found: mesa[all]`.
|
|
47
|
+
In that case, change the command to `pip install -U "mesa[rec]"`.
|
|
48
|
+
|
|
49
|
+
|
|
46
50
|
To install our latest pre-release:
|
|
47
51
|
|
|
48
52
|
```bash
|
|
@@ -259,6 +259,17 @@ the import from mesa.experimental. Otherwise here is a list of things you need t
|
|
|
259
259
|
|
|
260
260
|
Previously SolaraViz was initialized by providing a `model_cls` and a `model_params`. This has changed to expect a model instance `model`. You can still provide (user-settable) `model_params`, but only if users should be able to change them. It is now also possible to pass in a "reactive model" by first calling `model = solara.reactive(model)`. This is useful for notebook environments. It allows you to pass the model to the SolaraViz Module, but continue to use the model. For example calling `model.value.step()` (notice the extra .value) will automatically update the plots. This currently only automatically works for the step method, you can force visualization updates by calling `model.value.force_update()`.
|
|
261
261
|
|
|
262
|
+
### Model Initialization with Keyword Arguments
|
|
263
|
+
|
|
264
|
+
With the introduction of SolaraViz in Mesa 3.0, models are now instantiated using `**model_parameters.value`. This means all inputs for initializing a new model must be keyword arguments. Ensure your model's `__init__` method accepts keyword arguments matching the keys in `model_params`.
|
|
265
|
+
|
|
266
|
+
```python
|
|
267
|
+
class MyModel(mesa.Model):
|
|
268
|
+
def __init__(self, n_agents=10, seed=None):
|
|
269
|
+
super().__init__(seed=seed)
|
|
270
|
+
# Initialize the model with N agents
|
|
271
|
+
```
|
|
272
|
+
|
|
262
273
|
#### Default space visualization
|
|
263
274
|
|
|
264
275
|
Previously we included a default space drawer that you could configure with an `agent_portrayal` function. You now have to explicitly create a space drawer with the `agent_portrayal` function
|
|
@@ -62,12 +62,13 @@ class MoneyModel(mesa.Model):
|
|
|
62
62
|
self.grid = mesa.space.MultiGrid(width, height, True)
|
|
63
63
|
|
|
64
64
|
# Create agents
|
|
65
|
-
|
|
66
|
-
|
|
65
|
+
agents = MoneyAgent.create_agents(model=self, n=n)
|
|
66
|
+
# Create x and y positions for agents
|
|
67
|
+
x = self.rng.integers(0, self.grid.width, size=(n,))
|
|
68
|
+
y = self.rng.integers(0, self.grid.height, size=(n,))
|
|
69
|
+
for a, i, j in zip(agents, x, y):
|
|
67
70
|
# Add the agent to a random grid cell
|
|
68
|
-
|
|
69
|
-
y = self.random.randrange(self.grid.height)
|
|
70
|
-
self.grid.place_agent(a, (x, y))
|
|
71
|
+
self.grid.place_agent(a, (i, j))
|
|
71
72
|
|
|
72
73
|
self.datacollector = mesa.DataCollector(
|
|
73
74
|
model_reporters={"Gini": compute_gini}, agent_reporters={"Wealth": "wealth"}
|