ℹ️ This package is under continuous development
aiphoria is Python package that facilitates the assessment of wood materials flows, associated carbon stocks, and stock changes, as well as and their visualization over time. aiphoria builds on top of ODYM - Open Dynamic Material Systems Model.
aiphoria allows you to:
- Solve flows provided both in absolute and relative (%) values, for example semi-finished wood product statistics (absolute values) to end-uses (relative values)
- Conduct dynamic MFA as well as temporary carbon storage assessment
- Visualize material flows through a Sankey diagram and provided timestep.
aiphoria is ideal for:
- Any temporal and spatial situation where material systems want to be assessed
- Product sink/stock effects
aiphoria is available at Python Package Index (PyPi) and as source distribution in Github
pip install aiphoria
pip install git+https://github.com/EuropeanForestInstitute/aiphoria.git
aiphoria includes helper function to showcase example scenario with visualizations.
Showcase / example scenario can be run by the following code:
from aiphoria.example import run_example
run_example(remove_existing_output_dir=True)Network and Sankey visualizations are opened automatically in browser and output is generated
inside user home directory to directory called "aiphoria_example_scenario".
For the users who are already familiar using aiphoria the package exposes function for running scenarios by using the one-liner:
from aiphoria.runner import run_scenarios
run_scenarios(path_to_settings_file="path/to/scenario/file.xlsx",
path_to_output_dir="~/scenario_result",
remove_existing_output_dir=False)Using parameter path_to_output_dir overrides the output path defined in scenario file.
This makes easier to change target from Python script itself or when running multiple scenarios in batch.
Parameters:
- path_to_settings_file (string): Path to scenario settings file
- path_to_output_dir (string): Path to directory where results are saved
- remove_existing_output_dir: If True then existing output directory is deleted (defaults to False). If directory already exists then error is raised and execution is stopped
Online documentation can be found in GitHub wiki.
If you have any questions or need help, do not hesitate to contact us:
- Cleo Orfanidou cleo.orfanidou@efi.int
- Janne Järvikylä janne.jarvikyla@efi.int
A huge thank you to the following people who made aiphoria better:
-
Gustavo Ezequiel Martinez (virtual flows, system testing)
- GitHub: GustavoEzMartinez
- Email: gustavoezequiel.martinez@vito.be
-
Arthur Jakobs (packaging, CI/CD)
- GitHub: https://github.com/jakobsarthur
- Email: artos.jakobs@psi.ch