Skip to content

Index

  1. About Fire2a
  2. Getting help
  3. Contributing
  4. Developer setup

About Fire2a

We are a team dedicated to finding scientific and technological solutions to mitigate the effects of wildfires. We believe open-source collaboration is key and also providing custom consulting services for real-world organizations. Contact us

Our solutions involve the development of novel methodologies through the integration of various mathematical and technological tools. These tools include machine learning for fire ignition modeling, spatially explicit wildfire simulators, fire risk metrics, species distribution models, stochastic and multiobjective optimization, and simulation-based optimization.

Our goal is create fire-resilient landscapes while minimizing potential carbon emissions, protecting wildlife biodiversity, and ensuring the safety of human communities.

Main repos overview:

1. Cell2FireW: C++ command line WildFire simulator (forked)

2. Fire-Analytics-ToolBox: Friendly QGIS Processing Toolbox Plugin, interfacing our tools (simulation, optimization, GIS tasks and algorithm, etc.) in various ways, including easy to use clickable dialogs.

3. Algorithms-libs: Python package with algorithms and common GIS tasks.

4. Documentation: End user documentation, including Cell2Fire, Qgis-Toolbox, QGIS recipes, install & plugin management. Check it here

Getting help

Contributing

All contibutions are welcome, for effectiveness please follow:

  • Git etiquette
  • Coding style
  • Code formatting (each repo has it's own configuration... clang-format, black+friends)
  • Issues and Pull Requests minimal consistency:
    1. Check getting help before posting an issue
    2. Pull Requests must be associated to a corresponding issue that explains the motivation for the change and the expected outcome.
    3. Add a comment with an overview of the changes made
    4. One feature/bugfix per pull request
  • Scientific citations: Fire research deals with real life or death risks; If your code involves scientific models or calculations, include citations in BibText format. More info Cell2Fire-W/docs/README.md

Developer setup

Pick your poison:

  • Containerized, building on top of the official QGIS container
  • Or manual, system-wide installing QGIS and using it through a python virtual environment

Container

Long tutorial TL;DR:

  1. Clone the repos: Cell2FireW, Fire-Analytics-ToolBox, Algorithms-libs
  2. Get Containerfile and build.sh; Build the image (that mounts the repos and runs the build script).
  3. Run the container, enable our plugin in QGIS.
# required packages podman & git
sudo apt install podman git wget

# the current directory will be shared to the container
# let's start with an empty one
mkdir fire2a
cd fire2a

# get Containerfile and build.sh
wget https://raw.githubusercontent.com/fire2a/.github/refs/heads/main/build.sh
wget https://raw.githubusercontent.com/fire2a/.github/refs/heads/main/Containerfile

# clone the repos
git clone git@github.com:fire2a/C2F-W.git
git clone git@github.com:fire2a/fire-analytics-qgis-processing-toolbox-plugin.git toolbox
git clone git@github.com:fire2a/fire2a-lib.git

# build the container mounting the current directory into container user's home (/root)
podman build --tag qgis-fire2a --volume $(pwd):/root .

# run the container also with display capabilities
podman run -it --env DISPLAY=$DISPLAY --volume /tmp/.X11-unix:/tmp/.X11-unix --volume $(pwd):/root --device /dev/dri --name fire2a qgis-fire2a

# re-run the container
podman start fire2a
podman stop fire2a

Keep in mind that any changes made to the container's filesystem are lost when stopped except those made into the user's home (/root). This includes all temporary generated layers (whose files are generated into /tmp/processing...), so to keep them, save them home (--volume $(pwd):/root).

Manual

  1. Install the latest QGIS
  2. Clone the repos
  3. Symbolic link them
  4. Run QGIS

1. Get latest qgis

# required packages
sudo apt install gnupg software-properties-common wget

# add the key
sudo wget -O /etc/apt/keyrings/qgis-archive-keyring.gpg https://download.qgis.org/downloads/qgis-archive-keyring.gpg

# add the repo to sources.list (is the suite still bookworm?)
echo 'Types: deb deb-src
URIs: https://qgis.org/debian
Suites: bookworm
Architectures: amd64
Components: main
Signed-By: /etc/apt/keyrings/qgis-archive-keyring.gpg' | sudo tee /etc/apt/sources.list.d/qgis.sources

# install
sudo apt update
sudo apt install qgis qgis-plugin-grass

2. Get Cell2Fire, python libs and QGIS toolboox-plugin

# choose install location, below ~/fire is used
fire=~/fire
mkdir -p "$fire"

# get Cell2FireW
cd "$fire"
git clone git@github.com:fire2a/C2F-W.git
sudo apt install g++-12 libboost-all-dev libeigen3-dev libtiff-dev
cd C2F-W/Cell2Fire
make clean
make

# get python library
cd "$fire"
sudo apt install python3-venv 
python3 -m venv venv --system-site-packages # needs system qgis packages
source "$fire/venv/bin/activate"
git clone git@github.com:fire2a/fire2a-lib.git lib
cd lib
pip install -r requirements.build.txt
pip install -r requirements.code.txt
pip install -r requirements.txt
pip install --editable .

# get toolbox
cd "$fire"
git clone git@github.com:fire2a/fire-analytics-qgis-processing-toolbox-plugin.git toolbox

3. symlink them

plugins_dir=~/.local/share/QGIS/QGIS3/profiles/default/python/plugins/

 # if never opened QGIS
mkdir -p $plugins_dir

# toolbox to QGIS plugins
ln -sf "$(fire)/toolbox/fireanalyticstoolbox" "$plugins_dir/fireanalyticstoolbox"

# C2F to toolbox
ln -sf "$(fire)/C2F-W" "$(fire)/toolbox/fireanalyticstoolbox/simulator/C2F"

4. run

source $fire/venv/bin/activate
qgis

Enable our plugin on Plugins>Manage..>Installed> enable the check box on 'FireFire Analytics Processing-Toolbox'

Official tutorial

Pinned Loading

  1. C2F-W C2F-W Public

    Joint version of Cell2Fire, beta version with S&B and Kitral

    AGS Script 7 2

  2. fire-analytics-qgis-processing-toolbox-plugin fire-analytics-qgis-processing-toolbox-plugin Public

    QGIS>Plugins>ManageAnd...>Settings>Add>URL: https://fire2a.github.io/fire-analytics-qgis-processing-toolbox-plugin/plugins.xml Search:Fire>Install Plugin

    Python 4 3

  3. fire2a-lib fire2a-lib Public

    Forked from fdobad/template-python-package

    Algorithms and tools python package

    Python 1 1

  4. docs docs Public

    Fire2a research group documentation

    Shell 1 2

Repositories

Showing 10 of 17 repositories
  • C2F-W Public

    Joint version of Cell2Fire, beta version with S&B and Kitral

    fire2a/C2F-W’s past year of commit activity
    AGS Script 7 GPL-3.0 2 44 (1 issue needs help) 8 Updated Mar 12, 2025
  • fire2a/fire-analytics-qgis-processing-toolbox-plugin’s past year of commit activity
    Python 4 AGPL-3.0 3 4 6 Updated Mar 12, 2025
  • .github Public

    Profile page: https://github.com/fire2a

    fire2a/.github’s past year of commit activity
    Shell 0 AGPL-3.0 0 0 0 Updated Mar 12, 2025
  • qgis-pan-europeo Public

    Proof of concept of Pan European Raster Algorithms (PERA Project)

    fire2a/qgis-pan-europeo’s past year of commit activity
    Python 2 AGPL-3.0 0 2 0 Updated Mar 11, 2025
  • on-boarding Public
    fire2a/on-boarding’s past year of commit activity
    0 4 1 5 Updated Mar 11, 2025
  • fire2a-lib Public Forked from fdobad/template-python-package

    Algorithms and tools python package

    fire2a/fire2a-lib’s past year of commit activity
    Python 1 GPL-3.0 2 0 4 Updated Feb 28, 2025
  • Geospatial-Data-Cube-Generator Public

    Google Colab notebook for processing geospatial data with Google Earth Engine. Extracts topographic, climatic, and spectral variables, reprojects, compresses, and exports data as GeoTIFFs.

    fire2a/Geospatial-Data-Cube-Generator’s past year of commit activity
    Jupyter Notebook 0 0 0 0 Updated Feb 14, 2025
  • docs Public

    Fire2a research group documentation

    fire2a/docs’s past year of commit activity
    Shell 1 2 0 5 Updated Feb 10, 2025
  • growth Public

    A timber plantation growth simulator, with stands and management policies options.

    fire2a/growth’s past year of commit activity
    Python 0 AGPL-3.0 2 1 0 Updated Jan 2, 2025
  • fire2a/FireScar-Mapper-Plugin’s past year of commit activity
    Python 0 0 0 1 Updated Dec 31, 2024