A modular Python ecosystem for spatially explicit dynamic modeling — Cellular Automata, System Dynamics, and Land Use & Cover Change simulation.
Ecosystem
Each package has a focused role. Use the core alone or combine extensions for complex geospatial simulations.
Design
Every simulation is a traceable experiment. Coefficients live in versioned TOML files, not buried in code.
Each run produces an immutable ExperimentRecord capturing provenance, input SHA-256 checksums, and model commit — ready to cite in a paper.
Calibrated coefficients live in versioned TOML files in dissmodel-configs, reviewed via PR before publication. Never hardcoded, always citeable by git hash.
Science logic stays pure in the Model layer. The ModelExecutor wraps I/O, column mapping, and provenance — without touching the science.
Built on JupyterLab, FastAPI, Redis, and MinIO via Docker Compose. Pangeo / BDC integration planned for a future release.
┌─────────────────────────────────┐ │ DisSModel Platform │ │ │ │ FastAPI │ │ ├── POST /submit_job │ │ ├── GET /job/{id} │ │ └── POST /experiments/repro │ │ │ │ Worker │ │ ├── ExecutorRegistry │ │ ├── ModelExecutor ABC │ │ └── Dask Client │ ├─────────────────────────────────┤ │ dissmodel-configs │ │ ├── models/brmangue.toml │ │ └── models/dissluc.toml │ ├─────────────────────────────────┤ │ Infrastructure │ │ JupyterLab · MinIO · Dask │ └─────────────────────────────────┘
Reference Application
The brmangue-dissmodel repository demonstrates DisSModel on real data from Maranhão, Brazil —
implementing flood propagation and mangrove migration based on Bezerra et al. (2014).
Pure simulation logic — no I/O, no infrastructure. Works standalone in a notebook or script.
from dissmodel import Environment env = Environment(start_time=2008, end_time=2030) FloodModel(gdf=gdf, taxa_elevacao=0.5, attr_uso="uso") MangroveModel(gdf=gdf, altura_mare=6.0, attr_solo="solo") env.run()
Wraps the model with I/O, column mapping, provenance, and platform integration.
class CoastalVectorExecutor(ModelExecutor):
name = "brmangue_vector"
def load(self, record: ExperimentRecord) -> GeoDataFrame:
# load + apply column_map → canonical names
...
def run(self, data, record: ExperimentRecord):
# build env + models, call env.run()
...
The same executor runs locally via CLI or remotely via the platform API.
python main.py run \ --input data/input/mangue_grid.zip \ --output data/output/simulation.gpkg \ --param end_time=2030