A curated list of open technology projects to sustain a stable climate, energy supply, biodiversity and natural resources.

ASSUME

An open-source toolbox for agent-based simulations of European electricity markets, with a primary focus on the German market setup.
https://github.com/assume-framework/assume

Category: Energy Systems
Sub Category: Energy Markets

Last synced: about 22 hours ago
JSON representation

Repository metadata

ASSUME - Agent-based Simulation for Studying and Understanding Market Evolution

README.md

ASSUME: Agent-Based Electricity Markets Simulation Toolbox

Lint Status
Code Coverage
DOI
REUSE status





Try examples in Colab

ASSUME is an open-source toolbox for agent-based simulations of European electricity markets, with a primary focus on the German market setup. Developed as an open-source model, its primary objectives are to ensure usability and customizability for a wide range of users and use cases in the energy system modeling community.

Introduction

A unique feature of the ASSUME toolbox is its integration of Deep Reinforcement Learning methods into the behavioral strategies of market agents. The model offers various predefined agent representations for both the demand and generation sides, which can be used as plug-and-play modules, simplifying the reinforcement of learning strategies. This setup enables research into new market designs and dynamics in energy markets.

Documentation

Installation

You can install ASSUME using pip. Choose the appropriate installation method based on your needs:

Using pip

To install the core package:

pip install assume-framework

To install with reinforcement learning capabilities:

pip install 'assume-framework[learning]'

Please keep in mind, that the above installation method will install pytorch package without CUDA support. If you want to make use of your GPU with CUDA cores, please install pytorch with GPU support separately as described here.

We also include network-based market clearing algorithms such as for the re-dispatch or nodal market clearing, which requires the PyPSA library. To install the package with these capabilities, use:

pip install 'assume-framework[network]'

To install with all capabilities:

pip install 'assume-framework[all]'

Timescale Database and Grafana Dashboards

If you want to benefit from a supported database and integrated Grafana dashboards for scenario analysis, you can use the provided Docker Compose file.

Follow these steps:

  1. Clone the repository and navigate to its directory:
git clone https://github.com/assume-framework/assume.git
cd assume
  1. Start the database and Grafana using the following command:
docker-compose up -d

This will launch a container for TimescaleDB and Grafana with preconfigured dashboards for analysis. You can access the Grafana dashboards at http://localhost:3000.

Using TensorBoard to display Learning Metrics

When running an example with learning capabilities, you can start TensorBoard to observe the learning process. Use the following shell command to start TensorBoard:

tensorboard --logdir tensorboard

You can then head to http://localhost:6006/ to view and evaluate the training progress.

Please note that TensorBoard should ideally be shut down via Ctrl + C every time you want to start a new simulation run in the same folder structure and want to overwrite existing results, as failing to do so may lead to conflicts deleting old logs.

Trying out ASSUME and the provided Examples

To ease your way into ASSUME we provided some examples and tutorials. The former are helpful if you would like to get an impression of how ASSUME works and the latter introduce you into the development of ASSUME.

The Tutorials

The tutorials work completely detached from your own machine on google colab. They provide code snippets and task that show you, how you can work with the software package one your own. We have two tutorials prepared, one for introducing a new unit and one for getting reinforcement learning ready on ASSUME.

How to configure a new unit in ASSUME?
Open Learning Tutorial in Colab

How to use reinforcement learning for new market participants in ASSUME?

Open Learning Tutorial in Colab

How to change and adapt reinforcement learning algorithms in ASSUME?

Open Learning Tutorial in Colab

The Examples

To explore the provided examples, follow these steps:

  1. Clone the repository and navigate to its directory:
git clone https://github.com/assume-framework/assume.git
cd assume
  1. Quick Start:

There are three ways to run a simulation:

  • Local:
python examples/examples.py
  • Using the provided Docker setup:

If you have installed Docker and set up the Docker Compose file previously, you can select 'timescale' in examples.py before running the simulation. This will save the simulation results in a Timescale database, and you can access the Dashboard at http://localhost:3000.

  • Using the CLI to run simulations:
