Mesa 3.1.2__tar.gz → 3.1.4__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.

Files changed (190) hide show
  1. {mesa-3.1.2 → mesa-3.1.4}/.github/workflows/benchmarks.yml +3 -1
  2. {mesa-3.1.2 → mesa-3.1.4}/.pre-commit-config.yaml +3 -3
  3. {mesa-3.1.2 → mesa-3.1.4}/CONTRIBUTING.md +2 -0
  4. {mesa-3.1.2 → mesa-3.1.4}/HISTORY.md +92 -0
  5. {mesa-3.1.2 → mesa-3.1.4}/PKG-INFO +14 -10
  6. {mesa-3.1.2 → mesa-3.1.4}/README.md +4 -9
  7. {mesa-3.1.2 → mesa-3.1.4}/benchmarks/configurations.py +7 -2
  8. {mesa-3.1.2 → mesa-3.1.4}/binder/environment.yml +2 -2
  9. {mesa-3.1.2 → mesa-3.1.4}/docs/README.md +2 -1
  10. {mesa-3.1.2 → mesa-3.1.4}/docs/apis/experimental.md +12 -0
  11. {mesa-3.1.2 → mesa-3.1.4}/docs/apis/visualization.md +8 -0
  12. {mesa-3.1.2 → mesa-3.1.4}/docs/conf.py +1 -0
  13. {mesa-3.1.2 → mesa-3.1.4}/docs/getting_started.md +3 -5
  14. {mesa-3.1.2 → mesa-3.1.4}/docs/index.md +4 -9
  15. mesa-3.1.4/docs/mesa_extension.md +97 -0
  16. {mesa-3.1.2 → mesa-3.1.4}/docs/tutorials/intro_tutorial.ipynb +5 -11
  17. {mesa-3.1.2 → mesa-3.1.4}/docs/tutorials/visualization_tutorial.ipynb +1 -3
  18. {mesa-3.1.2 → mesa-3.1.4}/mesa/__init__.py +1 -1
  19. {mesa-3.1.2 → mesa-3.1.4}/mesa/datacollection.py +62 -2
  20. {mesa-3.1.2 → mesa-3.1.4}/mesa/examples/advanced/sugarscape_g1mt/app.py +15 -37
  21. {mesa-3.1.2 → mesa-3.1.4}/mesa/examples/basic/boid_flockers/agents.py +26 -38
  22. {mesa-3.1.2 → mesa-3.1.4}/mesa/examples/basic/boid_flockers/app.py +6 -1
  23. {mesa-3.1.2 → mesa-3.1.4}/mesa/examples/basic/boid_flockers/model.py +30 -37
  24. {mesa-3.1.2 → mesa-3.1.4}/mesa/experimental/__init__.py +2 -2
  25. {mesa-3.1.2 → mesa-3.1.4}/mesa/experimental/cell_space/grid.py +8 -8
  26. {mesa-3.1.2 → mesa-3.1.4}/mesa/experimental/cell_space/voronoi.py +1 -4
  27. mesa-3.1.4/mesa/experimental/continuous_space/__init__.py +8 -0
  28. mesa-3.1.4/mesa/experimental/continuous_space/continuous_space.py +273 -0
  29. mesa-3.1.4/mesa/experimental/continuous_space/continuous_space_agents.py +101 -0
  30. {mesa-3.1.2 → mesa-3.1.4}/mesa/model.py +1 -1
  31. {mesa-3.1.2 → mesa-3.1.4}/mesa/space.py +7 -0
  32. {mesa-3.1.2 → mesa-3.1.4}/mesa/visualization/__init__.py +1 -2
  33. {mesa-3.1.2 → mesa-3.1.4}/mesa/visualization/components/altair_components.py +10 -8
  34. {mesa-3.1.2 → mesa-3.1.4}/mesa/visualization/mpl_space_drawing.py +160 -101
  35. {mesa-3.1.2 → mesa-3.1.4}/mesa/visualization/solara_viz.py +35 -8
  36. {mesa-3.1.2 → mesa-3.1.4}/pyproject.toml +3 -3
  37. {mesa-3.1.2 → mesa-3.1.4}/tests/test_agent.py +3 -3
  38. {mesa-3.1.2 → mesa-3.1.4}/tests/test_cell_space.py +17 -17
  39. mesa-3.1.4/tests/test_continuous_space.py +432 -0
  40. {mesa-3.1.2 → mesa-3.1.4}/tests/test_datacollector.py +62 -0
  41. {mesa-3.1.2 → mesa-3.1.4}/tests/test_model.py +12 -0
  42. {mesa-3.1.2 → mesa-3.1.4}/tests/test_solara_viz.py +39 -6
  43. {mesa-3.1.2 → mesa-3.1.4}/.codespellignore +0 -0
  44. {mesa-3.1.2 → mesa-3.1.4}/.coveragerc +0 -0
  45. {mesa-3.1.2 → mesa-3.1.4}/.github/ISSUE_TEMPLATE/bug-report.md +0 -0
  46. {mesa-3.1.2 → mesa-3.1.4}/.github/ISSUE_TEMPLATE/config.yml +0 -0
  47. {mesa-3.1.2 → mesa-3.1.4}/.github/ISSUE_TEMPLATE/feature-request.md +0 -0
  48. {mesa-3.1.2 → mesa-3.1.4}/.github/PULL_REQUEST_TEMPLATE/bug.md +0 -0
  49. {mesa-3.1.2 → mesa-3.1.4}/.github/PULL_REQUEST_TEMPLATE/feature.md +0 -0
  50. {mesa-3.1.2 → mesa-3.1.4}/.github/dependabot.yml +0 -0
  51. {mesa-3.1.2 → mesa-3.1.4}/.github/pull_request_template.md +0 -0
  52. {mesa-3.1.2 → mesa-3.1.4}/.github/release.yml +0 -0
  53. {mesa-3.1.2 → mesa-3.1.4}/.github/workflows/build_lint.yml +0 -0
  54. {mesa-3.1.2 → mesa-3.1.4}/.github/workflows/release.yml +0 -0
  55. {mesa-3.1.2 → mesa-3.1.4}/.gitignore +0 -0
  56. {mesa-3.1.2 → mesa-3.1.4}/.readthedocs.yml +0 -0
  57. {mesa-3.1.2 → mesa-3.1.4}/CITATION.bib +0 -0
  58. {mesa-3.1.2 → mesa-3.1.4}/CODE_OF_CONDUCT.md +0 -0
  59. {mesa-3.1.2 → mesa-3.1.4}/Dockerfile +0 -0
  60. {mesa-3.1.2 → mesa-3.1.4}/LICENSE +0 -0
  61. {mesa-3.1.2 → mesa-3.1.4}/NOTICE +0 -0
  62. {mesa-3.1.2 → mesa-3.1.4}/benchmarks/compare_timings.py +0 -0
  63. {mesa-3.1.2 → mesa-3.1.4}/benchmarks/global_benchmark.py +0 -0
  64. {mesa-3.1.2 → mesa-3.1.4}/codecov.yaml +0 -0
  65. {mesa-3.1.2 → mesa-3.1.4}/docker-compose.yml +0 -0
  66. {mesa-3.1.2 → mesa-3.1.4}/docs/Makefile +0 -0
  67. {mesa-3.1.2 → mesa-3.1.4}/docs/_static/switcher.json +0 -0
  68. {mesa-3.1.2 → mesa-3.1.4}/docs/apis/agent.md +0 -0
  69. {mesa-3.1.2 → mesa-3.1.4}/docs/apis/api_main.md +0 -0
  70. {mesa-3.1.2 → mesa-3.1.4}/docs/apis/batchrunner.md +0 -0
  71. {mesa-3.1.2 → mesa-3.1.4}/docs/apis/datacollection.md +0 -0
  72. {mesa-3.1.2 → mesa-3.1.4}/docs/apis/mesa_logging.md +0 -0
  73. {mesa-3.1.2 → mesa-3.1.4}/docs/apis/model.md +0 -0
  74. {mesa-3.1.2 → mesa-3.1.4}/docs/apis/space.md +0 -0
  75. {mesa-3.1.2 → mesa-3.1.4}/docs/best-practices.md +0 -0
  76. {mesa-3.1.2 → mesa-3.1.4}/docs/example_template.txt +0 -0
  77. {mesa-3.1.2 → mesa-3.1.4}/docs/examples_overview_template.txt +0 -0
  78. {mesa-3.1.2 → mesa-3.1.4}/docs/images/mesa_logo.ico +0 -0
  79. {mesa-3.1.2 → mesa-3.1.4}/docs/images/mesa_logo.png +0 -0
  80. {mesa-3.1.2 → mesa-3.1.4}/docs/images/tutorial/br_ginis.png +0 -0
  81. {mesa-3.1.2 → mesa-3.1.4}/docs/images/tutorial/dc_endwealth.png +0 -0
  82. {mesa-3.1.2 → mesa-3.1.4}/docs/images/tutorial/dc_gini.png +0 -0
  83. {mesa-3.1.2 → mesa-3.1.4}/docs/images/tutorial/dc_oneagent.png +0 -0
  84. {mesa-3.1.2 → mesa-3.1.4}/docs/images/tutorial/first_hist.png +0 -0
  85. {mesa-3.1.2 → mesa-3.1.4}/docs/images/tutorial/multirun_hist.png +0 -0
  86. {mesa-3.1.2 → mesa-3.1.4}/docs/images/tutorial/numpy_grid.png +0 -0
  87. {mesa-3.1.2 → mesa-3.1.4}/docs/images/tutorial/viz_chart.png +0 -0
  88. {mesa-3.1.2 → mesa-3.1.4}/docs/images/tutorial/viz_empty.png +0 -0
  89. {mesa-3.1.2 → mesa-3.1.4}/docs/images/tutorial/viz_greycircles.png +0 -0
  90. {mesa-3.1.2 → mesa-3.1.4}/docs/images/tutorial/viz_histogram.png +0 -0
  91. {mesa-3.1.2 → mesa-3.1.4}/docs/images/tutorial/viz_redcircles.png +0 -0
  92. {mesa-3.1.2 → mesa-3.1.4}/docs/images/wolf_sheep.png +0 -0
  93. {mesa-3.1.2 → mesa-3.1.4}/docs/make.bat +0 -0
  94. {mesa-3.1.2 → mesa-3.1.4}/docs/mesa.md +0 -0
  95. {mesa-3.1.2 → mesa-3.1.4}/docs/migration_guide.md +0 -0
  96. {mesa-3.1.2 → mesa-3.1.4}/docs/tutorials/MoneyModel.py +0 -0
  97. {mesa-3.1.2 → mesa-3.1.4}/docs/tutorials/files/viz_chart.png +0 -0
  98. {mesa-3.1.2 → mesa-3.1.4}/docs/tutorials/files/viz_empty.png +0 -0
  99. {mesa-3.1.2 → mesa-3.1.4}/docs/tutorials/files/viz_greycircles.png +0 -0
  100. {mesa-3.1.2 → mesa-3.1.4}/docs/tutorials/files/viz_histogram.png +0 -0
  101. {mesa-3.1.2 → mesa-3.1.4}/docs/tutorials/files/viz_redcircles.png +0 -0
  102. {mesa-3.1.2 → mesa-3.1.4}/docs/tutorials/files/viz_slider.png +0 -0
  103. {mesa-3.1.2 → mesa-3.1.4}/maintenance/fetch_unlabeled_prs.py +0 -0
  104. {mesa-3.1.2 → mesa-3.1.4}/mesa/agent.py +0 -0
  105. {mesa-3.1.2 → mesa-3.1.4}/mesa/batchrunner.py +0 -0
  106. {mesa-3.1.2 → mesa-3.1.4}/mesa/examples/README.md +0 -0
  107. {mesa-3.1.2 → mesa-3.1.4}/mesa/examples/__init__.py +0 -0
  108. {mesa-3.1.2 → mesa-3.1.4}/mesa/examples/advanced/__init__.py +0 -0
  109. {mesa-3.1.2 → mesa-3.1.4}/mesa/examples/advanced/epstein_civil_violence/Epstein Civil Violence.ipynb +0 -0
  110. {mesa-3.1.2 → mesa-3.1.4}/mesa/examples/advanced/epstein_civil_violence/Readme.md +0 -0
  111. {mesa-3.1.2 → mesa-3.1.4}/mesa/examples/advanced/epstein_civil_violence/__init__.py +0 -0
  112. {mesa-3.1.2 → mesa-3.1.4}/mesa/examples/advanced/epstein_civil_violence/agents.py +0 -0
  113. {mesa-3.1.2 → mesa-3.1.4}/mesa/examples/advanced/epstein_civil_violence/app.py +0 -0
  114. {mesa-3.1.2 → mesa-3.1.4}/mesa/examples/advanced/epstein_civil_violence/model.py +0 -0
  115. {mesa-3.1.2 → mesa-3.1.4}/mesa/examples/advanced/pd_grid/Readme.md +0 -0
  116. {mesa-3.1.2 → mesa-3.1.4}/mesa/examples/advanced/pd_grid/__init__.py +0 -0
  117. {mesa-3.1.2 → mesa-3.1.4}/mesa/examples/advanced/pd_grid/agents.py +0 -0
  118. {mesa-3.1.2 → mesa-3.1.4}/mesa/examples/advanced/pd_grid/analysis.ipynb +0 -0
  119. {mesa-3.1.2 → mesa-3.1.4}/mesa/examples/advanced/pd_grid/app.py +0 -0
  120. {mesa-3.1.2 → mesa-3.1.4}/mesa/examples/advanced/pd_grid/model.py +0 -0
  121. {mesa-3.1.2 → mesa-3.1.4}/mesa/examples/advanced/sugarscape_g1mt/Readme.md +0 -0
  122. {mesa-3.1.2 → mesa-3.1.4}/mesa/examples/advanced/sugarscape_g1mt/__init__.py +0 -0
  123. {mesa-3.1.2 → mesa-3.1.4}/mesa/examples/advanced/sugarscape_g1mt/agents.py +0 -0
  124. {mesa-3.1.2 → mesa-3.1.4}/mesa/examples/advanced/sugarscape_g1mt/model.py +0 -0
  125. {mesa-3.1.2 → mesa-3.1.4}/mesa/examples/advanced/sugarscape_g1mt/sugar-map.txt +0 -0
  126. {mesa-3.1.2 → mesa-3.1.4}/mesa/examples/advanced/sugarscape_g1mt/tests.py +0 -0
  127. {mesa-3.1.2 → mesa-3.1.4}/mesa/examples/advanced/wolf_sheep/Readme.md +0 -0
  128. {mesa-3.1.2 → mesa-3.1.4}/mesa/examples/advanced/wolf_sheep/__init__.py +0 -0
  129. {mesa-3.1.2 → mesa-3.1.4}/mesa/examples/advanced/wolf_sheep/agents.py +0 -0
  130. {mesa-3.1.2 → mesa-3.1.4}/mesa/examples/advanced/wolf_sheep/app.py +0 -0
  131. {mesa-3.1.2 → mesa-3.1.4}/mesa/examples/advanced/wolf_sheep/model.py +0 -0
  132. {mesa-3.1.2 → mesa-3.1.4}/mesa/examples/basic/__init__.py +0 -0
  133. {mesa-3.1.2 → mesa-3.1.4}/mesa/examples/basic/boid_flockers/Readme.md +0 -0
  134. {mesa-3.1.2 → mesa-3.1.4}/mesa/examples/basic/boid_flockers/__init__.py +0 -0
  135. {mesa-3.1.2 → mesa-3.1.4}/mesa/examples/basic/boltzmann_wealth_model/Readme.md +0 -0
  136. {mesa-3.1.2 → mesa-3.1.4}/mesa/examples/basic/boltzmann_wealth_model/__init__.py +0 -0
  137. {mesa-3.1.2 → mesa-3.1.4}/mesa/examples/basic/boltzmann_wealth_model/agents.py +0 -0
  138. {mesa-3.1.2 → mesa-3.1.4}/mesa/examples/basic/boltzmann_wealth_model/app.py +0 -0
  139. {mesa-3.1.2 → mesa-3.1.4}/mesa/examples/basic/boltzmann_wealth_model/model.py +0 -0
  140. {mesa-3.1.2 → mesa-3.1.4}/mesa/examples/basic/boltzmann_wealth_model/st_app.py +0 -0
  141. {mesa-3.1.2 → mesa-3.1.4}/mesa/examples/basic/conways_game_of_life/Readme.md +0 -0
  142. {mesa-3.1.2 → mesa-3.1.4}/mesa/examples/basic/conways_game_of_life/__init__.py +0 -0
  143. {mesa-3.1.2 → mesa-3.1.4}/mesa/examples/basic/conways_game_of_life/agents.py +0 -0
  144. {mesa-3.1.2 → mesa-3.1.4}/mesa/examples/basic/conways_game_of_life/app.py +0 -0
  145. {mesa-3.1.2 → mesa-3.1.4}/mesa/examples/basic/conways_game_of_life/model.py +0 -0
  146. {mesa-3.1.2 → mesa-3.1.4}/mesa/examples/basic/conways_game_of_life/st_app.py +0 -0
  147. {mesa-3.1.2 → mesa-3.1.4}/mesa/examples/basic/schelling/Readme.md +0 -0
  148. {mesa-3.1.2 → mesa-3.1.4}/mesa/examples/basic/schelling/__init__.py +0 -0
  149. {mesa-3.1.2 → mesa-3.1.4}/mesa/examples/basic/schelling/agents.py +0 -0
  150. {mesa-3.1.2 → mesa-3.1.4}/mesa/examples/basic/schelling/analysis.ipynb +0 -0
  151. {mesa-3.1.2 → mesa-3.1.4}/mesa/examples/basic/schelling/app.py +0 -0
  152. {mesa-3.1.2 → mesa-3.1.4}/mesa/examples/basic/schelling/model.py +0 -0
  153. {mesa-3.1.2 → mesa-3.1.4}/mesa/examples/basic/virus_on_network/Readme.md +0 -0
  154. {mesa-3.1.2 → mesa-3.1.4}/mesa/examples/basic/virus_on_network/__init__.py +0 -0
  155. {mesa-3.1.2 → mesa-3.1.4}/mesa/examples/basic/virus_on_network/agents.py +0 -0
  156. {mesa-3.1.2 → mesa-3.1.4}/mesa/examples/basic/virus_on_network/app.py +0 -0
  157. {mesa-3.1.2 → mesa-3.1.4}/mesa/examples/basic/virus_on_network/model.py +0 -0
  158. {mesa-3.1.2 → mesa-3.1.4}/mesa/experimental/cell_space/__init__.py +0 -0
  159. {mesa-3.1.2 → mesa-3.1.4}/mesa/experimental/cell_space/cell.py +0 -0
  160. {mesa-3.1.2 → mesa-3.1.4}/mesa/experimental/cell_space/cell_agent.py +0 -0
  161. {mesa-3.1.2 → mesa-3.1.4}/mesa/experimental/cell_space/cell_collection.py +0 -0
  162. {mesa-3.1.2 → mesa-3.1.4}/mesa/experimental/cell_space/discrete_space.py +0 -0
  163. {mesa-3.1.2 → mesa-3.1.4}/mesa/experimental/cell_space/network.py +0 -0
  164. {mesa-3.1.2 → mesa-3.1.4}/mesa/experimental/cell_space/property_layer.py +0 -0
  165. {mesa-3.1.2 → mesa-3.1.4}/mesa/experimental/devs/__init__.py +0 -0
  166. {mesa-3.1.2 → mesa-3.1.4}/mesa/experimental/devs/eventlist.py +0 -0
  167. {mesa-3.1.2 → mesa-3.1.4}/mesa/experimental/devs/simulator.py +0 -0
  168. {mesa-3.1.2 → mesa-3.1.4}/mesa/experimental/mesa_signals/__init__.py +0 -0
  169. {mesa-3.1.2 → mesa-3.1.4}/mesa/experimental/mesa_signals/mesa_signal.py +0 -0
  170. {mesa-3.1.2 → mesa-3.1.4}/mesa/experimental/mesa_signals/observable_collections.py +0 -0
  171. {mesa-3.1.2 → mesa-3.1.4}/mesa/experimental/mesa_signals/signals_util.py +0 -0
  172. {mesa-3.1.2 → mesa-3.1.4}/mesa/mesa_logging.py +0 -0
  173. {mesa-3.1.2 → mesa-3.1.4}/mesa/visualization/components/__init__.py +0 -0
  174. {mesa-3.1.2 → mesa-3.1.4}/mesa/visualization/components/matplotlib_components.py +0 -0
  175. {mesa-3.1.2 → mesa-3.1.4}/mesa/visualization/user_param.py +0 -0
  176. {mesa-3.1.2 → mesa-3.1.4}/mesa/visualization/utils.py +0 -0
  177. {mesa-3.1.2 → mesa-3.1.4}/mypy.ini +0 -0
  178. {mesa-3.1.2 → mesa-3.1.4}/tests/__init__.py +0 -0
  179. {mesa-3.1.2 → mesa-3.1.4}/tests/read_requirements.py +0 -0
  180. {mesa-3.1.2 → mesa-3.1.4}/tests/test_batch_run.py +0 -0
  181. {mesa-3.1.2 → mesa-3.1.4}/tests/test_components_matplotlib.py +0 -0
  182. {mesa-3.1.2 → mesa-3.1.4}/tests/test_devs.py +0 -0
  183. {mesa-3.1.2 → mesa-3.1.4}/tests/test_end_to_end_viz.sh +0 -0
  184. {mesa-3.1.2 → mesa-3.1.4}/tests/test_examples.py +0 -0
  185. {mesa-3.1.2 → mesa-3.1.4}/tests/test_grid.py +0 -0
  186. {mesa-3.1.2 → mesa-3.1.4}/tests/test_import_namespace.py +0 -0
  187. {mesa-3.1.2 → mesa-3.1.4}/tests/test_lifespan.py +0 -0
  188. {mesa-3.1.2 → mesa-3.1.4}/tests/test_mesa_logging.py +0 -0
  189. {mesa-3.1.2 → mesa-3.1.4}/tests/test_mesa_signals.py +0 -0
  190. {mesa-3.1.2 → mesa-3.1.4}/tests/test_space.py +0 -0
