Skip to content

0.9 release: develop -> main - #830

Merged
johnjasa merged 249 commits into
mainfrom
develop
Aug 10, 2026
Merged

0.9 release: develop -> main#830
johnjasa merged 249 commits into
mainfrom
develop

Conversation

@johnjasa

@johnjasa johnjasa commented Aug 10, 2026

Copy link
Copy Markdown
Collaborator

0.9 release: develop -> main

New Features

  • Creates the EIANaturalGasFeedstockConfig and EIANaturalGasFeedstockCostModel to load EIA natural gas prices from file or to retrieve them from the EIA API. The model is able to retrieve the US or any of the 50 states' annual or monthly values, which will be converted into an hourly timeseries. PR 719
  • Add electric arc furnace performance and cost models based on the Carnegie Mellon University DecarbSTEEL v5 excel model PR 686
    • Adds scrap-only performance model
    • Adds DRI + scrap performance model
    • Adds EAF cost model applicable to both performance models
  • Introduce general system-level controls framework. PR 751
  • Add PeakLoadManagementHeuristicOpenLoopStorageController as a storage control strategy. PR 641
  • Added a thermal-nuclear (light-water reactor) model and a high-temperature steam electrolysis model. PR 807

Updates

Modeling

  • Change commodity in DRI and EAF model from pig iron to sponge iron based on likely carbon content PR 670
  • Added electricity and water consumption profiles as outputs to the ECOElectrolyzerPerformanceModel PR 690
  • Add per-year pricing support for Grid and Feedstock cost models, allowing price arrays of length plant_life in addition to scalar and per-timestep arrays. PR 700
  • Added ability to have a custom/user-specified resource model PR 698
  • Add {commodity}_set_point as an input to hydrogen fuel cell model PR 709
  • Rename n_control_window to n_control_window_hours for unit clarity PR 712
  • Creates a series of preprocessing tools for basic state name and abbreviation handling, and for reverse geocoding coordinates to state data. PR 719
  • Creates a series of preprocessing tools for downloading EIA natural gas prices to monthly and hourly timeseries that could be extended to other EIA API data in the future. PR 719
  • Added ability to use timeseries for finance calculations PR 725
  • Added multivariable purge gas stream output to AmmoniaSynLoopPerformanceModel PR 760
  • Add constant pricing mode for Grid cost models, allowing an explicit scalar price configuration alongside per_timestep and per_year modes. PR 764
  • Added dynamic operating constraints (turndown, ramping, warm/cold start delays) to AmmoniaSynLoopPerformanceModel and split AmmoniaSynLoopCostModel into its own module. PR 770
  • Added an optional inflation_rate input to NumpyFinancialNPVFinanceConfig that is combined with real_discount_rate via the Fisher equation to form the effective rate passed to numpy_financial.npv, allowing users to supply either a nominal discount rate (with inflation_rate=0, the default) or a real discount rate together with an explicit inflation rate. Matches how ProFAST combines its real discount rate and general_inflation inputs. PR 788
  • Renamed the discount_rate input to real_discount_rate in NumpyFinancialNPVFinanceConfig to clarify that it is combined with inflation_rate via the Fisher equation. The ProFAST models keep their existing discount_rate name. Updated the numpy NPV model, tests, docs, and the example 19 config accordingly. PR TBD
  • Connect each cost-aware system-level controller's {tech}_buy_price input directly to the technology's own buy-price input via OpenMDAO 3.44 input-to-input connections, so a single prob.set_val() on (for example) grid.electricity_buy_price now propagates to the SLC. PR 791
  • Added system-level-controller unit tests that confirm the cost_per_tech: feedstock mode correctly sums VarOpEx from all upstream feedstocks for a multi-feedstock dispatchable, including a fuel-cell-style hydrogen-plus-oxygen scenario and a case with feedstocks at different graph depths. PR 793
  • Updated ammonia synloop test values and loosened test value tolerances due to unnecessary sensitivities from dynamic behavior PR 795
  • Removed hard-coded logic of price units in finance models to be flexible to any type of commodity. Created helper functions _compute_price_units and _compute_rate_units in h2integrate.finances.tools and integrated usage of these functions into all finance models (numpy_financial_npv, profast_npv, profast_lco) accordingly. PR 786
  • Added capability to specify demand technology for system-level control, and renamed the framework-derived system-level control classification dict from slc_config to slc_topology to distinguish it from the user-authored control_parameters block. PR 784
  • Added capability to specify demand technology for system-level control, and renamed the framework-derived system-level control classification dict from slc_config to slc_topology to distinguish it from the user-authored control_parameters block. PR 784
  • Updated commodity_sell_price input to ProFastNPV to be per year of the plant life. Also updated BasicProFASTParameterConfig.as_dict() so explicitly input escalation values are not overwritten to the general inflation rate PR 799
  • Added calc_azimuth_angle() to PYSAMSolarPlantPerformanceModel to provide default azimuth angle based on whether the site is in the northern or southern hemisphere PR 806
  • Renamed OpenLoopStorageControlBase to OpenLoopControlBase and OpenLoopStorageControlBaseConfig to OpenLoopControlBaseConfig and moved them out of the control storage sub-directory. PR 828

Infrastructure

  • Renamed {commodity}_demand inputs to {commodity}_set_point on all converter performance components to align with storage baseclass naming and distinguish converter operating targets from demand components. PR 691
  • Minor cleanup to pose_optimization PR 695
  • feedstocks.py has moved from h2integrate/core/ to h2_integrate/feedstocks PR 719
  • Added basic check of 4-length connections in technology_interconnections PR 720
  • Adds H2IntegrateModel, load_yaml, write_yaml, and write_readable_yaml as package-level imports PR 728.
  • Reduced import time for h2integrate_model.py by deferring imports of heavy dependencies until they are needed PR 762
  • Renamed design_of_experiments to parameter_sweep throughout the codebase to avoid confusion with "Department of Energy" (DOE) in the energy domain. The core code supports both the new parameter_sweep and legacy design_of_experiments YAML keys for backward compatibility. Updated all driver configs, examples, tests, and documentation. Added generator type descriptions to the parameter sweep docs page and updated the run-cases docs to recommend parameter sweeps over manual for-loops. PR 768
  • Added imports for individual models to the appropriate __init__.py files to allow for direct imports of models from the package level and to ensure all models are properly imported and used in supported_models.py PR 769
  • Speed up the slowest tests in the suite by swapping the Floris wind model for PYSAMWindPlantPerformanceModel in examples 01 (01_onshore_steel_mn) and 02 (02_texas_ammonia), updating the affected test_steel_example/test_simple_ammonia_example expected values, fixing a pre-existing cases.sql cache-path bug and module-scoping the fixtures in h2integrate/postprocess/test/test_sql_timeseries_to_csv.py so the example only runs once for all four tests. PR 782
  • Exposed n_timesteps, dt, plant_life, and fraction_of_year_simulated as attributes on CostModelBaseClass (matching PerformanceModelBaseClass) and updated all cost and performance model subclasses across h2integrate/ to use these attributes instead of reading them from plant_config, removing redundant boilerplate from individual components. PR 783
  • Rewrote the "Adding a new technology" developer guide. Also replaced the hand-maintained model overview page with an auto-generated section (docs/generate_model_overview.py) that classifies every registered class in supported_models and appends the first sentence of each class's docstring. Migrated .readthedocs.yaml to invoke docs/build_book.sh via build.commands so hosted and local builds stay in sync. PR 787
  • Moves h2integrate/resource/utilities/file_tools.py::check_resource_dir to a general function h2integrate/core/utilities/file_utils.py::check_data_dir with a wrapped version for resource data (check_resource_dir) and feedstock data (check_feedstock_data). PR 791
  • Removed the is_electricity_producer helper from h2integrate.core.commodity_stream_definitions and the electricity-specific auto-detection branch in H2IntegrateModel, making finance-subgroup commodity_stream resolution fully commodity-agnostic; updated example plant_config.yaml files that previously relied on the auto-detection to set commodity_stream explicitly. PR 786
  • Ensure OpenMDAO data is cleaned up during testing PR 797.
  • Reduced Sphinx documentation build warnings from roughly 880 to under 20. PR 800
    • Set napoleon_use_ivar and added napoleon_custom_sections so custom Google-style sections (Inputs, Outputs, Promoted Inputs, Promoted Outputs, Subsystems, Discrete Inputs, Discrete Outputs, Options, Behavior, Side Effects) render cleanly.
    • Suppressed the etoc.toctree category emitted by autosummary :recursive: stubs.
    • Cleared stale _autosummary/ files at the start of every docs build.
    • Removed duplicated Methods: docstring sections that collided with autodoc method discovery.
    • Added :no-index: to hand-authored autoclass directives that duplicated autosummary entries.
    • Cleaned up docstring formatting bugs across roughly twenty source files (bullet and definition list separations, starred attribute markers, unbalanced backticks, and stray substitution references).
    • Fixed several MyST cross-reference targets (missing labels, ambiguous doc vs ref targets, incorrect autosummary path, duplicate labels, broken image path, and a broken literalinclude path).
    • Added a custom docs/_templates/autosummary/module.rst template that filters pytest conftest.py submodules from generated stubs, eliminating the "failed to import conftest" warnings that appeared on the Read the Docs build.
    • Renamed the GeoH2SubsurfaceCostModel MyST label in docs/technology_models/geologic_hydrogen.md to mathur-modified-geoh2-cost to remove an ambiguous cross-reference with the autosummary entry for the Python class of the same name.
  • Updates h2integrate/core/file_utils.py::check_data_dir to allow for the creation of nested directories, not just the final subdirectory for smoother initialization of a feedstock directory PR 801.
  • Adds feedstock_dir to the EIA natural gas retrieval to align the downloading or loading of the feedstock data with the resource data methodology PR 801.
  • Add support for slice notation in technology connections to allow users to connect between variables of different shapes. PR 774
  • Updated edge attribute commodity of in H2Integrate.create_technology_graph to use lists instead of strings to account for systems with multiple commodities connected between two technologies PR 823

Fixes

  • Bug fix so multi-level output path won't throw an error; updated test for EIA API handling. PR 820
  • Bugfix for round-trip efficiency handling when calling check_inputs around StoragePerformanceModel PR 684
  • Bugfix. Include nuclear in electricity producing tech list and improve error message for zero-length electricity producing techs in model when electricity is specified as the commodity. PR 685
  • Update N2 diagram for demand openloop control from static and outdated to dynamic and interactive PR 714
  • Update N2 diagram for Pyomo heuristic control from static image to dynamic and interactive embedded diagram PR 726
  • Fixes a series of small bugs in the EIA natural gas feedstock modeling, and adds a test for the file-based usage PR 777.
  • Corrected water rate units in pipe feedstock from galUS to galUS/h PR 813
  • Corrected timestamps in OpenMeteo resource downloads when resource data is downloaded in local time PR #814
  • Fixed docs build warnings by correcting inline-literal docstring markup etc, also enabled warning-as-error in the shared docs build script to minimize number of future warnings. PR 821

dakotaramos and others added 30 commits March 27, 2026 12:21
Develop -> Main for v0.8 release (#682)
* update from pig iron to sponge iron

* changelog

* update lco naming in test
ptrbortolotti and others added 27 commits June 18, 2026 13:14
#771)

* more robust api calls, suggested by copilot after all my api calls were failing

* run precommit

* Update h2integrate/resource/utilities/download_tools.py

Co-authored-by: elenya-grant <116225007+elenya-grant@users.noreply.github.com>

* import warnings was missing

* Apply suggestions from code review

Co-authored-by: John Jasa <john.jasa@nrel.gov>

* Apply suggestion from @johnjasa

---------

Co-authored-by: Pietro Bortolotti <pietro.bortolotti@nrel.gov>
Co-authored-by: John Jasa <johnjasa11@gmail.com>
Co-authored-by: elenya-grant <116225007+elenya-grant@users.noreply.github.com>
Co-authored-by: John Jasa <john.jasa@nrel.gov>
…786)

