Drivers#
Drivers enable additional methods to be called on the EOProduct
. They are set as
driver
attribute of the EOProduct
during its initialization, using some criteria to determine the most adapted driver. The first driver having its
associated criteria matching will be used. If no driver is found, the NoDriver
criteria is used.
Criteria#
- class eodag.api.product.drivers.DriverCriteria[source]#
Driver criteria definition
-
criteria:
list
[Callable
[...
,bool
]]# Function that returns True if the driver is suitable for the given
EOProduct
-
driver:
DatasetDriver
# driver to use
-
criteria:
- eodag.api.product.drivers.DRIVERS: list[DriverCriteria]#
list of drivers and their criteria
- eodag.api.product.drivers.LEGACY_DRIVERS: list[DriverCriteria]#
list of legacy drivers and their criteria
Methods available#
- class eodag.api.product.drivers.base.DatasetDriver[source]#
Parent class for all dataset drivers.
Drivers will provide methods adapted to a given
EOProduct
related to predefined criteria.-
legacy:
DatasetDriver
# legacy driver for deprecated
get_data()
method usage
-
ASSET_KEYS_PATTERNS_ROLES:
list
[AssetPatterns
] = []# list of patterns to match asset keys and roles
- STRIP_SPECIAL_PATTERN = re.compile('^[^A-Z0-9]+|[^A-Z0-9]+$', re.IGNORECASE)#
strip non-alphanumeric characters at the beginning and end of the key
- guess_asset_key_and_roles(href, eo_product)[source]#
Guess the asset key and roles from the given href.
- get_data_address(eo_product, band)[source]#
Retrieve the address of the dataset represented by eo_product.
- Parameters:
- Return type:
- Returns:
An address for the dataset
- Raises:
- Raises:
Deprecated since version 3.1.0: Method used by deprecated
get_data()
-
legacy:
Drivers Available#
EODAG currently advertises the following drivers:
A default |
|
Generic default Driver |
|
Driver for Sentinel1 products |
|
Driver for Sentinel2 products |