It's downloading satellite images from ESA's new Sentinel Hub API and combining them into animated gifs using pure Python.
A while ago, I completed the knowledge of collecting and preparing satellite image data from the European Space Agency's Sentinel satellites in my article titled Deep Dive into ESA's Sentinel API. Since then, ESA released a major update not seen in years to Sentinel Hub with update API access methods. Therefore, I briefly review how to get data from the current API. As an additional use case, I also show how to merge downloaded satellite image snapshots into animated gifs using pure Python. This article is intended to help you get started and engaged, with the ability to further explore the API based on specific use cases and data sets.
All images created by the author.
First, you'll need to install the Sentinelhub Python library, which you can do in a Jupyter notebook by running the following cell:
import sys
!{sys.executable} -m pip install sentinelhub --upgrade
Then you will also need register and create your access tokens. You can read the procedures here and get your account up and running on your Sentinel Hub. Panel here. The Dashboard also tells you about your data usage, including the number of free credits you have and the ability to upgrade to a premium plan. To that end, you might also be interested in reading about the different types of data layers that Sentinel Hub provides here in the section Data eyelash. In a nutshell: register in the API, log in to the Control Panel, press User Settings and g for the OAuth client button.
Let's set up our notebook:
from sentinelhub import SHConfigclient_secret = 'GEZixbNoqGcFYiFMNSLz74HrzN03rfvi'
client_id = '10e7a03e-5783-413f-a5ba-3e1a452ce742'
config = SHConfig(sh_client_id = client_id, sh_client_secret = client_secret)
Here I trust sample codes created by the Sentinel team to show you how to obtain image data for various areas. I try to make it interesting by selecting a few more…