-
Notifications
You must be signed in to change notification settings - Fork 23
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Would it be feasible to provide a WMS route? #53
Comments
Yes! This should be perfectly feasible. You'll need to create a new custom router that exposes an WMS endpoint. I think for a simple WMS endpoint, it will probably be easiest to just write the GET/POST routes from scratch but you should certainly take a look at the existing implementations in OWSLib before getting started. Between @benbovy and I, we can help point you in the right direction for getting the xpublish router stuff working. |
Great Unfortunately with regard to the WMS protocol and internals I‘m merely a user and implementing this myself might be well over my head (but I’ll try to read up on it). |
I think it would be be better if xpublish doesn't rely on 3rd party servers like skinnywms in order to keep the deployment easy. Thanks to FastAPI, It should be pretty straightforward to implement the WMS API endpoints in xpublish from scratch. A good part of the work to support WMS is to properly handle plotting of the data and exporting it to a PNG/JPG image. This is something that we could delegate to a 3rd party library like Holoviews/Datashader as suggested in #50 (comment). |
Hi @iacopoff, I'm not an expert in WMS either, but it might be worth looking at those projects:
|
Hi @benbovy, great, thanks for the suggestions. I have just forked the repo. I am going to start working on it from mid July, after holidays! |
Hi @benbovy,
Does it sound correct? Are you suggesting to use Titiler for both somehow? |
Hi @iacopoff, it sounds good to me. I had a look at Titiler a while ago, I'm not sure how easy / hard would it be to reuse it instead of re-implementing the same functionality here. I guess we would need a custom subclass of rio_tiler.BaseReader subclass, which is used by Titiler router factory classes. However, |
Hi @benbovy, I have started with something simpler: an XYZ service. |
An XYZ service would be a very nice addition too and I guess it could share many things with a WMTS regarding their implementation. For the (re)projection, you may want to look at how Xarray-leaflet handles it. It think it's based on morecantile and rioxarray. |
Hi @benbovy, I think I have now something working. |
Yes please open a PR! |
If folks are looking for WMS in Xpublish, @mpiannucci has created a plugin that will give you WMS routes without creating your own router. |
Very much a work in progress, but it shows how easy the flow is with plugins |
I moved |
Hi
Recently stumbled upon this neat little library. I currently have the problem that I'm building a dashboard using streamlit and folium. On the folium map, I'd like to overlay a raster which can be achieved rather easy if this is hosted via WMS somewhere. Now, I'd like to avoid hosting this single file via something expensive as geoserver or a threads instance just for this single map.
Would it be feasible to implement a WMS access option in Xpublish? not sure about the boilerplate required for doing this... 🤷♂️
The text was updated successfully, but these errors were encountered: