Skip to content

Commit a859620

Browse files
committed
feat: call report_bottlenecks from orchestration
1 parent 655fffc commit a859620

File tree

1 file changed

+6
-0
lines changed

1 file changed

+6
-0
lines changed

prereise/gather/griddata/hifld/orchestration.py

+6
Original file line numberDiff line numberDiff line change
@@ -11,6 +11,7 @@
1111
build_solar,
1212
build_wind,
1313
)
14+
from prereise.gather.griddata.hifld.data_process.topology import report_bottlenecks
1415
from prereise.gather.griddata.hifld.data_process.transmission import build_transmission
1516

1617

@@ -34,6 +35,7 @@ def create_csvs(
3435
hydro_kwargs,
3536
solar_kwargs,
3637
wind_kwargs,
38+
zone_demand=None,
3739
):
3840
"""Process HIFLD source data to CSVs compatible with PowerSimData.
3941
@@ -45,11 +47,15 @@ def create_csvs(
4547
:func:`prereise.gather.solardata.nsrdb.sam.retrieve_data_individual`.
4648
:param dict wind_kwargs: keyword arguments to pass to
4749
:func:`prereise.gather.griddata.hifld.data_process.profiles.build_wind`.
50+
:param pandas.DataFrame zone_demand: per-zone demand profiles, used to evaluate
51+
local transmission constraints. If None, this step will be skipped.
4852
"""
4953
_check_profile_kwargs(
5054
{"hydro": hydro_kwargs, "solar": solar_kwargs, "wind": wind_kwargs}
5155
)
5256
full_tables = create_grid(output_folder)
57+
if zone_demand is not None:
58+
report_bottlenecks(full_tables["branch"], full_tables["bus"], zone_demand)
5359
create_profiles(
5460
full_tables["plant"],
5561
profile_year,

0 commit comments

Comments
 (0)