cartopy.io.srtm.SRTM3Source#

class cartopy.io.srtm.SRTM3Source(downloader=None, max_nx=3, max_ny=3)[source]#

A source of SRTM3 data, which implements Cartopy’s RasterSource interface.

Parameters:
  • downloader (cartopy.io.Downloader instance or None) – The downloader to use for the SRTM3 dataset. If None, the downloader will be taken using cartopy.io.Downloader.from_config with (‘SRTM’, ‘SRTM3’) as the target.

  • max_nx – The maximum number of x tiles to be combined when producing a wider composite for this RasterSource.

  • max_ny – The maximum number of y tiles to be combined when producing a taller composite for this RasterSource.

combined(lon_min, lat_min, nx, ny)#

Return an image and its extent for the group of nx by ny tiles starting at the given bottom left location.

crs#

The CRS of the underlying SRTM data.

downloader#

The Cartopy Downloader which can handle SRTM data. Normally, this will be a SRTMDownloader instance.

fetch_raster(projection, extent, target_resolution)#

Fetch SRTM elevation for the given projection and approximate extent.

srtm_fname(lon, lat)#

Return the filename for the given lon/lat SRTM tile (downloading if necessary), or None if no such tile exists (i.e. the tile would be entirely over water, or out of latitude range).

validate_projection(projection)#

Raise an error if this raster source cannot provide images in the specified projection.

Parameters:

projection (cartopy.crs.Projection) – The desired projection of the image.