* removed logic in profast base for commodity units

* updated profast LCO and baseclass - still have clean-up todo

* fixed some bugs

* got profast npv working

* renamed function used for compute_units

* udpated numpy npv

* Added docstrings to compute_price_units and shifted it to tools

* Removed is_electricity_producer

* Adding back run_model call that was actually necessary

* Updating other examples for new finance setup:

* Trying to fix failing tests

* Removed placeholder logic for NPV, just having sell price units explicitly defined

* Removed last of logic that mapped names to units in H2IntegrateModel

* added new tool and fixed NPV models

* added in comments and docstring to tools

* undid previous change to a test structure for an npv model

* added test to profast_npv that uses nonstandard price units

* added subtest for heat-based commodity

* minor typo fix

* Simplified the units handling

* updated numpy npv to be able to handle nonstandard units

---------

Co-authored-by: John Jasa <johnjasa11@gmail.com>
…791)

* add  to  and default feedstocks

* move check_reource_dir tests to test_utilities and fix issues

* update usage in resource tools

* remove old usage

* update changelog

* add PR number

* remove subtest for loading data into a context

* update feedstock default directory and comment

* fixed bug w tests

* updated to use walruns operator

* use a fixture to temporarily set environment variables and clean them up consistently

* ensure the original value is preserved

* fix user error

* added comments warning folks about the sensitivities of the test that caused headaches

---------

Co-authored-by: John Jasa <johnjasa11@gmail.com>
Co-authored-by: elenya-grant <116225007+elenya-grant@users.noreply.github.com>
* move url retrieval below filename check in case of file, not api

* add missing and condition

* add missing arguments to monthly conversion

* add missing discrete i/o

* add missing discrete i/o in super call

* use all() on np.isclose() comparison

* use expected numpy array, not pandas dataframe

* remove unnecessary default price definition

* add test for eia feedstock from file usage and model run

* update changelog

* fix test after change from pd to np

* Update h2integrate/feedstocks/test/test_feedstocks.py

Co-authored-by: elenya-grant <116225007+elenya-grant@users.noreply.github.com>

* Update h2integrate/feedstocks/test/test_feedstocks.py

Co-authored-by: elenya-grant <116225007+elenya-grant@users.noreply.github.com>

* update all model calls

---------

