Skip to content

Commit

Permalink
tidy formatting
Browse files Browse the repository at this point in the history
  • Loading branch information
PatBall1 committed Oct 1, 2023
1 parent 1f6c1f1 commit 8d06531
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions detectree2/models/outputs.py
Original file line number Diff line number Diff line change
Expand Up @@ -454,10 +454,10 @@ def post_clean(unclean_df: gpd.GeoDataFrame,
return reclean_df.reset_index(drop=True)


def load_geopandas_dataframes(folder): # noqa:N605
def load_geopandas_dataframes(folder):
"""Load all GeoPackage files in a folder into a list of GeoDataFrames."""
all_files = glob.glob(f"{folder}/*.gpkg")
filenames = [f for f in all_files if re.match(f"{folder}/crowns_\d+\.gpkg", f)]
filenames = [f for f in all_files if re.match(rf"{folder}/crowns_\d+\.gpkg", f)]

# Load each file into a GeoDataFrame and add it to a list
geopandas_dataframes = [gpd.read_file(filename) for filename in filenames]
Expand Down

0 comments on commit 8d06531

Please sign in to comment.