Skip to main content

Module for reading spatial data files and services

Project description

GeoReader

Georeader is a module used to read common spatial data formats such as Esri ShapeFiles, GeoPackage, Geography Markup Language, CSV, GeoJSON, Web Feature Service, Esri Rest Service and Keyhole Markup Language. As well it can also hanlded compressed file type such as 7z, ZIP, KMZ files.

This module makes use of other packages to read the data such as GeoPandas, Fiona, GDAL, and FastKMl.

Basic Usage

>>> from georeader import GeoReader as gr
>>> georeader = gr("./cities_borders.gpkg")

# List layers.
>>> georeader.list_layers()
 ["Belfast", "Edinburgh", "London", ...]

# Get Layer Count
>>> georeader.get_layer_count()
 1000

# Layer Functions 
>>> layer = georeader.get_layer("Edinburgh")
>>> layer.GetName()
 "Edinburgh"
 
>>> layer.get_schema()
 ["id", "district", ...]
 
>>> layer.get_feature_count()
 1234
 
>>> type(layer.get_dataframe())
 Geopandas.Dataframe

Building Wheel file

> python .\setup.py bdist_wheel

Installation

> pip install dist/georeader-*.*.*-py3-none-any.whl

There are Some issues installing Geopandas through git so will have to install manually. Navigate to https://www.lfd.uci.edu/~gohlke/pythonlibs/ in browser and download the latest version of Fiona, Gdal and Shapely and pip install.

tested Versions

    "GDAL>=3.3.3",
    "Fiona>=1.8.2",
    "Shapely>=1.8.0"

once you have done that pip install geopandas :

> pip install geopandas

and hopefully you should be able to import georeader module as shown above.

Running the tests

Author

License

None

Project details


Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Source Distributions

No source distribution files available for this release.See tutorial on generating distribution archives.

Built Distribution

georeader-0.1.13-py3-none-any.whl (59.9 kB view hashes)

Uploaded Python 3

Supported by

AWS AWS Cloud computing and Security Sponsor Datadog Datadog Monitoring Fastly Fastly CDN Google Google Download Analytics Microsoft Microsoft PSF Sponsor Pingdom Pingdom Monitoring Sentry Sentry Error logging StatusPage StatusPage Status page