satellitetools

Submodules

Classes

AOI

Area of interest (AOI) class.

DataSource

Data source for the data request.

S2Band

Sentinel-2 bands.

SCLClass

Sentinel-2 Scene Classification Layer (SCL) classes.

Sentinel2RequestParams

S2 data request paramaters.

Package Contents

class satellitetools.AOI(name: str, geometry: str | shapely.geometry.Polygon | shapely.geometry.MultiPolygon, geometry_crs: str, tile: str = None)[source]

Area of interest (AOI) class.

Attributes: name: str

Name of the AOI.

geometry: Union[str, Polygon]

Geometry of the AOI. Can be either a WKT string or a shapely Polygon.

geometry_crs: str

Coordinate reference system of the geometry.

tile: str

Sentinel-2 tile ID.

Initialize the AOI class.

Parameters: name: str

Name of the AOI.

geometry: Union[str, Polygon]

Geometry of the AOI. Can be either a WKT string or a shapely Polygon.

geometry_crs: str

Coordinate reference system of the geometry.

tile: str

Sentinel-2 tile ID.

name
geometry
geometry_crs
tile = None
__repr__() str[source]
class satellitetools.DataSource[source]

Bases: enum.StrEnum

Data source for the data request.

Initialize self. See help(type(self)) for accurate signature.

GEE = 'gee'
AWS = 'aws_cog'
class satellitetools.S2Band[source]

Bases: enum.StrEnum

Sentinel-2 bands.

Initialize self. See help(type(self)) for accurate signature.

B1 = 'B1'
B2 = 'B2'
B3 = 'B3'
B4 = 'B4'
B5 = 'B5'
B6 = 'B6'
B7 = 'B7'
B8 = 'B8'
B8A = 'B8A'
B9 = 'B9'
B11 = 'B11'
B12 = 'B12'
AOT = 'AOT'
WVP = 'WVP'
SCL = 'SCL'
to_aws() str[source]

Convert band name to AWS band name. Returns: —————- str

Band name in AWS.

to_gee() str[source]

Convert band name to GEE band name.

Returns:

str

Band name in GEE.

classmethod get_10m_to_20m_bands() List[S2Band][source]

Get 10-20 m bands for the band.

Returns:

List[S2Band]

List of 10-20 m bands.

classmethod get_all_bands() List[S2Band][source]

Get all bands for the band.

Returns:

List[S2Band]

List of all bands.

class satellitetools.SCLClass(*args, **kwds)[source]

Bases: enum.Enum

Sentinel-2 Scene Classification Layer (SCL) classes.

NODATA = 0
SATURATED_DEFECTIVE = 1
DARK_FEATURE_SHADOW = 2
CLOUD_SHADOW = 3
VEGETATION = 4
NOT_VEGETATED = 5
WATER = 6
UNCLASSIFIED = 7
CLOUD_MEDIUM_PROBA = 8
CLOUD_HIGH_PROBA = 9
THIN_CIRRUS = 10
SNOW_ICE = 11
class satellitetools.Sentinel2RequestParams(datestart: str, dateend: str, datasource: satellitetools.common.classes.DataSource, bands: List[S2Band] = None, target_gsd: float = 20, qi_evaluation_scale: float = 20)[source]

S2 data request paramaters.

Attributes:

datestartstr

Start date of the data request.

dateendstr

End date of the data request.

datasourceDataSource

Data source for the request.

bandsList[S2Band]

List of Sentinel-2 bands to request.

target_gsdfloat

Target ground sampling distance (GSD) in meters.

qi_evaluation_scalefloat

Quality indicator evaluation scale.

Initialize the Sentinel2RequestParams class.

Parameters:

datestartstr

Start date of the data request.

dateendstr

End date of the data request.

datasourceDataSource

Data source for the request.

bandsList[S2Band]

List of Sentinel-2 bands to request.

target_gsdfloat

Target ground sampling distance (GSD) in meters.

qi_evaluation_scalefloat

Quality indicator evaluation scale.

datestart
dateend
datasource
target_gsd = 20
qi_evaluation_scale = 20
__repr__() str[source]