Factories#

This module contains factory functions for creating standardized objects from different data sources.

Search Factory#

sat_download.factories.search.get_landsat_8(satellite: str, name: str) SatelliteImage[source]#

Parse Landsat-8 image metadata from filename.

Parameters:
  • satellite (str) – The satellite platform name (‘Landsat-8’)

  • name (str) – The original filename containing metadata components

Returns:

A standardized satellite image object with extracted metadata

Return type:

SatelliteImage

Notes

Extracts date, satellite collection number, UUID, and tile information from standard Landsat-8 filename format.

sat_download.factories.search.get_satellite_image(collection: COLLECTIONS, data: dict) SatelliteImage[source]#

Factory function to create a SatelliteImage object based on collection type and metadata.

Parameters:
  • collection (COLLECTIONS) – The satellite collection enum indicating the source platform

  • data (dict) – Dictionary containing metadata about the satellite image

Returns:

A standardized satellite image object with extracted metadata

Return type:

SatelliteImage

Notes

This function delegates to specialized parsers for each collection type. The ‘Name’ field in the data dictionary is required for all collection types.

sat_download.factories.search.get_sentinel2(satellite: str, name: str) SatelliteImage[source]#

Parse Sentinel-2 image metadata from filename.

Parameters:
  • satellite (str) – The satellite platform name (‘Sentinel-2’)

  • name (str) – The original filename containing metadata components

Returns:

A standardized satellite image object with extracted metadata

Return type:

SatelliteImage

Notes

Extracts date, satellite brother (A/B), UUID, and tile information from standard Sentinel-2 filename format.

sat_download.factories.search.get_sentinel3(satellite: str, name: str) SatelliteImage[source]#

Parse Sentinel-3 image metadata from filename.

Parameters:
  • satellite (str) – The satellite platform name (‘Sentinel-3’)

  • name (str) – The original filename containing metadata components

Returns:

A standardized satellite image object with extracted metadata

Return type:

SatelliteImage

Notes

Extracts date, satellite brother (A/B), UUID, and tile information from standard Sentinel-3 filename format.