Skip to content

Commit

Permalink
Merge pull request #197 from PyPSA/cp-env
Browse files Browse the repository at this point in the history
Snakefile: export conda environment
  • Loading branch information
fneum authored Nov 15, 2022
2 parents c8d09da + 6372427 commit d35d3c3
Showing 1 changed file with 9 additions and 0 deletions.
9 changes: 9 additions & 0 deletions Snakefile
Original file line number Diff line number Diff line change
Expand Up @@ -532,6 +532,14 @@ rule copy_config:
script: "scripts/copy_config.py"


rule copy_conda_env:
output: SDIR + '/configs/environment.yaml'
threads: 1
resources: mem_mb=500
benchmark: SDIR + "/benchmarks/copy_conda_env"
shell: "conda env export -f {output} --no-builds"


rule make_summary:
input:
overrides="data/override_component_attrs",
Expand Down Expand Up @@ -591,6 +599,7 @@ if config["foresight"] == "overnight":
network=RDIR + "/prenetworks/elec_s{simpl}_{clusters}_lv{lv}_{opts}_{sector_opts}_{planning_horizons}.nc",
costs=CDIR + "costs_{}.csv".format(config['costs']['year']),
config=SDIR + '/configs/config.yaml'
env=SDIR + '/configs/environment.yaml'
output: RDIR + "/postnetworks/elec_s{simpl}_{clusters}_lv{lv}_{opts}_{sector_opts}_{planning_horizons}.nc"
shadow: "shallow"
log:
Expand Down

0 comments on commit d35d3c3

Please sign in to comment.