Merge branch 'fneum/line-rating' of github.com:PyPSA/pypsa-eur into fneum/line-rating

This commit is contained in:
Fabian Neumann 2023-06-29 11:42:15 +02:00
commit 907382e83a

View File

@ -271,17 +271,21 @@ rule build_hydro_profile:
"../scripts/build_hydro_profile.py" "../scripts/build_hydro_profile.py"
if config['lines']['dynamic_line_rating']['activate']: if config["lines"]["dynamic_line_rating"]["activate"]:
rule build_line_rating: rule build_line_rating:
input: input:
base_network=RESOURCES + "networks/base.nc", base_network=RESOURCES + "networks/base.nc",
cutout="cutouts/" + CDIR + config["lines"]['cutout'] + ".nc" cutout="cutouts/" + CDIR + config["lines"]["cutout"] + ".nc",
output: output:
output=RESOURCES + "networks/line_rating.nc" output=RESOURCES + "networks/line_rating.nc",
log: LOGS + "build_line_rating.log" log:
benchmark: BENCHMARKS + "build_line_rating" LOGS + "build_line_rating.log",
benchmark:
BENCHMARKS + "build_line_rating"
threads: ATLITE_NPROCESSES threads: ATLITE_NPROCESSES
resources: mem_mb=ATLITE_NPROCESSES * 1000 resources:
mem_mb=ATLITE_NPROCESSES * 1000,
conda: conda:
"../envs/environment.yaml" "../envs/environment.yaml"
script: script:
@ -309,7 +313,9 @@ rule add_electricity:
if str(fn).startswith("data/") if str(fn).startswith("data/")
}, },
base_network=RESOURCES + "networks/base.nc", base_network=RESOURCES + "networks/base.nc",
line_rating=RESOURCES + "networks/line_rating.nc" if config['lines']['dynamic_line_rating']['activate'] else RESOURCES + "networks/base.nc", line_rating=RESOURCES + "networks/line_rating.nc"
if config["lines"]["dynamic_line_rating"]["activate"]
else RESOURCES + "networks/base.nc",
tech_costs=COSTS, tech_costs=COSTS,
regions=RESOURCES + "regions_onshore.geojson", regions=RESOURCES + "regions_onshore.geojson",
powerplants=RESOURCES + "powerplants.csv", powerplants=RESOURCES + "powerplants.csv",