Skip to content

alexsysctrl/forest-fire-mesa4-fix

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

2 Commits
 
 
 
 
 
 

Repository files navigation

forest-fire-mesa4-fix

Updated Forest Fire notebook compatible with Mesa 4.x.

The Problem

The original forest_fire notebook uses deprecated Mesa 2.x APIs:

  • BatchRunner → removed in Mesa 4
  • fire.run_model() → deprecated
  • fire.dc → renamed to fire.datacollector
  • df.BurnedOut → column is "Burned Out" in batch_run output

The Fix

This repo provides a working Mesa 4.x compatible version of the forest fire example with:

  • batch_run() instead of BatchRunner
  • Updated DataCollector access
  • Correct column names
  • SolaraViz visualization

Usage

pip install mesa[solara]
python forest_fire_m4.py
solara run app.py

Credits

Created to help Mesa community fix issue #421.

About

Mesa 4.x compatible Forest Fire example fixing deprecated BatchRunner API

Topics

Resources

License

Stars

Watchers

Forks

Releases

No releases published

Packages

 
 
 

Contributors

Languages