minor code cleaning

This commit is contained in:
Fabian Neumann 2021-07-02 15:08:06 +02:00
parent 89eccd4f70
commit 81b009e062
2 changed files with 5 additions and 6 deletions

View File

@ -5,7 +5,6 @@ import xarray as xr
import pandas as pd import pandas as pd
import atlite import atlite
cutout_path = snakemake.config['atlite']['cutout_dir'] + "/" + snakemake.config['atlite']['cutout_name']+ ".nc"
if __name__ == '__main__': if __name__ == '__main__':
if 'snakemake' not in globals(): if 'snakemake' not in globals():

View File

@ -850,12 +850,12 @@ def add_electricity_grid_connection(n, costs):
n.generators.loc[gens, "capital_cost"] += costs.at['electricity grid connection', 'fixed'] n.generators.loc[gens, "capital_cost"] += costs.at['electricity grid connection', 'fixed']
def add_storage(network): def add_storage(n, costs):
print("adding electricity and hydrogen storage") print("adding electricity and hydrogen storage")
nodes = pop_layout.index nodes = pop_layout.index
network.add("Carrier", "H2") n.add("Carrier", "H2")
n.madd("Bus", n.madd("Bus",
nodes + " H2", nodes + " H2",