1

I have written a Python package whose main function takes a bounding box as input, reads the according data from a data source of mine and renders it into a png image which is returned to the caller. On top of this library, one could easily add an http API or a command line interface for external usage without Python.

Now, I would like to publish my images as a WMS service so that I can view my layer using any standard WMS client like QGIS. Of course it would be possible to implement a fully compliant WMS API on top of my library, however, the specification is kind of extensive and allows for a lot of mistakes to make.

Is there any tool or library available that would do the heavy lifting of the WMS API but still can serve my own images which would be created by calling out to my Python library (using pure Python, a command line interface, an HTTP API or whatever works)?

I am aware of the following solutions and do not consider them to be suitable:

  • Use GeoServer (or MapServer or uDig or ...) to do the rendering and publish the data as WMS. The way that my images are created is out of the scope of what GeoServer's styling features are capable of. Maybe I could write my own plugin for it but this sounds kind of heavy.
  • Pre-render all possible images, put them into some folder and let that folder be served by GeoServer or similar tools. However, my data is too dynamic to be proxied for a long time and would outdate pretty quick.
  • Did you consider OGCServer? – Kirk Kuykendall May 7 at 16:18
  • There exists also this github.com/sci-wms/sci-wms – user30184 May 7 at 16:51
  • To my understanding, both of these projects require a folder of pre-rendered map tiles. Instead, I would rather like to create my image on the fly from the most recent data in my datastore. – Dirk May 8 at 12:36

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Browse other questions tagged or ask your own question.