diff --git a/scripts/solve_network.py b/scripts/solve_network.py index 4028a156..8a577e23 100644 --- a/scripts/solve_network.py +++ b/scripts/solve_network.py @@ -735,9 +735,9 @@ def add_operational_reserve_margin(n, sns, config): .loc[vres_i.intersection(ext_i)] .rename({"Generator-ext": "Generator"}) ) - lhs = summed_reserve + (p_nom_vres * (-EPSILON_VRES * xr.DataArray(capacity_factor))).sum( - "Generator" - ) + lhs = summed_reserve + ( + p_nom_vres * (-EPSILON_VRES * xr.DataArray(capacity_factor)) + ).sum("Generator") # Total demand per t demand = get_as_dense(n, "Load", "p_set").sum(axis=1)