Skip to content

epri-dev/pyRAVT

Repository files navigation

Resource Adequacy Viewer Tool in Python (pyRAVT)

pyRAVT

Introduction

The pyRAVT GitHub repository contains the Python code to run EPRI's Resource Adequacy Viewer Tool (RAVT). This tool calculates and visualizes various metrics used in resource adequacy (RA) assessments.

Developed and maintained by EPRI's Transmission Operations & Planning group, pyRAVT is a Python version of the original tool, which was built in R and can be accessed here.

Resource Adequacy Metrics

RA metrics are used to measure whether a power system has adequate resources—including generation, demand-side contributions, and power imports—to meet electricity demand and maintain reliable service under various conditions. The following metrics are reported in pyRAVT:

  1. LOLH stands for Loss of Load Hours. This is the average event-hours per year across all of the simulated random samples. The unit of LOLH is hours/year.
  2. LOLD stands for Loss of Load Days. This is defined as the average number of event-periods per year across all of the random samples simulated. The LOLD metric can be applied to any time period length and must be clearly defined by the user. The unit of LOLD is days/year. In some regions, LOLD is assumed the same as LOLE or Loss of Load Expectation.
  3. LOLP stands for Loss of Load Probability. This is calculated as the total number of event-periods divided by the total number of time periods sampled. The LOLP metric can be applied to any time period length and study horizon, and must be clearly defined by the user. The unit of LOLP is %.
  4. LOLEv stands for Loss of Load Events. This is defined as the average number of events per year across all the simulated random samples. The unit of LOLEv is events/year.
  5. EUE stands for Expected Unserved Energy. This is the average load not served per year due to shortfall events across all the simulated random samples. The unit of EUE is MWh/year.
  6. CVaR stands for Conditional Value at Risk. This is the average event-hours or unserved load per year during extreme shortfall events. This is a metric calculated from the most severe or "tail-end" samples in a simulation.

More information on RA metrics is available here.

Getting Started

Installation Process

To install pyRAVT, users have two options: cloning the GitHub repository or downloading a ZIP file.

  1. Cloning the Repository: To clone the repository using the command prompt (on Windows) or terminal, use the following command: git clone https://github.com/epri-dev/XXXXXX. This will create a local copy of the project.
  2. Downloading a ZIP file: If users prefer to download the files directly, navigate to the GitHub page and click the Code button, then select Download ZIP. Once the download is complete, extract the contents of the ZIP file to your preferred location.

Dependencies

  • pandas
  • seaborn
  • matplotlib
  • numpy
  • plotly

Running pyRAVT

After installation,

  1. Open the input folder.
  2. Save the hourly unserved energy results to the file unserved_energy.csv within the input folder. Make sure the file includes nine column headers: Scenario_Name, Weather_Year, Sample_Number, Zone_Name, Year, Month, Day, Hour, and Unserved_Energy_MWh.
  3. Open Visual Studio Code.
  4. Open the pyRAVT notebook in Visual Studio Code.
  5. Update the inputs to the following parameters: no_samples, no_weather_years, start_weather_year, end_weather_year, figure_width, figure_height, no_columns, and CVaR_alpha.
  6. Save the pyRAVT notebook.
  7. Execute the Run All command within the environment.
  8. Output files will be generated in the output folder.

Version History

Version 0.1.0

Initial version

Contacts

For more information, please contact:

About

No description, website, or topics provided.

Resources

License

Stars

Watchers

Forks

Packages

No packages published

Contributors 2

  •  
  •