atb-calc

Python files and Jupyter notebooks for processing the Annual Technology Baseline (ATB) electricity data and determining LCOE and other metrics.

https://github.com/nrel/atb-calc

Science Score: 39.0%

This score indicates how likely this project is to be science-related based on various indicators:

  • CITATION.cff file
  • codemeta.json file
    Found codemeta.json file
  • .zenodo.json file
    Found .zenodo.json file
  • DOI references
    Found 2 DOI reference(s) in README
  • Academic publication links
  • Committers with academic emails
  • Institutional organization owner
  • JOSS paper metadata
  • Scientific vocabulary similarity
    Low similarity (12.7%) to scientific vocabulary
Last synced: 10 months ago · JSON representation

Repository

Python files and Jupyter notebooks for processing the Annual Technology Baseline (ATB) electricity data and determining LCOE and other metrics.

Basic Info
  • Host: GitHub
  • Owner: NREL
  • License: bsd-3-clause
  • Language: Python
  • Default Branch: main
  • Homepage: https://atb.nrel.gov
  • Size: 3.84 MB
Statistics
  • Stars: 40
  • Watchers: 6
  • Forks: 17
  • Open Issues: 5
  • Releases: 2
Created about 3 years ago · Last pushed about 1 year ago
Metadata Files
Readme License

README.md

Annual Technology Baseline Calculators (ATB-calc)

Python files and Jupyter notebooks for processing the Annual Technology Baseline (ATB) electricity data and determining LCOE and other metrics. All documentation and data for the ATB is available at the ATB website.

Installation and Requirements

The pipeline requires Python 3.10 or newer. Dependancies can be installed using pip:

$ pip install -r requirements.txt

Note that some examples may require additional dependencies such as Jupyter. See the README files in individual directories for specifics.

Once Python and all dependancies are installed the installation can be tested by running:

$ pytest

Tests take about a minute and should complete without errors. The ATB pipeline uses xlwings for accessing the ATB data workbook and requires a copy of Microsoft Excel. Currently the full pipeline will only run on MacOS and Windows. Linux support may be added in the future.

Running the ATB Electricity Pipeline

Running the pipeline requires downloaded the most current data in xlsx format from the ATB website. The pipeline may be ran for one or all ATB electricity technologies. Data may be exported in several formats. Below are several example workflows. It is assumed that all commands are run from the root directory of the repository. In the examples {PATH-TO-DATA-WORKBOOK} is the path and filename to the ATB electricity data workbook xlsx file.

Process all techs and export to a flat file named flat_file.csv:

$ python -m lcoe_calculator.process_all --save-flat flat_file.csv {PATH-TO-DATA-WORKBOOK}

Process only land-based wind and export pivoted data and meta data:

$ python -m lcoe_calculator.process_all --tech LandBasedWindProc \ --save-pivoted pivoted_file.csv --save-meta meta_file.csv {PATH-TO-DATA-WORKBOOK}

Process only pumped storage hydropower and copy data to the clipboard so it may be pasted into a spreadsheet:

$ python -m lcoe_calculator.process_all --tech PumpedStorageHydroProc \ --clipboard {PATH-TO-DATA-WORKBOOK}

Help for the processor and the names of available technologies can be viewed by running:

$ python -m lcoe_calculator.process_all --help

Debt Fraction Calculator

The debt fraction calculator uses PySAM to calculate debt fractions for one or all ATB technologies. To calculate debt fractions for all technologies run the following from the repository root directory:

$ python -m debt_fraction_calculator.debt_fraction_calc {PATH-TO-DATA-WORKBOOK} \ {OUTPUT-CSV-FILE}

where {PATH-TO-DATA-WORKBOOK} is the path and filename of the ATB data workbook, and {OUTPUT-CSV-FILE} is the name of the csv file to create with the calculated debt fractions.

Debt fractions can also be calculated for a single ATB technology if desired. The below command will calculate debt fractions for land-based wind:

