Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Features/#377 grid separation #380

Merged
merged 26 commits into from
May 9, 2023
Merged
Show file tree
Hide file tree
Changes from 11 commits
Commits
Show all changes
26 commits
Select commit Hold shift + click to select a range
1afb2be
added lv grid separation functionality
khelfen May 3, 2023
ea77207
added tests for lv grid separation
khelfen May 3, 2023
825109b
Merge branch 'dev' into features/#377-grid-separation
khelfen May 3, 2023
caf4e6b
Merge branch 'dev' of github.com:openego/eDisGo into features/#377-gr…
khelfen May 4, 2023
a6793c2
Added workflow to separate all lv grids
khelfen May 5, 2023
e720b79
connect new lv grid to existing mv bus instead of creating a new mv bus
khelfen May 5, 2023
80fcbae
make sure that only downstream buses of bus_1_2 are relocated to th n…
khelfen May 5, 2023
fa4f229
change logging string
khelfen May 5, 2023
ac17817
Make sure that the nodes of a feeder are sorted correctly when separa…
khelfen May 8, 2023
028d5ec
add equipment changes to workflow
khelfen May 8, 2023
d7c1992
adapted whatsnew
khelfen May 8, 2023
36b542e
docstrings
khelfen May 8, 2023
92c82a5
also except RuntimeErrors in enhanced reinforcement
khelfen May 8, 2023
ea470ef
fix docstrings
khelfen May 8, 2023
2d2def2
Merge branch 'dev' into features/#377-grid-separation
khelfen May 8, 2023
6684b92
Minor doc and logging changes
birgits May 8, 2023
f473b5a
simplify apparent power calculation
khelfen May 9, 2023
48255d3
make sure to idntify station node correctly
khelfen May 9, 2023
3a28aa2
add comments at hard to undrstand parts
khelfen May 9, 2023
ba00bc9
fix test_separate_lv_grid
khelfen May 9, 2023
20db1e1
Minor doc change
birgits May 9, 2023
b7230c1
Bug fix avoid float becoming object type
birgits May 9, 2023
efd4af0
Correct docstring
birgits May 9, 2023
74ea1e7
Fix check if LV grid ID is provided
birgits May 9, 2023
5024be3
Minor logging typo fix
birgits May 9, 2023
9a90942
Add grid separation when power flow for LV grid does not converge
birgits May 9, 2023
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
1 change: 1 addition & 0 deletions doc/whatsnew/v0-3-0.rst
Original file line number Diff line number Diff line change
Expand Up @@ -21,3 +21,4 @@ Changes
* Added method to iteratively reinforce a grid in case the power flow analysis does not always converge `#353 <https://github.com/openego/eDisGo/pull/353>`_
* Added method to aggregate LV grid buses to station bus secondary side `#353 <https://github.com/openego/eDisGo/pull/353>`_
* Added option to run reinforcement with reduced number of time steps `#379 <https://github.com/openego/eDisGo/pull/379>`_
* Added a new reinforcement method that separate lv grids when the overloading is very high `#380 <https://github.com/openego/eDisGo/pull/380>`_
14 changes: 10 additions & 4 deletions edisgo/edisgo.py
Original file line number Diff line number Diff line change
Expand Up @@ -1261,12 +1261,15 @@ def reinforce(
run_analyze_at_the_end = False

logger.info(f"Run the following reinforcements: {setting_list=}")

for setting in setting_list:
logger.info(f"Run the following reinforcement: {setting=}")
if not catch_convergence_problems:
func = reinforce_grid
else:
func = catch_convergence_reinforce_grid
func = (
catch_convergence_reinforce_grid
if catch_convergence_problems
else reinforce_grid
)

func(
edisgo_obj,
max_while_iterations=max_while_iterations,
Expand All @@ -1275,14 +1278,17 @@ def reinforce(
n_minus_one=n_minus_one,
**setting,
)

if run_analyze_at_the_end:
lv_grid_id = kwargs.get("lv_grid_id", None)

if mode == "lv" and lv_grid_id:
analyze_mode = "lv"
elif mode == "lv":
analyze_mode = None
else:
analyze_mode = mode

edisgo_obj.analyze(
mode=analyze_mode, lv_grid_id=lv_grid_id, timesteps=timesteps_pfa
)
Expand Down
Loading