Search and download Copernicus Sentinel satellite images
Online
OData attribute in older DHuS versions, such as https://coda.eumetsat.int. (#535 @valgur)filter_node
function generated by make_path_filter
so that node paths are no longer converted to lowercase before pattern matching. (#541 @avalentino)download_all()
, the initial check on already existing files now ignores server errors when determining the file name. Any existing files are still skipped when initiating the download. (#543 @joooeey)download_all()
has been completely rewritten to correctly handle server-side concurrency limits and bugs.
--fmt
to specify the format of the listed products. (#526 @avalentino)--fail-fast
option for downloading. (#532)concurrent_dl_limit
and concurrent_lta_trigger_limit
parameters to SentinelAPI
which are used to ensure that
the server-side limit for concurrent downloads (4 for scihub.copernicus.eu) and the maximum number of concurrent LTA retrievals
(set to 10 by default) are respected everywhere. (#532)lta_timeout
parameter to SentinelAPI
, which sets the maximum time to wait for products to be retrieved from the LTA.
Defaults to unlimited. (#532)dl_retry_delay
parameter to SentinelAPI
, which defaults to 10 seconds and limits the rate of download retries to give the server some time to recover. (#532)fail_fast
option to download_all()
. (#532)Downloader.download_all()
, which returns a detailed DownloadStatus
enum for each product, can now be used. (#532)download_all()
now waits for all LTA retrievals to finish before exiting. (#532)n_concurrent_dl
in download_all()
increased from 2 to 4. (#532)SentinelProductsAPI
has been merged into SentinelAPI
and will be removed in a future release. (#532)QueryLengthError
. (#524 @valgur)_get_filename
when Content-Disposition header not present (#494 @rbrishabh)download_all()
strictly tracks and limits the number of concurrent GET requests made (which includes LTA triggering) to respect server-side limits. (#532, #508 @avalentino).trigger_offline_retrieval()
(#491 @z4zz)download_all()
can now be cleanly interrupted without the downloads remaining active in the background. (#481, #532 @valgur)Downloader
class to keep the code more organized.
The existing API has been kept as-is, however. (#532)Dropped support for Python 2.7. Now setuptools requires Python >= 3.6.
--start
and --end
CLI arguments no longer use the default values of NOW-1DAY
and NOW
. (#459 @valgur)--footprints
now expects a path for the output file to be specified instead of using the previous default <--path>/search_footprints.geojson
. (#462 @valgur, #407 @IpsumCapra)--uuid
, --name
and --query
must now be repeated instead of passing a single comma-separated string.
Repeated keywords get treated as an "or" expression. (#463 @valgur)--info
(#367 @thomasyoung-audet)--location
(#372 @thomasyoung-audet)--geometry
input as a WKT or GeoJSON string (#381 @thomasyoung-audet)--quicklook
(#361 @mackland)--uuid
and --name
CLI arguments. The product IDs are now simply passed to api.query()
as a set.
As a result they no longer ignore the date range arguments (fixes #387). (#390 @valgur)--timeout
option with a default value of 60 seconds to avoid waiting indefinitely for a response. (#475 @valgur)--gnss
CLI flag to use the GNSS end-point for orbit products query and download (#441 @avalentino).setinelsat/__main__.py
(#412 @avalentino)get_stream()
(#430 @fwfichtner)sentinelsat/products.py
module providing a "product nodes" API that
allows to filter and download only selected files of the requested products
(#414 @avalentino)trigger_offline_retrieval()
. (#476 @valgur)download_quicklooks()
and download_all_quicklooks()
(#361 @mackland)SentinelAPIError
exceptions with more specific types. The new exceptions are still subclasses of SentinelAPIError
for backwards compatibility. (#285 @valgur, @dwlsalmeida)
SentinelAPIError
– the parent, catch-all exception. Only used when no other more specific exception can be applied.ServerError
– raised when the server responded in an unexpected manner, typically due to undergoing maintenance.UnauthorizedError
– raised when attempting to retrieve a product with incorrect credentials.QuerySyntaxError
– raised when the query string could not be parsed on the server side.QueryLengthError
– raised when the query string length was excessively long.InvalidKeyError
– raised when product with given key was not found on the server.InvalidChecksumError
– MD5 checksum of a local file does not match the one from the server.LTAError
– raised when triggering a retrieval from the Long Term Archive failed.LTATriggered
– raised in some cases when the product is offline and retrieval was triggered successfully.failed_products
dict returned by in .download_all()
for easier debugging (#378 @valgur)(key:value OR key:value)
format instead of the previous key:(value OR value)
format,
which for some reason took tens of seconds per query. (#390 @valgur)ValueError
immediately on the client side instead of letting the server generate it. (#390 @valgur)download()
now raises LTATriggered
or LTAError
if the requested product is offline. (#476 @valgur)
This is a workaround for the rare server-side bug of the OData info for the online status being incorrect (#467). (#469 @valgur)download_all
now returns a named tuple for clarity. (#477 @valgur)tqdm.auto
for nicer progress reporting in notebooks. (#480 @valgur)query_raw()
that was deprecated in v0.12.https://apihub.copernicus.eu/apihub/
.check_existing()
now determines the filename correctly for Sentinel-5 products. (@valgur #452)Online
field in OData response defaults to Online: True
instead of raising a KeyError
(#281 @viktorbahr)ContentGeometry
field in OData response defaults to footprint: None
instead of raising a TypeError
(#286 #325 @lukasbindreiter)black
checked by Travis-CI (#352)vcrpy
usage in unit tests with pytest-vcr
.
The pytest
command line options changed from --vcr disable
to --disable-vcr
and --vcr [use|record_new|reset]
to --vcr-record [once|record_new|all
.
See vcrpy docs <https://vcrpy.readthedocs.io/en/latest/usage.html#record-modes>
_ for details. (#283)None
or '*'
to denote no bound, for example query(date=(None, 'NOW-1YEAR'))
. If both bounds are set to unlimited, the keyword will be removed from the query. (#210)Feature
without a FeatureCollection.
(#224 @scottstanie)timeout
attribute to avoid indefinite wait on response from the server (#256, @viktorbahr)Online
, CreationDate
and IngestionDate
fields of an OData response~/.netrc
and document existing functionality in the API (#90)area_relation
query parameter documentation from 'Intersection'
to 'Intersects'
. (#225 @scottstanie)check_query_length()
logic to match the changed server-side behavior. (#230)to_geopandas()
now returns an empty GeoDataFrame for an empty product list input.[test]
and [docs]
with a single [dev]
installation extras target. (#208).travis.yml
to build fiona
and pyproj
from source for Python 3.7.pytest >= 3.6.3
required by pytest-socket
.--vcr record_new
or --vcr reset
, is now enforced by throwing a SocketBlockedError
in such cases. (#207)DHUS_USER
, DHUS_PASSWORD
and DHUS_URL
(#184, @temal-)count()
fully compatible with query()
. Irrelevant parameters are simply ignored.SENTINEL_USER
and SENTINEL_PASSWORD
are superceded by DHUS_USER
and DHUS_PASSWORD
order_by
parameter being ignored in queries that require multiple subqueries (that is, queries that return more than 100 products) (#200)check_query_length()
to reflect server-side changes.--uuid
) or filename (--name
).order_by
option to query()
which controls the fields by which the products are sorted on the server side before being returned. -o/--order-by
on the CLI.limit
the number of products returned by query()
and to set the number of products to skip via offset
. -l/--limit
on the CLI.query()
. The choices are 'Interesects', 'Contains' and 'IsWithin'.raw
parameter to query()
to append any additional raw query string to the query.count()
which quickly returns the number of products matching a query on the server without retrieving the full response.check_query_length
to check if a query will fail because of being excessively long.geojson_to_wkt()
.show_progressbars
to False
. Progressbars may be customized by overriding the _tqdm()
method.sentinel search
and sentinel download
into sentinelsat
.--user <username>
.initial_date
and end_date
parameters in query()
have been replaced with a single date
parameter that takes a tuple of start and end dates as input.check_existing
option from download()
and download_all()
. Similar functionality has been provided in the new check_files()
function.format_query_date
has been changed into a public function.query_raw()
has been merged with query()
and is deprecated. Used query(raw=...)
instead.