Skip to main content

A library for Building and Energy Simulation, Optimization and Surrogate-modelling

Project description

analysis domains encompassed by BESOS.

BESOS: Building and Energy Systems Optimization and Surrogate-modelling

PyPI Latest Release PyPi Package format PyPI Downloads License: GPL v3 DOI DOI

Documentation

pipeline status Coverage Code style: black pre-commit

BESOS is a collection of modules for the simulation and optimization of buildings and urban energy systems. BESOS is designed to help researchers and practitioners to design more sustainable, district-integrated buildings. It integrates EnergyPlus and EnergyHub simulation software with optimization and machine learning functionality. this includes lots of help with 'surrogate modelling', where machine learning models are fitted to data generated by parametric runs of detailed simulation models. BESOS facilitates running large-scale parametric analyses of EnergyPlus or EnergyHub models with output in a pandas DataFrame and using this to train machine learning surrogate models with scikit-learn or TensorFlow. We provide access to commonly used optimization algorithms via existing optimization toolboxes.

Installing BESOS

Ensure that you have Python 3.7+ and the corresponding version of pip. pip install besos[complete] (If you do not want to run the example notebooks, you can use pip install besos, which will install with less dependencies.)

Install Dependencies

We use third party software to run building models (EnergyPlus), to solve EnergyHub models (a MILP solver), and make use of Rbfopt (via Bonmin). To use this functionality you need to install the software for the corresponding the task. GLPK and Bonmin are optional, it is possible to use Besos without them.

Install Energyplus

Download EnergyPlus here. (BESOS is currently supporting versions from 8.8-9.3+).

For windows: After downloading the installation file, double click the setup file to start installing. After setup is complete, navigate to your System Properties and in the Advanced tab, select Environment Variables. In either your User Variables or System Variables (Depending on your permissions), double click on Path and add the location of your EnergyPlus folder to the end of it. Ensure the path is C:\EnergyPlusV{version} for proper integration with Besos.

For linux: Run the downloaded script, and accept the prompt to add symlinks. Ensure the path is /usr/local/EnergyPlus-{version} for proper integration with Besos.

TensorFlow (only required to use TensorFlow)

TensorFlow is a machine learning library of which we have provided some examples. This package is quite large 300 mb therefore we have not added this to the requirements.

To install TensorFlow use pip install.

pip install tensorflow

MILP solver (only required to use EnergyHub)

EnergyHub modelling requires a linear programming solver that is supported by PuLP, such as GLPK, CPlex, or Gurobi. To learn about how to setup a custom solver please review the readthedocs page on Customizing EnergyHub Solver.

GLPK is free and open source. It can be found here. If you are using a Debian based operating system, you can install GLPK with sudo apt install glpk-utils

Optional: Bonmin (only required to use RBFopt)

Bonmin is required to use the RBFopt optimizer. How to install Bonmin can be found here.

Running Example Notebooks

Examples of Besos' functionality are provided through example notebooks. The notebooks can be viewed as Python scripts or through a Jupyter notebook.

You can run notebooks from the Besos platform, which has the besos library and all dependencies pre-installed, or you can install Jupyter locally.

To run the notebooks you need Juptyer installed. Jupyter can be installed using: pip install juptyer and launched from the current directory with jupyter notebook.

Contributing and Support

When creating gitlab issues, please search the existing gitlab issues to see if someone else has already made the same request.

Feature Requests

To request a feature open a new issue with your feature request.

Bug reports/Questions

If you have found a bug, please open a gitlab issue describing the bug. Make sure to include steps to reproduce the bug. Ideally, include a small bit of code that causes the bug. If the bug causes an error, please include the traceback. If the bug causes the wrong behaviour, please mention what besos should do in this situation.

Code contributions

If you are interested in contributing to the code please review the readthedocs page on contributing to the code.

Example notebooks

A good way to start is using the example notebooks. They are described in the examples overview

Project details


Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Source Distribution

besos-2.2.3.tar.gz (2.3 MB view details)

Uploaded Source

Built Distribution

besos-2.2.3-py3-none-any.whl (2.4 MB view details)

Uploaded Python 3

File details

Details for the file besos-2.2.3.tar.gz.

File metadata

  • Download URL: besos-2.2.3.tar.gz
  • Upload date:
  • Size: 2.3 MB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/5.1.0 CPython/3.10.12

File hashes

Hashes for besos-2.2.3.tar.gz
Algorithm Hash digest
SHA256 377380227a74711a401454859813e7fb85d0d325f5a4c57d785ec9de2d4c4db3
MD5 fcd644a557518c496b4f01d202523657
BLAKE2b-256 38bb08166d2901ee102c418a64336b5ff706c3a44fba2f083eb95d6db14f928c

See more details on using hashes here.

File details

Details for the file besos-2.2.3-py3-none-any.whl.

File metadata

  • Download URL: besos-2.2.3-py3-none-any.whl
  • Upload date:
  • Size: 2.4 MB
  • Tags: Python 3
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/5.1.0 CPython/3.10.12

File hashes

Hashes for besos-2.2.3-py3-none-any.whl
Algorithm Hash digest
SHA256 be010e8a0a93a5f0f17196852a5b9522963fa472ea21d5c28d60ced53dd24fdb
MD5 2b17cb480614ec43bdb33124ba1b3f8c
BLAKE2b-256 f793f6a96eadcde35df8e71a2cef0d15386fd8a047541f97755292852fb607a7

See more details on using hashes here.

Supported by

AWS AWS Cloud computing and Security Sponsor Datadog Datadog Monitoring Fastly Fastly CDN Google Google Download Analytics Microsoft Microsoft PSF Sponsor Pingdom Pingdom Monitoring Sentry Sentry Error logging StatusPage StatusPage Status page