Remove unnecessary helper scihub_product_ids

This commit is contained in:
heyarne 2021-02-16 17:02:06 +00:00
commit 99678b9792
5 changed files with 4973 additions and 1006 deletions

View file

@ -307,7 +307,6 @@
],
"source": [
"from tqdm.notebook import tqdm\n",
"from sentinel_helpers import scihub_product_ids\n",
"\n",
"gdf = gdf.sort_values(by='cloudcoverpercentage', ascending=False)\n",
"geometry = footprint.iloc[0].geometry\n",
@ -551,7 +550,7 @@
},
{
"cell_type": "code",
"execution_count": 11,
"execution_count": 19,
"metadata": {},
"outputs": [],
"source": [
@ -559,8 +558,8 @@
"dst_path = Path('input/raster/true_color_pipeline')\n",
"! mkdir -p {dst_path}\n",
"\n",
"subset = scihub_product_ids(gdf.loc[:idx])\n",
"downloads = api.download_all(subset, dst_path)"
"product_ids = gdf.loc[:idx, 'uuid'].values\n",
"downloads, _m _ = api.download_all(subset, dst_path)"
]
},
{

View file

@ -833,15 +833,6 @@
"! mkdir -p {dst_path}"
]
},
{
"cell_type": "code",
"execution_count": 21,
"metadata": {},
"outputs": [],
"source": [
"from sentinel_helpers import scihub_product_ids"
]
},
{
"cell_type": "code",
"execution_count": 22,
@ -908,7 +899,7 @@
}
],
"source": [
"downloads = api.download_all(scihub_product_ids(largest_intersections), dst_path)\n",
"downloads, _, _ = api.download_all(largest_intersections['uuid'].values, dst_path)\n",
"downloads"
]
},
@ -926,7 +917,7 @@
}
],
"source": [
"downloaded_bytes_total = sum(p['downloaded_bytes'] for p in downloads[0].values())\n",
"downloaded_bytes_total = sum(p['downloaded_bytes'] for p in downloads.values())\n",
"print(f'Downloaded {(downloaded_bytes_total / 1024 ** 3):.2f}GB')"
]
},

File diff suppressed because one or more lines are too long

File diff suppressed because one or more lines are too long