From ba3eccaf936d996b9c54241e111235cdb2520016 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Mirko=20M=C3=A4licke?= Date: Tue, 29 Oct 2024 06:35:05 +0100 Subject: [PATCH] fix type error --- delineate.py | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/delineate.py b/delineate.py index 6e69d59..c5f7e07 100644 --- a/delineate.py +++ b/delineate.py @@ -379,6 +379,10 @@ def plot_basins(suffix: str): # Iterate over the basins so that we only have # to open up each Level 2 Basin shapefile once, and handle all of the gages in it for basin in basins: + # mmaelicke: I am not why this happens or where this comes from, but for some + # of my inputs ie. on megabasin 11 or 12, basin in a float. Then, load_gdf does not work. + basin = int(basin) + # Create a dataframe of the gages_basins_join in that basins gages_in_basin = gages_basins_join[gages_basins_join["BASIN"] == basin] num_gages_in_basin = len(gages_in_basin)