Пример #1
0
def epsg_3857_from_proj4():
    """
    Return a gdal spatial reference object with
    3857 crs using the ImportFromProj4 method.
    """
    spatial_ref = SpatialReference()
    spatial_ref.ImportFromProj4('+init=epsg:3857')
    return spatial_ref
Пример #2
0
def epsg_3857_from_proj4():
    """
    Return a gdal spatial reference object with
    3857 crs using the ImportFromProj4 method.
    """
    ds_3857 = rasterio.open(epsg_3857_raster_path)
    spatial_ref = SpatialReference()
    spatial_ref.ImportFromProj4(ds_3857.crs.to_string())
    return spatial_ref