CompositeFetcher
Tile fetcher that composes multiple tile fetchers
Notes
- The tile fetchers are called concurrently depending on the maximum number of threads
- If the maximum number of threads is 1, the tile fetchers are composed vertically, i.e., in sequence
- If the maximum number of threads is greater than 1, the tile fetchers are composed horizontally, i.e., in parallel
Implements the TileFetcher
protocol.
PARAMETER | DESCRIPTION |
---|---|
tile_fetchers
|
Tile fetchers
TYPE:
|
max_num_threads
|
Maximum number of threads
TYPE:
|
from_config
classmethod
Creates a composite fetcher from the configuration.
PARAMETER | DESCRIPTION |
---|---|
config
|
Configuration
TYPE:
|
RETURNS | DESCRIPTION |
---|---|
CompositeFetcher
|
Composite fetcher |
__call__
Fetches a tile from the sources.
PARAMETER | DESCRIPTION |
---|---|
coordinates
|
Coordinates (x_min, y_min) of the tile in meters
TYPE:
|
RETURNS | DESCRIPTION |
---|---|
Tile
|
Tile |
CompositeFetcherConfig
Bases: pydantic.BaseModel
Configuration for the from_config
class method of CompositeFetcher
Create the configuration from a config file
- Use null instead of None
Example
You can create the configuration from a config file.
package: 'aviary'
name: 'CompositeFetcher'
config:
tile_fetcher_configs:
- ...
...
max_num_threads: null
ATTRIBUTE | DESCRIPTION |
---|---|
tile_fetcher_configs |
Configurations of the tile fetchers
TYPE:
|
max_num_threads |
Maximum number of threads - defaults to None
TYPE:
|