Skip to content

Commit cf51088

Browse files
[pre-commit.ci] auto fixes from pre-commit.com hooks
for more information, see https://pre-commit.ci
1 parent e9f212d commit cf51088

File tree

2 files changed

+10
-4
lines changed

2 files changed

+10
-4
lines changed

scripts/prepare_sector_network.py

Lines changed: 7 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -412,9 +412,13 @@ def create_network_topology(
412412
lk_attrs = n.links.columns.intersection(lk_attrs)
413413

414414
candidates = pd.concat(
415-
[n.lines[ln_attrs],
416-
n.links.loc[(n.links.carrier.isin(carriers)) & (n.links.underwater_fraction > 0.1),
417-
lk_attrs]]
415+
[
416+
n.lines[ln_attrs],
417+
n.links.loc[
418+
(n.links.carrier.isin(carriers)) & (n.links.underwater_fraction > 0.1),
419+
lk_attrs,
420+
],
421+
]
418422
).fillna(0)
419423

420424
# base network topology purely on location not carrier

scripts/pypsa-de/additional_functionality.py

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -37,7 +37,9 @@ def add_capacity_limits(n, investment_year, limits_capacity, sense="maximum"):
3737
valid_components & ~c.static[attr + "_nom_extendable"]
3838
]
3939
extendable_index = c.static.index[
40-
valid_components & c.static[attr + "_nom_extendable"] & c.static.active
40+
valid_components
41+
& c.static[attr + "_nom_extendable"]
42+
& c.static.active
4143
]
4244

4345
existing_capacity = c.static.loc[existing_index, attr + "_nom"].sum()

0 commit comments

Comments
 (0)