correct placement of if/else

This commit is contained in:
martacki 2021-07-02 10:04:22 +02:00
parent d78f8b3e65
commit 89631b240a

View File

@ -363,11 +363,10 @@ if __name__ == "__main__":
if snakemake.wildcards.simpl: if snakemake.wildcards.simpl:
n, cluster_map = cluster(n, int(snakemake.wildcards.simpl)) n, cluster_map = cluster(n, int(snakemake.wildcards.simpl))
busmaps.append(cluster_map) busmaps.append(cluster_map)
update_p_nom_max(n)
else: else:
n.buses = n.buses.drop(['symbol', 'tags', 'under_construction', 'substation_lv', 'substation_off'], axis=1) n.buses = n.buses.drop(['symbol', 'tags', 'under_construction', 'substation_lv', 'substation_off'], axis=1)
update_p_nom_max(n)
n.export_to_netcdf(snakemake.output.network) n.export_to_netcdf(snakemake.output.network)