From 551389c6cb775df4e0bc5c59c8c03e561e0e5fa1 Mon Sep 17 00:00:00 2001 From: amsnyder <asnyder@usgs.gov> Date: Fri, 19 Jan 2024 15:40:57 -0600 Subject: [PATCH] use helpers --- ...45_time_slices_create_collection_from_zarr.ipynb | 13 +------------ 1 file changed, 1 insertion(+), 12 deletions(-) diff --git a/workflows/archive/TTU_2019_rcp45_time_slices_create_collection_from_zarr.ipynb b/workflows/archive/TTU_2019_rcp45_time_slices_create_collection_from_zarr.ipynb index cc8a0a00..ab7ccc57 100644 --- a/workflows/archive/TTU_2019_rcp45_time_slices_create_collection_from_zarr.ipynb +++ b/workflows/archive/TTU_2019_rcp45_time_slices_create_collection_from_zarr.ipynb @@ -742,18 +742,7 @@ "source": [ "# # helper to find items of wrong type\n", "# d = collection.to_dict()\n", - "# def find_paths(nested_dict, prepath=()):\n", - "# for k, v in nested_dict.items():\n", - "# try:\n", - "# path = prepath + (k,)\n", - "# if type(v) is np.float64: # found value\n", - "# yield path\n", - "# elif hasattr(v, 'items'): # v is a dict\n", - "# yield from find_paths(v, path) \n", - "# except:\n", - "# print(prepath)\n", - "\n", - "# print(*find_paths(d))" + "# print(*stac_helpers.find_paths(d))" ] }, { -- GitLab