assume -s example_01b -db "postgresql://assume:assume@localhost:5432/assume"

For additional CLI options, run assume -h.

Development

If you're contributing to the development of ASSUME, follow these steps:

  1. Clone the repository and navigate to its directory:
git clone https://github.com/assume-framework/assume.git
cd assume
  1. Install the package in editable mode:
pip install -e ".[all]"
  1. Install pre-commit:
pip install pre-commit
pre-commit install

To run pre-commit checks directly, use:

pre-commit run --all-files
  1. Install also testing capabilities:
pip install -e ".[testing]"

Release

To release a new version, increase the version in pyproject.toml and create a git tag of the release commit and release notes in GitHub.
To push to PyPi run:

rm -r dist
python -m build .
twine upload --repository pypi dist/*

See also: https://twine.readthedocs.io/en/stable/index.html#using-twine

Creating Documentation

First, create an environment that includes the documentation dependencies:

conda env create -f environment_docs.yaml

To generate or update the automatically created docs in docs/source/assume*, run:

sphinx-apidoc -o docs/source -Fa assume

To create and serve the documentation locally, use:

cd docs/source && python -m sphinx . ../build && cd ../.. && python -m http.server --directory docs/build

Contributors and Funding

The project is developed by a collaborative team of researchers from INATECH at the University of Freiburg, IISM at Karlsruhe Institute of Technology, Fraunhofer Institute for Systems and Innovation Research, Fraunhofer Institution for Energy Infrastructures and Geothermal Energy, and FH Aachen - University of Applied Sciences. Each contributor brings valuable expertise in electricity market modeling, deep reinforcement learning, demand side flexibility, and infrastructure modeling.

ASSUME is funded by the Federal Ministry for Economic Affairs and Climate Action (BMWK). We are grateful for their support in making this project possible.

License

Copyright 2022-2025 ASSUME developers.

ASSUME is licensed under the GNU Affero General Public License v3.0. This license is a strong copyleft license that requires that any derivative work be licensed under the same terms as the original work. It is approved by the Open Source Initiative.


Owner metadata


GitHub Events

Total
Last Year

Committers metadata

Last synced: 5 days ago

Total Commits: 937
Total Committers: 15
Avg Commits per committer: 62.467
Development Distribution Score (DDS): 0.66

Commits in past year: 439
Committers in past year: 9
Avg Commits per committer in past year: 48.778
Development Distribution Score (DDS) in past year: 0.64

Name Email Commits
Florian Maurer m****r@f****e 319
Nick Harder n****4@g****m 302
kim-mskw k****w@k****u 170
Andreas Eppler A****7@w****e 56
Johanna Adams j****s@t****e 47
Johanna Adams a****j@t****e 13
Manish Khanra 4****a 8
unknown a****o@w****e 5
Philipp Fritz f****p@o****e 5
tiernan-buckley-ufr t****2@s****e 4
mthede m****n@s****u 3
Michael Hafner 1****l 2
DominikBurkert 3****t 1
Hendrik Wulfert H****t@i****e 1
Robbe Sneyders r****s@g****m 1

Committer domains:


Issue and Pull Request metadata

Last synced: 2 days ago

Total issues: 135
Total pull requests: 348
Average time to close issues: 2 months
Average time to close pull requests: 6 days
Total issue authors: 14
Total pull request authors: 14
Average comments per issue: 1.51
Average comments per pull request: 1.89
Merged pull request: 302
Bot issues: 0
Bot pull requests: 0

Past year issues: 62
Past year pull requests: 195
Past year average time to close issues: about 1 month
Past year average time to close pull requests: 8 days
Past year issue authors: 11
Past year pull request authors: 10
Past year average comments per issue: 1.27
Past year average comments per pull request: 2.01
Past year merged pull request: 162
Past year bot issues: 0
Past year bot pull requests: 0

More stats: https://issues.ecosyste.ms/repositories/lookup?url=https://github.com/assume-framework/assume

Top Issue Authors

  • nick-harder (50)
  • kim-mskw (29)
  • maurerle (21)
  • adamsjohanna (11)
  • Manish-Khanra (5)
  • mthede (4)
  • paragpatil39 (4)
  • AndreasEppler (4)
  • HafnerMichael (2)
  • ScholzDaniel1985 (1)
  • RobbeSneyders (1)
  • fritzphilipp (1)
  • tiernan-buckley-ufr (1)
  • angelxmoreira (1)

Top Pull Request Authors

  • maurerle (137)
  • nick-harder (125)
  • kim-mskw (35)
  • adamsjohanna (16)
  • Manish-Khanra (8)
  • HafnerMichael (5)
  • tiernan-buckley-ufr (5)
  • AndreasEppler (5)
  • fritzphilipp (4)
  • paragpatil39 (3)
  • mthede (2)
  • DominikBurkert (1)
  • jsejdija (1)
  • RobbeSneyders (1)

Top Issue Labels

  • feature (14)
  • bug (11)
  • enhancement (10)
  • documentation (9)
  • validation (4)
  • tests (4)
  • Workshop Prep (3)
  • question (3)
  • examples (3)
  • priority: low (3)
  • priority: high (2)
  • invalid (1)

Top Pull Request Labels

  • documentation (1)
  • feature (1)
  • priority: high (1)
  • enhancement (1)
  • priority: low (1)
  • examples (1)
  • bug (1)

Package metadata

pypi.org: assume-framework

ASSUME - Agent-Based Electricity Markets Simulation Toolbox

  • Homepage: https://assume-project.de/
  • Documentation: https://assume.readthedocs.io
  • Licenses: AGPL-3.0-or-later
  • Latest release: 0.5.2 (published about 1 month ago)
  • Last Synced: 2025-04-25T12:10:27.969Z (2 days ago)
  • Versions: 17
  • Dependent Packages: 0
  • Dependent Repositories: 0
  • Downloads: 882 Last month
  • Rankings:
    • Dependent packages count: 7.402%
    • Stargazers count: 21.618%
    • Forks count: 22.802%
    • Average: 30.228%
    • Dependent repos count: 69.09%
  • Maintainers (2)
pypi.org: peakshaving-analyzer

Peak shaving analysis for industrial load profiles

  • Homepage:
  • Documentation: https://peakshaving-analyzer.readthedocs.io/
  • Licenses:
  • Latest release: 0.0.3 (published 10 days ago)
  • Last Synced: 2025-04-25T12:10:30.184Z (2 days ago)
  • Versions: 2
  • Dependent Packages: 0
  • Dependent Repositories: 0
  • Downloads: 197 Last month
  • Rankings:
    • Dependent packages count: 9.283%
    • Average: 30.784%
    • Dependent repos count: 52.286%
  • Maintainers (1)

Dependencies

.github/workflows/docker-publish.yml actions
  • actions/checkout v3 composite
  • docker/build-push-action v4 composite
  • docker/login-action v2.2.0 composite
  • docker/metadata-action v4 composite
  • docker/setup-buildx-action v2 composite
.github/workflows/lint-pytest.yml actions
  • actions/checkout v3 composite
  • actions/setup-python v4 composite
  • actions/upload-artifact v3 composite
  • codecov/codecov-action v3 composite
Dockerfile docker
  • python 3.11-bookworm build
environment.yml pypi
pyproject.toml pypi
  • black ^23.3.0
  • glpk ^0.4.7
  • isort ^5.12.0
  • mango-agents ^1.1.1
  • matplotlib ^3.7.2
  • mypy ^1.1.1
  • nest-asyncio ^1.5.6
  • paho-mqtt ^1.5.1
  • pandas ^2.0.0
  • psycopg2-binary ^2.9.5
  • pyomo ^6.6.1
  • pytest ^7.2.2
  • pytest-asyncio ^0.21.1
  • pytest-cov ^4.1.0
  • python ^3.10
  • python-dateutil ^2.8.2
  • pyyaml ^6.0
  • sqlalchemy ^2.0.9
  • torch ^2.0.1
  • tqdm ^4.64.1

Score: 13.771229462647138