Co-authored-by: elenya-grant <116225007+elenya-grant@users.noreply.github.com>
Co-authored-by: John Jasa <johnjasa11@gmail.com>
…tion (#797)

* convert temp_copy_of_example workaround to use temp_copy_of_example

* update changelog

---------

Co-authored-by: John Jasa <johnjasa11@gmail.com>
…iew, unify the docs build (#787)

* Revamped the adding a new technology page

* Updating model overview docs and other pages

* Updated changelog

* Update docs/developer_guide/adding_a_new_technology.md

* Update docs/developer_guide/adding_a_new_technology.md

* Update docs/developer_guide/adding_a_new_technology.md

* Update docs/developer_guide/adding_a_new_technology.md

* update docs

* Cleaning up part of the docs

---------

Co-authored-by: kbrunik <102193481+kbrunik@users.noreply.github.com>
Co-authored-by: kbrunik <kbrunik@gmail.com>
* updated SLC framework to require user to specify demand technology and only connect upstream techs to the controller

* fixed bug

* updated error message

* added framework tests for SLC

* renamed local variable of tech_graph to upstream_tech_graph

* updated SLC doc page

* added integration test example

* added integration tests

* added units with set and get_val and updated the one subtest thats failing to be more useful

* added control classifier to demand comps

* Renamed `slc_config` to `slc_topology` to reduce confusion

* Minor SLC logic clarifications

---------

Co-authored-by: John Jasa <johnjasa11@gmail.com>
…lity (#801)

* add feedstock_dir to EIA NG inputs

* allow for parent directory creation in multi-folder creation

* better control flow using data_subdir only when no input

* fix issues and update fixture usage

* update changelog

* update changelog

* only check feedstock_dir if filename is not None

* update changelog

* fix erroneous filename handling, duplicated directory resolution and missing assignment

* Fix changelog

---------

Co-authored-by: John Jasa <johnjasa11@gmail.com>
* move tests for split indices

* revert obsolete changes to plant schema

* fix bugs in length 3 connections for src_indices

* remove use of eval

* add ValueError for non-zero destination slice starts

* allow for src_indices tiling into destination

* update wind solar electrolyzer example to demonstrate different finance and connection approaches

* add tests for each finance/connection approach added to wind solar electrolyzer example

* add documentation for variable slicing in technology connections

* update changelog

* fix typo

* Update docs/user_guide/connecting_technologies.md

improve comment

Co-authored-by: elenya-grant <116225007+elenya-grant@users.noreply.github.com>

---------

Co-authored-by: elenya-grant <116225007+elenya-grant@users.noreply.github.com>
* Removing a lot of warnings when building docs

* Loosening ammonia tolerance in the example test

* Cleaning up a few more docs build issues

* Fixing minor doc indentation issues
* made it so profast npv can take in multi-year sell price costs

* updated error handling for misisng sell price value

* added subtest for inflation test

* updated profast NPV doc page

* updated BasicProFASTParameterConfig.from_dict() so that user-provided escalation values are not overwritten with the inflation rate

* updated so sell price is input as a dictionary to ProFAST

* minor updates to profast parameter config and added test

* updated so ProFAST NPV is input an array rather than a dict

* minor clarification in doc page

* updated changelog
* added calc_azimuth_angle to pysam solar

* removed azimuth specified in test_pvwatts_integration
…ariables (#798)

* added draft of generalizing api key tools

* generalized api methods properly

* moved base environment var functions to core

* removed old work

* minor clean-ups to generalized stuff

* removed commented out code

* removed usage of globals()

* started adding in test file

* added another test and bugfix in loading environment variable from file

* removed commented out code and added todos

* updated so that setter method is called after _get_env_with_fallback

* added doc strings to setter methods in nlr_developer_api_keys.py

* refactored environment tools with help from Rob

* minor changes to nlr_developer_api_keys

* updated tests for env_tools

* updated conftest.py files

* updated doc page

* updated conftest.py files and get_environment_variables

* added doc page for debugging environment variable problems

* updated doc page so formatting is nice

* typo fix in model_overview.md

* updates to doc pages

* added set_vars as input to get_nlr_developer_api_credential and updated conftest.py files

* updated debugging environment variables doc page

* cleaned up some of test_env_tools.py

* finished cleanups to test_env_tools.py

* updated conftest.py files

* updated changelog

* Added new method to check for duplicate defined environment variables and to raise a user warning

* changed executable code cell to python code block in doc page

* commiting johns doc changes

---------

Co-authored-by: John Jasa <johnjasa11@gmail.com>
* correct rate units from galUS to galUS/h

* update pipe units for water from galUS to galUS/h

* update changelog
* added draft of generalizing api key tools

* generalized api methods properly

* moved base environment var functions to core

* removed old work

* minor clean-ups to generalized stuff

* removed commented out code

* removed usage of globals()

* started adding in test file

* added another test and bugfix in loading environment variable from file

* removed commented out code and added todos

* updated so that setter method is called after _get_env_with_fallback

* added doc strings to setter methods in nlr_developer_api_keys.py

* refactored environment tools with help from Rob

* minor changes to nlr_developer_api_keys

* updated tests for env_tools

* updated conftest.py files

* updated doc page

* updated conftest.py files and get_environment_variables

* added doc page for debugging environment variable problems

* updated doc page so formatting is nice

* typo fix in model_overview.md

* updates to doc pages

* added set_vars as input to get_nlr_developer_api_credential and updated conftest.py files

* updated debugging environment variables doc page

* cleaned up some of test_env_tools.py

* finished cleanups to test_env_tools.py

* updated conftest.py files

* updated changelog

* Added new method to check for duplicate defined environment variables and to raise a user warning

* changed executable code cell to python code block in doc page

* trying to understand problem with openmeteo downloads

* still trying to understand openmeteo downloads

* got openmeteo solar data to work properly

* minor change to solar_resource_base

* cleaned up openmeteo solar data

* removed print statement

* minor cleanups to openmeteo solar model

* added all resource files that could be used for testing - will likely remove some of these

* Added big integration test of openmeteo solar models

* updated openmeteo wind and moved make_time_index to utility file

* removed 3 recently added resource files

* updated solar resource test that was failing

* added doc string and comments to new function in download_tools

* removed commented out code from openmeteo solar

* updated subtest values for example 13 and 26

* removed old download resource file and corresponding subtests

* updated resource_index.md

* updated changelog

* Added fail-fast false to CI

* Updated floris test

---------

Co-authored-by: John Jasa <johnjasa11@gmail.com>
* Add nuclear thermal plant model with primary `heat` and `electricity` modes
* Add HTSE/SOEC model with heat input

---------

Co-authored-by: Daniel Mark Mikkelson <89001004104222@fedidcard.gov>
Co-authored-by: mikkdm <74319124+mikkdm@users.noreply.github.com>
Co-authored-by: John Jasa <johnjasa11@gmail.com>
Co-authored-by: John Jasa <john.jasa@nrel.gov>
* Adding inflation rate to numpy NPV calc

* Update docs/finance_models/numpy_financial_npv.md

Co-authored-by: Jared Thomas <jaredthomas68@users.noreply.github.com>

* renaming discount_rate to real_discount_rate for numpy npv

* Inconsequential change to trigger CI

* add wacc calculation to numpy npv and clarify that the numpy npv model is pre-tax

---------

Co-authored-by: Jared Thomas <jaredthomas68@users.noreply.github.com>
Co-authored-by: Jared Thomas <jaredthomas68@gmail.com>
* Updating throughout to remove last of doc warnings

* Fix PR reference for docs build warnings

Updated PR reference for fixing docs build warnings in CHANGELOG.
* Bug fix for output path handling

* update changelog

* update eia test to reflect expected failure mode

* Changed EIA key logic to use monkeypatch

---------

Co-authored-by: John Jasa <johnjasa11@gmail.com>
* updated how technology_graph edge data is added and added test and updated what info is given to the SLC model wrt upstream techs

* updated slc baseclass method that would break with new use case

* Making graph edges always a list

* Updating commodity edges to always be lists

* updated changelog

* removed unused method and minor change

---------

Co-authored-by: John Jasa <johnjasa11@gmail.com>
* added Path validator to schema validators

* added unit test

* Very minor type checking changes to yaml schema

---------

Co-authored-by: John Jasa <johnjasa11@gmail.com>
* rename and move openloop_storage_control_base to remove 'storage' since it can be used for converters

* update changelog and class hierarchy
* update changelog

* Bump version number

---------

Co-authored-by: kbrunik <kbrunik@gmail.com>
@johnjasa
johnjasa requested a review from kbrunik August 10, 2026 17:20
@coveralls

coveralls commented Aug 10, 2026

Copy link
Copy Markdown

Coverage Status

coverage: 89.728% (+1.4%) from 88.286% — develop into main

@johnjasa
johnjasa merged commit d53fbd8 into main Aug 10, 2026
13 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.