Giter Site home page Giter Site logo

kooppy's Introduction

KoopPy

A FeatureServer/MapServer implementation based on FastAPI, Geopandas and ArcGIS API for Python. The name is an homage to KoopJS. KoopPy tries to achieve same functionality as KoopJS (sometime ... maybe).

Currently serves .geojson, .shp, .gdb & .urltext files inside ./data and should support usage in MapViewer Classic and the new MapViewer. Styling for both FeatureServer and MapServer is implemented.

MapServer is only usable in MapViewer Classic

The API serves the data using the following routes:

  1. http://127.0.0.1:8000/DATANAME/FeatureServer
  2. http://127.0.0.1:8000/DATANAME/FeatureServer/0
  3. http://127.0.0.1:8000/DATANAME/MapServer

For .gdb every dataset inside the .gdb will become its own service. For .urltext the filename will be the service name. Simply paste a url to a dataset (e.g. geojson) into the .urltext file and KoopPy will also serve it.

Example

For the example file inside the data folder ne_110m_admin_0_countries.shp the routes would be:

  1. http://127.0.0.1:8000/ne_110m_admin_0_countries/FeatureServer
  2. http://127.0.0.1:8000/ne_110m_admin_0_countries/FeatureServer/0
  3. http://127.0.0.1:8000/ne_110m_admin_0_countries/MapServer

To view all possible API endpoints refer to the following URL: http://127.0.0.1:8000/docs

How to use

  • Clone this repository
  • Create a new conda environment using the environment.yml (Windows) or use the requirements.txt (Windows/Linux).
  • Run the conda environment
  • Serve using uvicorn (e.g. uvicorn main:app)

OR

  • use the dockerfile.

TODO:

  • Properly implement renderers
  • Implement PBF output
  • Clean up code
  • etc.

kooppy's People

Contributors

karschmidt avatar

Stargazers

 avatar

Watchers

 avatar

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.