Download multiple images with command line


#1

Hi, so far I was able to download only one L1C products from tile info with the command line per time with the following example code:
$ sentinelhub.aws --tile 29SNC 2019-2-24 -e
I was wondering is it possible to download multiple images at the same time. The products I would like to download have the same tile info but different dates.

Thank you in advance!

Giulia


#2

Hi @giuliasent,

The command line interface of sentinelhub-py only supports downloading one Sentinel-2 product per command. To automatically download multiple products I suggest checking examples of Python code from this notebook: https://sentinelhub-py.readthedocs.io/en/latest/examples/aws_request.html

In first step you can use sentinelhub.WebFeatureService or sentinelhub.get_area_info to get a list of all dates for specific tile. Then in the second step you can use sentinelhub.AwsTileRequest to download each product.


#3

Thank you for your answer. I was already trying with the Python code, but in the AwsTileRequest I can’t find the way to input a list of dates because it returns me the error: ValueError: Time must be in format YYYY-MM-DD or YYYY-MM-DDTHH:MM:SS


#4

AwsTileRequest can only work with a single date and provides data for only a single Sentinel-2 tile. Therefore you will have to iterate over acquisition dates and for each one initialize and execute AwsTileRequest class.