@@ -28,8 +28,10 @@ jobs:
28
28
  python-version: '3.13'
29
29
  - name: Add project directory to PYTHONPATH
30
30
  run: echo "PYTHONPATH=$PYTHONPATH:$(pwd)" >> $GITHUB_ENV
31
+ - name: Install uv
32
+ run: pip install uv
31
33
  - name: Install dependencies
32
- run: pip install numpy pandas tqdm tabulate matplotlib solara networkx
34
+ run: uv pip install --system numpy pandas tqdm tabulate matplotlib solara networkx scipy
33
35
  # Benchmarks on the projectmesa main branch
34
36
  - name: Checkout main branch
35
37
  uses: actions/checkout@v4
@@ -4,7 +4,7 @@ ci:
4
4
  repos:
5
5
  - repo: https://github.com/astral-sh/ruff-pre-commit
6
6
  # Ruff version.
7
- rev: v0.8.1
7
+ rev: v0.9.4
8
8
  hooks:
9
9
  # Run the linter.
10
10
  - id: ruff
@@ -14,7 +14,7 @@ repos:
14
14
  - id: ruff-format
15
15
  types_or: [ python, pyi, jupyter ]
16
16
  - repo: https://github.com/asottile/pyupgrade
17
- rev: v3.19.0
17
+ rev: v3.19.1
18
18
  hooks:
