You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Line 259 in waterbodies.py: dam_height = np.nanmax([gdf["Dam_height"].iloc[i], 0.0]
(or similar parameter calculations)
Will raise np.nanmax error TypeError: '>=' not supported between instances of 'NoneType' and 'float' when rdf contains NoneType data (i.e. no data).
Applying gdf = gdf.fillna(value=np.nan) before the parameter calculation loop, will result in np.nanmax returning 0.0 like it is supposed to and prevent the error from occuring.
The text was updated successfully, but these errors were encountered:
jurianbeunk
changed the title
waterbodies.py
waterbodies.py (reservoir parameter calculation)
Jun 14, 2021
Line 259 in waterbodies.py:
dam_height = np.nanmax([gdf["Dam_height"].iloc[i], 0.0]
(or similar parameter calculations)
Will raise np.nanmax error
TypeError: '>=' not supported between instances of 'NoneType' and 'float'
whenrdf
contains NoneType data (i.e. no data).Applying
gdf = gdf.fillna(value=np.nan)
before the parameter calculation loop, will result in np.nanmax returning 0.0 like it is supposed to and prevent the error from occuring.The text was updated successfully, but these errors were encountered: