Merge pull request #1063 from PyPSA/pre-commit-ci-update-config
[pre-commit.ci] pre-commit autoupdate
This commit is contained in:
commit
3d24b20585
@ -74,7 +74,7 @@ repos:
|
|||||||
|
|
||||||
# Format Snakemake rule / workflow files
|
# Format Snakemake rule / workflow files
|
||||||
- repo: https://github.com/snakemake/snakefmt
|
- repo: https://github.com/snakemake/snakefmt
|
||||||
rev: v0.10.1
|
rev: v0.10.2
|
||||||
hooks:
|
hooks:
|
||||||
- id: snakefmt
|
- id: snakefmt
|
||||||
|
|
||||||
|
@ -111,16 +111,12 @@ def add_brownfield(n, n_p, year):
|
|||||||
.groupby(level=0)
|
.groupby(level=0)
|
||||||
.sum()
|
.sum()
|
||||||
)
|
)
|
||||||
remaining_capacity = (
|
remaining_capacity = pipe_capacity - CH4_per_H2 * already_retrofitted.reindex(
|
||||||
pipe_capacity
|
index=pipe_capacity.index
|
||||||
- CH4_per_H2
|
).fillna(0)
|
||||||
* already_retrofitted.reindex(index=pipe_capacity.index).fillna(0)
|
|
||||||
)
|
|
||||||
n.links.loc[gas_pipes_i, "p_nom"] = remaining_capacity
|
n.links.loc[gas_pipes_i, "p_nom"] = remaining_capacity
|
||||||
else:
|
else:
|
||||||
new_pipes = n.links.carrier.isin(pipe_carrier) & (
|
new_pipes = n.links.carrier.isin(pipe_carrier) & (n.links.build_year == year)
|
||||||
n.links.build_year == year
|
|
||||||
)
|
|
||||||
n.links.loc[new_pipes, "p_nom"] = 0.0
|
n.links.loc[new_pipes, "p_nom"] = 0.0
|
||||||
n.links.loc[new_pipes, "p_nom_min"] = 0.0
|
n.links.loc[new_pipes, "p_nom_min"] = 0.0
|
||||||
|
|
||||||
|
Loading…
Reference in New Issue
Block a user