You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Copy file name to clipboardExpand all lines: README.md
+32-2Lines changed: 32 additions & 2 deletions
Display the source diff
Display the rich diff
Original file line number
Diff line number
Diff line change
@@ -6,10 +6,40 @@
6
6
# PowNet: Unit Commitment / Economic Dispatch model in Python
7
7
PowNet is a least-cost optimization model for simulating the Unit Commitment and Economic Dispatch (UC/ED) of large-scale (regional to country) power systems. In PowNet, a power system is represented by a set of nodes that include power plants, high-voltage substations, and import/export stations (for cross-border systems). The model schedules and dispatches the electricity supply from power plant units to meet hourly electricity demand in substations at a minimum cost. It considers the techno-economic constraints of both generating units and high-voltage transmission network. The power flow calculation is based on a Direct Current (DC) network (with N-1 criterion), which provides a reasonable balance between modelling accuracy and data and computational requirements. PowNet can easily integrate information about variable renewable resources (e.g., hydro, wind, solar) into the UC/ED process. For example, it can be linked with models that estimate the electricity supply available from renewable resources as a function of the climatic conditions. In addition, PowNet has provision to account for the effect of droughts on the generation of dispatchable thermal units (e.g., coal, oil, gas-fired units) that depend on freshwater availability. These features facilitate the application of PowNet to problems in the water-energy nexus domain that investigate the impact of water availability on electricity supply and demand.
8
8
9
-
A quick start tutorial is provided here: https://pownet.readthedocs.io/en/latest/pages/quickstarter.html
10
-
11
9
Read the PowNet Documentation here: https://pownet.readthedocs.io/en/latest
12
10
11
+
12
+
## Installation
13
+
14
+
Download or clone the PowNet 2.0 repository to your local machine. For example: if we want to clone to "C://user/pownet",
Next, open a terminal and navigate to the directory where you cloned the repository:
21
+
22
+
```
23
+
cd C://user/pownet
24
+
```
25
+
26
+
The following step is highly recommended: creating a virtual environment to manage dependencies. If using Conda, you can create an envrionment named "pownet":
27
+
28
+
```
29
+
conda create --name pownet
30
+
conda activate pownet
31
+
```
32
+
33
+
Now, you can install this PowNet package using pip, which is a manager for Python packages:
34
+
35
+
```
36
+
pip install -e .
37
+
```
38
+
39
+
This command installs the package in "editable" mode (-e) using pyproject.toml that is located in the root directory of PowNet. The editable mode allows you to edit PowNet codebase when you need to modify or implement new features. The pyproject.toml file specifies the dependencies required to run PowNet.
40
+
41
+
A quick start tutorial to run a simple case study is provided here: https://pownet.readthedocs.io/en/latest/pages/quickstarter.html
Next, open a terminal and navigate to the directory where you cloned the repository:
15
+
16
+
.. code-block:: python
17
+
18
+
cd C://user/pownet
19
+
20
+
The following step is highly recommended: creating a virtual environment to manage dependencies. If using Conda, you can create an envrionment named "pownet":
21
+
22
+
.. code-block:: python
23
+
24
+
conda create --name pownet
25
+
conda activate pownet
26
+
27
+
Now, you can install this PowNet package using pip, which is a manager for Python packages:
28
+
29
+
.. code-block:: python
30
+
31
+
pip install -e .
32
+
33
+
This command installs the package in "editable" mode (-e) using pyproject.toml that is located in the root directory of PowNet. The editable mode allows you to edit PowNet codebase when you need to modify or implement new features. The pyproject.toml file specifies the dependencies required to run PowNet.
34
+
35
+
Now you have PowNet 2.0 installed and ready to use! You can proceed with the rest of this tutorial to run your first simulation using a small case study.
36
+
37
+
2. Model Overview
7
38
-----------------
8
39
9
40
The dummy power system includes a variety of generation sources and a single buyer.
@@ -22,7 +53,7 @@ The dummy power system includes a variety of generation sources and a single buy
22
53
Supplier pBiomass
23
54
24
55
25
-
2. Setup
56
+
3. Setup
26
57
----------
27
58
28
59
* **Input Folder:** Define the directory containing the power system models (`input_folder`). This folder may contain multiple subdirectories. Ensure the `input_folder` contains a subdirectory named `model_name` with the necessary model data, which is a set of CSV files.
@@ -34,7 +65,7 @@ The dummy power system includes a variety of generation sources and a single buy
34
65
* `steps_to_run`: Specify the number of simulation steps (e.g., 2 for a two-day simulation).
35
66
* `solver`: Select the optimization solver ('gurobi' or 'highs').
36
67
37
-
3. Code Example
68
+
4. Code Example
38
69
---------------
39
70
40
71
The following code has already been made available in the the `scripts` folder as `run_quickstart.py`. However, the code is also presented here.
@@ -92,13 +123,13 @@ The following code has already been made available in the the `scripts` folder a
92
123
main()
93
124
94
125
95
-
4. Running the Simulation
126
+
5. Running the Simulation
96
127
-------------------------
97
128
98
129
1. **Save:** Save the code above as a Python file (e.g., `run_tutorial.py`).
99
130
2. **Run:** Execute the script from your terminal using `python run_pownet.py`.
100
131
101
-
5. Outputs
132
+
6. Outputs
102
133
----------
103
134
104
135
* **Results:** Simulation results will be saved in the specified `output_folder`.
0 commit comments