Skip to content

Commit

Permalink
Modify default download parameters and show progress (AdrienWehrle#62)
Browse files Browse the repository at this point in the history
  • Loading branch information
AdrienWehrle authored Aug 13, 2022
1 parent 2a26209 commit 8c2dea8
Showing 1 changed file with 5 additions and 1 deletion.
6 changes: 5 additions & 1 deletion earthspy/earthspy.py
Original file line number Diff line number Diff line change
Expand Up @@ -60,6 +60,10 @@ def configure_connection(self) -> shb.SHConfig:

# setup Sentinel Hub connection
self.config = shb.SHConfig()

# modify default download parameters for batch downloads
self.config.download_timeout_seconds = 300
self.config.download_sleep_time = 20

# set credentials
self.config.sh_client_id = self.CLIENT_ID
Expand Down Expand Up @@ -837,7 +841,7 @@ def send_sentinelhub_requests(self) -> list:

# the actual Sentinel Hub download
self.outputs = shb.SentinelHubDownloadClient(config=self.config).download(
self.download_list, max_threads=20
self.download_list, max_threads=20, show_progress=True
)

# store raw folders created by Sentinel Hub API
Expand Down

0 comments on commit 8c2dea8

Please sign in to comment.