BICEP Examples

This section provides hands-on examples demonstrating how to use BICEP for electrical infrastructure analysis.

Interactive Jupyter Notebooks

We provide several Jupyter notebooks that demonstrate different aspects of BICEP:

  1. basic-analysis.ipynb - Basic analysis workflow
    • View on GitHub (main branch)
    • Setting up BICEP analysis
    • Loading pre-computed scenario results
    • Calculating and visualizing costs
    • Key cost drivers
  2. data-requirements.ipynb - Understanding input data
    • View on GitHub (main branch)
    • Input data structure and requirements
    • Available technologies and projections
    • Technology forecasts across scenarios
    • Custom forecast integration
  3. scenario-comparison.ipynb - Comparing scenarios
  4. custom-distributions.ipynb - Advanced customization

Running the Notebooks

Prerequisites

  1. Conda Environment: Set up the BICEP conda environment (see Getting Started)
  2. Data Files: Notebooks use the local SQLite database at data/bicep.x-stock.db
  3. Jupyter Kernel: Select the bicep-env kernel in VS Code or JupyterLab

Launch Instructions

Option 1: VS Code (Recommended)

  • Open the notebook file in VS Code
  • Select the bicep-env kernel when prompted
  • Run cells using Shift+Enter

Option 2: JupyterLab

jupyter lab examples/notebooks/basic-analysis.ipynb

Option 3: Jupyter Notebook

jupyter notebook examples/notebooks/basic-analysis.ipynb

Using BICEP Methods

For detailed API documentation and method references, see the API Reference.

Quick Start

The simplest way to use BICEP:

from bicep.analysis import BicepResults

# Create results for a scenario
results = BicepResults(scenario='bau')  # or 'high'

# View total costs
print(f"Total infrastructure cost: ${results.total_cost:,.0f}")

# Plot capacity requirements by technology
results.plot_drivers(residential=1)

Next Steps


Table of contents


Notice

This material was prepared as an account of work sponsored by an agency of the United States Government. Neither the United States Government nor the United States Department of Energy, nor Battelle, nor any of their employees, nor any jurisdiction or organization that has cooperated in the development of these materials, makes any warranty, express or implied, or assumes any legal liability or responsibility for the accuracy, completeness, or usefulness or any information, apparatus, product, software, or process disclosed, or represents that its use would not infringe privately owned rights.

Reference herein to any specific commercial product, process, or service by trade name, trademark, manufacturer, or otherwise does not necessarily constitute or imply its endorsement, recommendation, or favoring by the United States Government or any agency thereof, or Battelle Memorial Institute. The views and opinions of authors expressed herein do not necessarily state or reflect those of the United States Government or any agency thereof.

PACIFIC NORTHWEST NATIONAL LABORATORY
operated by
BATTELLE
for the
UNITED STATES DEPARTMENT OF ENERGY
under Contract DE-AC05-76RL01830

Copyright © 2024 Pacific Northwest National Laboratory. Distributed under the BSD 2-Clause License.