19
19
  - id: pyupgrade
20
20
  args: [--py311-plus]
@@ -25,7 +25,7 @@ repos:
25
25
  - id: check-toml
26
26
  - id: check-yaml
27
27
  - repo: https://github.com/codespell-project/codespell
28
- rev: v2.3.0
28
+ rev: v2.4.1
29
29
  hooks:
30
30
  - id: codespell
31
31
  args: [
@@ -137,6 +137,8 @@ To create a new release, follow these steps:
137
137
  9. The [`release.yml`](https://github.com/projectmesa/mesa/blob/main/.github/workflows/release.yml) CI workflow should automatically create and upload the package to PyPI. Verify this on [PyPI.org](https://pypi.org/project/mesa/).
138
138
  10. Finally, after release, open a new PR to update the version number in [`mesa/__init__.py`](https://github.com/projectmesa/mesa/blob/main/mesa/__init__.py) for the next release (e.g., `"3.1.0.dev"`).
139
139
 
140
+ A recorded video of this process is [available here](https://youtu.be/JE44jkegmns).
141
+
140
142
  ## Special Thanks
141
143
 
142
144
  A special thanks to the following projects who offered inspiration for this contributing file.
@@ -1,6 +1,98 @@
1
1
  ---
2
2
  title: Release History
3
3
  ---
4
+ # 3.1.4 (2025-02-09)
5
+ ## Highlights
6
+ This release contains various improvements and bugfixes to the matplotlib-based visualization of spaces. Hexgrids are now fully supported, including property layers. In making this possible, various minor bugs were encountered and also fixed. In addition to the visualization improvements, there are various minor convenience improvements to the docs.
7
+
8
+
9
+ ## What's Changed
10
+ ### 🛠 Enhancements made
11
+ * Fixed hex-space draw function to avoid overlaps by @Sahil-Chhoker in https://github.com/projectmesa/mesa/pull/2609
12
+ * Fix: Property layer visualization for HexGrid by @Sahil-Chhoker in https://github.com/projectmesa/mesa/pull/2646
13
+ * Enhance DataCollector to validate model_reporters functions by @peter-kinger in https://github.com/projectmesa/mesa/pull/2605
14
+ * Implemented post_process in Altair based components by @sanika-n in https://github.com/projectmesa/mesa/pull/2641
15
+ ### 🐛 Bugs fixed
16
+ * bugfix for draw_property_layer by @quaquel in https://github.com/projectmesa/mesa/pull/2639
17
+ * Uses array for hex grid property layer fix by @Sahil-Chhoker in https://github.com/projectmesa/mesa/pull/2651
18
+ * Update Binder environment to use latest Mesa version (#2652) by @aarav-shukla07 in https://github.com/projectmesa/mesa/pull/2655
19
+ * Change Hexgrid._connect_cells_2d to use x,y coordinates by @quaquel in https://github.com/projectmesa/mesa/pull/2632
20
+ ### 🔍 Examples updated
21
+ * Added property layer viz to sugarscape by @sanika-n in https://github.com/projectmesa/mesa/pull/2653
22
+ * added color-bar for spice by @sanika-n in https://github.com/projectmesa/mesa/pull/2622
23
+ ### 📜 Documentation improvements
24
+ * remove any reference to using --pre by @quaquel in https://github.com/projectmesa/mesa/pull/2618
25
+ * Updated Docs by @sanika-n in https://github.com/projectmesa/mesa/pull/2624
26
+ * Fixed 404 error for Examples Tab in Introductory Tutorial (#2662) by @aarav-shukla07 in https://github.com/projectmesa/mesa/pull/2664
27
+ * Documentation by @Spartan-71 in https://github.com/projectmesa/mesa/pull/2630
28
+ * Adding a copy option at the top of the code written in the docs by @PrashantChoudhary13579 in https://github.com/projectmesa/mesa/pull/2628
29
+ * Adding Mesa Extension page by @PrashantChoudhary13579 in https://github.com/projectmesa/mesa/pull/2627
30
+ ### 🔧 Maintenance
31
+ * remove remnants of mesa cli by @quaquel in https://github.com/projectmesa/mesa/pull/2617
32
+ * benchmarks.yml: Install SciPy and use uv for pip install by @EwoutH in https://github.com/projectmesa/mesa/pull/2633
33
+ * [pre-commit.ci] pre-commit autoupdate by @pre-commit-ci in https://github.com/projectmesa/mesa/pull/2659
34
+
35
+ ## New Contributors
36
+ * @PrashantChoudhary13579 made their first contribution in https://github.com/projectmesa/mesa/pull/2628
37
+ * @aarav-shukla07 made their first contribution in https://github.com/projectmesa/mesa/pull/2655
38
+ * @peter-kinger made their first contribution in https://github.com/projectmesa/mesa/pull/2605
39
+
40
+ **Full Changelog**: https://github.com/projectmesa/mesa/compare/v3.1.3...v3.1.4
41
+
42
+ # 3.1.3 (2025-01-11)
43
+ ## Highlights
44
+ Mesa 3.1.3 introduces a major experimental reimplementation of Mesa's continuous space, providing an intuitive agent-centric API and significant performance improvements. The new implementation supports n-dimensional spaces and offers streamlined methods for agent movement and neighbor calculations.
45
+
46
+ ### New Continuous Space Features
47
+ - Agent-centric movement API similar to cell spaces
48
+ - Efficient neighbor calculations and position updates
49
+ - Support for n-dimensional spaces
50
+ - Improved memory management with dynamic array resizing
51
+
52
+ Here's a quick look at the new API:
53
+
54
+ ```python
55
+ # Create a 2D continuous space
56
+ space = ContinuousSpace(
57
+ dimensions=[[0, 1], [0, 1]],
58
+ torus=True,
59
+ random=model.random
60
+ )
61
+
62
+ # Create and position an agent
63
+ agent = ContinuousSpaceAgent(space, model)
64
+ agent.position = [0.5, 0.5]
65
+
66
+ # Move agent using vector arithmetic
67
+ agent.position += [0.1, 0.1]
68
+
69
+ # Get neighbors within radius
70
+ neighbors, distances = agent.get_neighbors_in_radius(radius=0.2)
71
+
72
+ # Find k nearest neighbors
73
+ nearest, distances = agent.get_nearest_neighbors(k=5)
74
+ ```
75
+
76
+ The new implementation particularly benefits models requiring frequent position updates and neighbor queries, such as flocking simulations or particle systems. See [#2584](https://github.com/projectmesa/mesa/pull/2584) for more details. We would love to get feedback on the new Continuous Space in [#2611](https://github.com/projectmesa/mesa/discussions/2611).
77
+
78
+ Other improvements in this release include consistent visualization behavior across space types with the reimplementation of `draw_voronoi` [#2608](https://github.com/projectmesa/mesa/pull/2608), and a new render interval slider for controlling visualization update frequency in SolaraViz, which helps improve performance when working with complex visualizations [#2596](https://github.com/projectmesa/mesa/pull/2596). We've also fixed a bug affecting random number generation determinism when using `Model(seed=something)`, ensuring both `model.random` and `model.rng` now behave consistently when seeded with the same initial value [#2598](https://github.com/projectmesa/mesa/pull/2598).
79
+
80
+ ## What's Changed
81
+ ### 🧪 Experimental features
82
+ * Reimplementation of Continuous Space by @quaquel in https://github.com/projectmesa/mesa/pull/2584
83
+ ### 🛠 Enhancements made
84
+ * reimplementation of draw_voroinoi by @quaquel in https://github.com/projectmesa/mesa/pull/2608
85
+ * Add render interval slider to control visualization update frequency by @HMNS19 in https://github.com/projectmesa/mesa/pull/2596
86
+ ### 🐛 Bugs fixed
87
+ * Bugfix for non deterministic rng behavior by @quaquel in https://github.com/projectmesa/mesa/pull/2598
88
+ ### 🔍 Examples updated
89
+ * Clarify ContinuousSpace.get_neighbors behavior with multiple agents at same position by @quaquel in https://github.com/projectmesa/mesa/pull/2599
90
+
91
+ ## New Contributors
92
+ * @HMNS19 made their first contribution in https://github.com/projectmesa/mesa/pull/2596
93
+
94
+ **Full Changelog**: https://github.com/projectmesa/mesa/compare/v3.1.2...v3.1.3
95
+
4
96
  # 3.1.2 (2025-01-04)
5
97
  ## Highlights
6
98
  Mesa v3.1.2 is a patch release containing updates to our wolf-sheep, shelling and prisoner's dilemma example models and improving documentation in the tutorials and visualisation docstring. No functional changes to the core library were made.
@@ -1,6 +1,6 @@
1
1
  Metadata-Version: 2.4
2
2
  Name: Mesa
3
- Version: 3.1.2
3
+ Version: 3.1.4
4
4
  Summary: Agent-based modeling (ABM) in Python
5
5
  Project-URL: homepage, https://github.com/projectmesa/mesa
6
6
  Project-URL: repository, https://github.com/projectmesa/mesa
@@ -24,8 +24,10 @@ Classifier: Topic :: Scientific/Engineering :: Artificial Life
24
24
  Requires-Python: >=3.11
25
25
  Requires-Dist: numpy
26
26
  Requires-Dist: pandas
27
+ Requires-Dist: scipy
27
28
  Requires-Dist: tqdm
28
29
  Provides-Extra: all
30
+ Requires-Dist: altair; extra == 'all'
29
31
  Requires-Dist: ipython; extra == 'all'
30
32
  Requires-Dist: matplotlib; extra == 'all'
31
33
  Requires-Dist: myst-nb; extra == 'all'
@@ -40,7 +42,9 @@ Requires-Dist: scipy; extra == 'all'
40
42
  Requires-Dist: seaborn; extra == 'all'
41
43
  Requires-Dist: solara; extra == 'all'
42
44
  Requires-Dist: sphinx; extra == 'all'
45
+ Requires-Dist: sphinx-copybutton; extra == 'all'
43
46
  Provides-Extra: dev
47
+ Requires-Dist: altair; extra == 'dev'
44
48
  Requires-Dist: matplotlib; extra == 'dev'
45
49
  Requires-Dist: networkx; extra == 'dev'
46
50
  Requires-Dist: pytest; extra == 'dev'
@@ -50,6 +54,7 @@ Requires-Dist: ruff; extra == 'dev'
50
54
  Requires-Dist: solara; extra == 'dev'
51
55
  Requires-Dist: sphinx; extra == 'dev'
52
56
  Provides-Extra: docs
57
+ Requires-Dist: altair; extra == 'docs'
53
58
  Requires-Dist: ipython; extra == 'docs'
54
59
  Requires-Dist: matplotlib; extra == 'docs'
55
60
  Requires-Dist: myst-nb; extra == 'docs'
@@ -59,7 +64,9 @@ Requires-Dist: pydata-sphinx-theme; extra == 'docs'
59
64
  Requires-Dist: seaborn; extra == 'docs'
60
65
  Requires-Dist: solara; extra == 'docs'
61
66
  Requires-Dist: sphinx; extra == 'docs'
67
+ Requires-Dist: sphinx-copybutton; extra == 'docs'
62
68
  Provides-Extra: examples
69
+ Requires-Dist: altair; extra == 'examples'
63
70
  Requires-Dist: matplotlib; extra == 'examples'
64
71
  Requires-Dist: networkx; extra == 'examples'
65
72
  Requires-Dist: pytest; extra == 'examples'
@@ -68,10 +75,12 @@ Requires-Dist: solara; extra == 'examples'
68
75
  Provides-Extra: network
69
76
  Requires-Dist: networkx; extra == 'network'
70
77
  Provides-Extra: rec
78
+ Requires-Dist: altair; extra == 'rec'
71
79
  Requires-Dist: matplotlib; extra == 'rec'
72
80
  Requires-Dist: networkx; extra == 'rec'
73
81
  Requires-Dist: solara; extra == 'rec'
74
82
  Provides-Extra: viz
83
+ Requires-Dist: altair; extra == 'viz'
75
84
  Requires-Dist: matplotlib; extra == 'viz'
76
85
  Requires-Dist: solara; extra == 'viz'
77
86
  Description-Content-Type: text/markdown
@@ -106,27 +115,22 @@ can be displayed in browser windows or Jupyter.*
106
115
 
107
116
  ## Using Mesa
108
117
 
109
- To install our latest stable release (3.0.x), run:
118
+ To install our latest stable release, run:
110
119
 
111
120
  ``` bash
112
121
  pip install -U mesa
113
122
  ```
114
123
 
115
- To install our latest pre-release, run:
116
-
117
- ``` bash
118
- pip install -U --pre mesa
119
- ```
120
124
  Starting with Mesa 3.0, we don't install all our dependencies anymore by default.
121
125
  ```bash
122
126
  # You can customize the additional dependencies you need, if you want. Available are:
123
- pip install -U --pre mesa[network,viz]
127
+ pip install -U mesa[network,viz]
124
128
 
125
129
  # This is equivalent to our recommended dependencies:
126
- pip install -U --pre mesa[rec]
130
+ pip install -U mesa[rec]
127
131
 
128
132
  # To install all, including developer, dependencies:
129
- pip install -U --pre mesa[all]
133
+ pip install -U mesa[all]
130
134
  ```
131
135
 
132
136
  You can also use `pip` to install the latest GitHub version:
@@ -28,27 +28,22 @@ can be displayed in browser windows or Jupyter.*
28
28
 
29
29
  ## Using Mesa
30
30
 
31
- To install our latest stable release (3.0.x), run:
31
+ To install our latest stable release, run:
32
32
 
33
33
  ``` bash
34
34
  pip install -U mesa
35
35
  ```
36
36
 
37
- To install our latest pre-release, run:
38
-
39
- ``` bash
40
- pip install -U --pre mesa
41
- ```
42
37
  Starting with Mesa 3.0, we don't install all our dependencies anymore by default.
43
38
  ```bash
44
39
  # You can customize the additional dependencies you need, if you want. Available are:
45
- pip install -U --pre mesa[network,viz]
40
+ pip install -U mesa[network,viz]
46
41
 
47
42
  # This is equivalent to our recommended dependencies:
48
- pip install -U --pre mesa[rec]
43
+ pip install -U mesa[rec]
49
44
 
50
45
  # To install all, including developer, dependencies:
51
- pip install -U --pre mesa[all]
46
+ pip install -U mesa[all]
52
47
  ```
53
48
 
54
49
  You can also use `pip` to install the latest GitHub version:
@@ -90,14 +90,19 @@ configurations = {
90
90
  "seeds": 25,
91
91
  "replications": 3,
92
92
  "steps": 20,
93
- "parameters": {"population": 200, "width": 100, "height": 100, "vision": 5},
93
+ "parameters": {
94
+ "population_size": 200,
95
+ "width": 100,
96
+ "height": 100,
97
+ "vision": 5,
98
+ },
94
99
  },
95
100
  "large": {
96
101
  "seeds": 10,
97
102
  "replications": 3,
98
103
  "steps": 10,
99
104
  "parameters": {
100
- "population": 400,
105
+ "population_size": 400,
101
106
  "width": 150,
102
107
  "height": 150,
103
108
  "vision": 15,
@@ -1,4 +1,4 @@
1
- name: example-environment
1
+ name: mesa-tutorials
2
2
  channels:
3
3
  - conda-forge
4
4
  dependencies:
@@ -11,4 +11,4 @@ dependencies:
11
11
  - matplotlib
12
12
  - seaborn
13
13
  - solara
14
- - mesa[rec]==3.0.0b1
14
+ - mesa[rec]
@@ -15,6 +15,7 @@ Updating docs can be confusing. Here are the basic setups.
15
15
  1. Build the docs, from the inside of the docs folder.
16
16
  * **Requires** sphinx: `pip install sphinx`
17
17
  * **Requires** nbsphinx: `pip install nbsphinx` (this will render the images from jupyter in the docs)
18
+ * **Requires** sphinx-copybutton: `pip install sphinx-copybutton` (this will enable a copy option at the top of the code written in the docs)
18
19
  * `make html`
19
20
  1. Commit the changes. If there are new files, you will have to explicit add them.
20
21
  * `git commit -am "Updating docs."`
@@ -32,5 +33,5 @@ From this point, you will need to find someone that has access to readthedocs. C
32
33
  ### Helpful Sphnix tips
33
34
  * Build html from docs:
34
35
  * `make html`
35
- * Autogenerate / update sphninx from docstrings (replace your name as the author:
36
+ * Autogenerate / update sphninx from docstrings (replace your name as the author):
36
37
  * `sphinx-apidoc -A "Jackie Kazil" -F -o docs mesa/`
@@ -54,3 +54,15 @@ This namespace contains experimental features. These are under development, and
54
54
  .. automodule:: experimental.devs.simulator
55
55
  :members:
56
56
  ```
57
+
58
+ ## Continuous Space
59
+
60
+ ```{eval-rst}
61
+ .. automodule:: experimental.continuous_space.continuous_space
62
+ :members:
63
+ ```
64
+
65
+ ```{eval-rst}
66
+ .. automodule:: experimental.continuous_space.continuous_space_agents
67
+ :members:
68
+ ```
@@ -11,6 +11,13 @@ For a detailed tutorial, please refer to our [Visualization Tutorial](../tutoria
11
11
  :show-inheritance:
12
12
  ```
13
13
 
14
+ ```{eval-rst}
15
+ .. automodule:: mesa.visualization.components.__init__
16
+ :members:
17
+ :undoc-members:
18
+ :show-inheritance:
19
+ ```
20
+
14
21
  ## User Parameters
15
22
 
16
23
  ```{eval-rst}
@@ -37,6 +44,7 @@ For a detailed tutorial, please refer to our [Visualization Tutorial](../tutoria
37
44
  :show-inheritance:
38
45
  ```
39
46
 
47
+
40
48
  ## Altair-based visualizations
41
49
 
42
50
  ```{eval-rst}
@@ -47,6 +47,7 @@ extensions = [
47
47
  "sphinx.ext.viewcode",
48
48
  "sphinx.ext.napoleon", # for google style docstrings
49
49
  "myst_nb", # For Markdown and Jupyter notebooks
50
+ "sphinx_copybutton" # For copying the code in the documentation
50
51
  ]
51
52
 
52
53
  # Add any paths that contain templates here, relative to this directory.
@@ -68,7 +68,6 @@ model.step()
68
68
 
69
69
  You should see agents 1-5, activated in random order. See the [tutorial](tutorials/intro_tutorial) or API documentation for more detail on how to add model functionality.
70
70
 
71
- To bootstrap a new model install mesa and run `mesa startproject`
72
71
 
73
72
  ### AgentSet and model.agents
74
73
  Mesa 3.0 makes `model.agents` and the AgentSet class central in managing and activating agents.
@@ -178,8 +177,7 @@ The results are returned as a list of dictionaries, which can be easily converte
178
177
  ### Visualization
179
178
  Mesa now uses a new browser-based visualization system called SolaraViz. This allows for interactive, customizable visualizations of your models.
180
179
 
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
-
180
+ Note: SolaraViz is experimental and still in active development in Mesa 3.x. While we attempt to minimize them, there might be API breaking changes in minor releases.
183
181
  > **Note:** SolaraViz instantiates new models using `**model_parameters.value`, so all model inputs must be keyword arguments.
184
182
 
185
183
  Ensure your model's `__init__` method accepts keyword arguments matching the `model_params` keys.
@@ -189,8 +187,8 @@ class MyModel(Model):
189
187
  def __init__(self, n_agents=10, seed=None):
190
188
  super().__init__(seed=seed)
191
189
  # Initialize the model with N agents
192
-
193
- The core functionality for building your own visualizations resides in the [`mesa.visualization`](apis/visualization) namespace
190
+ ```
191
+ The core functionality for building your own visualizations resides in the [`mesa.visualization`](apis/visualization) namespace.
194
192
 
195
193
  Here's a basic example of how to set up a visualization:
196
194
 
@@ -33,7 +33,7 @@ Mesa allows users to quickly create agent-based models using built-in core compo
33
33
 
34
34
  ## Using Mesa
35
35
  ### Installation Options
36
- To install our latest stable release (3.0.x), run:
36
+ To install our latest stable release, run:
37
37
 
38
38
  ```bash
39
39
  pip install -U mesa
@@ -47,12 +47,6 @@ On a Mac, this command might cause an error stating `zsh: no matches found: mesa
47
47
  In that case, change the command to `pip install -U "mesa[rec]"`.
48
48
 
49
49
 
50
- To install our latest pre-release:
51
-
52
- ```bash
53
- pip install -U --pre mesa[rec]
54
- ```
55
-
56
50
  ### Resources
57
51
 
58
52
  For help getting started with Mesa, check out these resources:
@@ -60,6 +54,7 @@ For help getting started with Mesa, check out these resources:
60
54
  - [Getting started] - Learn about Mesa's core concepts and components
61
55
  - [Migration Guide] - Upgrade to Mesa 3.0
62
56
  - [Mesa Examples] - Browse user-contributed models and implementations
57
+ - [Mesa Extensions] - Overview of mesa's Extensions
63
58
  - [GitHub Discussions] - Ask questions and discuss Mesa
64
59
  - [Matrix Chat Room] - Real-time chat with the Mesa community
65
60
 
@@ -97,9 +92,9 @@ API Documentation <apis/api_main>
97
92
  [matrix chat room]: https://matrix.to/#/#project-mesa:matrix.org
98
93
  [mesa]: https://github.com/projectmesa/mesa/
99
94
  [mesa overview]: overview
100
- [mesa examples]: https://github.com/projectmesa/mesa-examples
95
+ [mesa examples]: https://mesa.readthedocs.io/stable/examples.html
101
96
  [mesa introductory tutorial]: tutorials/intro_tutorial
102
97
  [mesa visualization tutorial]: tutorials/visualization_tutorial
103
98
  [migration guide]: migration_guide
104
99
  [Getting started]: getting_started
105
-
100
+ [Mesa Extensions]: mesa_extension.md
@@ -0,0 +1,97 @@
1
+ # Mesa Extensions Overview
2
+
3
+ This contains an overview of Mesa Extensions. Mesa's extensibility is a key feature that allows users to enhance functionality, improve scalability, and foster innovation in agent-based modeling.
4
+
5
+
6
+ ## Mesa-Geo 🌍
7
+
8
+ **Field:** Geographic Information Systems (GIS)
9
+
10
+ ---
11
+ **Description:**
12
+ Mesa-Geo is an extension of the Mesa framework designed to facilitate working with geographic data in agent-based modeling. It introduces a **GeoSpace** to host **GeoAgents**, which are enhanced agents that include a `geometry` attribute ([a Shapely object](https://shapely.readthedocs.io/en/latest/manual.html)) and a `crs` attribute (Coordinate Reference System). These attributes enable the integration of geographic and spatial data into simulations. Geometries can be defined manually using Shapely or imported from various sources, such as vector data files (e.g., shapefiles), GeoJSON objects, or GeoPandas GeoDataFrames.
13
+
14
+ ---
15
+ **Key Features:**
16
+ - **Spatial Reference Systems Support:** Mesa-Geo handles coordinate reference systems (CRS), which is essential for working with geographic data in various projections.
17
+ - **Geometric Operations Support:** Mesa-Geo utilizes Shapely, which provides robust tools for creating and manipulating geometric shapes like points, polygons, and lines.
18
+ - **Topological Operations Support:** Functions for analyzing spatial relationships between geometries.
19
+
20
+ ---
21
+ **Author(s):** Wang Boyu
22
+
23
+ ---
24
+ **Additional Resources:**
25
+ For more information, visit the official [Mesa-Geo repository](https://github.com/projectmesa/mesa-geo?tab=readme-ov-file).
26
+
27
+ ---
28
+
29
+ ## Mesa Examples 📊
30
+
31
+ **Description:**
32
+ Mesa Examples provide a collection of models and use cases demonstrating the features and capabilities of the Mesa framework for agent-based modeling. These examples include core and user-submitted models covering a variety of domains like grid spaces, networks, visualization, and GIS.
33
+
34
+ ---
35
+
36
+ **Key Features:**
37
+ - **Core Examples:** Fully tested and updated models included directly with the Mesa framework.
38
+ - **User Examples:** Community-contributed models showcasing advanced and diverse use cases.
39
+ - **Extensive Coverage:** Examples for grid spaces, GIS integration, networks, visualization, and more.
40
+ - **Easy Access:** Available directly from the Mesa package or via installation from the repository.
41
+
42
+ ---
43
+
44
+ **Author(s):** Contributions from the Mesa developer community.
45
+
46
+ ---
47
+
48
+ **Examples Include:**
49
+ - **Grid Space:** Models like Bank Reserves, Conway’s Game of Life, and Forest Fire.
50
+ - **GIS:** GeoSchelling Models, Urban Growth, and Population Models.
51
+ - **Network:** Boltzmann Wealth Model and Ant System for the Traveling Salesman Problem.
52
+ - **Visualization:** Charting tools and grid displays.
53
+
54
+ ---
55
+
56
+ **For More Information:**
57
+ For more Detail, Visit the [Mesa Examples Repository](https://github.com/projectmesa/mesa/tree/main/mesa/examples).
58
+
59
+ ---
60
+
61
+ ## **Mesa-Frames** 🚀
62
+
63
+ **Description:**
64
+ Mesa-Frames is an extension of the Mesa framework designed to handle complex simulations with thousands of agents. By utilizing DataFrames (pandas or Polars), it enhances scalability and performance while maintaining a syntax similar to Mesa.
65
+
66
+ ---
67
+
68
+ **Key Features:**
69
+ - **Enhanced Performance:** Uses DataFrames for SIMD processing and vectorized functions to speed up simulations.
70
+ - **Backend Support:** Supports `pandas` (ease of use) and `Polars` (performance innovations with Rust-based backend).
71
+ - **Seamless Integration:** Maintains a similar API and functionality as the base Mesa framework for easier adoption.
72
+ - **In-Place Operations:** Functional programming and fast memory-efficient copy methods.
73
+ - **Future Plans:** GPU functionality, automatic model vectorization, and backend-independent AgentSet class.
74
+
75
+ ---
76
+
77
+ **Usage:**
78
+ - Define agents using `AgentSetPandas` or `AgentSetPolars`.
79
+ - Implement models by subclassing `ModelDF`.
80
+ - Perform vectorized operations to enhance simulation performance.
81
+
82
+ ---
83
+
84
+ **Author(s):**
85
+ Developed and maintained by the Mesa development community.
86
+
87
+ ---
88
+
89
+ **License:**
90
+ Distributed under the MIT License.
91
+
92
+ ---
93
+
94
+ **More Information:**
95
+ Visit the [GitHub Repository](https://github.com/projectmesa/mesa-frames).
96
+
97
+ ---
@@ -15,7 +15,7 @@
15
15
  "source": [
16
16
  "**Important:** \n",
17
17
  "- If you are just exploring Mesa and want the fastest way to execute the code we recommend executing this tutorial online in a Colab notebook. [![Colab](https://colab.research.google.com/assets/colab-badge.svg)](https://colab.research.google.com/github/projectmesa/mesa/blob/main/docs/tutorials/intro_tutorial.ipynb) or if you do not have a Google account you can use [![Binder](https://mybinder.org/badge_logo.svg)](https://mybinder.org/v2/gh/projectmesa/mesa/main?labpath=docs%2Ftutorials%2Fintro_tutorial.ipynb) (This can take 30 seconds to 5 minutes to load)\n",
18
- "- If you have installed mesa and are running locally, please ensure that your Mesa version is greater than or equal to 3.0.0b1.\n",
18
+ "- If you are running locally, please ensure you have the latest Mesa version installed.\n",
19
19
  "\n",
20
20
  "## Tutorial Description\n",
21
21
  "\n",
@@ -44,7 +44,7 @@
44
44
  "If you are looking for other Mesa models or tools here are some additional resources. \n",
45
45
  "\n",
46
46
  "- Interactive Dashboard: There is a separate [visualization tutorial](https://mesa.readthedocs.io/latest/tutorials/visualization_tutorial.html) that will take users through building a dashboard for this model (aka Boltzmann Wealth Model).\n",
47
- "- Classic ABMs: You can also find canonical examples of ABMs written in Mesa in the [Examples Tab](https://mesa.readthedocs.io/latest/tutorials/examples.html)\n",
47
+ "- Classic ABMs: You can also find canonical examples of ABMs written in Mesa in the [Examples Tab](https://mesa.readthedocs.io/stable/examples.html)\n",
48
48
  "- More Examples: Want to integrate Reinforcement Learning or work on the Traveling Salesman Problem checkout [Mesa Examples](https://github.com/projectmesa/mesa-examples/)\n",
49
49
  "- Mesa-Geo: If you need an ABM with Geographic Information Systems (GIS) checkout [Mesa-Geo](https://mesa-geo.readthedocs.io/latest/)\n",
50
50
  "- Mesa Frames: Have a large complex model that you need to speed up, check out [Mesa Frames](https://github.com/projectmesa/mesa-frames)"
@@ -85,12 +85,6 @@
85
85
  "pip install --upgrade mesa[rec] \n",
86
86
  "```\n",
87
87
  "\n",
88
- "If you want to use our newest features, you can also opt to install our latest pre-release version:\n",
89
- "\n",
90
- "```bash\n",
91
- "pip install --upgrade --pre mesa[rec]\n",
92
- "```\n",
93
- "\n",
94
88
  "Install Jupyter notebook (optional):\n",
95
89
  "\n",
96
90
  "```bash\n",
@@ -118,7 +112,7 @@
118
112
  "cell_type": "raw",
119
113
  "metadata": {},
120
114
  "source": [
121
- "pip install --quiet --upgrade --pre mesa[rec] #installs Mesa 3.0"
115
+ "pip install --quiet --upgrade mesa[rec] #installs Mesa 3.1.3"
122
116
  ]
123
117
  },
124
118
  {
@@ -615,8 +609,8 @@
615
609
  " # Create agents\n",
616
610
  " agents = MoneyAgent.create_agents(model=self, n=n)\n",
617
611
  " # Create x and y positions for agents\n",
618
- " x = self.rng.randint(0, self.grid.width, size=(n,))\n",
619
- " y = self.rng.randint(0, self.grid.height, size=(n,))\n",
612
+ " x = self.rng.integers(0, self.grid.width, size=(n,))\n",
613
+ " y = self.rng.integers(0, self.grid.height, size=(n,))\n",
620
614
  " for a, i, j in zip(agents, x, y):\n",
621
615
  " # Add the agent to a random grid cell\n",
622
616
  " self.grid.place_agent(a, (i, j))"
@@ -11,9 +11,7 @@
11
11
  "cell_type": "markdown",
12
12
  "metadata": {},
13
13
  "source": [
14
- "*This version of the visualisation tutorial is updated for Mesa 3.0, and works with Mesa `3.0.0` and above.*\n",
15
- "\n",
16
- "> **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.\n",
14
+ "*This version of the visualisation tutorial is updated for Mesa 3.1, and works with Mesa `3.1.0` and above.*\n",
17
15
  "\n",
18
16
  "**Important:** \n",
19
17
  "- If you are just exploring Mesa and want the fastest way to the the dashboard and code checkout [![py.cafe](https://img.shields.io/badge/launch-py.cafe-blue)](https://py.cafe/app/tpike3/boltzmann-wealth-model) (click \"Editor\" to see the code)\n",
@@ -22,7 +22,7 @@ __all__ = [
22
22
  ]
23
23
 
24
24
  __title__ = "mesa"
25
- __version__ = "3.1.2"
25
+ __version__ = "3.1.4"
26
26
  __license__ = "Apache 2.0"
27
27
  _this_year = datetime.datetime.now(tz=datetime.UTC).date().year
28
28
  __copyright__ = f"Copyright {_this_year} Project Mesa Team"