Mesa 3.0 beta 2
Pre-releaseHighlights
Mesa 3.0 beta 2 includes major work on the example models, docs, a new tutorial and visualisation.
The included example models are now part of the Mesa package itself and directly importable, using:
from mesa.examples import BoidFlockers, BoltzmannWealthModel, ConwaysGameOfLife, ...
The advanced examples were also restructured and cleaned up.
The tutorial was completely rewritten for Mesa 3.0, including it's latest features and practices. Many of our other docs also received some love, and almost everything is now ready for Mesa 3.0.
A new feature to remove all agents from the model was added, and the visualisation now supports drawing the experimental discrete spaces in both matplotlib and altair. All agents which are in a space can now conveniently be accessed with .agents
.
The rarely used mesa startproject
cookiecutter feature was removed. We updated our best-practice guide to include how to structure a modern Mesa project, which is now very straightforward.
What's Changed
⚠️ Breaking changes
🧪 Experimental features
🎉 New features added
- remove_all_agents method added to model by @quaquel in #2394
- Pass through model.rgn in agent analogous to model.random by @quaquel in #2400
- add agents property to all spaces by @quaquel in #2418
🛠 Enhancements made
🐛 Bugs fixed
- Fix for mistaken removal of _draw_grid by @quaquel in #2398
- fixes weakref bug in shuffe_do by @quaquel in #2399
🔍 Examples updated
- refactor: Simplify Schelling code by @rht in #2353
- Move examples into mesa by @Corvince in #2387
- Explicitly test basic examples by @quaquel in #2390
- Make example import absolute by @quaquel in #2402
- Cleanup and restructure EpsteinCivilViolence and PdGrid examples by @EwoutH in #2408
- Reorganize advanced examples: wolf_sheep and sugarscape_g1mt by @quaquel in #2410
- reactivate ruff for advanced examples and include them in tests by @quaquel in #2414
📜 Documentation improvements
- Include examples in readthedocs (port) by @EwoutH in #2392
- Update into_tutorial by @tpike3 in #2372
- Update Schelling Readme.md by @quaquel in #2406
- Update Conway example by @quaquel in #2403
- Boltzman readme by @quaquel in #2405
- Update Readme.md of Boid flockers by @quaquel in #2404
- add advanced examples to rtd by @quaquel in #2413
- Tutorial Improvements by @tpike3 in #2415
- space: Add note that Grids are maintenance only by @EwoutH in #2420
- Migration guide: Update automatic unique_id assignment examples by @EwoutH in #2419
- Update docstring of SimEvent by @quaquel in #2417
🔧 Maintenance
Full Changelog: v3.0.0b1...v3.0.0b2