This Python-based toolbox is designed to optimize geothermal reservoir development by combining advanced Thermo-Hydro-Mechanical (THM) numerical modeling, machine learning (ML) optimization routines, and automated feedback loops. The goal is to maximize total heat energy production while minimizing the risk of induced seismicity on known faults.
-
THM Reservoir Models
Simulate the coupled thermal, hydraulic, and mechanical behavior of the subsurface, based on geological models derived from seismic data.
-
Machine Learning Optimization
Algorithms adjust well locations and operational parameters (e.g., flow rate, injection temperature) to balance maximum heat recovery with minimal seismic risk.
-
Linking & Automation Scripts
Scripts facilitate communication between the THM simulations and ML routines, enabling iterative simulation cycles to determine optimal well placement and operation.
- Operating System: Ubuntu 22.04 (recommended)
- Python Version: 3.12 (configured in the Makefile)
- Make and common Unix tools: git, curl
To install basic dependencies (git
, curl
) essential for setup, run:
make prerequisites
You can install either a development environment (recommended for developers) or a streamlined release environment.
This installs all the necessary tools, including development dependencies, pre-commit hooks, Docker, LaTeX, and Python/uv environments:
make install-dev
This command will specifically:
- Install Python 3.12 and set up a virtual environment using
uv
. - Install LaTeX and TeXstudio for documentation purposes.
- Install Docker, verifying its functionality.
- Install all Python development dependencies and pre-commit hooks.
Note: Currently, Windows OS is not supported for this setup.
Installs only the dependencies necessary to run the application in a production setting. Run:
make install-release
To edit the project documentation using TeXstudio, execute:
make edit-docs
- This will open the documentation in TeXstudio if installed.
- If TeXstudio is not detected, please install it along with LaTeX by running:
make install-latex
Maintain codebase quality by executing pre-commit hooks:
make run-check
Docker is necessary for building and containerizing deployments. Install it using:
make install-docker
After installation, verify Docker functionality with:
make verify-docker
- If for some reason you did not initially run
make install-dev
ormake install-release
, activate the Python virtual environment manually and install git hooks by running:
source .venv/bin/activate
pre-commit install
Use pytest
to run the project's test suite:
pytest
To perform project compliance checks manually, run:
make run-check
- Familiarity with Unix commands and the
make
utility is assumed. - If you encounter issues during installation or operational errors, verify system compatibility and reread the instructions carefully.