sentinelhub.aws.data_safe
Module for creating .SAFE structure with data collected from AWS
- class sentinelhub.aws.data_safe.SafeProduct(product_id, tile_list=None, **kwargs)[source]
Bases:
AwsProduct
Class implementing transformation of Sentinel-2 satellite products from AWS into .SAFE structure
- Parameters:
product_id – ESA ID of the product
tile_list – list of tile names
parent_folder – location of the directory where the fetched data will be saved.
bands – List of Sentinel-2 bands for request. If parameter is set to None all bands will be used.
metafiles – List of additional metafiles available on AWS (e.g.
['metadata', 'tileInfo', 'preview/B01', 'TCI']
). If parameter is set to None the list will be set automatically.config – A custom instance of config class to override parameters from the saved configuration.
- get_requests()[source]
Creates product structure and returns list of files for download
- Returns:
list of download requests
- Return type:
Tuple[List[DownloadRequest], List[str]]
- get_safe_struct()[source]
Describes a structure inside tile folder of ESA product .SAFE structure
- Returns:
nested dictionaries representing .SAFE structure
- Return type:
dict
- get_datastrip_list()[source]
- Returns:
list of datastrips folder names and urls from productInfo.json file
- Return type:
List[Tuple[str, str]]
- get_datastrip_name(datastrip)[source]
- Parameters:
datastrip (str) – name of datastrip
- Returns:
name of datastrip folder
- Return type:
str
- class sentinelhub.aws.data_safe.SafeTile(*args, **kwargs)[source]
Bases:
AwsTile
Class implementing transformation of Sentinel-2 satellite tiles from AWS into .SAFE structure
Initialization parameters are inherited from parent class
- Parameters:
args (Any) –
kwargs (Any) –
- get_requests()[source]
Creates tile structure and returns list of files for download.
- Returns:
list of download requests for
- Return type:
Tuple[List[DownloadRequest], List[str]]
- get_safe_struct()[source]
Describes a structure inside tile folder of ESA product .SAFE structure.
- Returns:
nested dictionaries representing .SAFE structure
- Return type:
dict
- get_img_name(band, resolution=None)[source]
- Parameters:
band (str) – band name
resolution (str | None) – Specifies the resolution in case of Sentinel-2 L2A products
- Returns:
name of band image file
- Return type:
str