add_electricity: fill max_hours also for nan values
This commit is contained in:
parent
d7ebeb3843
commit
008539d635
@ -586,7 +586,7 @@ def attach_hydro(n, costs, ppl, profile_hydro, hydro_capacities, carriers, **par
|
|||||||
# fill missing max hours to params value and
|
# fill missing max hours to params value and
|
||||||
# assume no natural inflow due to lack of data
|
# assume no natural inflow due to lack of data
|
||||||
max_hours = params.get("PHS_max_hours", 6)
|
max_hours = params.get("PHS_max_hours", 6)
|
||||||
phs = phs.replace({"max_hours": {0: max_hours}})
|
phs = phs.replace({"max_hours": {0: max_hours, np.nan: max_hours}})
|
||||||
n.madd(
|
n.madd(
|
||||||
"StorageUnit",
|
"StorageUnit",
|
||||||
phs.index,
|
phs.index,
|
||||||
|
Loading…
Reference in New Issue
Block a user