Skip to content

Basic Usage

Rose Pearson edited this page Aug 3, 2021 · 22 revisions

geoapis is designed to be used as a library. See Package Install for installation instructions.

lidar_fetch.OpenTopography()

This class will locally download all LiDAR tiles from datasets within the specified polygon at a specified local directory.

class OpenTopography:
    """ A class to manage fetching LiDAR data from Open Topography
    API details for querying datasets within a search rectangle at:
        https://portal.opentopography.org/apidocs/#/Public/getOtCatalog
    Information for making a `bulk download` of a dataset using the AWS S3 protocol can be found by clicking on bulk
    download under any dataset.
    """

    def __init__(self, catchment_polygon: geopandas.geodataframe.GeoDataFrame,
                 cache_path: typing.Union[str, pathlib.Path], redownload_files: bool = False,
                 download_limit_gbytes: typing.Union[int, float] = 100, verbose: bool = False)

vector_fetch.Linz()

This class will locally download all vectors from the specified LINZ Data Service layer within the specified polygon at a specified local directory.

class Linz:
    """ A class to manage fetching Vector data from LINZ.
    API details at: https://www.linz.govt.nz/data/linz-data-service/guides-and-documentation/wfs-spatial-filtering
    The specified vector layer is queried each time run is called and any vectors passing though the catchment
    defined in the catchment_polygon are returned. 
    """

    def __init__(self, key: str, catchment_polygon: geopandas.geodataframe.GeoDataFrame, verbose: bool = False):
        """ Load in vector information from LINZ. Specify the layer to import during run.
        """
Clone this wiki locally