Skip to content

Navigation Menu

Sign in
Appearance settings

Search code, repositories, users, issues, pull requests...

Provide feedback

We read every piece of feedback, and take your input very seriously.

Saved searches

Use saved searches to filter your results more quickly

Appearance settings

PREP-NexT/PREP-SHOT

Open more actions menu

Repository files navigation

PREP-SHOT logo

Build GitHub contributors GitHub issues Twitter Follow License Download Documentation Status Google Colab (Quickstart)

Overview | Features | Quick Start | Contribute | Roadmap | Citation

Overview

PREP-SHOT (Pathways for Renewable Energy Planning coupling Short-term Hydropower OperaTion) is a transparent, modular, and open-source energy expansion model, offering advanced solutions for multi-scale, intertemporal, and cost-effective expansion of energy systems and transmission lines. It's developed by Zhanwei Liu and Xiaogang He from the PREP-NexT Lab at the National University of Singapore. PREPSHOT_Update07 For more information, please visit the Official Documentation.

This project is licensed under the GNU General Public License 3.0.

Why the Name?

The clean energy transition is our new moonshot to combat climate change – an ambitious 'shot' yet achievable. We're up to the challenge, which is why we developed PREP-SHOT to prepare us for this long shot.

Key Features

  • Optimization model based on linear programming for multi-zone energy systems.
  • Cost minimization while meeting given demand time series.
  • Adjustable operation on hourly-spaced time steps.
  • Input data in Excel format and output data in NetCDF format using Xarray.
  • Support for multiple solvers like HiGHS , GUROBI, COPT, and MOSEK via PyOptInterface.
  • Allows input of multiple scenarios for specific parameters.
  • A pure Python program, leveraging pandas and Xarray for simplified complex data analysis and extensibility.

Getting Started

The fastest way to try PREP-SHOT is in a hosted notebook -- click the Colab badge above to run doc/source/Quickstart.ipynb in your browser. A full solve + plot finishes in about five minutes.

For a more realistic case study, see examples/southeast_asia/SoutheastAsia.ipynb -- a walkthrough of the Lower Mekong basin dataset that ships with PREP-SHOT (5 countries, 57 cascading hydropower stations, 2030 carbon cap).

For a local setup follow the steps below.

  1. Clone the repo

    git clone https://github.com/PREP-NexT/PREP-SHOT.git
  2. Install the dependencies

    cd PREP-SHOT
    conda create -n prep-shot python=3.9
    conda activate prep-shot
    pip install -r requirements.txt

    Alternatively, install PREP-SHOT itself as an editable package (this also pulls in the dependencies declared in pyproject.toml):

    pip install -e .

    A PyPI release is planned with v2.0; until then, use pip install git+https://github.com/PREP-NexT/PREP-SHOT@<tag> to pin a specific version.

  3. Run your first model

    Each subdirectory of examples/ is a self-contained scenario (config.json + params.json + input/). Pick one and run from inside it:

    cd examples/three_zone     # or southeast_asia, thailand
    python -m prepshot

    Equivalent entry points: prepshot (console script) or python /path/to/run.py ..

This example is inspired by real-world data. For a hands-on walkthrough, see the Quickstart in our documentation.

By default, PREP-SHOT uses the open-source HiGHS solver. Solver-specific parameters are specified in the scenario's config.json. We also support the following commercial solvers:

🤝 How to Contribute

To contribute to this project, please read our Contributing Guidelines.

Versioning

We use SemVer for versioning. For the versions available, see the releases on this repository.

Citing PREP-SHOT

See the Citation Guide.

Please use the following logo if you use PREP-SHOT:

PREP-SHOT_logos_QR

If you use PREP-SHOT in a scientific publication, we would appreciate citations. You can use the following BibTeX entry:

@article{liu2023,
  title = {Balancing-oriented hydropower operation makes the clean energy transition more affordable and simultaneously boosts water security},
  author = {Liu, Zhanwei and He, Xiaogang},
  journal = {Nature Water},
  volume = {1},
  pages = {778--789},
  year = {2023},
  doi = {10.1038/s44221-023-00126-0},
}

Contact Us

If you have any questions, comments, or suggestions that aren't suitable for public discussions in the Issues section, please feel free to reach out to Zhanwei Liu.

Please use the GitHub Issues for public discussions related to bugs, enhancements, or other project-related discussions.

Roadmap

  • Benders decomposition-based fast solution framework
  • PyOptInterface-based low-memory and fast modelling engine
  • Support for input of cost–supply curves of technologies
  • Support for expanding conventional hydropower plants
  • Support for refurbishing conventional hydropower plants to pumped-storage schemes
  • Support for refurbishing carbon-emission plants to carbon capture and storage (CCS) schemes

Disclaimer

The PREP-SHOT model is an academic project and is not intended to be used as a precise prediction tool for specific hydropower operations or energy planning. The developers will not be held liable for any decisions made based on the use of this model. We recommend applying it in conjunction with expert judgment and other modeling tools in a decision-making context.


Repo Activity

Repo Analytics

⭐ Star History

Star History Chart

About

Pathways for Renewable Energy Planning coupling Short-term Hydropower OperaTion

Topics

Resources

License

Stars

Watchers

Forks

Packages

 
 
 

Contributors

Morty Proxy This is a proxified and sanitized view of the page, visit original site.