4

If you wanted to collect all Sentinel satellite data for a given region of interest (ROI), say, for a given day or time frame - is there any simple way to do it? That means: Without having to download all the full images manually and cropping the ROI subset manually as well afterwards?

  • Currently I use the SentinelAPI, and in api.query, I set area_relations='Contains'. However, this obviously still downloads the full product, and allows to download only data, which contains the full ROI. Is the ROI split into two or more Sentinel datasets, no mosaicking will be carried out. Another drawback: No georeferencing/terrain correction beyond the delivered standard product is included - this needs yet to be done... – Michael Sep 11 '17 at 15:45
1

Use Google Earth Engine: https://earthengine.google.com/

You can visualize and export sentinel images for a given ROI (customizable by user input shapefile, kml, etc) in a few lines of code. There are many demos available online.

More info here https://developers.google.com/earth-engine/sentinel1

2

The latest release of ESA SNAP (6 beta) features so-called AOI monitoring.

http://step.esa.int/main/download/

It allows you to define a region of interest, schedule searching for the data and apply processing chains (as defined with the graph builder) on the data automatically. And with the new sci-hub integration you can download S1 data directly in SNAP (you enter the same user credentials as on https://scihub.copernicus.eu/).

However, I don't think that only downloading subsets works by now. The whole product is retrieved but as soon as you integrate the subset operator in your graph, only the desired area is proessed.

enter image description here

  • Oh, that sounds handy! However, when trying it, the AOI selection doesn't really work for me. At least, I cannot zoom into that worldmap somehow. Is there any method to select the AOI based on a geojson file or else? – Michael Sep 11 '17 at 15:43
1

take a look to sentinelsat https://sentinelsat.readthedocs.io/en/stable/index.html Another option is using scihub_download

0

One option to automate downloading part (but not also cropping) would be to use a combination of OpenSearch API (http://opensearch.sentinel-hub.com/resto/api/collections/Sentinel2/describe.xml) and Python downloader (https://github.com/sinergise/sentinelhub).

(disclaimer: I am coming from Sinergise, a company, which developed Sentinel Hub and both of the above mentioned freely available tools; you could also use Sentinel Hub services to do exactly what you are asking for, but those are payable)

0

sentinelloader is a Python package that attempts to tackle this problem:

With this utility you can specify the desired polygon, image resolution, band name and aproximate dates and it will do the best effort to find all tiles needed to satisfy your requirement. Then it will download minimal data by selecting just the needed .jp2 files inside Products, combine downloaded tiles, crop the combined tiles image to the polygon and cache the results, returning a GeoTIFF image with raster for the selected area.

In other words, this still downloads the full images for the band(s) that you select (instead of the entire set), and it does so in an automatic way for the given time frame. Then it also crops and mosaics as needed to fit your ROI.

This package seems to be under development, with some bugs to clear out. I tried it out under Python 3.6.7 and managed to make it work.

Install

pip install git+https://github.com/flaviostutz/sentinelloader

Note: it will install its dependencies, but the requirements seem to be missing the following: pillow and cartopy

Example (adapted) from the repo:

from sentinelloader import Sentinel2Loader
from shapely.geometry import Polygon

sl = Sentinel2Loader('/temp_dir/sentinel/cache', 'username', 'password',
                     apiUrl='https://scihub.copernicus.eu/apihub/',
                     showProgressbars=True,
                     cacheApiCalls=False, cacheTilesData=False)

area = Polygon([(-47.873796, -16.044801), (-47.933796, -16.044801),
        (-47.933796, -15.924801), (-47.873796, -15.924801)])

geoTiffs = sl.getRegionHistory(area, 'TCI', '60m',
                               '2019-01-06', '2019-01-30', daysStep=5)

for geoTiff in geoTiffs:
    print('Desired image was prepared at')
    print(geoTiff)

This example will produce 5 geotiff files with TCI's at 60 m resolution. The first is dated from 2019-01-06 and then the remaining are 5 days apart from each other (11, 16, 21, and 26).

Here is the first one:

2019-01-06-TCI-60m.tiff

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.