How to avoid requests of no data for Sentinel-1 Gamma0 WCS requests


I am trying to download Gamma0 data for a given bounding box over a given time period.
I defined the layer in my configuration, and then use the Python API to issue a WCS request.


bounds=[600000.0, 5689020.0, 610980.0, 5700000.0]

bbox = BBox(bbox=bounds, crs=CRS(epsg))
time_interval = (start_date, end_date)

data_source = DataSource.SENTINEL1_IW

wcs_req = WcsRequest(layer=layer,

data = np.array(wcs_req.get_data())

data results in an array of shape [355, 549, 549, 2]. However, out of 355 acquisitions that are queried, 194 have all pixels with value 1, which I suppose should be no data. Is there a way to exclude this data from my request, in order to avoid useless requests and processing units usage, as well as reduce arrays size beforehand and speed up the request?

For other points where for example there is no descending orbit, if I query for descending data I get arrays of ones… also in this case, what should I do to avoid this? Also puzzling the fact that if there are no descending orbit, why do I get arrays?

Would it be an option to query for both ascending and descending together and separate them afterwards? Is there some metadata I can get for the WCS request to distinguish them?

Thanks :slight_smile:

Indeed I tested now to modify the layer and query for both ASCENDING and DESCENDING and indeed the arrays that were ones, where actually DESCENDING data.

So it appears that if the layer specifies either ‘ASCENDING’ or ‘DESCENDING’, the request retrieves both and then sets to no data those in the undesired orbit?

Is this the expected behavior? I would expect to only get the arrays of the orbit that I am querying for, without the nodata arrays.

I imagine that WcsRequest first executes WFS to get list of available dates and then goes for all of them…
It might be that WFS as it is implemented does not yet allow to filter by asc/desc. I guess there should be a workaround for that but not sure how at the moment.
Will think about it more, but certainly a requirement for the next version of the search API…

Thanks for the quick answer.
For my particular case, it’s fine to download both orbits, but I would need indeed a workaround to know afterwards what is what.

Hi @vitors.veg,

sentinelhub-py actually supports filtering by orbit direction since version 2.6.0. All you have to do in your code is to set

data_source = DataSource.SENTINEL1_IW_ASC

or for descending orbits

data_source = DataSource.SENTINEL1_IW_DES
1 Like