$ python -m debt_fraction_calculator.debt_fraction_calc --tech LandBasedWindProc \ {PATH-TO-DATA-WORKBOOK} {OUTPUT-CSV-FILE}

All options for the debt calculator can be viewed with:

$ python -m debt_fraction_calculator.debt_fraction_calc --help

Example Jupyter Notebooks

The ./example_notebooks directory has several Jupyter notebooks showing how to perform various tasks. The notebooks are a good way to understand how to use the code and experiment with the ATB pipeline code. Jupyter must first be installed before use:

$ pip install jupyter

The Jupyter server can then be started by running:

$ jupyter-notebook

in the root repository directory.

Notable Directories

  • ./lcoe_calculator Extract technology metrics from the data workbook xlsx file and calculate LCOE using Python.
  • ./debt_fraction_calculator Given data and assumptions in the data workbook xlsx file, calculate debt fractions using PySAM.
  • ./example_notebooks Example Jupyter notebooks showing how to perform various operations.
  • ./tests Tests for code in this repository.

Citing this Package

Mirletz, Brian, Bannister, Michael, Vimmerstedt, Laura, Stright, Dana, and Heine, Matthew. "ATB-calc (Annual Technology Baseline Calculators) [SWR-23-60]." Computer software. August 02, 2023. https://github.com/NREL/ATB-calc. https://doi.org/10.11578/dc.20230914.2.

Code Formatting

This project uses the Black code formatting VS Code plugin. Please install and run the plugin before making commits or a pull request.

Owner

  • Name: National Renewable Energy Laboratory
  • Login: NREL
  • Kind: organization
  • Location: Golden, CO

GitHub Events

Total
  • Issues event: 7
  • Watch event: 9
  • Delete event: 24
  • Issue comment event: 15
  • Push event: 48
  • Pull request review comment event: 3
  • Pull request review event: 22
  • Pull request event: 39
  • Fork event: 12
  • Create event: 21
Last Year
  • Issues event: 7
  • Watch event: 9
  • Delete event: 24
  • Issue comment event: 15
  • Push event: 48
  • Pull request review comment event: 3
  • Pull request review event: 22
  • Pull request event: 39
  • Fork event: 12
  • Create event: 21

Committers

Last synced: 11 months ago

All Time
  • Total Commits: 83
  • Total Committers: 3
  • Avg Commits per committer: 27.667
  • Development Distribution Score (DDS): 0.313
Past Year
  • Commits: 3
  • Committers: 2
  • Avg Commits per committer: 1.5
  • Development Distribution Score (DDS): 0.333
Top Committers
Name Email Commits
Brian Mirletz b****z@n****v 57
mbannist m****r@n****v 25
Ramdas, Ashwin A****s@n****v 1
Committer Domains (Top 20 + Academic)

Issues and Pull Requests

Last synced: 11 months ago

All Time
  • Total issues: 7
  • Total pull requests: 59
  • Average time to close issues: about 1 month
  • Average time to close pull requests: 4 days
  • Total issue authors: 5
  • Total pull request authors: 3
  • Average comments per issue: 1.57
  • Average comments per pull request: 0.25
  • Merged pull requests: 50
  • Bot issues: 0
  • Bot pull requests: 0
Past Year
  • Issues: 4
  • Pull requests: 42
  • Average time to close issues: about 12 hours
  • Average time to close pull requests: 5 days
  • Issue authors: 3
  • Pull request authors: 3
  • Average comments per issue: 2.25
  • Average comments per pull request: 0.24
  • Merged pull requests: 33
  • Bot issues: 0
  • Bot pull requests: 0
Top Authors
Issue Authors
  • brtietz (2)
  • kalebsm (2)
  • mikebannis (1)
  • NoahV-SC (1)
  • apalomES (1)
Pull Request Authors
  • brtietz (46)
  • mikebannis (23)
  • dstright (1)
Top Labels
Issue Labels
enhancement (1) bug (1)
Pull Request Labels