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
+39-10Lines changed: 39 additions & 10 deletions
Display the source diff
Display the rich diff
Original file line number
Diff line number
Diff line change
@@ -9,34 +9,63 @@ PowNet is a least-cost optimization model for simulating the Unit Commitment and
9
9
Read the PowNet Documentation here: https://pownet.readthedocs.io/en/latest
10
10
11
11
12
-
## Installation
12
+
## Installing and using PowNet
13
+
To use PowNet, a user needs to supply it with CSV files. For guidance on creating these CSV files, please see examples provided [here](https://github.com/Critical-Infrastructure-Systems-Lab/PowNet/tree/master/model_library). Please ensure that column names matches with those from the examples.
13
14
14
-
Download or clone the PowNet 2.0 repository to your local machine. For example: if we want to clone to "C://user/pownet",
15
+
As for installing PowNet, there are multiple options depending on whether we want to modify the source code. However, the following step is highly recommended for any user: creating a virtual environment to manage dependencies. If using Conda, we can create an envrionment with the following command
Next, open a terminal and navigate to the directory where you cloned the repository:
22
+
If deciding on a name for the environment takes too long, please feel free to name the environment as "pownet".
23
+
24
+
### Option 1: Regular user
25
+
A regular user is someone who has created their input files and wish to just run PowNet. In this case, it is best to simply install PowNet as a package from PyPI. We can achieve this with the following command:
21
26
22
27
```
23
-
cd C://user/pownet
28
+
pip install pownet
29
+
```
30
+
31
+
Once the package has been installed, we can now go to our working directory. In this example, we assume the following folder structure:
A Python script called "[run_quickstart.py](https://github.com/Critical-Infrastructure-Systems-Lab/PowNet/blob/master/scripts/run_quickstart.py)" provides an example on running a simulation, saving the simulation outputs, and visualizing the outputs.
48
+
49
+
### Option 2: Power user (no pun intended)
50
+
In case we wish to modify the source code, PowNet should be installed as an editable package. First, download or clone the PowNet repository to your local machine. For example: if we want to clone to "C://user/pownet",
The following step is highly recommended: creating a virtual environment to manage dependencies. If using Conda, you can create an envrionment named "pownet":
56
+
Next, open a terminal and navigate to the directory where we cloned the repository:
27
57
28
58
```
29
-
conda create --name pownet
30
-
conda activate pownet
59
+
cd C://user/pownet
31
60
```
32
61
33
-
Now, you can install this PowNet package using pip, which is a manager for Python packages:
62
+
Now, we can install this PowNet package using pip, which is a manager for Python packages:
34
63
35
64
```
36
65
pip install -e .
37
66
```
38
67
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.
68
+
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 us to edit PowNet codebase when we need to modify or implement new features. The pyproject.toml file specifies the dependencies required to run PowNet.
40
69
41
70
A quick start tutorial to run a simple case study is provided here: https://pownet.readthedocs.io/en/latest/pages/quickstarter.html
0 commit comments