Science Score: 51.0%
This score indicates how likely this project is to be science-related based on various indicators:
-
✓CITATION.cff file
Found CITATION.cff file -
○codemeta.json file
-
○.zenodo.json file
-
✓DOI references
Found 12 DOI reference(s) in README -
✓Academic publication links
Links to: arxiv.org, zenodo.org -
✓Committers with academic emails
12 of 110 committers (10.9%) from academic institutions -
○Institutional organization owner
-
○JOSS paper metadata
-
○Scientific vocabulary similarity
Low similarity (14.0%) to scientific vocabulary
Keywords
Keywords from Contributors
Repository
PyPSA: Python for Power System Analysis
Basic Info
- Host: GitHub
- Owner: PyPSA
- License: mit
- Language: Python
- Default Branch: master
- Homepage: https://docs.pypsa.org
- Size: 51.3 MB
Statistics
- Stars: 1,626
- Watchers: 72
- Forks: 542
- Open Issues: 127
- Releases: 85
Topics
Metadata Files
README.md
PyPSA - Python for Power System Analysis
PyPSA stands for Python for Power System Analysis. It is pronounced pipes-ah.
PyPSA is an open-source Python framework for optimising and simulating modern power and energy systems that include features such as conventional generators with unit commitment, variable wind and solar generation, hydro-electricity, inter-temporal storage, coupling to other energy sectors, elastic demands, and linearised power flow with loss approximations in DC and AC networks. PyPSA is designed to scale well with large networks and long time series. It is made for researchers, planners and utilities with basic coding aptitude who need a fast, easy-to-use and transparent tool for power and energy system analysis.
[!NOTE] PyPSA has many contributors, with the maintenance led by the Department of Digital Transformation in Energy Systems at the Technical University of Berlin. The project is currently supported by the German Research Foundation (grant number
528775426). Previous versions were developed at the Karlsruhe Institute of Technology funded by the Helmholtz Association, and at FIAS funded by the German Federal Ministry for Education and Research (BMBF).
Features
Economic Dispatch (ED): Models short-term market-based dispatch including unit commitment, renewable availability, short-duration and seasonal storage including hydro reservoirs with inflow and spillage dynamics, elastic demands, load shedding and conversion between energy carriers, using either perfect operational foresight or rolling horizon time resolution.
Linear Optimal Power Flow (LOPF): Extends economic dispatch to determine the least-cost dispatch while respecting network constraints in meshed AC-DC networks, using a linearised representation of power flow (KVL, KCL) with optional loss approximations.
Security-Constrained LOPF (SCLOPF): Extends LOPF by accounting for line outage contingencies to ensure system reliability under $N-1$ conditions.
Capacity Expansion Planning (CEP): Supports least-cost long-term system planning with investment decisions for generation, storage, conversion, and transmission infrastructure. Handles both single and multiple investment periods. Continuous and discrete investments are supported.
Pathway Planning: Supports co-optimisation of multiple investment periods to plan energy system transitions over time with perfect planning foresight.
Stochastic Optimisation: Implements two-stage stochastic programming framework with scenario-weighted uncertain inputs, with investments as first-stage decisions and dispatch as recourse decisions.
Modelling-to-Generate-Alternatives (MGA): Explores near-optimal decision spaces to provide insight into the range of feasible system configurations with similar costs.
Sector-Coupling: Modelling integrated energy systems with multiple energy carriers (electricity, heat, hydrogen, etc.) and conversion between them. Flexible representation of technologies such as heat pumps, electrolysers, battery electric vehicles (BEVs), direct air capture (DAC), and synthetic fuels production.
Static Power Flow Analysis: Computes both full non-linear and linearised load flows for meshed AC and DC grids using Newton-Raphson method.
Documentation
PyPSA has extensive documentation with tutorials, user guides, examples and an API reference.
Installation
pip:
bash
pip install pypsa
conda/mamba:
bash
conda install -c conda-forge pypsa
uv:
bash
uv add pypsa
Usage
``` py import pypsa
create a new network
n = pypsa.Network() n.add("Bus", "mybus") n.add("Load", "myload", bus="mybus", pset=100) n.add("Generator", "mygen", bus="mybus", pnom=100, marginal_cost=20)
load an example network
n = pypsa.examples.acdcmeshed()
run the optimisation
n.optimize()
plot results
n.generators_t.p.plot() n.plot()
get statistics
n.statistics() n.statistics.energy_balance() ```
Dependencies
PyPSA relies heavily on other open-source Python packages. Some of them are:
- pandas for storing data about components and time series
- numpy and scipy for linear algebra and matrix calculations
- linopy for preparing optimisation problems
- matplotlib, seaborn and plotly for static and interactive plotting
- networkx for network calculations
- pytest for unit testing
Find the full list of dependencies in the pyproject.toml file.
PyPSA can be used with different solvers. For instance, the free solvers HiGHS (installed by default), GLPK and CBC or commercial solvers like Gurobi or FICO Xpress for which free academic licenses are available.
Contributing and Support
We strongly welcome anyone interested in contributing to this project. If you have any ideas, suggestions or encounter problems, feel invited to file issues or make pull requests on GitHub.
- To discuss with other PyPSA users, organise projects, share news, and get in touch with the community you can use the Discord server.
- For bugs and feature requests, please open an issue.
- For troubleshooting and support, please check the troubleshooting and support sectionsin the documentation.
Detailed guidelines can be found in the Contributing guidelines of our documentation.
Code of Conduct
Please respect our Code of Conduct.
Citing PyPSA
If you use PyPSA for your research, we would appreciate it if you would cite the following paper:
- T. Brown, J. Hörsch, D. Schlachtberger, PyPSA: Python for Power System Analysis, 2018, Journal of Open Research Software, 6(1), arXiv:1707.09913, DOI:10.5334/jors.188
Please use the following BibTeX:
@article{PyPSA,
author = {T. Brown and J. H\"orsch and D. Schlachtberger},
title = {{PyPSA: Python for Power System Analysis}},
journal = {Journal of Open Research Software},
volume = {6},
issue = {1},
number = {4},
year = {2018},
eprint = {1707.09913},
url = {https://doi.org/10.5334/jors.188},
doi = {10.5334/jors.188}
}
If you want to cite a specific PyPSA version, each release of PyPSA is archived
on Zenodo with a release-specific DOI:
Licence
Copyright PyPSA Contributors
PyPSA is licensed under the open source MIT License. The documentation is licensed under CC-BY-4.0.
The repository uses REUSE to expose the licenses of its files.
Owner
- Name: PyPSA
- Login: PyPSA
- Kind: organization
- Website: www.pypsa.org
- Repositories: 29
- Profile: https://github.com/PyPSA
Python for Power System Analysis
Citation (CITATION.cff)
# SPDX-FileCopyrightText: PyPSA Contributors
#
# SPDX-License-Identifier: MIT
cff-version: 1.2.0
message: "If you use this package, please cite the corresponding manuscript in Journal of Open Research Software."
title: "PyPSA: Python for Power System Analysis"
repository: https://github.com/pypsa/pypsa
version: 1.1.2 # Don't touch, will be updated by the release script
license: MIT
journal: Journal of Open Research Software
doi: 10.5334/jors.188
authors:
- family-names: Brown
given-names: Tom
orcid: https://orcid.org/0000-0001-5898-1911
- family-names: Hörsch
given-names: Jonas
orcid: https://orcid.org/0000-0001-9438-767X
- family-names: Schlachtberger
given-names: David
orcid: https://orcid.org/0000-0002-8167-8213
GitHub Events
Total
- Create event: 96
- Release event: 10
- Issues event: 91
- Watch event: 337
- Delete event: 280
- Issue comment event: 222
- Push event: 616
- Pull request review comment event: 148
- Pull request review event: 226
- Pull request event: 308
- Fork event: 97
Last Year
- Create event: 96
- Release event: 10
- Issues event: 91
- Watch event: 337
- Delete event: 280
- Issue comment event: 222
- Push event: 616
- Pull request review comment event: 148
- Pull request review event: 226
- Pull request event: 308
- Fork event: 97
Committers
Last synced: about 1 month ago
Top Committers
| Name | Commits | |
|---|---|---|
| Fabian | f****f@g****e | 449 |
| Tom Brown | b****n@f****e | 412 |
| Fabian Neumann | f****n@o****e | 387 |
| Lukas Trippe | l****p@p****e | 275 |
| pre-commit-ci[bot] | 6****] | 237 |
| Jonas Hoersch | j****s@c****t | 229 |
| Philipp Glaum | p****m@t****e | 70 |
| Max Parzen | m****n@e****k | 50 |
| lisazeyen | l****n@w****e | 35 |
| Iegor Riepin | i****n@g****m | 31 |
| martacki | m****i@k****u | 27 |
| Koen van Greevenbroek | k****k@u****o | 25 |
| energyls | l****m@o****e | 20 |
| Russell Smith | r****h@e****m | 18 |
| euronion | 4****n | 17 |
| Markus Groissböck | m****k@g****t | 14 |
| JulianGeis | J****s@g****t | 14 |
| dependabot[bot] | 4****] | 13 |
| Enrico Giglio | 1****o@g****m | 13 |
| Matthew Dumlao | d****4@k****p | 12 |
| Nis Martensen | n****n@w****e | 10 |
| Bobby Xiong | 3****g | 10 |
| Ben Elliston | b****e@a****u | 9 |
| gailin-p | g****e@g****m | 9 |
| Jess | 1****n | 7 |
| ekatef | e****a@g****m | 7 |
| Heinz-Alexander Fuetterer | 3****r | 7 |
| Russell Smith | r****h@c****h | 6 |
| Alex-Neve | 1****e | 6 |
| David Schlachtberger | s****r@f****e | 6 |
| and 80 more... | ||
Committer Domains (Top 20 + Academic)
Issues and Pull Requests
Last synced: 7 months ago
All Time
- Total issues: 412
- Total pull requests: 1,154
- Average time to close issues: 6 months
- Average time to close pull requests: 17 days
- Total issue authors: 161
- Total pull request authors: 104
- Average comments per issue: 1.67
- Average comments per pull request: 1.33
- Merged pull requests: 934
- Bot issues: 0
- Bot pull requests: 118
Past Year
- Issues: 72
- Pull requests: 374
- Average time to close issues: 26 days
- Average time to close pull requests: 6 days
- Issue authors: 36
- Pull request authors: 33
- Average comments per issue: 0.65
- Average comments per pull request: 0.67
- Merged pull requests: 274
- Bot issues: 0
- Bot pull requests: 32
Top Authors
Issue Authors
- fneum (63)
- FabianHofmann (41)
- nworbmot (14)
- Cellophil (12)
- lisazeyen (12)
- fhg-isi (12)
- lkstrp (10)
- pz-max (9)
- loongmxbt (8)
- PeterKlein11 (7)
- coroa (7)
- jankaeh (5)
- davide-f (5)
- matteodefelice (5)
- euronion (5)
Pull Request Authors
- lkstrp (257)
- FabianHofmann (202)
- fneum (187)
- pre-commit-ci[bot] (97)
- p-glaum (40)
- coroa (25)
- lisazeyen (25)
- koen-vg (20)
- Irieo (18)
- pz-max (15)
- gincrement (14)
- martacki (14)
- afuetterer (12)
- nworbmot (12)
- dependabot[bot] (10)
Top Labels
Issue Labels
Pull Request Labels
Packages
- Total packages: 4
-
Total downloads:
- pypi 27,044 last-month
- Total docker downloads: 204
-
Total dependent packages: 8
(may contain duplicates) -
Total dependent repositories: 46
(may contain duplicates) - Total versions: 265
- Total maintainers: 3
pypi.org: pypsa
Python for Power Systems Analysis
- Homepage: https://github.com/PyPSA/PyPSA
- Documentation: https://docs.pypsa.org
- License: MIT License Copyright (c) <year> <copyright holders> Permission is hereby granted, free of charge, to any person obtaining a copy of this software and associated documentation files (the "Software"), to deal in the Software without restriction, including without limitation the rights to use, copy, modify, merge, publish, distribute, sublicense, and/or sell copies of the Software, and to permit persons to whom the Software is furnished to do so, subject to the following conditions: The above copyright notice and this permission notice shall be included in all copies or substantial portions of the Software. THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
-
Latest release: 1.1.2
published about 1 month ago
Rankings
proxy.golang.org: github.com/pypsa/pypsa
- Documentation: https://pkg.go.dev/github.com/pypsa/pypsa#section-documentation
- License: mit
-
Latest release: v1.1.1
published about 1 month ago
Rankings
proxy.golang.org: github.com/PyPSA/PyPSA
- Documentation: https://pkg.go.dev/github.com/PyPSA/PyPSA#section-documentation
- License: mit
-
Latest release: v1.0.7
published 3 months ago
Rankings
conda-forge.org: pypsa
PyPSA is a free software toolbox for simulating and optimising modern power systems that include features such as conventional generators with unit commitment, variable wind and solar generation, storage units, coupling to other energy sectors, and mixed alternating and direct current networks. PyPSA is designed to scale well with large networks and long time series.
- Homepage: https://pypsa.org/
- License: MIT
-
Latest release: 0.21.1
published over 3 years ago
Rankings
Dependencies
- deprecation *
- matplotlib *
- netcdf4 *
- networkx >=1.10
- numpy *
- pandas >=0.24.0
- pyomo >=5.7
- scipy *
- tables *
- xarray *
- actions/checkout v2 composite
- actions/setup-python v2 composite
- crazy-max/ghaction-chocolatey v1 composite
- actions/checkout v2 composite
- actions/setup-python v2 composite
- pypa/gh-action-pypi-publish master composite
- actions/checkout v3 composite
- codecov/codecov-action v3 composite
- mamba-org/setup-micromamba v1 composite
- cartopy >=0.16
- deprecation
- glpk
- libnetcdf
- linopy >=0.2
- matplotlib
- netcdf4
- networkx >=1.10
- numexpr <=2.8.4
- numpy
- pandas >=0.24.0,<2.1
- pyomo >=5.7.0,<6.6.2
- pytables
- python >=3.9
- scipy
- validators
- xarray
- vresutils *