Skip to main content

A program to solve a energy hub model in Python.

Project description

PyHub

A program to solve a energy hub model in Python.

Requirements

  • Python 3.6.1
  • pip for Python 3.6.1
  • GLPK or another solver supported by PyLP

Running a Model

To run a energy hub model, use the General_input.xlsx file to enter your data. The data must be in the same format.

Check the config.yaml file to see if the input file and output file is where you want to load and output the results of the model respectively.

While inside the config.yaml file, be sure to set the settings for using a specific solver that is installed on your system. The default one is glpk with some options, but you can set it to any other solver that is supported by PyLP.

Once you have configured the config.yaml file, run:

python run.py

to solve the model. The results should be in the file you specified in config.yaml.

Development

Installation

To install PyHub, make a new directory and then cd into it.

mkdir pyhub
cd pyhub

Download the repo:

git clone https://<username>@bitbucket.org/hues/pyhub.git

Install the libraries needed for PyHub to run:

pip install -r requirements.txt

Also install glpk or another solver. Edit the config.yaml file to use a selected solver.

Run the run.py script to see if everything works.

python run.py

Docs

Can be found here.

Contributing

Features/Bug fixes

If you are fixing a bug or making a new feature, first get the lastest master branch.

git checkout master
git pull

Then create your own branch for you to work on:

git branch <your-branch-name>
git checkout <your-branch-name>

Once you are done, please submit a pull request.

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

pyehub-1.0.0.tar.gz (27.6 kB view details)

Uploaded Source

Built Distribution

If you're not sure about the file name format, learn more about wheel file names.

pyehub-1.0.0-py3-none-any.whl (34.6 kB view details)

Uploaded Python 3

File details

Details for the file pyehub-1.0.0.tar.gz.

File metadata

  • Download URL: pyehub-1.0.0.tar.gz
  • Upload date:
  • Size: 27.6 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/1.12.1 pkginfo/1.4.2 requests/2.21.0 setuptools/40.6.3 requests-toolbelt/0.8.0 tqdm/4.28.1 CPython/3.7.1

File hashes

Hashes for pyehub-1.0.0.tar.gz
Algorithm Hash digest
SHA256 2aa7c268407439502c11d578a7e5179fd592bd96dde18fe932c94b2e37e50627
MD5 4348db31c79390c8a2c71e3da9fb511c
BLAKE2b-256 0914149c42b4162285214acb17f2e26479cb9a675e66923310831e30a26a2dd7

See more details on using hashes here.

File details

Details for the file pyehub-1.0.0-py3-none-any.whl.

File metadata

  • Download URL: pyehub-1.0.0-py3-none-any.whl
  • Upload date:
  • Size: 34.6 kB
  • Tags: Python 3
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/1.12.1 pkginfo/1.4.2 requests/2.21.0 setuptools/40.6.3 requests-toolbelt/0.8.0 tqdm/4.28.1 CPython/3.7.1

File hashes

Hashes for pyehub-1.0.0-py3-none-any.whl
Algorithm Hash digest
SHA256 d753bed9a9d6a1d61bbdec097a2594fa6546e1ea77cd4de38c68e0dcbe99c51e
MD5 143b938b413dcb25e63f7516bba30a92
BLAKE2b-256 b081212f699bf5ead22c45d0633e2195941da17889761d63f0b50a067a5acc48

See more details on using hashes here.

Supported by

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