[pre-commit.ci] auto fixes from pre-commit.com hooks

for more information, see https://pre-commit.ci
This commit is contained in:
pre-commit-ci[bot] 2024-03-01 17:42:20 +00:00 committed by Fabian Neumann
parent 2055fe68ef
commit 1d709913ed

View File

@ -2905,7 +2905,10 @@ def add_industry(n, costs):
investment_year, investment_year,
) )
if snakemake.config["industry"]["waste_to_energy"] and options["regional_oil_demand"]: if (
snakemake.config["industry"]["waste_to_energy"]
and options["regional_oil_demand"]
):
n.madd( n.madd(
"Bus", "Bus",
@ -2913,7 +2916,7 @@ def add_industry(n, costs):
location=spatial.oil.demand_locations, location=spatial.oil.demand_locations,
carrier="non-sequestered HVC", carrier="non-sequestered HVC",
unit="MWh_LHV", unit="MWh_LHV",
) )
n.madd( n.madd(
"Link", "Link",
@ -2924,7 +2927,9 @@ def add_industry(n, costs):
bus3=spatial.co2.process_emissions, bus3=spatial.co2.process_emissions,
carrier="naphtha for industry", carrier="naphtha for industry",
p_nom_extendable=True, p_nom_extendable=True,
efficiency2=non_sequestered*emitted_co2_per_naphtha/costs.at["oil", "CO2 intensity"], efficiency2=non_sequestered
* emitted_co2_per_naphtha
/ costs.at["oil", "CO2 intensity"],
efficiency3=process_co2_per_naphtha, efficiency3=process_co2_per_naphtha,
) )
@ -2938,7 +2943,7 @@ def add_industry(n, costs):
efficiency=costs.at["oil", "CO2 intensity"], efficiency=costs.at["oil", "CO2 intensity"],
) )
#TODO add heat # TODO add heat
n.madd( n.madd(
"Link", "Link",
spatial.oil.demand_locations + " waste CHP", spatial.oil.demand_locations + " waste CHP",
@ -2948,14 +2953,16 @@ def add_industry(n, costs):
carrier="waste CHP", carrier="waste CHP",
p_nom_extendable=True, p_nom_extendable=True,
# p_nom=biomass_potential['municipal solid waste'] / 8760, # p_nom=biomass_potential['municipal solid waste'] / 8760,
capital_cost=costs.at['waste CHP', 'fixed'] * costs.at['waste CHP', 'efficiency'], capital_cost=costs.at["waste CHP", "fixed"]
marginal_cost=costs.at['waste CHP', 'VOM'], * costs.at["waste CHP", "efficiency"],
efficiency=costs.at['waste CHP', 'efficiency'], marginal_cost=costs.at["waste CHP", "VOM"],
#efficiency4=costs.at['waste CHP', 'efficiency-heat'], efficiency=costs.at["waste CHP", "efficiency"],
efficiency2=costs.at['oil', 'CO2 intensity'], # efficiency4=costs.at['waste CHP', 'efficiency-heat'],
lifetime=costs.at['waste CHP', 'lifetime']) efficiency2=costs.at["oil", "CO2 intensity"],
lifetime=costs.at["waste CHP", "lifetime"],
)
#TODO add heat # TODO add heat
n.madd( n.madd(
"Link", "Link",
spatial.oil.demand_locations + " waste CHP CC", spatial.oil.demand_locations + " waste CHP CC",
@ -2966,14 +2973,15 @@ def add_industry(n, costs):
carrier="waste CHP CC", carrier="waste CHP CC",
p_nom_extendable=True, p_nom_extendable=True,
# p_nom=biomass_potential['municipal solid waste'] / 8760, # p_nom=biomass_potential['municipal solid waste'] / 8760,
capital_cost=costs.at['waste CHP CC', 'fixed'] * costs.at['waste CHP CC', 'efficiency'], capital_cost=costs.at["waste CHP CC", "fixed"]
marginal_cost=costs.at['waste CHP CC', 'VOM'], * costs.at["waste CHP CC", "efficiency"],
efficiency=costs.at['waste CHP CC', 'efficiency'], marginal_cost=costs.at["waste CHP CC", "VOM"],
#efficiency4=costs.at['waste CHP', 'efficiency-heat'], efficiency=costs.at["waste CHP CC", "efficiency"],
efficiency2=costs.at['oil', 'CO2 intensity']*(1 - options["cc_fraction"]), # efficiency4=costs.at['waste CHP', 'efficiency-heat'],
efficiency3=costs.at['oil', 'CO2 intensity']*options["cc_fraction"], efficiency2=costs.at["oil", "CO2 intensity"] * (1 - options["cc_fraction"]),
lifetime=costs.at['waste CHP CC', 'lifetime']) efficiency3=costs.at["oil", "CO2 intensity"] * options["cc_fraction"],
lifetime=costs.at["waste CHP CC", "lifetime"],
)
else: else:
@ -2986,7 +2994,7 @@ def add_industry(n, costs):
bus3=spatial.co2.process_emissions, bus3=spatial.co2.process_emissions,
carrier="naphtha for industry", carrier="naphtha for industry",
p_nom_extendable=True, p_nom_extendable=True,
efficiency2=emitted_co2_per_naphtha*non_sequestered, efficiency2=emitted_co2_per_naphtha * non_sequestered,
efficiency3=process_co2_per_naphtha, efficiency3=process_co2_per_naphtha,
) )